From 1c4311135628b53daa336821ff452292a9d063e9 Mon Sep 17 00:00:00 2001 From: 无关风月 <443237572@qq.com> Date: 星期三, 28 八月 2024 09:14:10 +0800 Subject: [PATCH] 代码提交 bug解决 --- ruoyi-modules/ruoyi-management/src/main/java/com/ruoyi/management/service/impl/SlVolumeProductionCkglServiceImpl.java | 23 +++++++++++++++-------- 1 files changed, 15 insertions(+), 8 deletions(-) diff --git a/ruoyi-modules/ruoyi-management/src/main/java/com/ruoyi/management/service/impl/SlVolumeProductionCkglServiceImpl.java b/ruoyi-modules/ruoyi-management/src/main/java/com/ruoyi/management/service/impl/SlVolumeProductionCkglServiceImpl.java index 920c0a4..33b0631 100644 --- a/ruoyi-modules/ruoyi-management/src/main/java/com/ruoyi/management/service/impl/SlVolumeProductionCkglServiceImpl.java +++ b/ruoyi-modules/ruoyi-management/src/main/java/com/ruoyi/management/service/impl/SlVolumeProductionCkglServiceImpl.java @@ -132,14 +132,20 @@ @Override public VolumeProductionCkglInfoVO getVolumeProductionCkglnfo(Long id) { - SlVolumeProductionCkgl byId = this.getById(id); VolumeProductionCkglInfoVO v= BeanUtils.copyBean(byId, VolumeProductionCkglInfoVO.class); + v.setAuthorization(byId.getAuthorizationUrl()); SlStoreManagement slStoreManagement = slStoreManagementMapper.selectById(byId.getManagementId()); v.setStoreManagementName(slStoreManagement.getStoreManagementName()); + v.setZhuren(slStoreManagement.getDirectorId()); + v.setZhuguan(slStoreManagement.getCompetentId()); + v.setGuanliyuan(slStoreManagement.getAdministratorId()); + v.setReasonsRefusal(byId.getReasonsRefusal()); SysUser data1 = sysUserClient.getSysUser(Long.valueOf(byId.getSysId())).getData(); - v.setSysName(data1.getNickName()); - v.setSysPhone(data1.getPhonenumber()); + if (data1!=null){ + v.setSysName(data1.getNickName()); + v.setSysPhone(data1.getPhonenumber()); + } return v; } @@ -147,7 +153,7 @@ public VolumeProductionCkglInventoryVO getVolumeProductionCkglInventory(Long id) { SlVolumeProductionCkgl byId = this.getById(id); VolumeProductionCkglInventoryVO vo = new VolumeProductionCkglInventoryVO(); - SysUser data = sysUserClient.getSysUser(byId.getId()).getData(); + SysUser data = sysUserClient.getSysUser(byId.getSysId()).getData(); vo.setSysPhone(data.getPhonenumber()); vo.setSysName(data.getNickName()); vo.setStartiTime(byId.getStartiTime()); @@ -221,11 +227,13 @@ wrapper1.orderByDesc(SlVolumeProductionCk::getCreateTime); List<SlVolumeProductionCk> page2 = slVolumeProductionCkMapper.selectList(wrapper1); for (SlVolumeProductionCk list : page2) { + list.setCkTime(new Date()); + slVolumeProductionCkMapper.updateById(list); SlVolumeProductionRk slVolumeProductionRk = slVolumeProductionRkMapper.selectById(list.getRkId()); Long num =slVolumeProductionRk.getRepertoryZhai()-Long.valueOf(list.getCkNum()); slVolumeProductionRk.setRepertoryZhai(num); + slVolumeProductionRk.setNewAddTime("1"); slVolumeProductionRkMapper.updateById(slVolumeProductionRk); - LambdaQueryWrapper<ManagementGoodsMaterials> wrapper2 = Wrappers.lambdaQuery(); wrapper2.eq(ManagementGoodsMaterials::getGoodsMaterialsId,list.getMaterialsId()); wrapper2.eq(ManagementGoodsMaterials::getManagementId,slVolumeProductionRk.getManagementId()); @@ -236,7 +244,7 @@ Long re1=repertoryZhai-Long.valueOf(list.getCkNum()); Integer num1= managementGoodsMaterials.getRepertoryChu()+list.getCkNum(); managementGoodsMaterials.setRepertoryZhai(re1); - managementGoodsMaterials.setCheckNum(num1); + managementGoodsMaterials.setRepertoryChu(num1); managementGoodsMaterialsMapper.updateById(managementGoodsMaterials); } } @@ -256,13 +264,12 @@ List<SlVolumeProductionCk> page2 = slVolumeProductionCkMapper.selectList(wrapper1); for (SlVolumeProductionCk list : page2) { list.setIsGh(2); + list.setGhTime(new Date()); slVolumeProductionCkMapper.updateById(list); - SlVolumeProductionRk slVolumeProductionRk = slVolumeProductionRkMapper.selectById(list.getRkId()); Long num =slVolumeProductionRk.getRepertoryZhai()+Long.valueOf(list.getGuihNum()); slVolumeProductionRk.setRepertoryZhai(num); slVolumeProductionRkMapper.updateById(slVolumeProductionRk); - LambdaQueryWrapper<ManagementGoodsMaterials> wrapper2 = Wrappers.lambdaQuery(); wrapper2.eq(ManagementGoodsMaterials::getGoodsMaterialsId,list.getMaterialsId()); wrapper2.eq(ManagementGoodsMaterials::getManagementId,slVolumeProductionRk.getManagementId()); -- Gitblit v1.7.1