zhangyuewww 3 年之前
父節點
當前提交
e7944fa368

+ 24 - 0
winsea-haixin-plugin-yiliangyiyun/src/main/java/com/yh/saas/plugin/yiliangyiyun/entity/ContractManagementInfo.java

@@ -349,6 +349,10 @@ public class ContractManagementInfo extends BaseModel<ContractManagementInfo> {
      * 反馈负责人电话
      * 反馈负责人电话
      */
      */
     private String feedbackLeaderPhone;
     private String feedbackLeaderPhone;
+    /**
+     * 客户送粮上限
+     */
+    private Float grainDelivery;
     /**
     /**
      * 模糊查询
      * 模糊查询
      */
      */
@@ -441,6 +445,26 @@ public class ContractManagementInfo extends BaseModel<ContractManagementInfo> {
      */
      */
     @TableField(exist = false)
     @TableField(exist = false)
     private Double invoiced;
     private Double invoiced;
+    /**
+     * 应付金额
+     */
+    @TableField(exist = false)
+    private Double amountIngPayable;
+    /**
+     * 已收金额
+     */
+    @TableField(exist = false)
+    private Double amountEdCollectionable;
+    /**
+     * 应收金额
+     */
+    @TableField(exist = false)
+    private Double amountNotCollectable;
+    /**
+     * 已付金额
+     */
+    @TableField(exist = false)
+    private Double amountEdPayableNew;
 
 
 
 
     @Override
     @Override

+ 1 - 5
winsea-haixin-plugin-yiliangyiyun/src/main/resources/mapper/CollectionWarehousingRecordMapper.xml

@@ -70,7 +70,6 @@
         id,
         id,
         comp_id as compId,
         comp_id as compId,
         payment_no as paymentNo,
         payment_no as paymentNo,
-        warehouse_name as warehouseName,
         goods_name as goodsName,
         goods_name as goodsName,
         car_no as carNo,
         car_no as carNo,
         relation_id as relationId,
         relation_id as relationId,
@@ -78,14 +77,11 @@
         contract_no as contractNo,
         contract_no as contractNo,
         net_weight as netWeight,
         net_weight as netWeight,
         invoicing_sale as invoicingSale,
         invoicing_sale as invoicingSale,
-        tare,
         unit_deduction as unitDeduction,
         unit_deduction as unitDeduction,
         unit_have as unithave,
         unit_have as unithave,
-        solid_grain_price as solidGrainPrice,
         amount_ing_payable as amountIngPayable,
         amount_ing_payable as amountIngPayable,
         amount_ed_payable as amountEdPayable,
         amount_ed_payable as amountEdPayable,
         amount_not_payable as amountNotPayable,
         amount_not_payable as amountNotPayable,
-        remarks,
         payment_screenshot as paymentScreenshot,
         payment_screenshot as paymentScreenshot,
         collection_screenshot as collectionScreenshot,
         collection_screenshot as collectionScreenshot,
         amount_ed_collectionable as amountEdCollectionable,
         amount_ed_collectionable as amountEdCollectionable,
@@ -103,7 +99,7 @@
         unit_deduction as unitDeduction,
         unit_deduction as unitDeduction,
         picture_address as pictureAddress,
         picture_address as pictureAddress,
         invoicing,
         invoicing,
-        grade,
+        grade
         FROM collection_warehousing_record
         FROM collection_warehousing_record
         WHERE
         WHERE
         delete_flag = '0'
         delete_flag = '0'

+ 20 - 0
winsea-haixin-plugin-yiliangyiyun/src/main/resources/mapper/ContractManagementInfoMapper.xml

@@ -75,6 +75,26 @@
         p.mildew_grain as contractExpenditure,
         p.mildew_grain as contractExpenditure,
         p.water_content as expenses,
         p.water_content as expenses,
         p.goods_name as invoiced,
         p.goods_name as invoiced,
+        (SELECT IFNULL(sum(col.amount_ing_payable),0)
+        FROM collection_warehousing_record col
+        WHERE col.delete_flag = '0'
+        AND col.contract_no=m.contract_no
+        AND col.comp_id = m.comp_id) as amountIngPayable,
+        (SELECT IFNULL(sum(col.amount_ed_payable),0)
+        FROM collection_warehousing_record col
+        WHERE col.delete_flag = '0'
+        AND col.contract_no=m.contract_no
+        AND col.comp_id = m.comp_id) as amountEdPayableNew,
+        (SELECT IFNULL(sum(col.amount_not_collectable),0)
+        FROM collection_warehousing_record col
+        WHERE col.delete_flag = '0'
+        AND col.contract_no=m.contract_no
+        AND col.comp_id = m.comp_id) as amountNotCollectable,
+        (SELECT IFNULL(sum(col.amount_ed_collectionable),0)
+        FROM collection_warehousing_record col
+        WHERE col.delete_flag = '0'
+        AND col.contract_no=m.contract_no
+        AND col.comp_id = m.comp_id) as amountEdCollectionable,
         case when m.deliver_type = '1' then (SELECT IFNULL(sum(t.amount_ed_payable),0)
         case when m.deliver_type = '1' then (SELECT IFNULL(sum(t.amount_ed_payable),0)
         FROM tran_settlement_report t
         FROM tran_settlement_report t
         WHERE t.delete_flag = '0'
         WHERE t.delete_flag = '0'