瀏覽代碼

资源管理提交

hujh 3 年之前
父節點
當前提交
f2eb93b3b0
共有 33 個文件被更改,包括 1553 次插入107 次删除
  1. 5 7
      src/main/java/com/steerinfo/dil/controller/RmsCarrierController.java
  2. 85 0
      src/main/java/com/steerinfo/dil/controller/RmsConsigneeController.java
  3. 1 1
      src/main/java/com/steerinfo/dil/controller/RmsShipperController.java
  4. 0 3
      src/main/java/com/steerinfo/dil/controller/RmsWarehouseController.java
  5. 14 0
      src/main/java/com/steerinfo/dil/mapper/RmsConsigneeMapper.java
  6. 319 0
      src/main/java/com/steerinfo/dil/model/RmsConsignee.java
  7. 14 0
      src/main/java/com/steerinfo/dil/model/RmsWarehouse.java
  8. 3 2
      src/main/java/com/steerinfo/dil/service/IRmsCarrierService.java
  9. 25 0
      src/main/java/com/steerinfo/dil/service/IRmsConsigneeService.java
  10. 13 1
      src/main/java/com/steerinfo/dil/service/impl/RmsCapacityServiceImpl.java
  11. 11 1
      src/main/java/com/steerinfo/dil/service/impl/RmsCarDriverServiceImpl.java
  12. 121 20
      src/main/java/com/steerinfo/dil/service/impl/RmsCarrierServiceImpl.java
  13. 38 0
      src/main/java/com/steerinfo/dil/service/impl/RmsConsigneeServiceImpl.java
  14. 11 1
      src/main/java/com/steerinfo/dil/service/impl/RmsGatepostServiceImpl.java
  15. 11 1
      src/main/java/com/steerinfo/dil/service/impl/RmsMaterialServiceImpl.java
  16. 12 3
      src/main/java/com/steerinfo/dil/service/impl/RmsPersonnelServiceImpl.java
  17. 12 1
      src/main/java/com/steerinfo/dil/service/impl/RmsShipperServiceImpl.java
  18. 11 2
      src/main/java/com/steerinfo/dil/service/impl/RmsSupplierServiceImpl.java
  19. 2 13
      src/main/java/com/steerinfo/dil/service/impl/RmsWarehouseServiceImpl.java
  20. 10 2
      src/main/resources/com/steerinfo/dil/mapper/RmsCapacityMapper.xml
  21. 9 2
      src/main/resources/com/steerinfo/dil/mapper/RmsCarDriverMapper.xml
  22. 9 1
      src/main/resources/com/steerinfo/dil/mapper/RmsCarrierMapper.xml
  23. 656 0
      src/main/resources/com/steerinfo/dil/mapper/RmsConsigneeMapper.xml
  24. 9 0
      src/main/resources/com/steerinfo/dil/mapper/RmsDriverCapacityMapper.xml
  25. 9 0
      src/main/resources/com/steerinfo/dil/mapper/RmsGatepostMapper.xml
  26. 9 0
      src/main/resources/com/steerinfo/dil/mapper/RmsMaterialMapper.xml
  27. 9 1
      src/main/resources/com/steerinfo/dil/mapper/RmsMaterialTypeMapper.xml
  28. 9 1
      src/main/resources/com/steerinfo/dil/mapper/RmsOilPriceMapper.xml
  29. 9 0
      src/main/resources/com/steerinfo/dil/mapper/RmsPersonnelMapper.xml
  30. 11 1
      src/main/resources/com/steerinfo/dil/mapper/RmsShipperMapper.xml
  31. 9 0
      src/main/resources/com/steerinfo/dil/mapper/RmsSupplierMapper.xml
  32. 9 0
      src/main/resources/com/steerinfo/dil/mapper/RmsTruckCalculateMapper.xml
  33. 78 43
      src/main/resources/com/steerinfo/dil/mapper/RmsWarehouseMapper.xml

+ 5 - 7
src/main/java/com/steerinfo/dil/controller/RmsCarrierController.java

@@ -18,6 +18,7 @@ import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
 
 import java.math.BigDecimal;
+import java.text.ParseException;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
@@ -104,9 +105,6 @@ public class RmsCarrierController extends BaseRESTfulController {
         if (listTotal == null) {
             listTotal = rmsCarrierService.getCarrierList(mapValue);
         }
-
-//        System.out.println(listTotal);
-
         System.out.println(listTotal);
         PageHelper.startPage(pageNum, pageSize);
         //分页查询数据
@@ -148,8 +146,8 @@ public class RmsCarrierController extends BaseRESTfulController {
     @ApiImplicitParam(name = "rmsCarrier", value = "详细实体rmsCarrier", required = true, dataType = "RmsCarrier")
     //@RequiresPermissions("rmscarrier:create")
     @PostMapping(value = "/insertCarrier")
-    public RESTfulResult insertCarrier(@RequestBody(required = false) RmsCarrier rmsCarrier){
-        int result = rmsCarrierService.insertCarrier(rmsCarrier);
+    public RESTfulResult insertCarrier(@RequestBody(required = false) Map<String, Object> mapValue) throws ParseException {
+        int result = rmsCarrierService.insertCarrier(mapValue);
         if (result==-1){
             return failed();
         }
@@ -168,8 +166,8 @@ public class RmsCarrierController extends BaseRESTfulController {
     })
     //@RequiresPermissions("rmscarrier:update")
     @PostMapping(value = "/updateCarrier", produces  = "application/json;charset=UTF-8")
-    public RESTfulResult updateCarrier(@RequestBody RmsCarrier rmsCarrier){
-        int result = rmsCarrierService.updateCarrier(rmsCarrier);
+    public RESTfulResult updateCarrier(@RequestBody(required = false) Map<String ,Object> mapValue) throws ParseException {
+        int result = rmsCarrierService.updateCarrier(mapValue);
         return success(result);
     }
 

+ 85 - 0
src/main/java/com/steerinfo/dil/controller/RmsConsigneeController.java

@@ -0,0 +1,85 @@
+package com.steerinfo.dil.controller;
+
+import com.alibaba.fastjson.JSON;
+import com.steerinfo.dil.feign.ESFeign;
+import com.steerinfo.dil.service.impl.RmsConsigneeServiceImpl;
+import com.steerinfo.dil.util.BaseRESTfulController;
+import com.steerinfo.dil.util.ColumnDataUtil;
+import com.steerinfo.dil.util.PageListAdd;
+import com.steerinfo.framework.controller.RESTfulResult;
+import com.steerinfo.framework.service.pagehelper.PageHelper;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+@RestController
+@RequestMapping("/${api.version}/rmsconsignee")
+public class RmsConsigneeController extends BaseRESTfulController {
+    @Autowired
+    RmsConsigneeServiceImpl rmsConsigneeService;
+    @Autowired
+    ColumnDataUtil columnDataUtil;
+    @Autowired
+    ESFeign esFeign;
+
+    @ApiOperation(value = "模糊查询展示客户信息表", notes = "分页查询")
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "pageNum", value = "查询页数", required = false, dataType = "Integer"),
+            @ApiImplicitParam(name = "pageSize", value = "每页记录数", required = false, dataType = "Integer"),
+            @ApiImplicitParam(name = "apiId", value = "407", required = false, dataType = "BigDecimal"),
+    })
+    @PostMapping(value = "/getConsigneeList")
+    public RESTfulResult getConsigneeList(@RequestBody(required = false) Map<String, Object> mapValue,
+                                         Integer apiId,
+                                         Integer pageNum,
+                                         Integer pageSize,
+                                         String con) {
+        if (mapValue==null){
+            mapValue=new HashMap<>();
+        }
+        //框计算
+        if (con != null) {
+            if (!"undefined".equals(con)) {
+                //设置要查询的索引名称
+                String index = "get_consignee_list";
+                //获取查询结果
+                return success(esFeign.getConResult(mapValue, index, apiId, pageNum, pageSize, con));
+            }
+        }
+        //初始化过滤
+        List<Map<String, Object>> listTotal = null;
+        //如果有条件查询则跳过初始化,和创建索引
+        if (mapValue.size() == 0) {
+            //将查询结果存入索引中
+            listTotal = rmsConsigneeService.getConsigneeList(null);
+            Map<String, Object> map = new HashMap<>();
+            //添加索引
+            map.put("index", "get_consignee_list");
+            //添加id
+            map.put("indexId", "consigneeId");
+            listTotal.add(map);
+            //新建索引
+            String s = JSON.toJSONString(listTotal);
+            esFeign.insertIndex(listTotal);
+            //删除
+            listTotal.remove(listTotal.size() - 1);
+        }
+        if (listTotal == null) {
+            listTotal = rmsConsigneeService.getConsigneeList(mapValue);
+        }
+        PageHelper.startPage(pageNum, pageSize);
+        //分页查询数据
+        List<Map<String, Object>> columnList = rmsConsigneeService.getConsigneeList(mapValue);
+        PageListAdd data = columnDataUtil.tableColumnData(apiId, listTotal, columnList);
+        return success(data);
+    }
+}

+ 1 - 1
src/main/java/com/steerinfo/dil/controller/RmsShipperController.java

@@ -74,7 +74,7 @@ public class RmsShipperController extends BaseRESTfulController {
         if (con != null) {
             if (!"undefined".equals(con)) {
                 //设置要查询的索引名称
-                String index = "get_supplier_list";
+                String index = "get_shipper_list";
                 //获取查询结果
                 return success(esFeign.getConResult(mapValue, index, apiId, pageNum, pageSize, con));
             }

+ 0 - 3
src/main/java/com/steerinfo/dil/controller/RmsWarehouseController.java

@@ -50,9 +50,6 @@ public class RmsWarehouseController extends BaseRESTfulController {
     @PostMapping(value = "/insertWarehouse")
     public RESTfulResult insertWarehouse(@RequestBody(required = false) RmsWarehouse rmsWarehouse){
         int result = rmsWarehouseService.insertWarehouse(rmsWarehouse);
-        if (result==-1){
-            return failed();
-        }
         return success(result);
     }
 

+ 14 - 0
src/main/java/com/steerinfo/dil/mapper/RmsConsigneeMapper.java

@@ -0,0 +1,14 @@
+package com.steerinfo.dil.mapper;
+
+import com.steerinfo.dil.model.RmsConsignee;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+import java.util.Map;
+
+@Mapper
+public interface RmsConsigneeMapper extends IBaseMapper<RmsConsignee, Long> {
+
+    List<Map<String, Object>> getConsigneeList(Map<String, Object> mapValue);
+}

+ 319 - 0
src/main/java/com/steerinfo/dil/model/RmsConsignee.java

@@ -0,0 +1,319 @@
+package com.steerinfo.dil.model;
+
+import com.steerinfo.framework.model.IBasePO;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+@ApiModel(value="收货客户")
+public class RmsConsignee implements IBasePO<BigDecimal> {
+    /**
+     * 主键id(CONSIGNEE_ID,DECIMAL,10)
+     */
+    @ApiModelProperty(value="主键id",required=true)
+    private BigDecimal consigneeId;
+
+    /**
+     * 公司名称(CONSIGNEE_COMPANY_NAME,VARCHAR,100)
+     */
+    @ApiModelProperty(value="公司名称",required=false)
+    private String consigneeCompanyName;
+
+    /**
+     * 收货方简称(CONSIGNEE_ABBREVIATION,VARCHAR,50)
+     */
+    @ApiModelProperty(value="收货方简称",required=false)
+    private String consigneeAbbreviation;
+
+    /**
+     * 注册地址(CONSIGNEE_REGISTERED_ADDRESS,VARCHAR,50)
+     */
+    @ApiModelProperty(value="注册地址",required=false)
+    private String consigneeRegisteredAddress;
+
+    /**
+     * 收货地址(CONSIGNEE_RECEIVE_ADDRESS,VARCHAR,50)
+     */
+    @ApiModelProperty(value="收货地址",required=false)
+    private String consigneeReceiveAddress;
+
+    /**
+     * 注册时间(CONSIGNEE_REGISTRATION_TIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="注册时间",required=false)
+    private Date consigneeRegistrationTime;
+
+    /**
+     * 联系人(CONSIGNEE_CONTACT_NAME,VARCHAR,20)
+     */
+    @ApiModelProperty(value="联系人",required=false)
+    private String consigneeContactName;
+
+    /**
+     * 质保书份数(CONSIGNEE_WARRANTY_AMOUNT,DECIMAL,0)
+     */
+    @ApiModelProperty(value="质保书份数",required=false)
+    private BigDecimal consigneeWarrantyAmount;
+
+    /**
+     * 质保书(0:理重;1:磅重)(CONSIGNEE_WARRANTY_WEIGHT,VARCHAR,4)
+     */
+    @ApiModelProperty(value="质保书(0:理重;1:磅重)",required=false)
+    private String consigneeWarrantyWeight;
+
+    /**
+     * 联系电话(CONSIGNEE_CONTACT_TEL,VARCHAR,20)
+     */
+    @ApiModelProperty(value="联系电话",required=false)
+    private String consigneeContactTel;
+
+    /**
+     * 换票送货单份数(CONSIGNEE_EXCHANGE_DELIVERY,DECIMAL,0)
+     */
+    @ApiModelProperty(value="换票送货单份数",required=false)
+    private BigDecimal consigneeExchangeDelivery;
+
+    /**
+     * 记录创建人(INSERT_USERNAME,VARCHAR,20)
+     */
+    @ApiModelProperty(value="记录创建人",required=false)
+    private String insertUsername;
+
+    /**
+     * 记录创建时间(INSERT_TIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="记录创建时间",required=false)
+    private Date insertTime;
+
+    /**
+     * 记录修改人(UPDATE_USERNAME,VARCHAR,20)
+     */
+    @ApiModelProperty(value="记录修改人",required=false)
+    private String updateUsername;
+
+    /**
+     * 记录修改时间(UPDATE_TIME,TIMESTAMP,7)
+     */
+    @ApiModelProperty(value="记录修改时间",required=false)
+    private Date updateTime;
+
+    /**
+     * 记录创建或修改备注(INSERT_UPDATE_REMARK,VARCHAR,100)
+     */
+    @ApiModelProperty(value="记录创建或修改备注",required=false)
+    private String insertUpdateRemark;
+
+    /**
+     * 逻辑删除(DELETED,DECIMAL,0)
+     */
+    @ApiModelProperty(value="逻辑删除",required=false)
+    private BigDecimal deleted;
+
+    /**
+     * 金蝶收获客户主键ID(EAS_CONSIGNEE_ID,VARCHAR,50)
+     */
+    @ApiModelProperty(value="金蝶收获客户主键ID",required=false)
+    private String easConsigneeId;
+
+    /**
+     * 收货客户编码(CONSIGNEE_CODE,VARCHAR,50)
+     */
+    @ApiModelProperty(value="收货客户编码",required=false)
+    private String consigneeCode;
+
+    private static final long serialVersionUID = 1L;
+
+    @Override
+    public BigDecimal getId() {
+        return this.consigneeId;
+    }
+
+    @Override
+    public void setId(BigDecimal consigneeId) {
+        this.consigneeId = consigneeId;
+    }
+
+    public BigDecimal getConsigneeId() {
+        return consigneeId;
+    }
+
+    public void setConsigneeId(BigDecimal consigneeId) {
+        this.consigneeId = consigneeId;
+    }
+
+    public String getConsigneeCompanyName() {
+        return consigneeCompanyName;
+    }
+
+    public void setConsigneeCompanyName(String consigneeCompanyName) {
+        this.consigneeCompanyName = consigneeCompanyName == null ? null : consigneeCompanyName.trim();
+    }
+
+    public String getConsigneeAbbreviation() {
+        return consigneeAbbreviation;
+    }
+
+    public void setConsigneeAbbreviation(String consigneeAbbreviation) {
+        this.consigneeAbbreviation = consigneeAbbreviation == null ? null : consigneeAbbreviation.trim();
+    }
+
+    public String getConsigneeRegisteredAddress() {
+        return consigneeRegisteredAddress;
+    }
+
+    public void setConsigneeRegisteredAddress(String consigneeRegisteredAddress) {
+        this.consigneeRegisteredAddress = consigneeRegisteredAddress == null ? null : consigneeRegisteredAddress.trim();
+    }
+
+    public String getConsigneeReceiveAddress() {
+        return consigneeReceiveAddress;
+    }
+
+    public void setConsigneeReceiveAddress(String consigneeReceiveAddress) {
+        this.consigneeReceiveAddress = consigneeReceiveAddress == null ? null : consigneeReceiveAddress.trim();
+    }
+
+    public Date getConsigneeRegistrationTime() {
+        return consigneeRegistrationTime;
+    }
+
+    public void setConsigneeRegistrationTime(Date consigneeRegistrationTime) {
+        this.consigneeRegistrationTime = consigneeRegistrationTime;
+    }
+
+    public String getConsigneeContactName() {
+        return consigneeContactName;
+    }
+
+    public void setConsigneeContactName(String consigneeContactName) {
+        this.consigneeContactName = consigneeContactName == null ? null : consigneeContactName.trim();
+    }
+
+    public BigDecimal getConsigneeWarrantyAmount() {
+        return consigneeWarrantyAmount;
+    }
+
+    public void setConsigneeWarrantyAmount(BigDecimal consigneeWarrantyAmount) {
+        this.consigneeWarrantyAmount = consigneeWarrantyAmount;
+    }
+
+    public String getConsigneeWarrantyWeight() {
+        return consigneeWarrantyWeight;
+    }
+
+    public void setConsigneeWarrantyWeight(String consigneeWarrantyWeight) {
+        this.consigneeWarrantyWeight = consigneeWarrantyWeight == null ? null : consigneeWarrantyWeight.trim();
+    }
+
+    public String getConsigneeContactTel() {
+        return consigneeContactTel;
+    }
+
+    public void setConsigneeContactTel(String consigneeContactTel) {
+        this.consigneeContactTel = consigneeContactTel == null ? null : consigneeContactTel.trim();
+    }
+
+    public BigDecimal getConsigneeExchangeDelivery() {
+        return consigneeExchangeDelivery;
+    }
+
+    public void setConsigneeExchangeDelivery(BigDecimal consigneeExchangeDelivery) {
+        this.consigneeExchangeDelivery = consigneeExchangeDelivery;
+    }
+
+    public String getInsertUsername() {
+        return insertUsername;
+    }
+
+    public void setInsertUsername(String insertUsername) {
+        this.insertUsername = insertUsername == null ? null : insertUsername.trim();
+    }
+
+    public Date getInsertTime() {
+        return insertTime;
+    }
+
+    public void setInsertTime(Date insertTime) {
+        this.insertTime = insertTime;
+    }
+
+    public String getUpdateUsername() {
+        return updateUsername;
+    }
+
+    public void setUpdateUsername(String updateUsername) {
+        this.updateUsername = updateUsername == null ? null : updateUsername.trim();
+    }
+
+    public Date getUpdateTime() {
+        return updateTime;
+    }
+
+    public void setUpdateTime(Date updateTime) {
+        this.updateTime = updateTime;
+    }
+
+    public String getInsertUpdateRemark() {
+        return insertUpdateRemark;
+    }
+
+    public void setInsertUpdateRemark(String insertUpdateRemark) {
+        this.insertUpdateRemark = insertUpdateRemark == null ? null : insertUpdateRemark.trim();
+    }
+
+    public BigDecimal getDeleted() {
+        return deleted;
+    }
+
+    public void setDeleted(BigDecimal deleted) {
+        this.deleted = deleted;
+    }
+
+    public String getEasConsigneeId() {
+        return easConsigneeId;
+    }
+
+    public void setEasConsigneeId(String easConsigneeId) {
+        this.easConsigneeId = easConsigneeId == null ? null : easConsigneeId.trim();
+    }
+
+    public String getConsigneeCode() {
+        return consigneeCode;
+    }
+
+    public void setConsigneeCode(String consigneeCode) {
+        this.consigneeCode = consigneeCode == null ? null : consigneeCode.trim();
+    }
+
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder();
+        sb.append(getClass().getSimpleName());
+        sb.append(" [");
+        sb.append("Hash = ").append(hashCode());
+        sb.append(", consigneeId=").append(consigneeId);
+        sb.append(", consigneeCompanyName=").append(consigneeCompanyName);
+        sb.append(", consigneeAbbreviation=").append(consigneeAbbreviation);
+        sb.append(", consigneeRegisteredAddress=").append(consigneeRegisteredAddress);
+        sb.append(", consigneeReceiveAddress=").append(consigneeReceiveAddress);
+        sb.append(", consigneeRegistrationTime=").append(consigneeRegistrationTime);
+        sb.append(", consigneeContactName=").append(consigneeContactName);
+        sb.append(", consigneeWarrantyAmount=").append(consigneeWarrantyAmount);
+        sb.append(", consigneeWarrantyWeight=").append(consigneeWarrantyWeight);
+        sb.append(", consigneeContactTel=").append(consigneeContactTel);
+        sb.append(", consigneeExchangeDelivery=").append(consigneeExchangeDelivery);
+        sb.append(", insertUsername=").append(insertUsername);
+        sb.append(", insertTime=").append(insertTime);
+        sb.append(", updateUsername=").append(updateUsername);
+        sb.append(", updateTime=").append(updateTime);
+        sb.append(", insertUpdateRemark=").append(insertUpdateRemark);
+        sb.append(", deleted=").append(deleted);
+        sb.append(", easConsigneeId=").append(easConsigneeId);
+        sb.append(", consigneeCode=").append(consigneeCode);
+        sb.append(", serialVersionUID=").append(serialVersionUID);
+        sb.append("]");
+        return sb.toString();
+    }
+}

+ 14 - 0
src/main/java/com/steerinfo/dil/model/RmsWarehouse.java

@@ -87,6 +87,20 @@ public class RmsWarehouse implements IBasePO<BigDecimal> {
     @ApiModelProperty(value="逻辑删除",required=false)
     private BigDecimal deleted;
 
+    /*
+     * 托运人Id
+     * */
+    @ApiModelProperty(value = "托运人",required = false)
+    private BigDecimal shipperId;
+
+    public BigDecimal getShipperId() {
+        return shipperId;
+    }
+
+    public void setShipperId(BigDecimal shipperId) {
+        this.shipperId = shipperId;
+    }
+
     private static final long serialVersionUID = 1L;
 
     @Override

+ 3 - 2
src/main/java/com/steerinfo/dil/service/IRmsCarrierService.java

@@ -3,6 +3,7 @@ package com.steerinfo.dil.service;
 import com.steerinfo.dil.model.RmsCarrier;
 
 import java.math.BigDecimal;
+import java.text.ParseException;
 import java.util.List;
 import java.util.Map;
 
@@ -25,9 +26,9 @@ public interface IRmsCarrierService {
     //删除承运商信息
     int deleteCarrier(BigDecimal id);
     //修改承运商信息
-    int updateCarrier(RmsCarrier rmsCarrier);
+    int updateCarrier(Map<String, Object> mapValue) throws ParseException;
     //添加承运商信息
-    int insertCarrier(RmsCarrier rmsCarrier);
+    int insertCarrier(Map<String, Object> mapValue) throws ParseException;
     //    根据id值展示承运商信息
     List<Map<String, Object>> getCarrierById(BigDecimal id);
 //    展示中标区域

+ 25 - 0
src/main/java/com/steerinfo/dil/service/IRmsConsigneeService.java

@@ -0,0 +1,25 @@
+package com.steerinfo.dil.service;
+
+import com.steerinfo.dil.model.RmsConsignee;
+import com.steerinfo.framework.service.IBaseService;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * RmsConsignee服务接口:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-12-21 09:47
+ * 类描述
+ * 修订历史:
+ * 日期:2021-12-21
+ * 作者:generator
+ * 参考:
+ * 描述:RmsConsignee服务接口
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+public interface IRmsConsigneeService{
+
+    List<Map<String, Object>> getConsigneeList(Map<String, Object> mapValue);
+}

+ 13 - 1
src/main/java/com/steerinfo/dil/service/impl/RmsCapacityServiceImpl.java

@@ -42,8 +42,20 @@ public class RmsCapacityServiceImpl implements IRmsCapacityService {
         Map<String, Object> map=new HashMap<>();
         map.put("capacityNumber",capacityNumber);
         List<RmsCapacity> rmsCapacities=rmsCapacityMapper.selectByParameters(map);
+
         if (rmsCapacities.size()!=0){
-            i=-1;
+            RmsCapacity rmsCapacity1=rmsCapacities.get(0);
+            if (rmsCapacity1.getDeleted().equals(new BigDecimal(1))){
+                rmsCapacity.setCapacityStatus(new BigDecimal(0));
+                rmsCapacity.setDeleted(new BigDecimal(0));
+                rmsCapacity.setInsertTime(new Date());
+                rmsCapacity.setInsertUsername("admin");
+                rmsCapacity.setCapacityId(rmsCapacityMapper.selectCapacityId());
+                i+=rmsCapacityMapper.insertSelective(rmsCapacity);
+            }
+            else{
+                i=-1;
+            }
         }
         else {
             rmsCapacity.setCapacityStatus(new BigDecimal(0));

+ 11 - 1
src/main/java/com/steerinfo/dil/service/impl/RmsCarDriverServiceImpl.java

@@ -65,8 +65,18 @@ public class RmsCarDriverServiceImpl implements IRmsCarDriverService {
         Map<String, Object> map=new HashMap<>();
         map.put("driverIdentityCard",driverIdentityCard);
         List<RmsCarDriver> rmsCarDrivers=rmsCarDriverMapper.selectByParameters(map);
+
         if (rmsCarDrivers.size()!=0){
-            i=-1;
+            RmsCarDriver rmsCarDriver1=rmsCarDrivers.get(0);
+            if (rmsCarDriver1.getDeleted().equals(new BigDecimal(1))){
+                rmsCarDriver.setInsertUsername("admin");
+                rmsCarDriver.setInsertTime(new Date());
+                rmsCarDriver.setDeleted(new BigDecimal(0));
+                rmsCarDriver.setDriverId(rmsCarDriverMapper.selectCarDriverId());
+                i+= rmsCarDriverMapper.insertSelective(rmsCarDriver);
+            }else {
+                i = -1;
+            }
         }
         else {
             rmsCarDriver.setInsertUsername("admin");

+ 121 - 20
src/main/java/com/steerinfo/dil/service/impl/RmsCarrierServiceImpl.java

@@ -9,6 +9,8 @@ import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
 import java.math.BigDecimal;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
 import java.util.Date;
 import java.util.HashMap;
 import java.util.List;
@@ -58,61 +60,160 @@ public class RmsCarrierServiceImpl implements IRmsCarrierService {
 
     /**
      * 修改承运商信息
-     * @param rmsCarrier
+     * @param mapValue
      * @return
      */
     @Override
-    public int updateCarrier(RmsCarrier rmsCarrier) {
-        String transportType=rmsCarrier.getCarrierTransportType();
+    public int updateCarrier(Map<String ,Object> mapValue) throws ParseException {
+        SimpleDateFormat simpleDateFormat=new SimpleDateFormat("yyyy-MM-dd");
+        RmsCarrier rmsCarrier=new RmsCarrier();
+        Map<String,Object> map1= (Map<String,Object>) mapValue.get("RmsCarrier");
+        Map<String,Object> registerDate=(Map<String,Object>)mapValue.get("registerDate");
+        Integer transportType=(Integer)map1.get("carrierTransportType");
+        Date date=new Date(0);
+        String registerDates=(String) registerDate.get("registerDate");
+        Date registerDate2= simpleDateFormat.parse(registerDates);
+
         if (transportType!=null){
-            if (transportType.equals("1")){
+            if (transportType.equals(1)){
                 rmsCarrier.setCarrierTransportType("危化品");
             }
-            if(transportType.equals("2")){
+            if(transportType.equals(2)){
                 rmsCarrier.setCarrierTransportType("其他");
             }
         }
         rmsCarrier.setUpdateUsername("admin");
         rmsCarrier.setUpdateTime(new Date());
         rmsCarrier.setRegisterDate(rmsCarrier.getRegisterDate());
-
+        rmsCarrier.setRegisterDate(registerDate2);
+        if (registerDate.get("registerDate").equals(date)){
+            rmsCarrier.setRegisterDate(null);
+        }
+        String carrierId=(String)  map1.get("carrierId");
+        rmsCarrier.setCarrierId(new BigDecimal(carrierId));
+        rmsCarrier.setCarrierName((String)map1.get("carrierName"));
+        rmsCarrier.setCarrierAbbreviation((String) map1.get("carrierAbbreviation"));
+        rmsCarrier.setCarrierAddress((String) map1.get("carrierAddress"));
+        rmsCarrier.setRegisterNo((String)map1.get("registerNo"));
+        Integer carrierBidAreaId=(Integer) map1.get("carrierBidAreaId");
+        rmsCarrier.setCarrierBidAreaId(new BigDecimal(carrierBidAreaId));
+        rmsCarrier.setCarrierLegalRepresentative((String) map1.get("carrierLegalRepresentative"));
+        rmsCarrier.setRegisterCapital((String) map1.get("registerCapital"));
+        rmsCarrier.setBusinessScope((String) map1.get("businessScope"));
+        rmsCarrier.setAnnualDate((String) map1.get("annualDate"));
+        rmsCarrier.setCompanyStatusDesc((String) map1.get("companyStatusDesc"));
+        rmsCarrier.setCompanyTypeDesc((String) map1.get("companyTypeDesc"));
+        rmsCarrier.setOperationPeriod((String) map1.get("operationPeriod"));
+        rmsCarrier.setRegisterOrganization((String) map1.get("registerOrganization"));
+        rmsCarrier.setRegisterAptitudes((String) map1.get("registerAptitudes"));
+        rmsCarrier.setContactsName((String) map1.get("contactName"));
+        rmsCarrier.setCarrierContactNumber((String) map1.get("carrierContactNumber"));
+        rmsCarrier.setCarrierType((String) map1.get("carrierType"));
         return rmsCarrierMapper.updateByPrimaryKeySelective(rmsCarrier);
     }
 
     /**
      * 添加承运商信息
-     * @param rmsCarrier
+     * @param mapValue
      * @return
      */
     @Override
-    public int insertCarrier(RmsCarrier rmsCarrier) {
+    public int insertCarrier(Map<String, Object> mapValue) throws ParseException {
+        SimpleDateFormat simpleDateFormat=new SimpleDateFormat("yyyy-MM-dd");
+        RmsCarrier rmsCarrier=new RmsCarrier();
+        Map<String,Object> map1= (Map<String,Object>) mapValue.get("RmsCarrier");
+        Map<String,Object> registerDate=(Map<String,Object>)mapValue.get("registerDate");
+        Date date=new Date(0);
         int i=0;
-        String carrierName=rmsCarrier.getCarrierName();
         Map<String, Object> map=new HashMap<>();
+        String carrierName=(String)map1.get("carrierName");
+        Integer transportType=(Integer)map1.get("carrierTransportType");
         map.put("carrierName",carrierName);
         List<RmsCarrier> rmsCarriers=rmsCarrierMapper.selectByParameters(map);
+        String registerDates=(String) registerDate.get("registerDate");
+        Date registerDate2= simpleDateFormat.parse(registerDates);
+//        当数据库中存在相同的承运商名
         if (rmsCarriers.size()!=0){
-            i=-1;
-        }
-        else {
-            String transportType = rmsCarrier.getCarrierTransportType();
-            Date date = new Date(0);
-            if (!rmsCarrier.getRegisterDate().equals(date)) {
-                if (transportType != null) {
-                    if (transportType.equals("1")) {
+//            当逻辑删除的字段为1
+            RmsCarrier rmsCarrier1=rmsCarriers.get(0);
+            if (rmsCarrier1.getDeleted().equals(new BigDecimal(1))){
+                if (transportType!=null){
+                    if (transportType.equals(1)){
                         rmsCarrier.setCarrierTransportType("危化品");
                     }
-                    if (transportType.equals("2")) {
+                    if (transportType.equals(2)){
                         rmsCarrier.setCarrierTransportType("其他");
                     }
+                    rmsCarrier.setInsertTime(new Date());
+                    rmsCarrier.setInsertUsername("admin");
+                    rmsCarrier.setDeleted(new BigDecimal(0));
+                    rmsCarrier.setCarrierId(rmsCarrierMapper.getCarrierId());
+
+                    rmsCarrier.setRegisterDate(registerDate2);
+                    if (registerDate.get("registerDate").equals(date)){
+                        rmsCarrier.setRegisterDate(null);
+                    }
+                    rmsCarrier.setCarrierName((String)map1.get("carrierName"));
+                    rmsCarrier.setCarrierAbbreviation((String) map1.get("carrierAbbreviation"));
+                    rmsCarrier.setCarrierAddress((String) map1.get("carrierAddress"));
+                    rmsCarrier.setRegisterNo((String)map1.get("registerNo"));
+                    Integer carrierBidAreaId=(Integer) map1.get("carrierBidAreaId");
+                    rmsCarrier.setCarrierBidAreaId(new BigDecimal(carrierBidAreaId));
+                    rmsCarrier.setCarrierLegalRepresentative((String) map1.get("carrierLegalRepresentative"));
+                    rmsCarrier.setRegisterCapital((String) map1.get("registerCapital"));
+                    rmsCarrier.setBusinessScope((String) map1.get("businessScope"));
+                    rmsCarrier.setAnnualDate((String) map1.get("annualDate"));
+                    rmsCarrier.setCompanyStatusDesc((String) map1.get("companyStatusDesc"));
+                    rmsCarrier.setCompanyTypeDesc((String) map1.get("companyTypeDesc"));
+                    rmsCarrier.setOperationPeriod((String) map1.get("operationPeriod"));
+                    rmsCarrier.setRegisterOrganization((String) map1.get("registerOrganization"));
+                    rmsCarrier.setRegisterAptitudes((String) map1.get("registerAptitudes"));
+                    rmsCarrier.setContactsName((String) map1.get("contactName"));
+                    rmsCarrier.setCarrierContactNumber((String) map1.get("carrierContactNumber"));
+                    rmsCarrier.setCarrierType((String) map1.get("carrierType"));
+                    i+=rmsCarrierMapper.insertSelective(rmsCarrier);
+                }
+                else{
+                    i=-1;
+                }
+            }
+        }
+        else{
+            if (transportType!=null){
+                if (transportType.equals(1)){
+                    rmsCarrier.setCarrierTransportType("危化品");
+                }
+                if (transportType.equals(2)){
+                    rmsCarrier.setCarrierTransportType("其他");
                 }
                 rmsCarrier.setInsertTime(new Date());
                 rmsCarrier.setInsertUsername("admin");
                 rmsCarrier.setDeleted(new BigDecimal(0));
                 rmsCarrier.setCarrierId(rmsCarrierMapper.getCarrierId());
+
+                rmsCarrier.setRegisterDate(registerDate2);
+                if (registerDate.get("registerDate").equals(date)){
+                    rmsCarrier.setRegisterDate(null);
+                }
+                rmsCarrier.setCarrierName((String)map1.get("carrierName"));
+                rmsCarrier.setCarrierAbbreviation((String) map1.get("carrierAbbreviation"));
+                rmsCarrier.setCarrierAddress((String) map1.get("carrierAddress"));
+                rmsCarrier.setRegisterNo((String)map1.get("registerNo"));
+                Integer carrierBidAreaId=(Integer) map1.get("carrierBidAreaId");
+                rmsCarrier.setCarrierBidAreaId(new BigDecimal(carrierBidAreaId));
+                rmsCarrier.setCarrierLegalRepresentative((String) map1.get("carrierLegalRepresentative"));
+                rmsCarrier.setRegisterCapital((String) map1.get("registerCapital"));
+                rmsCarrier.setBusinessScope((String) map1.get("businessScope"));
+                rmsCarrier.setAnnualDate((String) map1.get("annualDate"));
+                rmsCarrier.setCompanyStatusDesc((String) map1.get("companyStatusDesc"));
+                rmsCarrier.setCompanyTypeDesc((String) map1.get("companyTypeDesc"));
+                rmsCarrier.setOperationPeriod((String) map1.get("operationPeriod"));
+                rmsCarrier.setRegisterOrganization((String) map1.get("registerOrganization"));
+                rmsCarrier.setRegisterAptitudes((String) map1.get("registerAptitudes"));
+                rmsCarrier.setContactsName((String) map1.get("contactsName"));
+                rmsCarrier.setCarrierContactNumber((String) map1.get("carrierContactNumber"));
+                rmsCarrier.setCarrierType((String) map1.get("carrierType"));
                 i+=rmsCarrierMapper.insertSelective(rmsCarrier);
-            }else{
-                rmsCarrier.setRegisterDate(null);
             }
         }
 

+ 38 - 0
src/main/java/com/steerinfo/dil/service/impl/RmsConsigneeServiceImpl.java

@@ -0,0 +1,38 @@
+package com.steerinfo.dil.service.impl;
+
+import com.steerinfo.dil.mapper.RmsConsigneeMapper;
+import com.steerinfo.dil.model.RmsConsignee;
+import com.steerinfo.dil.service.IRmsConsigneeService;
+import com.steerinfo.framework.mapper.IBaseMapper;
+import com.steerinfo.framework.service.impl.BaseServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * RmsConsignee服务实现:
+ * @author generator
+ * @version 1.0-SNAPSHORT 2021-12-21 09:47
+ * 类描述
+ * 修订历史:
+ * 日期:2021-12-21
+ * 作者:generator
+ * 参考:
+ * 描述:RmsConsignee服务实现
+ * @see null
+ * @Copyright 湖南视拓信息技术股份有限公司. All rights reserved.
+ */
+@Service(value = "rmsConsigneeService")
+public class RmsConsigneeServiceImpl implements IRmsConsigneeService {
+
+    @Autowired
+    private RmsConsigneeMapper rmsConsigneeMapper;
+
+    
+    @Override
+    public List<Map<String, Object>> getConsigneeList(Map<String, Object> mapValue) {
+        return rmsConsigneeMapper.getConsigneeList(mapValue);
+    }
+}

+ 11 - 1
src/main/java/com/steerinfo/dil/service/impl/RmsGatepostServiceImpl.java

@@ -134,7 +134,17 @@ public class RmsGatepostServiceImpl implements IRmsGatepostService {
         map.put("gatepostName",gatepostName);
         List<RmsGatepost> rmsGateposts=rmsGatepostMapper.selectByParameters(map);
         if (rmsGateposts.size()!=0){
-            i=-1;
+            RmsGatepost rmsGatepost1=rmsGateposts.get(0);
+            if (rmsGatepost1.getDeleted().equals(new BigDecimal(1))){
+                rmsGatepost.setInsertUsername("admin");
+                rmsGatepost.setInsertTime(new Date());
+                rmsGatepost.setDeleted(new BigDecimal(0));
+                rmsGatepost.setGatepostId(rmsGatepostMapper.getGatepostId());
+                i += rmsGatepostMapper.insertSelective(rmsGatepost);
+            }
+            else{
+                i=-1;
+            }
         }
         else {
             rmsGatepost.setInsertUsername("admin");

+ 11 - 1
src/main/java/com/steerinfo/dil/service/impl/RmsMaterialServiceImpl.java

@@ -147,7 +147,17 @@ public class RmsMaterialServiceImpl implements IRmsMaterialService {
         map.put("materialCode",materialCode);
         List<RmsMaterial> rmsMaterials=rmsMaterialMapper.selectByParameters(map);
         if (rmsMaterials.size()!=0){
-            i=-1;
+            RmsMaterial rmsMaterial1=rmsMaterials.get(0);
+            if (rmsMaterial1.getDeleted().equals(new BigDecimal(1))){
+                rmsMaterial.setDeleted(new BigDecimal(0));
+                rmsMaterial.setMaterialId(rmsMaterialMapper.getMaterialId());
+                rmsMaterial.setInsertTime(new Date());
+                rmsMaterial.setInsertUsername("admin");
+                i += rmsMaterialMapper.insertSelective(rmsMaterial);
+            }
+            else{
+                i=-1;
+            }
         }
         else {
             rmsMaterial.setDeleted(new BigDecimal(0));

+ 12 - 3
src/main/java/com/steerinfo/dil/service/impl/RmsPersonnelServiceImpl.java

@@ -107,9 +107,18 @@ public class RmsPersonnelServiceImpl implements IRmsPersonnelService {
         String personnelJobNumber=rmsPersonnel.getPersonnelJobNumber();
         Map<String, Object> map=new HashMap<>();
         map.put("personnelJobNumber",personnelJobNumber);
-        List<RmsShipper> rmsShippers=rmsShipperMapper.selectByParameters(map);
-        if (rmsShippers.size()!=0){
-            i=-1;
+        List<RmsPersonnel> rmsPersonnels=rmsPersonnelMapper.selectByParameters(map);
+        if (rmsPersonnels.size()!=0){
+            RmsPersonnel rmsPersonnel1=rmsPersonnels.get(0);
+            if (rmsPersonnel1.getDeleted().equals(new BigDecimal(1))){
+                rmsPersonnel.setInsertUsername("admin");
+                rmsPersonnel.setDeleted(new BigDecimal(0));
+                rmsPersonnel.setPersonnelId(rmsPersonnelMapper.getPersonnelId());
+                i+= rmsPersonnelMapper.insertSelective(rmsPersonnel);
+            }
+            else{
+                i=-1;
+            }
         }
         else {
             rmsPersonnel.setInsertTime(new Date());

+ 12 - 1
src/main/java/com/steerinfo/dil/service/impl/RmsShipperServiceImpl.java

@@ -2,6 +2,7 @@ package com.steerinfo.dil.service.impl;
 
 import com.steerinfo.dil.mapper.RmsShipperMapper;
 import com.steerinfo.dil.model.RmsShipper;
+import com.steerinfo.dil.model.RmsSupplier;
 import com.steerinfo.dil.service.IRmsShipperService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -55,7 +56,17 @@ public class RmsShipperServiceImpl implements IRmsShipperService {
         map.put("shipperName",shipperName);
         List<RmsShipper> rmsShippers=rmsShipperMapper.selectByParameters(map);
         if (rmsShippers.size()!=0){
-            i=-1;
+            RmsShipper rmsShipper1=rmsShippers.get(0);
+            if (rmsShipper1.getDeleted().equals(new BigDecimal(1))){
+                rmsShipper.setInsertTime(new Date());
+                rmsShipper.setInsertUsername("admin");
+                rmsShipper.setDeleted(new BigDecimal(0));
+                rmsShipper.setShipperId(rmsShipperMapper.getShipperId());
+                i+=rmsShipperMapper.insertSelective(rmsShipper);
+            }
+            else{
+                i=-1;
+            }
         }
         else{
             rmsShipper.setInsertTime(new Date());

+ 11 - 2
src/main/java/com/steerinfo/dil/service/impl/RmsSupplierServiceImpl.java

@@ -119,10 +119,19 @@ public class RmsSupplierServiceImpl implements IRmsSupplierService {
         Map<String,Object> map = new HashMap<>();
         map.put("supplierName",supplierName);
         List<RmsSupplier> rmsSuppliers = rmsSupplierMapper.selectByParameters(map);
-
         if (rmsSuppliers.size() != 0 ) {
+            RmsSupplier rmsSupplier1=rmsSuppliers.get(0);
 //                当供应商编号存在的时候,直接返回已经存在数据就行了
-            i=-1;
+            if (rmsSupplier1.getDeleted().equals(new BigDecimal(1))){
+                rmsSupplier.setInsertTime(new Date());
+                rmsSupplier.setInsertUsername("admin");
+                rmsSupplier.setDeleted(new BigDecimal(0));
+                rmsSupplier.setSupplierId(rmsSupplierMapper.getSupplierId());
+                i+=rmsSupplierMapper.insertSelective(rmsSupplier);
+            }
+            else{
+                i=-1;
+            }
         }
         else {
 //                当供应商编号不存在的话,就直接加入

+ 2 - 13
src/main/java/com/steerinfo/dil/service/impl/RmsWarehouseServiceImpl.java

@@ -44,23 +44,12 @@ public class RmsWarehouseServiceImpl  implements IRmsWarehouseService {
     * */
     @Override
     public int insertWarehouse(RmsWarehouse rmsWarehouse) {
-        int i=0;
-        String warehouseName=rmsWarehouse.getWarehouseName();
-        Map<String, Object> map=new HashMap<>();
-        map.put("warehouseName",warehouseName);
-        List<RmsWarehouse> rmsWarehouses=rmsWarehouseMapper.selectByParameters(map);
-        if (rmsWarehouses.size()!=0){
-            i=-1;
-        }
-        else {
             rmsWarehouse.setWarehouseTypeId(new BigDecimal(3));
             rmsWarehouse.setDeleted(new BigDecimal(0));
             rmsWarehouse.setInsertUsername("admin");
             rmsWarehouse.setInsertTime(new Date());
-            rmsWarehouse.setWarehouseId(new BigDecimal(String.valueOf(rmsWarehouseMapper.selectWarehouseId())));
-            i+= rmsWarehouseMapper.insertSelective(rmsWarehouse);
-        }
-        return i;
+            rmsWarehouse.setWarehouseId(rmsWarehouseMapper.selectWarehouseId());
+        return rmsWarehouseMapper.insertSelective(rmsWarehouse);
     }
     /*
     * 更改原料工厂

+ 10 - 2
src/main/resources/com/steerinfo/dil/mapper/RmsCapacityMapper.xml

@@ -753,10 +753,18 @@
           "carrierName" in #{item}
         </foreach>
       </if>
-
     </where>
+   <include refid="orderBy"></include>
   </select>
-
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
+  
 
   <select id="getCapacityById" resultType="java.util.LinkedHashMap" >
          SELECT

+ 9 - 2
src/main/resources/com/steerinfo/dil/mapper/RmsCarDriverMapper.xml

@@ -1038,10 +1038,17 @@
         "driverLicence3" in #{item}
       </foreach>
     </if>
-
     </where>
-
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
 
 
 

+ 9 - 1
src/main/resources/com/steerinfo/dil/mapper/RmsCarrierMapper.xml

@@ -1213,8 +1213,16 @@
         </foreach>
       </if>
     </where>
+    <include refid="orderBy"></include>
   </select>
-
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
   <!--  根据id值获取承运商信息-->
   <select id="selectCarrierById"  resultType="java.util.LinkedHashMap">
     select

+ 656 - 0
src/main/resources/com/steerinfo/dil/mapper/RmsConsigneeMapper.xml

@@ -0,0 +1,656 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.steerinfo.dil.mapper.RmsConsigneeMapper">
+  <resultMap id="BaseResultMap" type="com.steerinfo.dil.model.RmsConsignee">
+    <id column="CONSIGNEE_ID" jdbcType="DECIMAL" property="consigneeId" />
+    <result column="CONSIGNEE_COMPANY_NAME" jdbcType="VARCHAR" property="consigneeCompanyName" />
+    <result column="CONSIGNEE_ABBREVIATION" jdbcType="VARCHAR" property="consigneeAbbreviation" />
+    <result column="CONSIGNEE_REGISTERED_ADDRESS" jdbcType="VARCHAR" property="consigneeRegisteredAddress" />
+    <result column="CONSIGNEE_RECEIVE_ADDRESS" jdbcType="VARCHAR" property="consigneeReceiveAddress" />
+    <result column="CONSIGNEE_REGISTRATION_TIME" jdbcType="TIMESTAMP" property="consigneeRegistrationTime" />
+    <result column="CONSIGNEE_CONTACT_NAME" jdbcType="VARCHAR" property="consigneeContactName" />
+    <result column="CONSIGNEE_WARRANTY_AMOUNT" jdbcType="DECIMAL" property="consigneeWarrantyAmount" />
+    <result column="CONSIGNEE_WARRANTY_WEIGHT" jdbcType="VARCHAR" property="consigneeWarrantyWeight" />
+    <result column="CONSIGNEE_CONTACT_TEL" jdbcType="VARCHAR" property="consigneeContactTel" />
+    <result column="CONSIGNEE_EXCHANGE_DELIVERY" jdbcType="DECIMAL" property="consigneeExchangeDelivery" />
+    <result column="INSERT_USERNAME" jdbcType="VARCHAR" property="insertUsername" />
+    <result column="INSERT_TIME" jdbcType="TIMESTAMP" property="insertTime" />
+    <result column="UPDATE_USERNAME" jdbcType="VARCHAR" property="updateUsername" />
+    <result column="UPDATE_TIME" jdbcType="TIMESTAMP" property="updateTime" />
+    <result column="INSERT_UPDATE_REMARK" jdbcType="VARCHAR" property="insertUpdateRemark" />
+    <result column="DELETED" jdbcType="DECIMAL" property="deleted" />
+    <result column="EAS_CONSIGNEE_ID" jdbcType="VARCHAR" property="easConsigneeId" />
+    <result column="CONSIGNEE_CODE" jdbcType="VARCHAR" property="consigneeCode" />
+  </resultMap>
+  <sql id="columns">
+    CONSIGNEE_ID, CONSIGNEE_COMPANY_NAME, CONSIGNEE_ABBREVIATION, CONSIGNEE_REGISTERED_ADDRESS, 
+    CONSIGNEE_RECEIVE_ADDRESS, CONSIGNEE_REGISTRATION_TIME, CONSIGNEE_CONTACT_NAME, CONSIGNEE_WARRANTY_AMOUNT, 
+    CONSIGNEE_WARRANTY_WEIGHT, CONSIGNEE_CONTACT_TEL, CONSIGNEE_EXCHANGE_DELIVERY, INSERT_USERNAME, 
+    INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK, DELETED, EAS_CONSIGNEE_ID, 
+    CONSIGNEE_CODE
+  </sql>
+  <sql id="columns_alias">
+    t.CONSIGNEE_ID, t.CONSIGNEE_COMPANY_NAME, t.CONSIGNEE_ABBREVIATION, t.CONSIGNEE_REGISTERED_ADDRESS, 
+    t.CONSIGNEE_RECEIVE_ADDRESS, t.CONSIGNEE_REGISTRATION_TIME, t.CONSIGNEE_CONTACT_NAME, 
+    t.CONSIGNEE_WARRANTY_AMOUNT, t.CONSIGNEE_WARRANTY_WEIGHT, t.CONSIGNEE_CONTACT_TEL, 
+    t.CONSIGNEE_EXCHANGE_DELIVERY, t.INSERT_USERNAME, t.INSERT_TIME, t.UPDATE_USERNAME, 
+    t.UPDATE_TIME, t.INSERT_UPDATE_REMARK, t.DELETED, t.EAS_CONSIGNEE_ID, t.CONSIGNEE_CODE
+  </sql>
+  <sql id="select">
+    SELECT <include refid="columns" /> FROM RMS_CONSIGNEE
+  </sql>
+  <sql id="select_alias">
+    SELECT <include refid="columns_alias" /> FROM RMS_CONSIGNEE t
+  </sql>
+  <sql id="where">
+    <where> 
+      <if test="consigneeId != null">
+        and CONSIGNEE_ID = #{consigneeId}
+      </if>
+      <if test="consigneeCompanyName != null and consigneeCompanyName != ''">
+        and CONSIGNEE_COMPANY_NAME = #{consigneeCompanyName}
+      </if>
+      <if test="consigneeAbbreviation != null and consigneeAbbreviation != ''">
+        and CONSIGNEE_ABBREVIATION = #{consigneeAbbreviation}
+      </if>
+      <if test="consigneeRegisteredAddress != null and consigneeRegisteredAddress != ''">
+        and CONSIGNEE_REGISTERED_ADDRESS = #{consigneeRegisteredAddress}
+      </if>
+      <if test="consigneeReceiveAddress != null and consigneeReceiveAddress != ''">
+        and CONSIGNEE_RECEIVE_ADDRESS = #{consigneeReceiveAddress}
+      </if>
+      <if test="consigneeRegistrationTime != null">
+        and TO_CHAR(CONSIGNEE_REGISTRATION_TIME,'yyyy-MM-dd') = #{consigneeRegistrationTime}
+      </if>
+      <if test="consigneeContactName != null and consigneeContactName != ''">
+        and CONSIGNEE_CONTACT_NAME = #{consigneeContactName}
+      </if>
+      <if test="consigneeWarrantyAmount != null">
+        and CONSIGNEE_WARRANTY_AMOUNT = #{consigneeWarrantyAmount}
+      </if>
+      <if test="consigneeWarrantyWeight != null and consigneeWarrantyWeight != ''">
+        and CONSIGNEE_WARRANTY_WEIGHT = #{consigneeWarrantyWeight}
+      </if>
+      <if test="consigneeContactTel != null and consigneeContactTel != ''">
+        and CONSIGNEE_CONTACT_TEL = #{consigneeContactTel}
+      </if>
+      <if test="consigneeExchangeDelivery != null">
+        and CONSIGNEE_EXCHANGE_DELIVERY = #{consigneeExchangeDelivery}
+      </if>
+      <if test="insertUsername != null and insertUsername != ''">
+        and INSERT_USERNAME = #{insertUsername}
+      </if>
+      <if test="insertTime != null">
+        and TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = #{insertTime}
+      </if>
+      <if test="updateUsername != null and updateUsername != ''">
+        and UPDATE_USERNAME = #{updateUsername}
+      </if>
+      <if test="updateTime != null">
+        and TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = #{updateTime}
+      </if>
+      <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
+        and INSERT_UPDATE_REMARK = #{insertUpdateRemark}
+      </if>
+      <if test="deleted != null">
+        and DELETED = #{deleted}
+      </if>
+      <if test="easConsigneeId != null and easConsigneeId != ''">
+        and EAS_CONSIGNEE_ID = #{easConsigneeId}
+      </if>
+      <if test="consigneeCode != null and consigneeCode != ''">
+        and CONSIGNEE_CODE = #{consigneeCode}
+      </if>
+    </where>
+  </sql>
+  <sql id="whereLike">
+    <where> 
+      <if test="consigneeId != null">
+        and CONSIGNEE_ID = #{consigneeId}
+      </if>
+      <if test="consigneeCompanyName != null and consigneeCompanyName != ''">
+        and CONSIGNEE_COMPANY_NAME LIKE '%${consigneeCompanyName}%'
+      </if>
+      <if test="consigneeAbbreviation != null and consigneeAbbreviation != ''">
+        and CONSIGNEE_ABBREVIATION LIKE '%${consigneeAbbreviation}%'
+      </if>
+      <if test="consigneeRegisteredAddress != null and consigneeRegisteredAddress != ''">
+        and CONSIGNEE_REGISTERED_ADDRESS LIKE '%${consigneeRegisteredAddress}%'
+      </if>
+      <if test="consigneeReceiveAddress != null and consigneeReceiveAddress != ''">
+        and CONSIGNEE_RECEIVE_ADDRESS LIKE '%${consigneeReceiveAddress}%'
+      </if>
+      <if test="consigneeRegistrationTime != null">
+        and TO_CHAR(CONSIGNEE_REGISTRATION_TIME,'yyyy-MM-dd') = #{consigneeRegistrationTime}
+      </if>
+      <if test="consigneeContactName != null and consigneeContactName != ''">
+        and CONSIGNEE_CONTACT_NAME LIKE '%${consigneeContactName}%'
+      </if>
+      <if test="consigneeWarrantyAmount != null">
+        and CONSIGNEE_WARRANTY_AMOUNT = #{consigneeWarrantyAmount}
+      </if>
+      <if test="consigneeWarrantyWeight != null and consigneeWarrantyWeight != ''">
+        and CONSIGNEE_WARRANTY_WEIGHT LIKE '%${consigneeWarrantyWeight}%'
+      </if>
+      <if test="consigneeContactTel != null and consigneeContactTel != ''">
+        and CONSIGNEE_CONTACT_TEL LIKE '%${consigneeContactTel}%'
+      </if>
+      <if test="consigneeExchangeDelivery != null">
+        and CONSIGNEE_EXCHANGE_DELIVERY = #{consigneeExchangeDelivery}
+      </if>
+      <if test="insertUsername != null and insertUsername != ''">
+        and INSERT_USERNAME LIKE '%${insertUsername}%'
+      </if>
+      <if test="insertTime != null">
+        and TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = #{insertTime}
+      </if>
+      <if test="updateUsername != null and updateUsername != ''">
+        and UPDATE_USERNAME LIKE '%${updateUsername}%'
+      </if>
+      <if test="updateTime != null">
+        and TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = #{updateTime}
+      </if>
+      <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
+        and INSERT_UPDATE_REMARK LIKE '%${insertUpdateRemark}%'
+      </if>
+      <if test="deleted != null">
+        and DELETED = #{deleted}
+      </if>
+      <if test="easConsigneeId != null and easConsigneeId != ''">
+        and EAS_CONSIGNEE_ID LIKE '%${easConsigneeId}%'
+      </if>
+      <if test="consigneeCode != null and consigneeCode != ''">
+        and CONSIGNEE_CODE LIKE '%${consigneeCode}%'
+      </if>
+    </where>
+  </sql>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
+    delete from RMS_CONSIGNEE
+    where CONSIGNEE_ID = #{consigneeId,jdbcType=DECIMAL}
+  </delete>
+  <delete id="deleteBySelectiveElement" parameterType="java.util.HashMap">
+    delete from RMS_CONSIGNEE
+    where 1!=1 
+      <if test="consigneeCompanyName != null and consigneeCompanyName != ''">
+        or CONSIGNEE_COMPANY_NAME = #{consigneeCompanyName}
+      </if>
+      <if test="consigneeAbbreviation != null and consigneeAbbreviation != ''">
+        or CONSIGNEE_ABBREVIATION = #{consigneeAbbreviation}
+      </if>
+      <if test="consigneeRegisteredAddress != null and consigneeRegisteredAddress != ''">
+        or CONSIGNEE_REGISTERED_ADDRESS = #{consigneeRegisteredAddress}
+      </if>
+      <if test="consigneeReceiveAddress != null and consigneeReceiveAddress != ''">
+        or CONSIGNEE_RECEIVE_ADDRESS = #{consigneeReceiveAddress}
+      </if>
+      <if test="consigneeRegistrationTime != null">
+        or TO_CHAR(CONSIGNEE_REGISTRATION_TIME,'yyyy-MM-dd') = '#{consigneeRegistrationTime}'
+      </if>
+      <if test="consigneeContactName != null and consigneeContactName != ''">
+        or CONSIGNEE_CONTACT_NAME = #{consigneeContactName}
+      </if>
+      <if test="consigneeWarrantyAmount != null">
+        or CONSIGNEE_WARRANTY_AMOUNT = #{consigneeWarrantyAmount}
+      </if>
+      <if test="consigneeWarrantyWeight != null and consigneeWarrantyWeight != ''">
+        or CONSIGNEE_WARRANTY_WEIGHT = #{consigneeWarrantyWeight}
+      </if>
+      <if test="consigneeContactTel != null and consigneeContactTel != ''">
+        or CONSIGNEE_CONTACT_TEL = #{consigneeContactTel}
+      </if>
+      <if test="consigneeExchangeDelivery != null">
+        or CONSIGNEE_EXCHANGE_DELIVERY = #{consigneeExchangeDelivery}
+      </if>
+      <if test="insertUsername != null and insertUsername != ''">
+        or INSERT_USERNAME = #{insertUsername}
+      </if>
+      <if test="insertTime != null">
+        or TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = '#{insertTime}'
+      </if>
+      <if test="updateUsername != null and updateUsername != ''">
+        or UPDATE_USERNAME = #{updateUsername}
+      </if>
+      <if test="updateTime != null">
+        or TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = '#{updateTime}'
+      </if>
+      <if test="insertUpdateRemark != null and insertUpdateRemark != ''">
+        or INSERT_UPDATE_REMARK = #{insertUpdateRemark}
+      </if>
+      <if test="deleted != null">
+        or DELETED = #{deleted}
+      </if>
+      <if test="easConsigneeId != null and easConsigneeId != ''">
+        or EAS_CONSIGNEE_ID = #{easConsigneeId}
+      </if>
+      <if test="consigneeCode != null and consigneeCode != ''">
+        or CONSIGNEE_CODE = #{consigneeCode}
+      </if>
+  </delete>
+  <insert id="insert" parameterType="com.steerinfo.dil.model.RmsConsignee">
+    insert into RMS_CONSIGNEE (CONSIGNEE_ID, CONSIGNEE_COMPANY_NAME, 
+      CONSIGNEE_ABBREVIATION, CONSIGNEE_REGISTERED_ADDRESS, 
+      CONSIGNEE_RECEIVE_ADDRESS, CONSIGNEE_REGISTRATION_TIME, 
+      CONSIGNEE_CONTACT_NAME, CONSIGNEE_WARRANTY_AMOUNT, 
+      CONSIGNEE_WARRANTY_WEIGHT, CONSIGNEE_CONTACT_TEL, 
+      CONSIGNEE_EXCHANGE_DELIVERY, INSERT_USERNAME, 
+      INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, 
+      INSERT_UPDATE_REMARK, DELETED, EAS_CONSIGNEE_ID, 
+      CONSIGNEE_CODE)
+    values (#{consigneeId,jdbcType=DECIMAL}, #{consigneeCompanyName,jdbcType=VARCHAR}, 
+      #{consigneeAbbreviation,jdbcType=VARCHAR}, #{consigneeRegisteredAddress,jdbcType=VARCHAR}, 
+      #{consigneeReceiveAddress,jdbcType=VARCHAR}, #{consigneeRegistrationTime,jdbcType=TIMESTAMP}, 
+      #{consigneeContactName,jdbcType=VARCHAR}, #{consigneeWarrantyAmount,jdbcType=DECIMAL}, 
+      #{consigneeWarrantyWeight,jdbcType=VARCHAR}, #{consigneeContactTel,jdbcType=VARCHAR}, 
+      #{consigneeExchangeDelivery,jdbcType=DECIMAL}, #{insertUsername,jdbcType=VARCHAR}, 
+      #{insertTime,jdbcType=TIMESTAMP}, #{updateUsername,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, 
+      #{insertUpdateRemark,jdbcType=VARCHAR}, #{deleted,jdbcType=DECIMAL}, #{easConsigneeId,jdbcType=VARCHAR}, 
+      #{consigneeCode,jdbcType=VARCHAR})
+  </insert>
+  <insert id="insertSelective" parameterType="com.steerinfo.dil.model.RmsConsignee">
+    insert into RMS_CONSIGNEE
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="consigneeId != null">
+        CONSIGNEE_ID,
+      </if>
+      <if test="consigneeCompanyName != null">
+        CONSIGNEE_COMPANY_NAME,
+      </if>
+      <if test="consigneeAbbreviation != null">
+        CONSIGNEE_ABBREVIATION,
+      </if>
+      <if test="consigneeRegisteredAddress != null">
+        CONSIGNEE_REGISTERED_ADDRESS,
+      </if>
+      <if test="consigneeReceiveAddress != null">
+        CONSIGNEE_RECEIVE_ADDRESS,
+      </if>
+      <if test="consigneeRegistrationTime != null">
+        CONSIGNEE_REGISTRATION_TIME,
+      </if>
+      <if test="consigneeContactName != null">
+        CONSIGNEE_CONTACT_NAME,
+      </if>
+      <if test="consigneeWarrantyAmount != null">
+        CONSIGNEE_WARRANTY_AMOUNT,
+      </if>
+      <if test="consigneeWarrantyWeight != null">
+        CONSIGNEE_WARRANTY_WEIGHT,
+      </if>
+      <if test="consigneeContactTel != null">
+        CONSIGNEE_CONTACT_TEL,
+      </if>
+      <if test="consigneeExchangeDelivery != null">
+        CONSIGNEE_EXCHANGE_DELIVERY,
+      </if>
+      <if test="insertUsername != null">
+        INSERT_USERNAME,
+      </if>
+      <if test="insertTime != null">
+        INSERT_TIME,
+      </if>
+      <if test="updateUsername != null">
+        UPDATE_USERNAME,
+      </if>
+      <if test="updateTime != null">
+        UPDATE_TIME,
+      </if>
+      <if test="insertUpdateRemark != null">
+        INSERT_UPDATE_REMARK,
+      </if>
+      <if test="deleted != null">
+        DELETED,
+      </if>
+      <if test="easConsigneeId != null">
+        EAS_CONSIGNEE_ID,
+      </if>
+      <if test="consigneeCode != null">
+        CONSIGNEE_CODE,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="consigneeId != null">
+        #{consigneeId,jdbcType=DECIMAL},
+      </if>
+      <if test="consigneeCompanyName != null">
+        #{consigneeCompanyName,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeAbbreviation != null">
+        #{consigneeAbbreviation,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeRegisteredAddress != null">
+        #{consigneeRegisteredAddress,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeReceiveAddress != null">
+        #{consigneeReceiveAddress,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeRegistrationTime != null">
+        #{consigneeRegistrationTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="consigneeContactName != null">
+        #{consigneeContactName,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeWarrantyAmount != null">
+        #{consigneeWarrantyAmount,jdbcType=DECIMAL},
+      </if>
+      <if test="consigneeWarrantyWeight != null">
+        #{consigneeWarrantyWeight,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeContactTel != null">
+        #{consigneeContactTel,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeExchangeDelivery != null">
+        #{consigneeExchangeDelivery,jdbcType=DECIMAL},
+      </if>
+      <if test="insertUsername != null">
+        #{insertUsername,jdbcType=VARCHAR},
+      </if>
+      <if test="insertTime != null">
+        #{insertTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="updateUsername != null">
+        #{updateUsername,jdbcType=VARCHAR},
+      </if>
+      <if test="updateTime != null">
+        #{updateTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="insertUpdateRemark != null">
+        #{insertUpdateRemark,jdbcType=VARCHAR},
+      </if>
+      <if test="deleted != null">
+        #{deleted,jdbcType=DECIMAL},
+      </if>
+      <if test="easConsigneeId != null">
+        #{easConsigneeId,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeCode != null">
+        #{consigneeCode,jdbcType=VARCHAR},
+      </if>
+    </trim>
+  </insert>
+  <update id="updateByPrimaryKey" parameterType="com.steerinfo.dil.model.RmsConsignee">
+    update RMS_CONSIGNEE
+    set CONSIGNEE_COMPANY_NAME = #{consigneeCompanyName,jdbcType=VARCHAR},
+      CONSIGNEE_ABBREVIATION = #{consigneeAbbreviation,jdbcType=VARCHAR},
+      CONSIGNEE_REGISTERED_ADDRESS = #{consigneeRegisteredAddress,jdbcType=VARCHAR},
+      CONSIGNEE_RECEIVE_ADDRESS = #{consigneeReceiveAddress,jdbcType=VARCHAR},
+      CONSIGNEE_REGISTRATION_TIME = #{consigneeRegistrationTime,jdbcType=TIMESTAMP},
+      CONSIGNEE_CONTACT_NAME = #{consigneeContactName,jdbcType=VARCHAR},
+      CONSIGNEE_WARRANTY_AMOUNT = #{consigneeWarrantyAmount,jdbcType=DECIMAL},
+      CONSIGNEE_WARRANTY_WEIGHT = #{consigneeWarrantyWeight,jdbcType=VARCHAR},
+      CONSIGNEE_CONTACT_TEL = #{consigneeContactTel,jdbcType=VARCHAR},
+      CONSIGNEE_EXCHANGE_DELIVERY = #{consigneeExchangeDelivery,jdbcType=DECIMAL},
+      INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR},
+      INSERT_TIME = #{insertTime,jdbcType=TIMESTAMP},
+      UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR},
+      UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP},
+      INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR},
+      DELETED = #{deleted,jdbcType=DECIMAL},
+      EAS_CONSIGNEE_ID = #{easConsigneeId,jdbcType=VARCHAR},
+      CONSIGNEE_CODE = #{consigneeCode,jdbcType=VARCHAR}
+    where CONSIGNEE_ID = #{consigneeId,jdbcType=DECIMAL}
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.dil.model.RmsConsignee">
+    update RMS_CONSIGNEE
+    <set>
+      <if test="consigneeCompanyName != null">
+        CONSIGNEE_COMPANY_NAME = #{consigneeCompanyName,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeAbbreviation != null">
+        CONSIGNEE_ABBREVIATION = #{consigneeAbbreviation,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeRegisteredAddress != null">
+        CONSIGNEE_REGISTERED_ADDRESS = #{consigneeRegisteredAddress,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeReceiveAddress != null">
+        CONSIGNEE_RECEIVE_ADDRESS = #{consigneeReceiveAddress,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeRegistrationTime != null">
+        CONSIGNEE_REGISTRATION_TIME = #{consigneeRegistrationTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="consigneeContactName != null">
+        CONSIGNEE_CONTACT_NAME = #{consigneeContactName,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeWarrantyAmount != null">
+        CONSIGNEE_WARRANTY_AMOUNT = #{consigneeWarrantyAmount,jdbcType=DECIMAL},
+      </if>
+      <if test="consigneeWarrantyWeight != null">
+        CONSIGNEE_WARRANTY_WEIGHT = #{consigneeWarrantyWeight,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeContactTel != null">
+        CONSIGNEE_CONTACT_TEL = #{consigneeContactTel,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeExchangeDelivery != null">
+        CONSIGNEE_EXCHANGE_DELIVERY = #{consigneeExchangeDelivery,jdbcType=DECIMAL},
+      </if>
+      <if test="insertUsername != null">
+        INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR},
+      </if>
+      <if test="insertTime != null">
+        INSERT_TIME = #{insertTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="updateUsername != null">
+        UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR},
+      </if>
+      <if test="updateTime != null">
+        UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="insertUpdateRemark != null">
+        INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR},
+      </if>
+      <if test="deleted != null">
+        DELETED = #{deleted,jdbcType=DECIMAL},
+      </if>
+      <if test="easConsigneeId != null">
+        EAS_CONSIGNEE_ID = #{easConsigneeId,jdbcType=VARCHAR},
+      </if>
+      <if test="consigneeCode != null">
+        CONSIGNEE_CODE = #{consigneeCode,jdbcType=VARCHAR},
+      </if>
+    </set>
+    where CONSIGNEE_ID = #{consigneeId,jdbcType=DECIMAL}
+  </update>
+  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
+    <include refid="select" />
+    where CONSIGNEE_ID = #{consigneeId,jdbcType=DECIMAL}
+  </select>
+  <select id="selectByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
+    <include refid="select" />
+    <include refid="where" />
+  </select>
+  <select id="selectLikeByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
+    <include refid="select" />
+    <include refid="whereLike" />
+  </select>
+  <insert id="batchInsert" parameterType="java.util.List">
+    insert into RMS_CONSIGNEE 
+      (CONSIGNEE_ID, 
+      CONSIGNEE_COMPANY_NAME, CONSIGNEE_ABBREVIATION, 
+      CONSIGNEE_REGISTERED_ADDRESS, CONSIGNEE_RECEIVE_ADDRESS, 
+      CONSIGNEE_REGISTRATION_TIME, CONSIGNEE_CONTACT_NAME, 
+      CONSIGNEE_WARRANTY_AMOUNT, CONSIGNEE_WARRANTY_WEIGHT, 
+      CONSIGNEE_CONTACT_TEL, CONSIGNEE_EXCHANGE_DELIVERY, 
+      INSERT_USERNAME, INSERT_TIME, 
+      UPDATE_USERNAME, UPDATE_TIME, 
+      INSERT_UPDATE_REMARK, DELETED, 
+      EAS_CONSIGNEE_ID, CONSIGNEE_CODE
+      )
+    ( <foreach collection="list" item="item" separator="union all"> 
+   select  
+      #{item.consigneeId,jdbcType=DECIMAL}, 
+      #{item.consigneeCompanyName,jdbcType=VARCHAR}, #{item.consigneeAbbreviation,jdbcType=VARCHAR}, 
+      #{item.consigneeRegisteredAddress,jdbcType=VARCHAR}, #{item.consigneeReceiveAddress,jdbcType=VARCHAR}, 
+      #{item.consigneeRegistrationTime,jdbcType=TIMESTAMP}, #{item.consigneeContactName,jdbcType=VARCHAR}, 
+      #{item.consigneeWarrantyAmount,jdbcType=DECIMAL}, #{item.consigneeWarrantyWeight,jdbcType=VARCHAR}, 
+      #{item.consigneeContactTel,jdbcType=VARCHAR}, #{item.consigneeExchangeDelivery,jdbcType=DECIMAL}, 
+      #{item.insertUsername,jdbcType=VARCHAR}, #{item.insertTime,jdbcType=TIMESTAMP}, 
+      #{item.updateUsername,jdbcType=VARCHAR}, #{item.updateTime,jdbcType=TIMESTAMP}, 
+      #{item.insertUpdateRemark,jdbcType=VARCHAR}, #{item.deleted,jdbcType=DECIMAL}, 
+      #{item.easConsigneeId,jdbcType=VARCHAR}, #{item.consigneeCode,jdbcType=VARCHAR}
+       from dual  
+   </foreach> )
+  </insert>
+  <update id="batchUpdate" parameterType="java.util.List">
+     update RMS_CONSIGNEE
+     set
+       CONSIGNEE_ID=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeId,jdbcType=DECIMAL}
+       </foreach>
+       ,CONSIGNEE_COMPANY_NAME=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeCompanyName,jdbcType=VARCHAR}
+       </foreach>
+       ,CONSIGNEE_ABBREVIATION=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeAbbreviation,jdbcType=VARCHAR}
+       </foreach>
+       ,CONSIGNEE_REGISTERED_ADDRESS=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeRegisteredAddress,jdbcType=VARCHAR}
+       </foreach>
+       ,CONSIGNEE_RECEIVE_ADDRESS=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeReceiveAddress,jdbcType=VARCHAR}
+       </foreach>
+       ,CONSIGNEE_REGISTRATION_TIME=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeRegistrationTime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,CONSIGNEE_CONTACT_NAME=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeContactName,jdbcType=VARCHAR}
+       </foreach>
+       ,CONSIGNEE_WARRANTY_AMOUNT=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeWarrantyAmount,jdbcType=DECIMAL}
+       </foreach>
+       ,CONSIGNEE_WARRANTY_WEIGHT=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeWarrantyWeight,jdbcType=VARCHAR}
+       </foreach>
+       ,CONSIGNEE_CONTACT_TEL=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeContactTel,jdbcType=VARCHAR}
+       </foreach>
+       ,CONSIGNEE_EXCHANGE_DELIVERY=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeExchangeDelivery,jdbcType=DECIMAL}
+       </foreach>
+       ,INSERT_USERNAME=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.insertUsername,jdbcType=VARCHAR}
+       </foreach>
+       ,INSERT_TIME=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.insertTime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,UPDATE_USERNAME=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.updateUsername,jdbcType=VARCHAR}
+       </foreach>
+       ,UPDATE_TIME=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.updateTime,jdbcType=TIMESTAMP}
+       </foreach>
+       ,INSERT_UPDATE_REMARK=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.insertUpdateRemark,jdbcType=VARCHAR}
+       </foreach>
+       ,DELETED=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.deleted,jdbcType=DECIMAL}
+       </foreach>
+       ,EAS_CONSIGNEE_ID=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.easConsigneeId,jdbcType=VARCHAR}
+       </foreach>
+       ,CONSIGNEE_CODE=
+       <foreach close="end" collection="list" index="index" item="item" open="case CONSIGNEE_ID" separator=" ">
+          when #{item.consigneeId,jdbcType=DECIMAL} then #{item.consigneeCode,jdbcType=VARCHAR}
+       </foreach>
+     where CONSIGNEE_ID in 
+     <foreach close=")" collection="list" index="index" item="item" open="(" separator=",">
+    #{item.consigneeId,jdbcType=DECIMAL}
+     </foreach> 
+  </update>
+  <delete id="batchDelete" parameterType="java.util.List">
+    delete from RMS_CONSIGNEE
+    where CONSIGNEE_ID in 
+    <foreach close=")" collection="list" item="id" open="(" separator=",">
+      #{id}
+    </foreach>
+  </delete>
+  <!-- 友情提示!!!-->
+  <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
+ <select id="getConsigneeList" parameterType="java.util.Map" resultType="java.util.Map">
+   SELECT *
+   FROM (
+   SELECT
+      RC.CONSIGNEE_ID AS "consigneeId",
+      RC.CONSIGNEE_COMPANY_NAME AS "companyName",
+      RC.CONSIGNEE_ABBREVIATION AS "consigneeAbbreviation",
+      RC.CONSIGNEE_REGISTERED_ADDRESS AS "consigneeRegisteredAddress",
+      RC.CONSIGNEE_RECEIVE_ADDRESS AS "consigneeReceiveAddress",
+      RC.CONSIGNEE_REGISTRATION_TIME AS "consigneeRegistrationTime",
+      RC.CONSIGNEE_CONTACT_NAME AS "consigneeContactName",
+      RC.CONSIGNEE_CONTACT_TEL AS "consigneeContactTel"
+   FROM RMS_CONSIGNEE RC
+   WHERE RC.DELETED!=1
+   ORDER BY RC.INSERT_TIME DESC
+   )
+   WHERE rownum &lt; 100
+   <where>
+   <if test="companyName!= null">
+     and
+     <foreach collection="companyName" item="item" open="(" separator="," close=")">
+       "companyName" in #{item}
+     </foreach>
+   </if>
+   <if test="consigneeAbbreviation!= null">
+     and
+     <foreach collection="consigneeAbbreviation" item="item" open="(" separator="," close=")">
+       "consigneeAbbreviation" in #{item}
+     </foreach>
+   </if>
+   <if test="consigneeRegisteredAddress!= null">
+     and
+     <foreach collection="consigneeRegisteredAddress" item="item" open="(" separator="," close=")">
+       "consigneeRegisteredAddress" in #{item}
+     </foreach>
+   </if>
+   <if test="consigneeReceiveAddress= null">
+     and
+     <foreach collection="consigneeReceiveAddress" item="item" open="(" separator="," close=")">
+       "consigneeReceiveAddress" in #{item}
+     </foreach>
+   </if>
+   <if test="consigneeRegistrationTime!= null">
+     and
+     <foreach collection="consigneeRegistrationTime" item="item" open="(" separator="," close=")">
+       "consigneeRegistrationTime" in #{item}
+     </foreach>
+   </if>
+   <if test="consigneeContactName!= null">
+     and
+     <foreach collection="consigneeContactName" item="item" open="(" separator="," close=")">
+       "consigneeContactName" in #{item}
+     </foreach>
+   </if>
+   <if test="consigneeContactTel!= null">
+     and
+     <foreach collection="consigneeContactTel" item="item" open="(" separator="," close=")">
+       "consigneeContactTel" in #{item}
+     </foreach>
+   </if>
+   </where>
+   <include refid="orderBy"></include>
+ </select>
+  <sql id="orderBy">
+  <if test="orderField!=null and orderField !=''">
+    order by "${orderField}"
+    <if test="orderType !=null and orderType !=''">
+      ${orderType}
+    </if>
+  </if>
+  </sql>
+</mapper>

+ 9 - 0
src/main/resources/com/steerinfo/dil/mapper/RmsDriverCapacityMapper.xml

@@ -385,7 +385,16 @@
         </foreach>
       </if>
     </where>
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
 
 
   <select id="getDriverCapacityById" resultType="java.util.LinkedHashMap">

+ 9 - 0
src/main/resources/com/steerinfo/dil/mapper/RmsGatepostMapper.xml

@@ -403,7 +403,16 @@
         </foreach>
       </if>
     </where>
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
   <!--  根据门岗id获取详细的门岗规则-->
   <select id="getGatepostRulesById" parameterType="java.util.LinkedHashMap" resultType="java.util.LinkedHashMap">
     SELECT

+ 9 - 0
src/main/resources/com/steerinfo/dil/mapper/RmsMaterialMapper.xml

@@ -609,7 +609,16 @@
                 </foreach>
             </if>
         </where>
+        <include refid="orderBy"></include>
     </select>
+    <sql id="orderBy">
+        <if test="orderField!=null and orderField !=''">
+            order by "${orderField}"
+            <if test="orderType !=null and orderType !=''">
+                ${orderType}
+            </if>
+        </if>
+    </sql>
 <!--根据id查询材料的详细信息-->
     <select id="selectMaterialById" resultType="java.util.LinkedHashMap">
         SELECT

+ 9 - 1
src/main/resources/com/steerinfo/dil/mapper/RmsMaterialTypeMapper.xml

@@ -6,7 +6,6 @@
     <result column="MATERIAL_TYPE_NAME" jdbcType="VARCHAR" property="materialTypeName" />
     <result column="MATERIAL_UNIT" jdbcType="VARCHAR" property="materialUnit" />
     <result column="MATERIAL_ORDER" jdbcType="DECIMAL" property="materialOrder" />
-    <result column="MATERIAL_PACKING_TYPE" jdbcType="VARCHAR" property="materialPackingType" />
     <result column="INSERT_USERNAME" jdbcType="VARCHAR" property="insertUsername" />
     <result column="INSERT_TIME" jdbcType="TIMESTAMP" property="insertTime" />
     <result column="UPDATE_USERNAME" jdbcType="VARCHAR" property="updateUsername" />
@@ -366,6 +365,15 @@
     </if>
 
   </where>
+  <include refid="orderBy"></include>
 </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
   
 </mapper>

+ 9 - 1
src/main/resources/com/steerinfo/dil/mapper/RmsOilPriceMapper.xml

@@ -366,8 +366,16 @@
       </if>
 
     </where>
-
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
 
 
 

+ 9 - 0
src/main/resources/com/steerinfo/dil/mapper/RmsPersonnelMapper.xml

@@ -594,7 +594,16 @@
         </foreach>
       </if>
     </where>
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
 
   <!--    根据id值展示人员信息-->
   <select id="selectPersonnelById"  resultType="java.util.LinkedHashMap">

+ 11 - 1
src/main/resources/com/steerinfo/dil/mapper/RmsShipperMapper.xml

@@ -1057,7 +1057,16 @@
         </foreach>
       </if>
     </where>
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
   <!--  根据id值获取托运人信息-->
   <select id="selectShipperById" resultType="java.util.LinkedHashMap">
     select
@@ -1065,6 +1074,7 @@
     RS.SHIPPER_NAME as "shipperName",
     RS.SHIPPER_ABBREVIATION as "shipperAbbreviation"
     from RMS_SHIPPER RS
-    WHERE RS.SHIPPER_ID=#{id}
+    where RS.SHIPPER_ID=#{id}
+    and RS.DELETED != 1
   </select>
 </mapper>

+ 9 - 0
src/main/resources/com/steerinfo/dil/mapper/RmsSupplierMapper.xml

@@ -922,7 +922,16 @@
         </foreach>
       </if>
     </where>
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
   <!--    根据id值展示供应商信息-->
   <select id="selectSupplierById" resultType="java.util.LinkedHashMap">
         SELECT

+ 9 - 0
src/main/resources/com/steerinfo/dil/mapper/RmsTruckCalculateMapper.xml

@@ -538,7 +538,16 @@
       </foreach>
     </if>
   </where>
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
 
 
 <select id="getTruckCalculateById" parameterType="java.util.Map" resultType="java.util.Map">

+ 78 - 43
src/main/resources/com/steerinfo/dil/mapper/RmsWarehouseMapper.xml

@@ -15,22 +15,23 @@
     <result column="UPDATE_TIME" jdbcType="TIMESTAMP" property="updateTime" />
     <result column="INSERT_UPDATE_REMARK" jdbcType="VARCHAR" property="insertUpdateRemark" />
     <result column="DELETED" jdbcType="DECIMAL" property="deleted" />
+    <result column="SHIPPER_ID" jdbcType="DECIMAL" property="shipperId" />
   </resultMap>
   <sql id="columns">
     WAREHOUSE_ID, WAREHOUSE_TYPE_ID, PORT_ID, WAREHOUSE_NAME, WAREHOUSE_CAPACITY, WAREHOUSE_LONGITUDE, 
     WAREHOUSE_LATITUDE, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK, 
-    DELETED
+    DELETED, SHIPPER_ID
   </sql>
   <sql id="columns_alias">
     t.WAREHOUSE_ID, t.WAREHOUSE_TYPE_ID, t.PORT_ID, t.WAREHOUSE_NAME, t.WAREHOUSE_CAPACITY, 
     t.WAREHOUSE_LONGITUDE, t.WAREHOUSE_LATITUDE, t.INSERT_USERNAME, t.INSERT_TIME, t.UPDATE_USERNAME, 
-    t.UPDATE_TIME, t.INSERT_UPDATE_REMARK, t.DELETED
+    t.UPDATE_TIME, t.INSERT_UPDATE_REMARK, t.DELETED, t.SHIPPER_ID
   </sql>
   <sql id="select">
-    SELECT <include refid="columns"/> FROM RMS_WAREHOUSE
+    SELECT <include refid="columns" /> FROM RMS_WAREHOUSE
   </sql>
   <sql id="select_alias">
-    SELECT <include refid="columns_alias"/> FROM RMS_WAREHOUSE t
+    SELECT <include refid="columns_alias" /> FROM RMS_WAREHOUSE t
   </sql>
   <sql id="where">
     <where> 
@@ -73,6 +74,9 @@
       <if test="deleted != null">
         and DELETED = #{deleted}
       </if>
+      <if test="shipperId != null">
+        and SHIPPER_ID = #{shipperId}
+      </if>
     </where>
   </sql>
   <sql id="whereLike">
@@ -116,6 +120,9 @@
       <if test="deleted != null">
         and DELETED = #{deleted}
       </if>
+      <if test="shipperId != null">
+        and SHIPPER_ID = #{shipperId}
+      </if>
     </where>
   </sql>
   <delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal">
@@ -161,18 +168,21 @@
       <if test="deleted != null">
         or DELETED = #{deleted}
       </if>
+      <if test="shipperId != null">
+        or SHIPPER_ID = #{shipperId}
+      </if>
   </delete>
   <insert id="insert" parameterType="com.steerinfo.dil.model.RmsWarehouse">
     insert into RMS_WAREHOUSE (WAREHOUSE_ID, WAREHOUSE_TYPE_ID, PORT_ID, 
       WAREHOUSE_NAME, WAREHOUSE_CAPACITY, WAREHOUSE_LONGITUDE, 
       WAREHOUSE_LATITUDE, INSERT_USERNAME, INSERT_TIME, 
       UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK, 
-      DELETED)
+      DELETED, SHIPPER_ID)
     values (#{warehouseId,jdbcType=DECIMAL}, #{warehouseTypeId,jdbcType=DECIMAL}, #{portId,jdbcType=DECIMAL}, 
       #{warehouseName,jdbcType=VARCHAR}, #{warehouseCapacity,jdbcType=DECIMAL}, #{warehouseLongitude,jdbcType=VARCHAR}, 
       #{warehouseLatitude,jdbcType=VARCHAR}, #{insertUsername,jdbcType=VARCHAR}, #{insertTime,jdbcType=TIMESTAMP}, 
       #{updateUsername,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{insertUpdateRemark,jdbcType=VARCHAR}, 
-      #{deleted,jdbcType=DECIMAL})
+      #{deleted,jdbcType=DECIMAL}, #{shipperId,jdbcType=DECIMAL})
   </insert>
   <insert id="insertSelective" parameterType="com.steerinfo.dil.model.RmsWarehouse">
     insert into RMS_WAREHOUSE
@@ -216,6 +226,9 @@
       <if test="deleted != null">
         DELETED,
       </if>
+      <if test="shipperId != null">
+        SHIPPER_ID,
+      </if>
     </trim>
     <trim prefix="values (" suffix=")" suffixOverrides=",">
       <if test="warehouseId != null">
@@ -257,6 +270,9 @@
       <if test="deleted != null">
         #{deleted,jdbcType=DECIMAL},
       </if>
+      <if test="shipperId != null">
+        #{shipperId,jdbcType=DECIMAL},
+      </if>
     </trim>
   </insert>
   <update id="updateByPrimaryKey" parameterType="com.steerinfo.dil.model.RmsWarehouse">
@@ -272,7 +288,8 @@
       UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR},
       UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP},
       INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR},
-      DELETED = #{deleted,jdbcType=DECIMAL}
+      DELETED = #{deleted,jdbcType=DECIMAL},
+      SHIPPER_ID = #{shipperId,jdbcType=DECIMAL}
     where WAREHOUSE_ID = #{warehouseId,jdbcType=DECIMAL}
   </update>
   <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.dil.model.RmsWarehouse">
@@ -314,20 +331,23 @@
       <if test="deleted != null">
         DELETED = #{deleted,jdbcType=DECIMAL},
       </if>
+      <if test="shipperId != null">
+        SHIPPER_ID = #{shipperId,jdbcType=DECIMAL},
+      </if>
     </set>
     where WAREHOUSE_ID = #{warehouseId,jdbcType=DECIMAL}
   </update>
   <select id="selectByPrimaryKey" parameterType="java.math.BigDecimal" resultMap="BaseResultMap">
-    <include refid="select"/>
+    <include refid="select" />
     where WAREHOUSE_ID = #{warehouseId,jdbcType=DECIMAL}
   </select>
   <select id="selectByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
-    <include refid="select"/>
-    <include refid="where"/>
+    <include refid="select" />
+    <include refid="where" />
   </select>
   <select id="selectLikeByParameters" parameterType="java.util.HashMap" resultMap="BaseResultMap">
-    <include refid="select"/>
-    <include refid="whereLike"/>
+    <include refid="select" />
+    <include refid="whereLike" />
   </select>
   <insert id="batchInsert" parameterType="java.util.List">
     insert into RMS_WAREHOUSE 
@@ -337,7 +357,7 @@
       WAREHOUSE_LATITUDE, INSERT_USERNAME, 
       INSERT_TIME, UPDATE_USERNAME, 
       UPDATE_TIME, INSERT_UPDATE_REMARK, 
-      DELETED)
+      DELETED, SHIPPER_ID)
     ( <foreach collection="list" item="item" separator="union all"> 
    select  
       #{item.warehouseId,jdbcType=DECIMAL}, 
@@ -346,86 +366,92 @@
       #{item.warehouseLatitude,jdbcType=VARCHAR}, #{item.insertUsername,jdbcType=VARCHAR}, 
       #{item.insertTime,jdbcType=TIMESTAMP}, #{item.updateUsername,jdbcType=VARCHAR}, 
       #{item.updateTime,jdbcType=TIMESTAMP}, #{item.insertUpdateRemark,jdbcType=VARCHAR}, 
-      #{item.deleted,jdbcType=DECIMAL} from dual  
+      #{item.deleted,jdbcType=DECIMAL}, #{item.shipperId,jdbcType=DECIMAL} from dual  
    </foreach> )
   </insert>
   <update id="batchUpdate" parameterType="java.util.List">
      update RMS_WAREHOUSE
      set
        WAREHOUSE_ID=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.warehouseId,jdbcType=DECIMAL}
        </foreach>
        ,WAREHOUSE_TYPE_ID=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.warehouseTypeId,jdbcType=DECIMAL}
        </foreach>
        ,PORT_ID=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.portId,jdbcType=DECIMAL}
        </foreach>
        ,WAREHOUSE_NAME=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.warehouseName,jdbcType=VARCHAR}
        </foreach>
        ,WAREHOUSE_CAPACITY=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.warehouseCapacity,jdbcType=DECIMAL}
        </foreach>
        ,WAREHOUSE_LONGITUDE=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.warehouseLongitude,jdbcType=VARCHAR}
        </foreach>
        ,WAREHOUSE_LATITUDE=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.warehouseLatitude,jdbcType=VARCHAR}
        </foreach>
        ,INSERT_USERNAME=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.insertUsername,jdbcType=VARCHAR}
        </foreach>
        ,INSERT_TIME=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.insertTime,jdbcType=TIMESTAMP}
        </foreach>
        ,UPDATE_USERNAME=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.updateUsername,jdbcType=VARCHAR}
        </foreach>
        ,UPDATE_TIME=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.updateTime,jdbcType=TIMESTAMP}
        </foreach>
        ,INSERT_UPDATE_REMARK=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.insertUpdateRemark,jdbcType=VARCHAR}
        </foreach>
        ,DELETED=
-       <foreach collection="list" item="item" index="index" separator=" " open="case WAREHOUSE_ID" close="end">
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
           when #{item.warehouseId,jdbcType=DECIMAL} then #{item.deleted,jdbcType=DECIMAL}
        </foreach>
+       ,SHIPPER_ID=
+       <foreach close="end" collection="list" index="index" item="item" open="case WAREHOUSE_ID" separator=" ">
+          when #{item.warehouseId,jdbcType=DECIMAL} then #{item.shipperId,jdbcType=DECIMAL}
+       </foreach>
      where WAREHOUSE_ID in 
-     <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
+     <foreach close=")" collection="list" index="index" item="item" open="(" separator=",">
     #{item.warehouseId,jdbcType=DECIMAL}
      </foreach> 
   </update>
   <delete id="batchDelete" parameterType="java.util.List">
     delete from RMS_WAREHOUSE
     where WAREHOUSE_ID in 
-    <foreach collection="list" item="id" open="(" close=")" separator=",">
+    <foreach close=")" collection="list" item="id" open="(" separator=",">
       #{id}
     </foreach>
   </delete>
   <!-- 友情提示!!!-->
   <!-- 请将自己写的代码放在此标签之下,方便以后粘贴复制。-->
-
   <select id="getWarehouseList" parameterType="java.util.Map" resultType="java.util.Map">
     SELECT * FROM
     (
     SELECT
     RW.WAREHOUSE_ID AS "warehouseId",
-    RW.WAREHOUSE_NAME AS "warehouseName"
+    RW.WAREHOUSE_NAME AS "warehouseName",
+    RS.SHIPPER_NAME AS "shipperName"
     FROM RMS_WAREHOUSE RW
+    LEFT JOIN RMS_SHIPPER RS
+    ON RW.SHIPPER_ID=RS.SHIPPER_ID
     WHERE RW.WAREHOUSE_TYPE_ID=3 AND RW.DELETED!=1
     ORDER BY RW.INSERT_TIME DESC
     )
@@ -442,8 +468,23 @@
           "warehouseName" in #{item}
         </foreach>
       </if>
+      <if test="shipperName!= null">
+        and
+        <foreach collection="shipperName" item="item" open="(" separator="," close=")">
+          "shipperName" in #{item}
+        </foreach>
+      </if>
     </where>
+    <include refid="orderBy"></include>
   </select>
+  <sql id="orderBy">
+    <if test="orderField!=null and orderField !=''">
+      order by "${orderField}"
+      <if test="orderType !=null and orderType !=''">
+        ${orderType}
+      </if>
+    </if>
+  </sql>
 
   <select id="getWarehouseById" resultType="java.util.LinkedHashMap">
     SELECT
@@ -467,7 +508,8 @@
            RP.PORT_NAME AS "label"
     FROM RMS_PORT RP
     </select>
-     <select id="getYardList" resultType="java.util.Map">
+
+  <select id="getYardList" resultType="java.util.Map">
     select
       rw.warehouse_id "warehouseId",
       RW.WAREHOUSE_NAME "warehouseName",
@@ -483,21 +525,14 @@
           #{item}
         </foreach>
       </if>
-        <if test="portName != null">
+      <if test="portName != null">
         and "portName" in
         <foreach collection="portName" item="item" open="(" separator="," close=")">
           #{item}
         </foreach>
       </if>
     </where>
-      <include refid="orderBy"></include>
-    </select>
-  <sql id="orderBy">
-    <if test="orderField != null and orderField != ''">
-      order by "${orderField}"
-      <if test="orderType != null and orderType != ''">
-        ${orderType}
-      </if>
-    </if>
-  </sql>
+
+  </select>
+
 </mapper>