|
@@ -0,0 +1,66 @@
|
|
|
+package com.fjhx.sale.flow;
|
|
|
+
|
|
|
+import com.alibaba.fastjson.JSONObject;
|
|
|
+import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
|
|
|
+import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
|
|
|
+import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
|
+import com.fjhx.flow.core.FlowDelegate;
|
|
|
+import com.fjhx.purchase.entity.purchase.enums.PurchaseDataResourceEnum;
|
|
|
+import com.fjhx.purchase.entity.purchase.enums.PurchaseDetailStatusEnum;
|
|
|
+import com.fjhx.purchase.entity.purchase.enums.PurchaseStatusEnum;
|
|
|
+import com.fjhx.purchase.entity.purchase.po.Purchase;
|
|
|
+import com.fjhx.purchase.entity.purchase.po.PurchaseDetail;
|
|
|
+import com.fjhx.purchase.service.purchase.PurchaseDetailService;
|
|
|
+import com.fjhx.purchase.service.purchase.PurchaseService;
|
|
|
+import com.fjhx.purchase.util.code.CodeEnum;
|
|
|
+import com.fjhx.sale.entity.contract.po.ContractProduct;
|
|
|
+import com.fjhx.sale.service.contract.ContractProductService;
|
|
|
+import com.obs.services.internal.ServiceException;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.stereotype.Component;
|
|
|
+
|
|
|
+import java.math.BigDecimal;
|
|
|
+import java.util.ArrayList;
|
|
|
+import java.util.Date;
|
|
|
+import java.util.List;
|
|
|
+
|
|
|
+/**
|
|
|
+ * 采购流程
|
|
|
+ *
|
|
|
+ * @Author:caozj
|
|
|
+ * @DATE:2023/4/3 17:38
|
|
|
+ */
|
|
|
+@Component
|
|
|
+public class PurchaseFlowByWdly extends FlowDelegate {
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private PurchaseFlow purchaseFlow;
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public String getFlowKey() {
|
|
|
+ return "wdly_purchase";
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 发起流程
|
|
|
+ * @param flowId 流程ID
|
|
|
+ * @param submitData 采购数据
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ @Override
|
|
|
+ public Long start(Long flowId, JSONObject submitData) {
|
|
|
+ return purchaseFlow.start(flowId,submitData);
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 结束流程
|
|
|
+ * @param flowId 流程ID
|
|
|
+ * @param businessId 业务ID
|
|
|
+ * @param submitData 数据
|
|
|
+ */
|
|
|
+ @Override
|
|
|
+ public void end(Long flowId, Long businessId, JSONObject submitData) {
|
|
|
+ purchaseFlow.end(flowId,businessId,submitData);
|
|
|
+ }
|
|
|
+
|
|
|
+}
|