Browse Source

优化 入库确认接口,修改出库确认 调取仓储费协议求得收款信息

阿伏兔 4 năm trước cách đây
mục cha
commit
6a7a4f1e37

+ 18 - 1
ruoyi-common/src/main/java/com/ruoyi/common/utils/DateUtils.java

@@ -1,10 +1,11 @@
 package com.ruoyi.common.utils;
 
+import org.apache.commons.lang3.time.DateFormatUtils;
+
 import java.lang.management.ManagementFactory;
 import java.text.ParseException;
 import java.text.SimpleDateFormat;
 import java.util.Date;
-import org.apache.commons.lang3.time.DateFormatUtils;
 
 /**
  * 时间工具类
@@ -132,6 +133,22 @@ public class DateUtils extends org.apache.commons.lang3.time.DateUtils
     }
 
     /**
+     * 计算两个时间差多少天
+     */
+    public static long getDateDay(Date endDate, Date nowDate)
+    {
+        long nd = 1000 * 24 * 60 * 60;
+        long nh = 1000 * 60 * 60;
+        long nm = 1000 * 60;
+        // long ns = 1000;
+        // 获得两个时间的毫秒时间差异
+        long diff = endDate.getTime() - nowDate.getTime();
+        // 计算差多少天
+        long day = diff / nd;
+        return day;
+    }
+
+    /**
      * 计算两个时间差
      */
     public static String getDatePoor(Date endDate, Date nowDate)

+ 47 - 54
ruoyi-warehouse/src/main/java/com/ruoyi/reportManagement/domain/TWhgenleg.java

@@ -62,6 +62,13 @@ public class TWhgenleg extends BaseEntity {
     private Long fGoodsid;
 
     /**
+     * 仓储计费日期
+     */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "仓储计费日期", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date fChargedate;
+
+    /**
      * 贸易方式,对应t_trademodels name
      */
     private Long fTrademodeid;
@@ -73,18 +80,18 @@ public class TWhgenleg extends BaseEntity {
     private Long fPreqty;
 
     /**
-     * 上期毛重,单位为吨,保留6位小数
-     */
-    @Excel(name = "上期毛重,单位为吨,保留6位小数")
-    private BigDecimal fPregrossweight;
-
-    /**
      * 仓库
      */
     @Excel(name = "仓库")
     private Long fWarehouseid;
 
     /**
+     * 上期毛重,单位为吨,保留6位小数
+     */
+    @Excel(name = "上期毛重,单位为吨,保留6位小数")
+    private BigDecimal fPregrossweight;
+
+    /**
      * 上期净重,
      */
     @Excel(name = "上期净重,")
@@ -93,7 +100,6 @@ public class TWhgenleg extends BaseEntity {
     /**
      * 入库件数
      */
-
     @Excel(name = "入库件数")
     private Long fQtyd;
 
@@ -104,6 +110,12 @@ public class TWhgenleg extends BaseEntity {
     private BigDecimal fVolumnd;
 
     /**
+     * 计费方式(数据字典)
+     */
+    @Excel(name = "计费方式(数据字典)")
+    private Long fBillingway;
+
+    /**
      * 入库毛重
      */
     @Excel(name = "入库毛重")
@@ -128,18 +140,18 @@ public class TWhgenleg extends BaseEntity {
     private Long fQtyc;
 
     /**
-     * 结余件数
-     */
-    @Excel(name = "结余件数")
-    private Long fQtyblc;
-
-    /**
      * 出库毛重,单位为吨
      */
     @Excel(name = "出库毛重,单位为吨")
     private BigDecimal fGrossweightc;
 
     /**
+     * 结余件数
+     */
+    @Excel(name = "结余件数")
+    private Long fQtyblc;
+
+    /**
      * 结余毛重
      */
     @Excel(name = "结余毛重")
@@ -246,19 +258,35 @@ public class TWhgenleg extends BaseEntity {
 
     }
 
+    public void setfChargedate(Date fChargedate) {
+        this.fChargedate = fChargedate;
+    }
+
+    public Date getfChargedate() {
+        return fChargedate;
+    }
+
     public void setfMblno(String fMblno) {
 
         this.fMblno = fMblno;
 
     }
 
-
     public String getfMblno() {
 
         return fMblno;
 
     }
 
+    public void setfBillingway(Long fBillingway) {
+        this.fBillingway = fBillingway;
+    }
+
+    public Long getfBillingway() {
+        return fBillingway;
+    }
+
+
     public void setfOriginalbillno(String fOriginalbillno) {
 
         this.fOriginalbillno = fOriginalbillno;
@@ -575,79 +603,44 @@ public class TWhgenleg extends BaseEntity {
     @Override
 
     public String toString() {
-
         return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
-
                 .append("fId", getfId())
-
                 .append("fAccyear", getfAccyear())
-
                 .append("fAccmonth", getfAccmonth())
-
                 .append("fCorpid", getfCorpid())
-
                 .append("fMblno", getfMblno())
-
                 .append("fOriginalbillno", getfOriginalbillno())
-
                 .append("fWarehouseLocationid", getfWarehouseLocationid())
-
                 .append("fGoodsid", getfGoodsid())
-
+                .append("fChargedate", getfChargedate())
                 .append("fTrademodeid", getfTrademodeid())
-
                 .append("fPreqty", getfPreqty())
-
-                .append("fPregrossweight", getfPregrossweight())
-
                 .append("fWarehouseid", getfWarehouseid())
-
+                .append("fPregrossweight", getfPregrossweight())
                 .append("fPrenetweight", getfPrenetweight())
-
                 .append("fQtyd", getfQtyd())
-
                 .append("fVolumnd", getfVolumnd())
-
+                .append("fBillingway", getfBillingway())
                 .append("fGrossweightd", getfGrossweightd())
-
                 .append("fNetweightd", getfNetweightd())
-
                 .append("fVolumnc", getfVolumnc())
-
                 .append("fQtyc", getfQtyc())
-
-                .append("fQtyblc", getfQtyblc())
-
                 .append("fGrossweightc", getfGrossweightc())
-
+                .append("fQtyblc", getfQtyblc())
                 .append("fGrossweightblc", getfGrossweightblc())
-
                 .append("fNetweightc", getfNetweightc())
-
                 .append("fNetweightblc", getfNetweightblc())
-
                 .append("fCntrno", getfCntrno())
-
                 .append("fStatus", getfStatus())
-
                 .append("delFlag", getDelFlag())
-
-                .append("fMarks", getfMarks())
-
                 .append("createBy", getCreateBy())
-
+                .append("fMarks", getfMarks())
                 .append("createTime", getCreateTime())
-
                 .append("updateBy", getUpdateBy())
-
                 .append("updateTime", getUpdateTime())
-
                 .append("remark", getRemark())
-
                 .append("fOriginalbilldate", getfOriginalbilldate())
-
                 .toString();
-
     }
 
 }

+ 69 - 36
ruoyi-warehouse/src/main/java/com/ruoyi/warehouseBusiness/domain/TWarehousebillsitems.java

@@ -1,5 +1,6 @@
 package com.ruoyi.warehouseBusiness.domain;
 
+import com.fasterxml.jackson.annotation.JsonFormat;
 import com.ruoyi.common.annotation.Excel;
 import com.ruoyi.common.core.domain.BaseEntity;
 import org.apache.commons.lang3.builder.ToStringBuilder;
@@ -29,12 +30,6 @@ public class TWarehousebillsitems extends BaseEntity {
     private Long fPid;
 
     /**
-     * 原始入库业务编号
-     */
-    @Excel(name = "原始入库业务编号")
-    private String fOriginalbillno;
-
-    /**
      * 行号,针对pid顺序排列,1,2,3,4,
      */
     @Excel(name = "行号,针对pid顺序排列,1,2,3,4,")
@@ -47,6 +42,18 @@ public class TWarehousebillsitems extends BaseEntity {
     private Long fGoodsid;
 
     /**
+     * 提单号
+     */
+    @Excel(name = "提单号")
+    private String fMblno;
+
+    /**
+     * 计费方式(数据字典)
+     */
+    @Excel(name = "计费方式(数据字典)")
+    private Long fBillingway;
+
+    /**
      * 入库库区,存储库区ID,显示仓库 库位 库区,t_warehouse_area中的f_id
      */
     @Excel(name = "入库库区,存储库区ID,显示仓库 库位 库区,t_warehouse_area中的f_id")
@@ -59,16 +66,10 @@ public class TWarehousebillsitems extends BaseEntity {
     private Date fBsdate;
 
     /**
-     * 提单号
-     */
-    @Excel(name = "提单号")
-    private String fMblno;
-
-    /**
-     * 唛头
+     * 原始入库业务编号
      */
-    @Excel(name = "唛头")
-    private String fMarks;
+    @Excel(name = "原始入库业务编号")
+    private String fOriginalbillno;
 
     /**
      * 箱号
@@ -95,6 +96,13 @@ public class TWarehousebillsitems extends BaseEntity {
     private String fCntrtype;
 
     /**
+     * 仓储计费日期
+     */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "仓储计费日期", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date fChargedate;
+
+    /**
      * 计划件数
      */
     @Excel(name = "计划件数")
@@ -171,6 +179,12 @@ public class TWarehousebillsitems extends BaseEntity {
      */
     private String delFlag;
 
+    /**
+     * 唛头
+     */
+    @Excel(name = "唛头")
+    private String fMarks;
+
     public void setfId(Long fId) {
         this.fId = fId;
     }
@@ -203,6 +217,14 @@ public class TWarehousebillsitems extends BaseEntity {
         return fGoodsid;
     }
 
+    public void setfMblno(String fMblno) {
+        this.fMblno = fMblno;
+    }
+
+    public String getfMblno() {
+        return fMblno;
+    }
+
     public void setfWarehouselocid(Long fWarehouselocid) {
         this.fWarehouselocid = fWarehouselocid;
     }
@@ -211,20 +233,20 @@ public class TWarehousebillsitems extends BaseEntity {
         return fWarehouselocid;
     }
 
-    public void setfBsdate(Date fBsdate) {
-        this.fBsdate = fBsdate;
+    public void setfChargedate(Date fChargedate) {
+        this.fChargedate = fChargedate;
     }
 
-    public Date getfBsdate() {
-        return fBsdate;
+    public Date getfChargedate() {
+        return fChargedate;
     }
 
-    public void setfBoxno(String fBoxno) {
-        this.fBoxno = fBoxno;
+    public void setfBsdate(Date fBsdate) {
+        this.fBsdate = fBsdate;
     }
 
-    public String getfBoxno() {
-        return fBoxno;
+    public Date getfBsdate() {
+        return fBsdate;
     }
 
     public void setfOriginalbillno(String fOriginalbillno) {
@@ -235,20 +257,12 @@ public class TWarehousebillsitems extends BaseEntity {
         return fOriginalbillno;
     }
 
-    public void setfMblno(String fMblno) {
-        this.fMblno = fMblno;
-    }
-
-    public String getfMblno() {
-        return fMblno;
-    }
-
-    public void setfMarks(String fMarks) {
-        this.fMarks = fMarks;
+    public void setfBoxno(String fBoxno) {
+        this.fBoxno = fBoxno;
     }
 
-    public String getfMarks() {
-        return fMarks;
+    public String getfBoxno() {
+        return fBoxno;
     }
 
     public void setfCntqty(Long fCntqty) {
@@ -259,6 +273,14 @@ public class TWarehousebillsitems extends BaseEntity {
         return fCntqty;
     }
 
+    public void setfBillingway(Long fBillingway) {
+        this.fBillingway = fBillingway;
+    }
+
+    public Long getfBillingway() {
+        return fBillingway;
+    }
+
     public void setfGoodsval(BigDecimal fGoodsval) {
         this.fGoodsval = fGoodsval;
     }
@@ -379,6 +401,14 @@ public class TWarehousebillsitems extends BaseEntity {
         return delFlag;
     }
 
+    public void setfMarks(String fMarks) {
+        this.fMarks = fMarks;
+    }
+
+    public String getfMarks() {
+        return fMarks;
+    }
+
     @Override
     public String toString() {
         return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
@@ -386,15 +416,17 @@ public class TWarehousebillsitems extends BaseEntity {
                 .append("fPid", getfPid())
                 .append("fLineno", getfLineno())
                 .append("fGoodsid", getfGoodsid())
+                .append("fMblno", getfMblno())
                 .append("fWarehouselocid", getfWarehouselocid())
                 .append("fBsdate", getfBsdate())
                 .append("fOriginalbillno", getfOriginalbillno())
                 .append("fBoxno", getfBoxno())
-                .append("fMblno", getfMblno())
+                .append("fChargedate", getfChargedate())
                 .append("fCntqty", getfCntqty())
                 .append("fGoodsval", getfGoodsval())
                 .append("fCntrtype", getfCntrtype())
                 .append("fPlanqty", getfPlanqty())
+                .append("fBillingway", getfBillingway())
                 .append("fPlanvolumn", getfPlanvolumn())
                 .append("fPackagespecs", getfPackagespecs())
                 .append("fPlangrossweight", getfPlangrossweight())
@@ -412,6 +444,7 @@ public class TWarehousebillsitems extends BaseEntity {
                 .append("updateBy", getUpdateBy())
                 .append("updateTime", getUpdateTime())
                 .append("remark", getRemark())
+                .append("fMarks", getfMarks())
                 .toString();
     }
 }

+ 11 - 8
ruoyi-warehouse/src/main/java/com/ruoyi/warehouseBusiness/service/impl/TWarehouseAgreementServiceImpl.java

@@ -15,9 +15,10 @@ import com.ruoyi.common.core.domain.entity.SysUser;
 import com.ruoyi.common.core.domain.model.LoginUser;
 import com.ruoyi.common.utils.DateUtils;
 import com.ruoyi.common.utils.StringUtils;
-import com.ruoyi.reportManagement.domain.TWhgenleg;
 import com.ruoyi.system.mapper.SysDeptMapper;
-import com.ruoyi.warehouseBusiness.domain.*;
+import com.ruoyi.warehouseBusiness.domain.BillnoDel;
+import com.ruoyi.warehouseBusiness.domain.TWarehouseAgreement;
+import com.ruoyi.warehouseBusiness.domain.TWarehouseAgreementitems;
 import com.ruoyi.warehouseBusiness.mapper.BillnoDelMapper;
 import com.ruoyi.warehouseBusiness.mapper.TWarehouseAgreementMapper;
 import com.ruoyi.warehouseBusiness.mapper.TWarehouseAgreementitemsMapper;
@@ -26,9 +27,6 @@ import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
 import java.math.BigDecimal;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
 import java.util.*;
 
 /**
@@ -256,12 +254,12 @@ public class TWarehouseAgreementServiceImpl implements ITWarehouseAgreementServi
      * @param itemNums 数量
      * @return
      */
-    public BigDecimal getCarryingCost(Long fCorpid,
+    public Map<String, Object> getCarryingCost(Long fCorpid,
                                       Long fGoodsid,
                                       Long days,
                                       Long feeUnitid,
                                       Long itemNums) {
-
+        Map<String, Object> map = new HashMap<>();
         if (null == fCorpid ||
                 null == fGoodsid ||
                 null == days ||
@@ -277,17 +275,22 @@ public class TWarehouseAgreementServiceImpl implements ITWarehouseAgreementServi
         }
         BigDecimal money = new BigDecimal(0);
         Long dayLength = 0L;
+        Long feeId = 0L;
         for (TWarehouseAgreementitems tWarehouseAgreementitems : itemList) {
             if (days < 1) break;
             dayLength = tWarehouseAgreementitems.getfEndays() - tWarehouseAgreementitems.getfFromdays() + 1L;
             if (days >= dayLength) {
+                feeId = tWarehouseAgreementitems.getfFeeid();
                 money = money.add(this.getCalculate(itemNums,tWarehouseAgreementitems.getfPrice(),dayLength));
                 days -=  dayLength;
             } else {
+                feeId = tWarehouseAgreementitems.getfFeeid();
                 money = money.add(this.getCalculate(itemNums,feeUnitid,days));
             }
         }
-        return money;
+        map.put("amt", money);
+        map.put("feeId", feeId);
+        return map;
     }
 
 

+ 42 - 1
ruoyi-warehouse/src/main/java/com/ruoyi/warehouseBusiness/service/impl/TWarehouseBillsServiceImpl.java

@@ -292,6 +292,10 @@ public class TWarehouseBillsServiceImpl implements ITWarehouseBillsService {
         tWhgenleg.setfWarehouseLocationid(warehousebillsitems.getfWarehouselocid());
         // 货物品名
         tWhgenleg.setfGoodsid(warehousebillsitems.getfGoodsid());
+        // 计费方式
+        tWhgenleg.setfBillingway(warehousebillsitems.getfBillingway());
+        // 仓储计费日期
+        tWhgenleg.setfChargedate(warehousebillsitems.getfChargedate());
         // 贸易方式
         tWhgenleg.setfTrademodeid(warehouseBills.getfTrademodeid());
         // 入库数
@@ -565,6 +569,7 @@ public class TWarehouseBillsServiceImpl implements ITWarehouseBillsService {
             tWarehouseBills.setfBscorpno(bscorpno);
             tWarehouseBills.setCreateBy(loginUser.getUser().getUserName());
             tWarehouseBills.setCreateTime(new Date());
+            tWarehouseBills.setfBilltype("SJRK");
             tWarehouseBills.setfBsdeptid(loginUser.getUser().getDeptId());
             // 已入账
             tWarehouseBills.setfBillstatus("2");
@@ -576,10 +581,13 @@ public class TWarehouseBillsServiceImpl implements ITWarehouseBillsService {
         for (TWarehousebillsitems item : warehousebillsitemsList) {
             // 唛头添加
             item.setfMarks(tWarehouseBills.getfMarks());
+            item.setfBillingway(tWarehouseBills.getfBillingway());
+            item.setfChargedate(tWarehouseBills.getfChargedate());
             TWhgenleg tWhgenle = queryTWhgenleg(tWarehouseBills, item);
             if (StringUtils.isNotNull(tWhgenle)) {
                 int i = updateTWhgenlegData(item, tWhgenle.getfId(), billsType);
                 if (i <= 0) {
+                    TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
                     return AjaxResult.error("更新库存总账失败");
                 }
             } else {
@@ -656,6 +664,7 @@ public class TWarehouseBillsServiceImpl implements ITWarehouseBillsService {
     @Transactional
     public AjaxResult updateCredit(String warehouseBills, String warehousebillsitems, LoginUser loginUser, String billsType) {
         Long fPid = null;
+        Map<String, Object> map = new HashMap<>();
         if (StringUtils.isNull(warehouseBills) || "[]".equals(warehouseBills)) {
             return AjaxResult.error("未找到主表信息");
         }
@@ -689,6 +698,8 @@ public class TWarehouseBillsServiceImpl implements ITWarehouseBillsService {
         JSONArray warehouseJSON = JSONArray.parseArray(warehousebillsitems);
         List<TWarehousebillsitems> warehousebillsitemsList = JSONObject.parseArray(warehouseJSON.toJSONString(), TWarehousebillsitems.class);
         int i = 1;
+        List<TFees> feesList = new ArrayList<>();
+        List<TWarehousebillsfees> warehousebillsfees = new ArrayList<>();
         for (TWarehousebillsitems wbItem : warehousebillsitemsList) {
             // 唛头添加
             wbItem.setfMarks(tWarehouseBills.getfMarks());
@@ -705,7 +716,34 @@ public class TWarehouseBillsServiceImpl implements ITWarehouseBillsService {
                         TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
                         return AjaxResult.error("库存明细第" + i + "行库存不足");
                     }
+                    // 更新库存总账
                     updateTWhgenlegData(wbItem, tWhgenle.getfId(), billsType);
+                    TWarehouseAgreementServiceImpl tWarehouseAgreementService = new TWarehouseAgreementServiceImpl();
+                    long dateDay = DateUtils.getDateDay(tWarehouseBills.getfBsdate(), wbItem.getfBsdate());
+                    long fCorpid = tWarehouseBills.getfCorpid();
+                    long fGoodsid = wbItem.getfGoodsid();
+                    long fBillingway = wbItem.getfBillingway();
+                    long fQty = wbItem.getfQty();
+                    // 计算仓储费明细
+                    Map<String, Object> objectMap = tWarehouseAgreementService.getCarryingCost(fCorpid, fGoodsid, dateDay, fBillingway, fQty);
+                    if (StringUtils.isNull(objectMap)) {
+                        TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
+                        return AjaxResult.error("库存明细第" + i + "行没有维护出库明细的仓储协议,操作终止");
+                    }
+                    TWarehousebillsfees fees = new TWarehousebillsfees();
+                    Long feeId = (Long) objectMap.get("feeId");
+                    BigDecimal amt = (BigDecimal) objectMap.get("amt");
+                    fees.setfPid(fPid);
+                    fees.setfFeeid(feeId);
+                    fees.setfFeeUnitid(fBillingway);
+                    fees.setfQty(new BigDecimal(1));
+                    fees.setfUnitprice(amt);
+                    fees.setfAmount(amt);
+                    warehousebillsfees.add(fees);
+                    TFees tFees = tFeesMapper.selectTFeesById(feeId);
+                    if (StringUtils.isNotNull(tFees)) {
+                        feesList.add(tFees);
+                    }
                 }
             } else if ("CKDB".equals(billsType)) { // 调拨查询
                 if (StringUtils.isNull(tWhgenle)) { // 为空 提示没有库存
@@ -791,8 +829,11 @@ public class TWarehouseBillsServiceImpl implements ITWarehouseBillsService {
             warehouseBill.setfItemsStatus("2");
         }
         tWarehouseBillsMapper.updateTWarehousebills(warehouseBill);
+        map.put("fPid", fPid);
+        map.put("fees", feesList);
+        map.put("warehousebillsfees", warehousebillsfees);
         // 添加成功 主键返回 前台
-        return AjaxResult.success("成功", fPid);
+        return AjaxResult.success("成功", map);
     }
 
     // 入库 收费明细 校验

+ 27 - 22
ruoyi-warehouse/src/main/resources/mapper/reportManagement/TWhgenlegMapper.xml

@@ -5,14 +5,15 @@
 <mapper namespace="com.ruoyi.reportManagement.mapper.TWhgenlegMapper">
 
     <resultMap type="TWhgenleg" id="TWhgenlegResult">
-        <result property="fAccyear" column="f_accyear"/>
         <result property="fId" column="f_id"/>
+        <result property="fAccyear" column="f_accyear"/>
         <result property="fAccmonth" column="f_accmonth"/>
         <result property="fCorpid" column="f_corpid"/>
         <result property="fMblno" column="f_mblno"/>
         <result property="fOriginalbillno" column="f_originalbillno"/>
         <result property="fWarehouseLocationid" column="f_warehouse_locationid"/>
         <result property="fGoodsid" column="f_goodsid"/>
+        <result property="fChargedate" column="f_chargedate"/>
         <result property="fTrademodeid" column="f_trademodeid"/>
         <result property="fPreqty" column="f_preqty"/>
         <result property="fWarehouseid" column="f_warehouseid"/>
@@ -20,56 +21,57 @@
         <result property="fPrenetweight" column="f_prenetweight"/>
         <result property="fQtyd" column="f_qtyD"/>
         <result property="fVolumnd" column="f_volumnD"/>
+        <result property="fBillingway" column="f_billingway"/>
         <result property="fGrossweightd" column="f_grossweightD"/>
         <result property="fNetweightd" column="f_netweightD"/>
         <result property="fVolumnc" column="f_volumnC"/>
         <result property="fQtyc" column="f_qtyC"/>
-        <result property="fQtyblc" column="f_qtyblc"/>
         <result property="fGrossweightc" column="f_grossweightC"/>
-        <result property="fNetweightc" column="f_netweightC"/>
+        <result property="fQtyblc" column="f_qtyblc"/>
         <result property="fGrossweightblc" column="f_grossweightblc"/>
+        <result property="fNetweightc" column="f_netweightC"/>
         <result property="fNetweightblc" column="f_netweightblc"/>
         <result property="fCntrno" column="f_cntrno"/>
-        <result property="fMarks" column="f_marks"/>
         <result property="fStatus" column="f_status"/>
         <result property="delFlag" column="del_flag"/>
         <result property="createBy" column="create_by"/>
+        <result property="fMarks" column="f_marks"/>
         <result property="createTime" column="create_time"/>
         <result property="updateBy" column="update_by"/>
         <result property="updateTime" column="update_time"/>
-        <result property="fOriginalbilldate" column="f_originalbilldate"/>
         <result property="remark" column="remark"/>
+        <result property="fOriginalbilldate" column="f_originalbilldate"/>
     </resultMap>
 
     <sql id="selectTWhgenlegVo">
-        select f_accyear, f_id, f_accmonth, f_corpid, f_mblno, f_originalbilldate, f_warehouseid, f_originalbillno, f_marks, f_warehouse_locationid, f_goodsid, f_trademodeid, f_preqty, f_pregrossweight, f_prenetweight, f_qtyD, f_volumnD, f_grossweightD, f_netweightD, f_volumnC, f_qtyC, f_qtyblc, f_grossweightC, f_netweightC, f_grossweightblc, f_netweightblc, f_cntrno, f_status, del_flag, create_by, create_time, update_by, update_time, remark from t_whgenleg
+        select f_id, f_accyear, f_accmonth, f_corpid, f_mblno, f_originalbillno, f_warehouse_locationid, f_goodsid, f_chargedate, f_trademodeid, f_preqty, f_warehouseid, f_pregrossweight, f_prenetweight, f_qtyD, f_volumnD, f_billingway, f_grossweightD, f_netweightD, f_volumnC, f_qtyC, f_grossweightC, f_qtyblc, f_grossweightblc, f_netweightC, f_netweightblc, f_cntrno, f_status, del_flag, create_by, f_marks, create_time, update_by, update_time, remark, f_originalbilldate from t_whgenleg
     </sql>
 
     <select id="selectTWhgenlegList" parameterType="TWhgenleg" resultMap="TWhgenlegResult">
         <include refid="selectTWhgenlegVo"/>
         <where>
             <if test="fOriginalbillno != null  and fOriginalbillno != ''">and f_originalbillno = #{fOriginalbillno}</if>
+            <if test="fChargedate != null ">and f_chargedate = #{fChargedate}</if>
             <if test="fPreqty != null ">and f_preqty = #{fPreqty}</if>
-            <if test="fCorpid != null ">and f_corpid = #{fCorpid}</if>
-            <if test="fMblno != null ">and f_mblno = #{fMblno}</if>
+            <if test="fWarehouseid != null ">and f_warehouseid = #{fWarehouseid}</if>
             <if test="fPregrossweight != null ">and f_pregrossweight = #{fPregrossweight}</if>
             <if test="fPrenetweight != null ">and f_prenetweight = #{fPrenetweight}</if>
             <if test="fQtyd != null ">and f_qtyD = #{fQtyd}</if>
             <if test="fVolumnd != null ">and f_volumnD = #{fVolumnd}</if>
-            <if test="fWarehouseid != null ">and f_warehouseid = #{fWarehouseid}</if>
+            <if test="fBillingway != null ">and f_billingway = #{fBillingway}</if>
             <if test="fGrossweightd != null ">and f_grossweightD = #{fGrossweightd}</if>
-            <if test="fOriginalbilldate != null ">and f_originalbilldate = #{fOriginalbilldate}</if>
             <if test="fNetweightd != null ">and f_netweightD = #{fNetweightd}</if>
             <if test="fVolumnc != null ">and f_volumnC = #{fVolumnc}</if>
             <if test="fQtyc != null ">and f_qtyC = #{fQtyc}</if>
-            <if test="fMarks != null  and fMarks != ''">and f_marks = #{fMarks}</if>
-            <if test="fQtyblc != null ">and f_qtyblc = #{fQtyblc}</if>
             <if test="fGrossweightc != null ">and f_grossweightC = #{fGrossweightc}</if>
-            <if test="fNetweightc != null ">and f_netweightC = #{fNetweightc}</if>
+            <if test="fQtyblc != null ">and f_qtyblc = #{fQtyblc}</if>
             <if test="fGrossweightblc != null ">and f_grossweightblc = #{fGrossweightblc}</if>
+            <if test="fNetweightc != null ">and f_netweightC = #{fNetweightc}</if>
             <if test="fNetweightblc != null ">and f_netweightblc = #{fNetweightblc}</if>
             <if test="fCntrno != null  and fCntrno != ''">and f_cntrno = #{fCntrno}</if>
             <if test="fStatus != null  and fStatus != ''">and f_status = #{fStatus}</if>
+            <if test="fMarks != null  and fMarks != ''">and f_marks = #{fMarks}</if>
+            <if test="fOriginalbilldate != null ">and f_originalbilldate = #{fOriginalbilldate}</if>
         </where>
     </select>
 
@@ -162,13 +164,13 @@
         insert into t_whgenleg
         <trim prefix="(" suffix=")" suffixOverrides=",">
             <if test="fAccyear != null">f_accyear,</if>
-            <if test="fId != null">f_id,</if>
             <if test="fAccmonth != null">f_accmonth,</if>
             <if test="fCorpid != null">f_corpid,</if>
             <if test="fMblno != null">f_mblno,</if>
             <if test="fOriginalbillno != null">f_originalbillno,</if>
             <if test="fWarehouseLocationid != null">f_warehouse_locationid,</if>
             <if test="fGoodsid != null">f_goodsid,</if>
+            <if test="fChargedate != null">f_chargedate,</if>
             <if test="fTrademodeid != null">f_trademodeid,</if>
             <if test="fPreqty != null">f_preqty,</if>
             <if test="fWarehouseid != null">f_warehouseid,</if>
@@ -176,14 +178,15 @@
             <if test="fPrenetweight != null">f_prenetweight,</if>
             <if test="fQtyd != null">f_qtyD,</if>
             <if test="fVolumnd != null">f_volumnD,</if>
+            <if test="fBillingway != null">f_billingway,</if>
             <if test="fGrossweightd != null">f_grossweightD,</if>
             <if test="fNetweightd != null">f_netweightD,</if>
             <if test="fVolumnc != null">f_volumnC,</if>
             <if test="fQtyc != null">f_qtyC,</if>
             <if test="fGrossweightc != null">f_grossweightC,</if>
             <if test="fQtyblc != null">f_qtyblc,</if>
-            <if test="fNetweightc != null">f_netweightC,</if>
             <if test="fGrossweightblc != null">f_grossweightblc,</if>
+            <if test="fNetweightc != null">f_netweightC,</if>
             <if test="fNetweightblc != null">f_netweightblc,</if>
             <if test="fCntrno != null">f_cntrno,</if>
             <if test="fStatus != null">f_status,</if>
@@ -198,13 +201,13 @@
         </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="fAccyear != null">#{fAccyear},</if>
-            <if test="fId != null">#{fId},</if>
             <if test="fAccmonth != null">#{fAccmonth},</if>
             <if test="fCorpid != null">#{fCorpid},</if>
             <if test="fMblno != null">#{fMblno},</if>
             <if test="fOriginalbillno != null">#{fOriginalbillno},</if>
             <if test="fWarehouseLocationid != null">#{fWarehouseLocationid},</if>
             <if test="fGoodsid != null">#{fGoodsid},</if>
+            <if test="fChargedate != null">#{fChargedate},</if>
             <if test="fTrademodeid != null">#{fTrademodeid},</if>
             <if test="fPreqty != null">#{fPreqty},</if>
             <if test="fWarehouseid != null">#{fWarehouseid},</if>
@@ -212,14 +215,15 @@
             <if test="fPrenetweight != null">#{fPrenetweight},</if>
             <if test="fQtyd != null">#{fQtyd},</if>
             <if test="fVolumnd != null">#{fVolumnd},</if>
+            <if test="fBillingway != null">#{fBillingway},</if>
             <if test="fGrossweightd != null">#{fGrossweightd},</if>
             <if test="fNetweightd != null">#{fNetweightd},</if>
             <if test="fVolumnc != null">#{fVolumnc},</if>
             <if test="fQtyc != null">#{fQtyc},</if>
             <if test="fGrossweightc != null">#{fGrossweightc},</if>
             <if test="fQtyblc != null">#{fQtyblc},</if>
-            <if test="fNetweightc != null">#{fNetweightc},</if>
             <if test="fGrossweightblc != null">#{fGrossweightblc},</if>
+            <if test="fNetweightc != null">#{fNetweightc},</if>
             <if test="fNetweightblc != null">#{fNetweightblc},</if>
             <if test="fCntrno != null">#{fCntrno},</if>
             <if test="fStatus != null">#{fStatus},</if>
@@ -237,13 +241,14 @@
     <update id="updateTWhgenleg" parameterType="TWhgenleg">
         update t_whgenleg
         <trim prefix="SET" suffixOverrides=",">
-            <if test="fId != null">f_id = #{fId},</if>
+            <if test="fAccyear != null">f_accyear = #{fAccyear},</if>
             <if test="fAccmonth != null">f_accmonth = #{fAccmonth},</if>
             <if test="fCorpid != null">f_corpid = #{fCorpid},</if>
             <if test="fMblno != null">f_mblno = #{fMblno},</if>
             <if test="fOriginalbillno != null">f_originalbillno = #{fOriginalbillno},</if>
             <if test="fWarehouseLocationid != null">f_warehouse_locationid = #{fWarehouseLocationid},</if>
             <if test="fGoodsid != null">f_goodsid = #{fGoodsid},</if>
+            <if test="fChargedate != null">f_chargedate = #{fChargedate},</if>
             <if test="fTrademodeid != null">f_trademodeid = #{fTrademodeid},</if>
             <if test="fPreqty != null">f_preqty = #{fPreqty},</if>
             <if test="fWarehouseid != null">f_warehouseid = #{fWarehouseid},</if>
@@ -251,14 +256,15 @@
             <if test="fPrenetweight != null">f_prenetweight = #{fPrenetweight},</if>
             <if test="fQtyd != null">f_qtyD = #{fQtyd},</if>
             <if test="fVolumnd != null">f_volumnD = #{fVolumnd},</if>
+            <if test="fBillingway != null">f_billingway = #{fBillingway},</if>
             <if test="fGrossweightd != null">f_grossweightD = #{fGrossweightd},</if>
             <if test="fNetweightd != null">f_netweightD = #{fNetweightd},</if>
             <if test="fVolumnc != null">f_volumnC = #{fVolumnc},</if>
             <if test="fQtyc != null">f_qtyC = #{fQtyc},</if>
             <if test="fGrossweightc != null">f_grossweightC = #{fGrossweightc},</if>
             <if test="fQtyblc != null">f_qtyblc = #{fQtyblc},</if>
-            <if test="fNetweightc != null">f_netweightC = #{fNetweightc},</if>
             <if test="fGrossweightblc != null">f_grossweightblc = #{fGrossweightblc},</if>
+            <if test="fNetweightc != null">f_netweightC = #{fNetweightc},</if>
             <if test="fNetweightblc != null">f_netweightblc = #{fNetweightblc},</if>
             <if test="fCntrno != null">f_cntrno = #{fCntrno},</if>
             <if test="fStatus != null">f_status = #{fStatus},</if>
@@ -368,7 +374,7 @@
         </where>
     </select>
 
-    <select id="selectWareHouseList"  resultType="Map">
+    <select id="selectWareHouseList" resultType="Map">
         SELECT
             t.f_warehouseid AS fWarehouseid,
             w.f_name AS fName,
@@ -389,7 +395,7 @@
             ) t ON w.f_id = t.f_warehouseid
     </select>
 
-    <select id="selectCorpsList"  resultType="Map">
+    <select id="selectCorpsList" resultType="Map">
         SELECT
             t.f_corpid AS fCorpid,
             c.f_name AS fName
@@ -432,7 +438,6 @@
         </where>
     </select>
 
-
     <select id="selectDateFQtyblcListList"  resultType="Map">
         SELECT
             t.f_originalbilldate AS fOriginalbilldate,

+ 55 - 46
ruoyi-warehouse/src/main/resources/mapper/warehouseBusiness/TWarehousebillsitemsMapper.xml

@@ -9,15 +9,17 @@
         <result property="fPid" column="f_pid"/>
         <result property="fLineno" column="f_lineno"/>
         <result property="fGoodsid" column="f_goodsid"/>
+        <result property="fMblno" column="f_mblno"/>
         <result property="fWarehouselocid" column="f_warehouselocid"/>
         <result property="fBsdate" column="f_bsdate"/>
+        <result property="fOriginalbillno" column="f_originalbillno"/>
         <result property="fBoxno" column="f_boxno"/>
         <result property="fCntqty" column="f_cntqty"/>
         <result property="fGoodsval" column="f_goodsval"/>
         <result property="fCntrtype" column="f_cntrtype"/>
-        <result property="fOriginalbillno" column="f_originalbillno"/>
+        <result property="fChargedate" column="f_chargedate"/>
+        <result property="fBillingway" column="f_billingway"/>
         <result property="fPlanqty" column="f_planqty"/>
-        <result property="fMblno" column="f_mblno"/>
         <result property="fPlanvolumn" column="f_planvolumn"/>
         <result property="fPackagespecs" column="f_packagespecs"/>
         <result property="fPlangrossweight" column="f_plangrossweight"/>
@@ -35,12 +37,11 @@
         <result property="updateBy" column="update_by"/>
         <result property="updateTime" column="update_time"/>
         <result property="remark" column="remark"/>
+        <result property="fMarks" column="f_marks"/>
     </resultMap>
 
     <sql id="selectTWarehousebillsitemsVo">
-        select f_id, f_pid, f_lineno, f_goodsid, f_warehouselocid, f_originalbillno, f_mblno, f_bsdate, f_boxno, f_cntqty,
-         f_goodsval, f_cntrtype, f_planqty, f_planvolumn, f_packagespecs, f_plangrossweight, f_plannetweight, f_qty, f_volumn, f_grossweight, f_netweight,
-          f_cntrno, f_truckno, f_billstatus, del_flag, create_by, create_time, update_by, update_time, remark from t_warehousebillsitems
+        select f_id, f_pid, f_lineno, f_goodsid, f_mblno, f_warehouselocid, f_bsdate, f_originalbillno, f_boxno, f_cntqty, f_goodsval, f_cntrtype, f_chargedate, f_billingway, f_planqty, f_planvolumn, f_packagespecs, f_plangrossweight, f_plannetweight, f_qty, f_volumn, f_grossweight, f_netweight, f_cntrno, f_truckno, f_billstatus, del_flag, create_by, create_time, update_by, update_time, remark, f_marks from t_warehousebillsitems
     </sql>
 
     <select id="selectTWarehousebillsitemsList" parameterType="TWarehousebillsitems"
@@ -50,16 +51,17 @@
             <if test="fPid != null ">and f_pid = #{fPid}</if>
             <if test="fLineno != null ">and f_lineno = #{fLineno}</if>
             <if test="fGoodsid != null ">and f_goodsid = #{fGoodsid}</if>
+            <if test="fMblno != null  and fMblno != ''">and f_mblno = #{fMblno}</if>
             <if test="fWarehouselocid != null ">and f_warehouselocid = #{fWarehouselocid}</if>
             <if test="fBsdate != null ">and f_bsdate = #{fBsdate}</if>
+            <if test="fOriginalbillno != null  and fOriginalbillno != ''">and f_originalbillno = #{fOriginalbillno}</if>
             <if test="fBoxno != null  and fBoxno != ''">and f_boxno = #{fBoxno}</if>
             <if test="fCntqty != null ">and f_cntqty = #{fCntqty}</if>
-            <if test="fOriginalbillno != null  and fOriginalbillno != ''">and f_originalbillno = #{fOriginalbillno}</if>
             <if test="fGoodsval != null ">and f_goodsval = #{fGoodsval}</if>
             <if test="fCntrtype != null  and fCntrtype != ''">and f_cntrtype = #{fCntrtype}</if>
             <if test="fPlanqty != null ">and f_planqty = #{fPlanqty}</if>
-            <if test="fMblno != null ">and f_mblno = #{fMblno}</if>
             <if test="fPlanvolumn != null ">and f_planvolumn = #{fPlanvolumn}</if>
+            <if test="fChargedate != null ">and f_chargedate = #{fChargedate}</if>
             <if test="fPackagespecs != null ">and f_packagespecs = #{fPackagespecs}</if>
             <if test="fPlangrossweight != null ">and f_plangrossweight = #{fPlangrossweight}</if>
             <if test="fPlannetweight != null ">and f_plannetweight = #{fPlannetweight}</if>
@@ -70,43 +72,44 @@
             <if test="fCntrno != null  and fCntrno != ''">and f_cntrno = #{fCntrno}</if>
             <if test="fTruckno != null  and fTruckno != ''">and f_truckno = #{fTruckno}</if>
             <if test="fBillstatus != null  and fBillstatus != ''">and f_billstatus = #{fBillstatus}</if>
+            <if test="fMarks != null  and fMarks != ''">and f_marks = #{fMarks}</if>
         </where>
     </select>
 
     <select id="selectGoodsTransferitemsList" parameterType="TWarehousebillsitems" resultType="Map">
         select
         DISTINCT
-            item.f_id AS fId,
-            item.f_pid AS fPid,
-            item.f_lineno AS fLineno,
-            item.f_goodsid AS fGoodsid,
-            goods.f_name AS fGoodsids,
-            item.f_warehouselocid AS fWarehouselocid,
-            area.f_name AS fWarehouselocids,
-            item.f_originalbillno AS fOriginalbillno,
-            item.f_mblno AS fMblno,
-            item.f_bsdate AS fBsdate,
-            item.f_boxno AS fBoxno,
-            item.f_cntqty AS fCntqty,
-            item.f_goodsval AS fGoodsval,
-            item.f_cntrtype AS fCntrtype,
-            item.f_planqty AS fPlanqty,
-            item.f_planvolumn AS fPlanvolumn,
-            item.f_packagespecs AS fPackagespecs,
-            item.f_plangrossweight AS fPlangrossweight,
-            item.f_plannetweight AS fPlannetweight,
-            item.f_qty AS fQty,
-            item.f_volumn AS fVolumn,
-            item.f_grossweight AS fGrossweight,
-            item.f_netweight AS fNetweight,
-            item.f_cntrno AS fCntrno,
-            item.f_truckno AS fTruckno,
-            item.f_billstatus AS fBillstatus,
-            item.remark
+        item.f_id AS fId,
+        item.f_pid AS fPid,
+        item.f_lineno AS fLineno,
+        item.f_goodsid AS fGoodsid,
+        goods.f_name AS fGoodsids,
+        item.f_warehouselocid AS fWarehouselocid,
+        area.f_name AS fWarehouselocids,
+        item.f_originalbillno AS fOriginalbillno,
+        item.f_mblno AS fMblno,
+        item.f_bsdate AS fBsdate,
+        item.f_boxno AS fBoxno,
+        item.f_cntqty AS fCntqty,
+        item.f_goodsval AS fGoodsval,
+        item.f_cntrtype AS fCntrtype,
+        item.f_planqty AS fPlanqty,
+        item.f_planvolumn AS fPlanvolumn,
+        item.f_packagespecs AS fPackagespecs,
+        item.f_plangrossweight AS fPlangrossweight,
+        item.f_plannetweight AS fPlannetweight,
+        item.f_qty AS fQty,
+        item.f_volumn AS fVolumn,
+        item.f_grossweight AS fGrossweight,
+        item.f_netweight AS fNetweight,
+        item.f_cntrno AS fCntrno,
+        item.f_truckno AS fTruckno,
+        item.f_billstatus AS fBillstatus,
+        item.remark
         from
-            t_warehousebillsitems item
-            LEFT JOIN t_goods goods ON goods.f_id = item.f_goodsid
-            LEFT JOIN t_warehouse_area area ON area.f_id = item.f_warehouselocid
+        t_warehousebillsitems item
+        LEFT JOIN t_goods goods ON goods.f_id = item.f_goodsid
+        LEFT JOIN t_warehouse_area area ON area.f_id = item.f_warehouselocid
         <where>
             <if test="fPid != null ">and item.f_pid = #{fPid}</if>
         </where>
@@ -128,18 +131,20 @@
             <if test="fWarehouselocid != null">f_warehouselocid,</if>
             <if test="fBsdate != null">f_bsdate,</if>
             <if test="fOriginalbillno != null">f_originalbillno,</if>
-            <if test="fCntqty != null">f_cntqty,</if>
             <if test="fBoxno != null">f_boxno,</if>
-            <if test="fCntrtype != null">f_cntrtype,</if>
+            <if test="fCntqty != null">f_cntqty,</if>
             <if test="fGoodsval != null">f_goodsval,</if>
+            <if test="fCntrtype != null">f_cntrtype,</if>
+            <if test="fChargedate != null">f_chargedate,</if>
+            <if test="fBillingway != null">f_billingway,</if>
             <if test="fPlanqty != null">f_planqty,</if>
             <if test="fPlanvolumn != null">f_planvolumn,</if>
             <if test="fPackagespecs != null">f_packagespecs,</if>
             <if test="fPlangrossweight != null">f_plangrossweight,</if>
             <if test="fPlannetweight != null">f_plannetweight,</if>
             <if test="fQty != null">f_qty,</if>
-            <if test="fGrossweight != null">f_grossweight,</if>
             <if test="fVolumn != null">f_volumn,</if>
+            <if test="fGrossweight != null">f_grossweight,</if>
             <if test="fNetweight != null">f_netweight,</if>
             <if test="fCntrno != null">f_cntrno,</if>
             <if test="fTruckno != null">f_truckno,</if>
@@ -160,18 +165,20 @@
             <if test="fWarehouselocid != null">#{fWarehouselocid},</if>
             <if test="fBsdate != null">#{fBsdate},</if>
             <if test="fOriginalbillno != null">#{fOriginalbillno},</if>
-            <if test="fCntqty != null">#{fCntqty},</if>
             <if test="fBoxno != null">#{fBoxno},</if>
-            <if test="fCntrtype != null">#{fCntrtype},</if>
+            <if test="fCntqty != null">#{fCntqty},</if>
             <if test="fGoodsval != null">#{fGoodsval},</if>
+            <if test="fCntrtype != null">#{fCntrtype},</if>
+            <if test="fChargedate != null">#{fChargedate},</if>
+            <if test="fBillingway != null">#{fBillingway},</if>
             <if test="fPlanqty != null">#{fPlanqty},</if>
             <if test="fPlanvolumn != null">#{fPlanvolumn},</if>
             <if test="fPackagespecs != null">#{fPackagespecs},</if>
             <if test="fPlangrossweight != null">#{fPlangrossweight},</if>
             <if test="fPlannetweight != null">#{fPlannetweight},</if>
             <if test="fQty != null">#{fQty},</if>
-            <if test="fGrossweight != null">#{fGrossweight},</if>
             <if test="fVolumn != null">#{fVolumn},</if>
+            <if test="fGrossweight != null">#{fGrossweight},</if>
             <if test="fNetweight != null">#{fNetweight},</if>
             <if test="fCntrno != null">#{fCntrno},</if>
             <if test="fTruckno != null">#{fTruckno},</if>
@@ -196,18 +203,20 @@
             <if test="fWarehouselocid != null">f_warehouselocid = #{fWarehouselocid},</if>
             <if test="fBsdate != null">f_bsdate = #{fBsdate},</if>
             <if test="fOriginalbillno != null">f_originalbillno = #{fOriginalbillno},</if>
-            <if test="fCntqty != null">f_cntqty = #{fCntqty},</if>
             <if test="fBoxno != null">f_boxno = #{fBoxno},</if>
-            <if test="fCntrtype != null">f_cntrtype = #{fCntrtype},</if>
+            <if test="fCntqty != null">f_cntqty = #{fCntqty},</if>
             <if test="fGoodsval != null">f_goodsval = #{fGoodsval},</if>
+            <if test="fCntrtype != null">f_cntrtype = #{fCntrtype},</if>
+            <if test="fChargedate != null">f_chargedate = #{fChargedate},</if>
+            <if test="fBillingway != null">f_billingway = #{fBillingway},</if>
             <if test="fPlanqty != null">f_planqty = #{fPlanqty},</if>
             <if test="fPlanvolumn != null">f_planvolumn = #{fPlanvolumn},</if>
             <if test="fPackagespecs != null">f_packagespecs = #{fPackagespecs},</if>
             <if test="fPlangrossweight != null">f_plangrossweight = #{fPlangrossweight},</if>
             <if test="fPlannetweight != null">f_plannetweight = #{fPlannetweight},</if>
             <if test="fQty != null">f_qty = #{fQty},</if>
-            <if test="fGrossweight != null">f_grossweight = #{fGrossweight},</if>
             <if test="fVolumn != null">f_volumn = #{fVolumn},</if>
+            <if test="fGrossweight != null">f_grossweight = #{fGrossweight},</if>
             <if test="fNetweight != null">f_netweight = #{fNetweight},</if>
             <if test="fCntrno != null">f_cntrno = #{fCntrno},</if>
             <if test="fTruckno != null">f_truckno = #{fTruckno},</if>