diff --git a/bonus-modules/bonus-material/src/main/java/com/bonus/material/settlement/controller/SltAgreementInfoController.java b/bonus-modules/bonus-material/src/main/java/com/bonus/material/settlement/controller/SltAgreementInfoController.java index 1f6d388e..f0cf3fab 100644 --- a/bonus-modules/bonus-material/src/main/java/com/bonus/material/settlement/controller/SltAgreementInfoController.java +++ b/bonus-modules/bonus-material/src/main/java/com/bonus/material/settlement/controller/SltAgreementInfoController.java @@ -1596,8 +1596,8 @@ public class SltAgreementInfoController extends BaseController { @ApiOperation(value = "结算审批列表") @GetMapping("/getSltList") public TableDataInfo getSltList(SltAgreementInfo bean) { -// Long deptId = typeService.getUserDeptId(); -// bean.setCompanyId(deptId); + Long deptId = typeService.getUserDeptId(); + bean.setCompanyId(deptId); startPage(); List list = sltAgreementInfoService.getSltList(bean); return getDataTable(list); diff --git a/bonus-modules/bonus-material/src/main/java/com/bonus/material/settlement/service/impl/SltAgreementInfoServiceImpl.java b/bonus-modules/bonus-material/src/main/java/com/bonus/material/settlement/service/impl/SltAgreementInfoServiceImpl.java index 0cada512..a972d2ea 100644 --- a/bonus-modules/bonus-material/src/main/java/com/bonus/material/settlement/service/impl/SltAgreementInfoServiceImpl.java +++ b/bonus-modules/bonus-material/src/main/java/com/bonus/material/settlement/service/impl/SltAgreementInfoServiceImpl.java @@ -731,17 +731,17 @@ public class SltAgreementInfoServiceImpl implements ISltAgreementInfoService { UUID uuid = UUID.randomUUID(); String sltTask = uuid.toString(); String sltAuditor = null; - if(GlobalConstants.LONG_JJ == deptId){ + if(101 == deptId){ if (sltInfoVo.getSettlementType() == null) { sltAuditor = "待张志峰,刘春杰审核"; } else if (sltInfoVo.getSettlementType() == 1) { - sltAuditor = "待张志峰审核"; + sltAuditor = "待张志峰或李靖涛审核"; }else if (sltInfoVo.getSettlementType() == 2) { sltAuditor = "待刘春杰审核"; }else{ sltAuditor = "待审核"; } - }else if(GlobalConstants.LONG_HY == deptId){ + }else if(309 == deptId){ sltAuditor = "顾国强或王文斌审核"; }else{ sltAuditor = "待审核"; @@ -878,33 +878,25 @@ public class SltAgreementInfoServiceImpl implements ISltAgreementInfoService { sltInfoVo.setUpdateTime(DateUtils.getNowDate()); } if (sltInfoVo !=null) { - List filteredLeaseList = getLeaseList(info).stream() - .filter(lease -> lease.getAgreementId().equals(sltInfoVo.getAgreementId())) - .collect(Collectors.toList()); + List filteredLeaseList = new ArrayList<>(getLeaseList(info)); if (!filteredLeaseList.isEmpty()) { sltAgreementInfoMapper.insertSltAgreementDetailLease(filteredLeaseList, id); } } if (sltInfoVo !=null) { - List filteredRepairList = getRepairList(info).stream() - .filter(lease -> lease.getAgreementId().equals(sltInfoVo.getAgreementId())) - .collect(Collectors.toList()); + List filteredRepairList = new ArrayList<>(getRepairList(info)); if (!filteredRepairList.isEmpty()) { sltAgreementInfoMapper.insertSltAgreementDetailRepair(filteredRepairList, id); } } if (sltInfoVo !=null) { - List filteredScrapList = getScrapList(info).stream() - .filter(lease -> lease.getAgreementId().equals(sltInfoVo.getAgreementId())) - .collect(Collectors.toList()); + List filteredScrapList = new ArrayList<>(getScrapList(info)); if (!filteredScrapList.isEmpty()) { sltAgreementInfoMapper.insertSltAgreementDetailScrap(filteredScrapList, id); } } if (sltInfoVo !=null) { - List filteredLoseList = getLoseList(info).stream() - .filter(lease -> lease.getAgreementId().equals(sltInfoVo.getAgreementId())) - .collect(Collectors.toList()); + List filteredLoseList = new ArrayList<>(getLoseList(info)); if (!filteredLoseList.isEmpty()) { sltAgreementInfoMapper.insertSltAgreementDetailLose(filteredLoseList, id); } @@ -1212,6 +1204,9 @@ public class SltAgreementInfoServiceImpl implements ISltAgreementInfoService { if(checkSettlementType == 1 && "73".equals(userId)){ sltSwitch = true; } + if(checkSettlementType == 1 && "422".equals(userId)){ + sltSwitch = true; + } if(checkSettlementType == 2 && "1549".equals(userId)){ sltSwitch = true; } diff --git a/bonus-modules/bonus-material/src/main/resources/mapper/material/settlement/SltAgreementInfoMapper.xml b/bonus-modules/bonus-material/src/main/resources/mapper/material/settlement/SltAgreementInfoMapper.xml index 1dca036a..1020a9ef 100644 --- a/bonus-modules/bonus-material/src/main/resources/mapper/material/settlement/SltAgreementInfoMapper.xml +++ b/bonus-modules/bonus-material/src/main/resources/mapper/material/settlement/SltAgreementInfoMapper.xml @@ -584,6 +584,7 @@ create_time, status, cost, + company_id, #{agreementId}, @@ -594,6 +595,7 @@ #{createTime}, 1, #{totalCostAll}, + #{companyId},