Browse Source

合同卡顿问题处理

yzc 1 year ago
parent
commit
83d9f5c520

+ 4 - 4
hx-sale/src/main/java/com/fjhx/sale/entity/contract/po/Contract.java

@@ -340,10 +340,10 @@ public class Contract extends BasePo {
      */
     private Integer isShow;
 
-    /**
-     * 数据JSON
-     */
-    private String dataJson;
+//    /**
+//     * 数据JSON
+//     */
+//    private String dataJson;
 
     /**
      * 交接单附件列表

+ 7 - 9
hx-sale/src/main/java/com/fjhx/sale/entity/sample/po/Sample.java

@@ -1,18 +1,16 @@
 package com.fjhx.sale.entity.sample.po;
 
+import com.baomidou.mybatisplus.annotation.TableField;
 import com.baomidou.mybatisplus.annotation.TableName;
-import com.baomidou.mybatisplus.annotation.Version;
 import com.fjhx.file.entity.ObsFile;
 import com.ruoyi.common.core.domain.BasePo;
-import com.baomidou.mybatisplus.annotation.TableField;
+import lombok.Getter;
+import lombok.Setter;
 
 import java.math.BigDecimal;
 import java.util.Date;
 import java.util.List;
 
-import lombok.Getter;
-import lombok.Setter;
-
 /**
  * <p>
  * 样品单表
@@ -271,10 +269,10 @@ public class Sample extends BasePo {
      */
     private Integer isShow;
 
-    /**
-     * 数据JSON
-     */
-    private String dataJson;
+//    /**
+//     * 数据JSON
+//     */
+//    private String dataJson;
 
     /**
      * 流程ID

+ 2 - 3
hx-sale/src/main/java/com/fjhx/sale/service/contract/impl/ContractServiceImpl.java

@@ -310,7 +310,7 @@ public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract>
         } else {
             wrapper.eq("t1", Contract::getIsChange, "0");//列表只展示未变更得数据
             wrapper.ne("t1", Contract::getIsShow, 1);
-            wrapper.between("t1", Contract::getStatus, FlowStatusEnum1.DRAFT.getKey(), FlowStatusEnum1.CANCELLATION.getKey() - 1);
+//            wrapper.between("t1", Contract::getStatus, FlowStatusEnum1.DRAFT.getKey(), FlowStatusEnum1.CANCELLATION.getKey() - 1);
         }
         if (StringUtils.isNotEmpty(dto.getUserId())) {
             wrapper.eq("t1.salesmanId", dto.getUserId());
@@ -715,7 +715,7 @@ public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract>
                 grossProfitInfo.setCompareLastGross(BigDecimal.ZERO);
                 if ((i - 1) >= 0) {
                     ContractBudgetVo.GrossProfitInfo lastGrossProfitInfo = grossProfitInfoList.get(i - 1);
-                    BigDecimal subtract = lastGrossProfitInfo.getGross().subtract(grossProfitInfo.getGross());
+                    BigDecimal subtract = grossProfitInfo.getGross().subtract(lastGrossProfitInfo.getGross());
                     grossProfitInfo.setCompareLastGross(subtract);
                 }
             }
@@ -1044,7 +1044,6 @@ public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract>
         );
         Map<Long, List<EhsdPurchase>> purchaseMap = purchaseList.stream().collect(Collectors.groupingBy(EhsdPurchase::getDataResourceId));
         for (ContractBudgetVo v : list) {
-            v.setDataJson(null);
             v.setOtherIncomeAmount(BigDecimal.ZERO);//暂时先设置其他收入为0
 
             v.setRmbContractAmount(v.getAmount().multiply(v.getRate()));//计算汇算人民币