user30
This commit is contained in:
+2
-1
@@ -982,7 +982,8 @@ public class ContractManageApplicationService {
|
|||||||
&& Objects.equals(item.getContractType(), contractType))
|
&& Objects.equals(item.getContractType(), contractType))
|
||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
if (contractManagePOs != null && contractManagePOs.size() > 1) {
|
if (contractManagePOs != null && contractManagePOs.size() > 1) {
|
||||||
throw new ServiceException("存在多条相同费用科目的合同,请检查");
|
resultContract.setIsMany("1");
|
||||||
|
return resultContract;
|
||||||
}
|
}
|
||||||
if(contractManagePOList != null && contractManagePOList.size()>0){
|
if(contractManagePOList != null && contractManagePOList.size()>0){
|
||||||
if(StringUtils.isNotEmpty(settlementCustomersCode)){
|
if(StringUtils.isNotEmpty(settlementCustomersCode)){
|
||||||
|
|||||||
+1
-1
@@ -183,5 +183,5 @@ public class ContractManagePO extends BaseVOEntity{
|
|||||||
|
|
||||||
@ApiModelProperty(name = "是否包含运输费用(1-包含,2-包含)")
|
@ApiModelProperty(name = "是否包含运输费用(1-包含,2-包含)")
|
||||||
private Integer transportationCosts;
|
private Integer transportationCosts;
|
||||||
|
private String isMany;
|
||||||
}
|
}
|
||||||
+5
-1
@@ -618,7 +618,7 @@ public class BusinessDocumentApplicationService {
|
|||||||
if(businessDocumentDO.getBelongModuleCode().equals(BelongModuleCode.WMS.getCode())){
|
if(businessDocumentDO.getBelongModuleCode().equals(BelongModuleCode.WMS.getCode())){
|
||||||
contractType = 1;
|
contractType = 1;
|
||||||
}
|
}
|
||||||
AjaxResult ajaxResult = systemServiceFeign.getInfoByCustomerAndSecondSubjectCode(businessDocumentDO.getSettlementCustomersCode(),contractType,businessDocumentDO.getFirstSubjectCode(),businessDocumentDO.getTopOrganizationId(),businessDocumentDO.getOrganizationId());
|
AjaxResult ajaxResult = systemServiceFeign.getInfoByCustomerAndSecondSubjectCode(businessDocumentDO.getSettlementCustomersCode(),contractType,businessDocumentDO.getFirstSubjectCode() != null ?businessDocumentDO.getFirstSubjectCode():businessDocumentDO.getSecondSubjectCode(),businessDocumentDO.getTopOrganizationId(),businessDocumentDO.getOrganizationId());
|
||||||
if(!"200".equals(String.valueOf(ajaxResult.get("code")))) {
|
if(!"200".equals(String.valueOf(ajaxResult.get("code")))) {
|
||||||
throw new ServiceException("合同信息未找到");
|
throw new ServiceException("合同信息未找到");
|
||||||
}
|
}
|
||||||
@@ -626,6 +626,10 @@ public class BusinessDocumentApplicationService {
|
|||||||
if (null == contractPO) {
|
if (null == contractPO) {
|
||||||
throw new ServiceException("合同信息未找到");
|
throw new ServiceException("合同信息未找到");
|
||||||
}
|
}
|
||||||
|
String isMany = contractPO.getIsMany();
|
||||||
|
if ("1".equals(isMany)) {
|
||||||
|
throw new ServiceException("存在多条相同费用科目的合同,请检查");
|
||||||
|
}
|
||||||
businessDocumentDO.setContractName(contractPO.getContractName());
|
businessDocumentDO.setContractName(contractPO.getContractName());
|
||||||
businessDocumentDO.setContractNumber(contractPO.getContractNumber());
|
businessDocumentDO.setContractNumber(contractPO.getContractNumber());
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -169,4 +169,6 @@ public class ContractManagePO extends BaseVOEntity{
|
|||||||
@ApiModelProperty(name = "主体类型(1-货主,2-客户,3-承运商)")
|
@ApiModelProperty(name = "主体类型(1-货主,2-客户,3-承运商)")
|
||||||
private Integer principalType;
|
private Integer principalType;
|
||||||
|
|
||||||
|
private String isMany;
|
||||||
|
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user