Commit 1493e496 authored by tangwei's avatar tangwei

修改合同审批

parent 2ae62d11
......@@ -198,7 +198,7 @@ public class HouseholdContractController extends BaseController {
householdContrac.setStatus(HouseholdContractEnum.合同状态_农户已签署.getCode());
//生成填报任务
ToDoTasks toDoTasks1= new ToDoTasks ( TaskTypeStationEnum.合同填报.getCode(), householdContrac.getSequenceNbr(), "用户"+householdContrac.getPartyA()+"合同盖章",householdContrac.getDealerCode());
ToDoTasks toDoTasks1= new ToDoTasks ( TaskTypeStationEnum.合同填报.getCode(), householdContrac.getSequenceNbr(), "用户"+householdContrac.getPartyA()+"合同盖章",null);
toDoTasksServiceImpl.addToDoTasksByRole(engineering,toDoTasks1,"发起合同成功");
......
......@@ -153,8 +153,8 @@ public class QiyuesuoController extends BaseController {
wrapper4.eq(HouseholdContract::getContractLockId,CallbackDto.getContractId());
HouseholdContract householdContrac= householdContractMapper.selectOne(wrapper4);
//生成填报任务
ToDoTasks toDoTasks1= new ToDoTasks ( TaskTypeStationEnum.合同填报.getCode(), householdContrac.getSequenceNbr(), "用户"+householdContrac.getPartyA()+"合同盖章",householdContrac.getDealerCode());
toDoTasksServiceImpl.addToDoTasksByRole(engineering,toDoTasks1,"发起合同成功");
ToDoTasks toDoTasks1= new ToDoTasks ( TaskTypeStationEnum.合同填报.getCode(), householdContrac.getSequenceNbr(), "用户"+householdContrac.getPartyA()+"合同盖章",null);
toDoTasksServiceImpl.addToDoTasksByRole(engineering,toDoTasks1,"合同签字成功");
}else if("SEAL".equals(CallbackDto.getCallbackType())){
......
......@@ -72,7 +72,6 @@ public class HouseholdContractServiceImpl extends BaseService<HouseholdContractD
qw.eq(dto.getPeasantHouseholdId()!=null, "peasant_household_id",dto.getPeasantHouseholdId() );
qw.eq(dto.getDealerId()!=null, "dealer_id",dto.getDealerId() );
qw.eq(StringUtils.isNotEmpty(dto.getInitiateStatus()), "initiate_status",dto.getInitiateStatus() );
qw.eq(StringUtils.isNotEmpty(dto.getSurveyStatus()), "survey_status",dto.getSurveyStatus() );
qw.eq(StringUtils.isNotEmpty(dto.getSignStatus()), "sign_status",dto.getSignStatus() );
qw.eq(StringUtils.isNotEmpty(dto.getUserId()), "project_user_id",dto.getUserId() );
......
......@@ -192,7 +192,7 @@ public class PowerStationServiceImpl extends BaseService<PowerStationDto, PowerS
String result = String.valueOf(kv.get("approvalStatue"));
boolean flag = true;
if (PowerStationNodeEnum.设计上传图纸.getCode().equals(nodeCode)||PowerStationNodeEnum.经销商上传图纸.getCode().equals(nodeCode)) {
this.updateSeve(powerStation.getPeasantHouseholdId(),kv);
this.updateSeve(nodeCode,powerStation.getPeasantHouseholdId(),kv);
} else {
if (VERIFY_RESULT_NO.equals(result)) {
......@@ -314,21 +314,36 @@ public class PowerStationServiceImpl extends BaseService<PowerStationDto, PowerS
// 设计信息填充
public void updateSeve(String peasantHouseholdId, Map<String, Object> kv ){
public void updateSeve(String nodeCode,String peasantHouseholdId, Map<String, Object> kv ){
LambdaQueryWrapper<DesignInformation> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(DesignInformation::getPeasantHouseholdId, peasantHouseholdId);
DesignInformation designInformation=designInformationMapper.selectOne(wrapper);
if(designInformation!=null){
DesignInformation designInformationnew=this.mapToBean(kv,DesignInformation.class);
designInformationnew.setTypicalDiagram(designInformation.getTypicalDiagram());
if (PowerStationNodeEnum.经销商上传图纸.getCode().equals(nodeCode)) {
designInformation.setPeasantHouseholdId(peasantHouseholdId);
designInformation.setComponentLayout(designInformationnew.getComponentLayout());
designInformation.setComponentBracket(designInformationnew.getComponentBracket());
designInformation.setConnectionLine(designInformationnew.getConnectionLine());
designInformation.setOnceLine(designInformationnew.getOnceLine());
designInformationMapper.updateById(designInformation);
}else{
// designInformationnew.setTypicalDiagram(designInformationnew.getTypicalDiagram());
designInformationnew.setPeasantHouseholdId(peasantHouseholdId);
designInformationnew.setComponentLayout(designInformation.getComponentLayout());
designInformationnew.setComponentBracket(designInformation.getComponentBracket());
designInformationnew.setConnectionLine(designInformation.getConnectionLine());
designInformationnew.setOnceLine(designInformation.getOnceLine());
designInformationnew.setSequenceNbr(designInformation.getSequenceNbr());
designInformationnew.setRecDate(designInformation.getRecDate());
designInformationnew.setRecUserId(designInformation.getRecUserId());
designInformationnew.setRecUserName(designInformation.getRecUserName());
designInformationnew.setIsDelete(designInformation.getIsDelete());
designInformationMapper.updateById(designInformationnew);
}
}else{
DesignInformation designInformationnew=this.mapToBean(kv,DesignInformation.class);
designInformationnew.setTypicalDiagram((List<Object>)kv.get("typicalDiagram")) ;
......
......@@ -347,19 +347,21 @@ public class SurveyInformationServiceImpl extends BaseService<SurveyInformationD
QueryWrapper<Commercial> commercialQueryWrapper = new QueryWrapper<>();
commercialQueryWrapper.eq("survey_information_id", surveyInformationId);
Commercial commercial = commercialService.getBaseMapper().selectOne(commercialQueryWrapper);
commercial.setApplicant(surveyInfoAllDto.getSurveyInformation().getOwnersName());
commercial.setIdCard(surveyInfoAllDto.getSurveyInformation().getIdCard());
commercial.setTelephone(surveyInfoAllDto.getSurveyInformation().getTelephone());
commercial.setProjectAddress(surveyInfoAllDto.getSurveyInformation().getProjectAddress());
commercial.setProjectAddressName(surveyInfoAllDto.getSurveyInformation().getProjectAddressName());
commercial.setProjectAddressDetail(surveyInfoAllDto.getSurveyInformation().getProjectAddressDetail());
commercial.setLegalContactTelephone(surveyInfoAllDto.getSurveyInformation().getTelephone());
if(commercial==null){
commercial=new Commercial();
}
commercial.setApplicant(peasantHousehold.getOwnersName());
commercial.setIdCard(peasantHousehold.getIdCard());
commercial.setTelephone(peasantHousehold.getTelephone());
commercial.setProjectAddress(peasantHousehold.getProjectAddress());
commercial.setProjectAddressName(peasantHousehold.getProjectAddressName());
commercial.setProjectAddressDetail(peasantHousehold.getProjectAddressDetail());
commercial.setLegalContactTelephone(peasantHousehold.getTelephone());
if(information == null){
CommercialDto commercialDto = new CommercialDto();
CommercialDto commercialDto = BeanDtoUtils.convert(commercial, CommercialDto.class);
commercialDto.setType("zrr");
commercialDto.setLegalType("zjdnhw");
surveyInfoAllDto.setCommercial(commercialDto);
......@@ -414,13 +416,19 @@ public class SurveyInformationServiceImpl extends BaseService<SurveyInformationD
FeignClientResult<Collection<RegionModel>> collectionFeignClientResult = Systemctl.regionClient.queryForTreeParent(610000L);
Collection<RegionModel> result = collectionFeignClientResult.getResult();
for (RegionModel regionModel : result) {
if(regionModel.getChildren()!=null&&!regionModel.getChildren().isEmpty()){
for (RegionModel child : regionModel.getChildren()) {
if(child.getChildren()!=null&&!child.getChildren().isEmpty()){
for (RegionModel childChild : child.getChildren()) {
jsonArray.add(childChild);
}
child.setChildren(regionChild);
jsonArray.add(child);
}
}
}
regionModel.setChildren(regionChild);
jsonArray.add(regionModel);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment