This commit is contained in:
zt
2025-08-30 02:05:48 +08:00
parent d46f672b9a
commit 8a29ffdd2e
5 changed files with 63 additions and 16 deletions

View File

@ -208,4 +208,18 @@ public class BusContactnoticeServiceImpl implements IBusContactnoticeService {
} }
this.deleteWithValidByIds(Collections.singleton(contactnotice.getId()), true); this.deleteWithValidByIds(Collections.singleton(contactnotice.getId()), true);
} }
@EventListener(condition = "#processEvent.flowCode.endsWith('contactForm')")
public void contactFormProcessHandler(ProcessEvent processEvent) {
log.info("联系单审核任务执行了{}", processEvent.toString());
BusContactnotice contactnotice = baseMapper.selectById(Convert.toLong(processEvent.getBusinessId()));
contactnotice.setStatus(processEvent.getStatus());
if (processEvent.getSubmit()) {
contactnotice.setStatus(BusinessStatusEnum.WAITING.getStatus());
}
baseMapper.updateById(contactnotice);
}
} }

View File

@ -77,4 +77,7 @@ public class DesVolumeFileBo extends BaseEntity {
*/ */
private String documentName; private String documentName;
private String auditStatus;
} }

View File

@ -125,28 +125,46 @@ public class DesVolumeFileServiceImpl extends ServiceImpl<DesVolumeFileMapper, D
desVolumeFileCodeVo.setProjectName(byId.getProjectName()); desVolumeFileCodeVo.setProjectName(byId.getProjectName());
desVolumeFileCodeVo.setType(desVolumeFile.getType()); desVolumeFileCodeVo.setType(desVolumeFile.getType());
if("3".equals(desVolumeFile.getType())){
//查询图纸最新版
List<DesVolumeFile> existingFiles = baseMapper.selectList(new LambdaQueryWrapper<DesVolumeFile>()
.eq(DesVolumeFile::getVolumeCatalogId, desVolumeFile.getVolumeCatalogId())
.eq(DesVolumeFile::getType, "3")
.orderByDesc(DesVolumeFile::getVersion));
if(CollectionUtil.isNotEmpty(existingFiles)){
DesVolumeFile desVolumeFile1 = existingFiles.getFirst();
if(!desVolumeFile1.getId().equals(id)){
SysOssVo ossVo = ossService.getById(desVolumeFile1.getFileId());
desVolumeFileCodeVo.setFileUrl(ossVo.getUrl());
}else {
desVolumeFileCodeVo.setIsLatest(true);
}
}
}
//查询过程图纸最新版 //查询过程图纸最新版
List<DesVolumeFile> existingFiles = baseMapper.selectList(new LambdaQueryWrapper<DesVolumeFile>() List<DesVolumeFile> existingFiles = baseMapper.selectList(new LambdaQueryWrapper<DesVolumeFile>()
.eq(DesVolumeFile::getVolumeCatalogId, desVolumeFile.getVolumeCatalogId()) .eq(DesVolumeFile::getVolumeCatalogId, desVolumeFile.getVolumeCatalogId())
.eq(DesVolumeFile::getType, "1") .eq(DesVolumeFile::getType, "1")
.orderByDesc(DesVolumeFile::getVersion)); .orderByDesc(DesVolumeFile::getVersion));
DesVolumeFile first = existingFiles.getFirst(); if(!existingFiles.isEmpty()){
DesVolumeFile first = existingFiles.getFirst();
if ("4".equals(desVolumeFile.getType())) { if ("4".equals(desVolumeFile.getType())) {
SysOssVo ossVo = ossService.getById(first.getFileId());
desVolumeFileCodeVo.setFileUrl(ossVo.getUrl());
}
if ("1".equals(desVolumeFile.getType())) {
if (!first.getId().equals(id)) {
desVolumeFileCodeVo.setIsLatest(false);
SysOssVo ossVo = ossService.getById(first.getFileId()); SysOssVo ossVo = ossService.getById(first.getFileId());
desVolumeFileCodeVo.setFileUrl(ossVo.getUrl()); desVolumeFileCodeVo.setFileUrl(ossVo.getUrl());
} else {
desVolumeFileCodeVo.setIsLatest(true);
} }
if ("1".equals(desVolumeFile.getType())) {
if (!first.getId().equals(id)) {
desVolumeFileCodeVo.setIsLatest(false);
SysOssVo ossVo = ossService.getById(first.getFileId());
desVolumeFileCodeVo.setFileUrl(ossVo.getUrl());
} else {
desVolumeFileCodeVo.setIsLatest(true);
}
}
} }
return desVolumeFileCodeVo; return desVolumeFileCodeVo;
@ -393,6 +411,7 @@ public class DesVolumeFileServiceImpl extends ServiceImpl<DesVolumeFileMapper, D
return null; return null;
}); });
} }
desVolumeFile.setFileId(null);
this.updateById(desVolumeFile); this.updateById(desVolumeFile);
} }
@ -455,6 +474,7 @@ public class DesVolumeFileServiceImpl extends ServiceImpl<DesVolumeFileMapper, D
return null; return null;
}); });
} }
desVolumeFile.setFileId(null);
this.updateById(desVolumeFile); this.updateById(desVolumeFile);
} }

View File

@ -357,9 +357,19 @@ public class OutMonthPlanServiceImpl extends ServiceImpl<OutMonthPlanMapper, Out
if("2".equals(outMonthPlan.getValueType())){ //采购产值 if("2".equals(outMonthPlan.getValueType())){ //采购产值
//todo: 罗成没写完 PurchaseValueAReq purchaseValueAReq = new PurchaseValueAReq();
BigDecimal bigDecimal = busMaterialsorderService.grossOutput(outMonthPlan.getProjectId(), outMonthPlan.getPlanMonth(), 0); purchaseValueAReq.setProjectId(outMonthPlan.getProjectId());
outMonthPlan.setCompleteValue(bigDecimal); purchaseValueAReq.setType(outMonthPlan.getType());
purchaseValueAReq.setPlanMonth(outMonthPlan.getPlanMonth());
List<BusProcurement> busProcurements =purchaseValueA(purchaseValueAReq);
BigDecimal purchaseValue = BigDecimal.ZERO;
for (BusProcurement busProcurement : busProcurements) {
if(busProcurement != null && busProcurement.getAcceptedQuantity() != null && busProcurement.getUnitPrice() != null){
purchaseValue = purchaseValue.add(busProcurement.getAcceptedQuantity().multiply(busProcurement.getUnitPrice()));
}
}
outMonthPlan.setCompleteValue(purchaseValue);
}else if("3".equals(outMonthPlan.getValueType())){ //施工产值 }else if("3".equals(outMonthPlan.getValueType())){ //施工产值
//查询项目的审核通过的施工详细表 1.累计完成产值 2.完成产值月合计 3.各周完成产值 //查询项目的审核通过的施工详细表 1.累计完成产值 2.完成产值月合计 3.各周完成产值
List<OutConstructionValue> outConstructionValues = constructionValueService.lambdaQuery() List<OutConstructionValue> outConstructionValues = constructionValueService.lambdaQuery()

View File

@ -8,7 +8,7 @@
select f.*, c.design_subitem, c.specialty, c.volume_number, c.document_name, c.principal select f.*, c.design_subitem, c.specialty, c.volume_number, c.document_name, c.principal
from des_volume_file f from des_volume_file f
left join des_volume_catalog c on f.volume_catalog_id = c.design left join des_volume_catalog c on f.volume_catalog_id = c.design
WHERE c.project_id = #{bo.projectId} and f.type = #{bo.type} WHERE c.project_id = #{bo.projectId} and f.type = #{bo.type} and f.audit_status = #{bo.auditStatus}
<if test="bo.volumeNumber != null and bo.volumeNumber != '' "> <if test="bo.volumeNumber != null and bo.volumeNumber != '' ">
AND c.volume_number like concat('%',#{bo.volumeNumber},'%') AND c.volume_number like concat('%',#{bo.volumeNumber},'%')
</if> </if>