Showing
1 changed file
with
9 additions
and
2 deletions
xingyun-sc/src/main/java/com/lframework/xingyun/sc/controller/order/PurchaseOrderInfoController.java
| ... | ... | @@ -298,8 +298,15 @@ public class PurchaseOrderInfoController extends DefaultBaseController { |
| 298 | 298 | if (contract == null) { |
| 299 | 299 | throw new DefaultClientException("合同不存在!"); |
| 300 | 300 | } |
| 301 | - Boolean standardStandardized = contract.getStandardStandardized(); | |
| 302 | - if (!BooleanUtils.isTrue(standardStandardized)) { | |
| 301 | + String contractType = contract.getType(); | |
| 302 | + if (("DISTRIB_STD".equals(contractType) || "INTL_STD_CONTRACT".equals(contractType) || "PROCESS_STD_AGMT".equals(contractType) | |
| 303 | + || "DRAFT_DIST_AGMT".equals(contractType) || "INTL_OPEN_SPEC_AGMT".equals(contractType)) | |
| 304 | + && !"PASS".equals(contract.getStandardApproved())) { | |
| 305 | + // 标准、未锁规合同 | |
| 306 | + throw new DefaultClientException("合同不规范,请补充!"); | |
| 307 | + } else if (("DIST_STOCK_CONTRACT".equals(contractType) || "INTL_INVENTORY_AGMT".equals(contractType)) | |
| 308 | + && !"PASS".equals(contract.getFormalApproved())) { | |
| 309 | + // 库存合同 | |
| 303 | 310 | throw new DefaultClientException("合同不规范,请补充!"); |
| 304 | 311 | } |
| 305 | 312 | return InvokeResultBuilder.success(); | ... | ... |