Compare commits

..

2 Commits

Author SHA1 Message Date
mx
79a441234f Merge branch 'main' of http://124.236.46.74:9103/mengxu/pusong-crm into main
# Conflicts:
#	pusong-admin/src/main/resources/application-dev.yml
2024-12-31 14:42:08 +08:00
mx
95c825f2b8 bug 2024-12-31 14:34:14 +08:00
2 changed files with 16 additions and 11 deletions

View File

@ -134,17 +134,16 @@ public abstract class ApproverAbstractServiceImpl implements ApproverService {
} }
Page<PsApproverRecordVo> res = recordMapper.selectPageApproverList(pageQuery.build(), lqw, bo.getPay()); Page<PsApproverRecordVo> res = recordMapper.selectPageApproverList(pageQuery.build(), lqw, bo.getPay());
List<String> codes = res.getRecords().stream().map(PsApproverRecordVo::getContractCode).toList();
QueryWrapper<PsCompanyInfoVo> wq = Wrappers.<PsCompanyInfoVo>query()
.eq("com.del_flag", "0")
.eq("pcc.del_flag","0")
.in("pcc.contract_code", codes);
List<PsCompanyInfoVo> list = companyInfoMapper.selectContractServiceCompany(wq);
Map<String, List<PsCompanyInfoVo>> contractCompanyMap = list.stream().collect(Collectors.groupingBy(PsCompanyInfoVo::getContractCode));
if(CollectionUtils.isNotEmpty(res.getRecords())){ if(CollectionUtils.isNotEmpty(res.getRecords())){
List<String> codes = res.getRecords().stream().map(PsApproverRecordVo::getContractCode).toList();
QueryWrapper<PsCompanyInfoVo> wq = Wrappers.<PsCompanyInfoVo>query()
.eq("com.del_flag", "0")
.eq("pcc.del_flag","0")
.in("pcc.contract_code", codes);
List<PsCompanyInfoVo> list = companyInfoMapper.selectContractServiceCompany(wq);
Map<String, List<PsCompanyInfoVo>> contractCompanyMap = list.stream().collect(Collectors.groupingBy(PsCompanyInfoVo::getContractCode));
res.getRecords().forEach(item->{ res.getRecords().forEach(item->{
if (item.getContractAmount() != null) if (item.getContractAmount() != null)
item.setResidualMoney(item.getContractAmount().subtract(item.getPayMoney())); item.setResidualMoney(item.getContractAmount().subtract(item.getPayMoney()));

View File

@ -772,8 +772,14 @@ public class PsContractInfoServiceImpl implements IPsContractInfoService {
detailBos.add(item); detailBos.add(item);
for (PsContractBusinessDetailBo detailBo : item.getDetailBos()) { for (PsContractBusinessDetailBo detailBo : item.getDetailBos()) {
contractType = dictDataService.selectDict("service_project", detailBo.getBusinessProject()); String dictLabel = "";
String dictLabel = contractType.getDictLabel(); if (StringUtils.isEmpty(detailBo.getBusinessProject())){
dictLabel = detailBo.getBusinessProjectLabel();
}else{
contractType = dictDataService.selectDict("service_project", detailBo.getBusinessProject());
dictLabel = contractType.getDictLabel();
}
String remark = contractType.getRemark(); String remark = contractType.getRemark();
if (!StringUtils.isEmpty(remark)){ if (!StringUtils.isEmpty(remark)){
JSONObject jsonObject = JSONObject.parseObject(remark); JSONObject jsonObject = JSONObject.parseObject(remark);