|
@@ -211,22 +211,25 @@ public class ContractInfoService {
|
|
|
//对参与签约方进行操作
|
|
|
participantMapper.deleteFromParticipant(info.getId());
|
|
|
//在操作前,清空之前的信息
|
|
|
- if (info.getCwWorkClientContactDTOList().size()>0){
|
|
|
- info.getCwWorkClientContactDTOList().forEach(cw->{
|
|
|
-
|
|
|
- String parId = UUID.randomUUID().toString().replace("-", "");
|
|
|
- participant.setId(parId);
|
|
|
- participant.setContractInfoId(info.getId());
|
|
|
- participant.setCustomerName(cw.getName());
|
|
|
- participant.setCustomerNo(cw.getNo());
|
|
|
- participant.setCreateBy(userDTO.getId());
|
|
|
- participant.setCreateDate(new Date());
|
|
|
- participant.setUpdateBy(userDTO.getId());
|
|
|
- participant.setUpdateDate(new Date());
|
|
|
- participantMapper.insert(participant);
|
|
|
- });
|
|
|
+ if (info.getCwWorkClientContactDTOList() != null){
|
|
|
+ if (info.getCwWorkClientContactDTOList().size()>0){
|
|
|
+ info.getCwWorkClientContactDTOList().forEach(cw->{
|
|
|
+
|
|
|
+ String parId = UUID.randomUUID().toString().replace("-", "");
|
|
|
+ participant.setId(parId);
|
|
|
+ participant.setContractInfoId(info.getId());
|
|
|
+ participant.setCustomerName(cw.getName());
|
|
|
+ participant.setCustomerNo(cw.getNo());
|
|
|
+ participant.setCreateBy(userDTO.getId());
|
|
|
+ participant.setCreateDate(new Date());
|
|
|
+ participant.setUpdateBy(userDTO.getId());
|
|
|
+ participant.setUpdateDate(new Date());
|
|
|
+ participantMapper.insert(participant);
|
|
|
+ });
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
+
|
|
|
List<WorkAttachmentDto> list = info.getContractProperList();
|
|
|
if (CollectionUtils.isNotEmpty(list)) {
|
|
|
updateFiles(list, userDTO, info.getId());
|
|
@@ -259,19 +262,21 @@ public class ContractInfoService {
|
|
|
//对参与签约方进行操作
|
|
|
participantMapper.deleteFromParticipant(info.getId());
|
|
|
ContractParticipant participant = new ContractParticipant();
|
|
|
- if (info.getCwWorkClientContactDTOList().size()>0){
|
|
|
- info.getCwWorkClientContactDTOList().forEach(cw->{
|
|
|
- String parId = UUID.randomUUID().toString().replace("-", "");
|
|
|
- participant.setId(parId);
|
|
|
- participant.setContractInfoId(id);
|
|
|
- participant.setCustomerName(cw.getName());
|
|
|
- participant.setCustomerNo(cw.getNo());
|
|
|
- participant.setCreateBy(userDTO.getId());
|
|
|
- participant.setCreateDate(new Date());
|
|
|
- participant.setUpdateBy(userDTO.getId());
|
|
|
- participant.setUpdateDate(new Date());
|
|
|
- participantMapper.insert(participant);
|
|
|
- });
|
|
|
+ if (info.getCwWorkClientContactDTOList() != null){
|
|
|
+ if (info.getCwWorkClientContactDTOList().size()>0){
|
|
|
+ info.getCwWorkClientContactDTOList().forEach(cw->{
|
|
|
+ String parId = UUID.randomUUID().toString().replace("-", "");
|
|
|
+ participant.setId(parId);
|
|
|
+ participant.setContractInfoId(id);
|
|
|
+ participant.setCustomerName(cw.getName());
|
|
|
+ participant.setCustomerNo(cw.getNo());
|
|
|
+ participant.setCreateBy(userDTO.getId());
|
|
|
+ participant.setCreateDate(new Date());
|
|
|
+ participant.setUpdateBy(userDTO.getId());
|
|
|
+ participant.setUpdateDate(new Date());
|
|
|
+ participantMapper.insert(participant);
|
|
|
+ });
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
List<WorkAttachmentDto> list = contractInfo.getContractProperList();
|