HUJIANGUO 3 years ago
parent
commit
71877c4e77

+ 1 - 1
pom.xml

@@ -110,7 +110,7 @@
                     <targetPackage>com.steerinfo.dil</targetPackage>
                     <tables>
 <!--                        <table>TMSTRUCK_UNLOAD_RESULT</table>-->
-                        <param>OMSTRUCK_ORDER_MATERIAL</param>
+                        <param>OMSTRUCK_ORDER</param>
                     </tables>
                 </configuration>
                 <executions>

+ 5 - 2
src/main/java/com/steerinfo/dil/controller/OmstruckOrderController.java

@@ -592,12 +592,15 @@ public class OmstruckOrderController extends BaseRESTfulController {
                                               Integer orderType,
                                               Integer orderStatus,
                                               String con,
-                                              String carrierSsoId
+                                              String carrierSsoId,
+                                              Integer shipperId
     ) {
         if (orderType != null) {
             mapValue.put("orderTypee", orderType);
         }
-
+        if (shipperId != null) {
+            mapValue.put("shipperId",shipperId);
+        }
         if (orderStatus != null) {
             mapValue.put("orderStatus", orderStatus);
         }

+ 47 - 2
src/main/java/com/steerinfo/dil/model/OmstruckOrder.java

@@ -100,9 +100,9 @@ public class OmstruckOrder implements IBasePO<BigDecimal> {
     private BigDecimal deleted;
 
     /**
-     * 订单类型(1:销售订单;2:焦炭发运计划;3:水渣发运计划;4:内转到异地库;5:采购辅料订单;6:采购老区燃料订单;7:采购新区燃料订单;8:采购进口矿(万州-厂内);9:采购内转(达州-厂内);10:采购内转(老区-厂内); 11:厂内内转;12:零星物资进厂、13:零星物资出厂:14:钢材退货 ;15 内转精煤进厂;16 内转精煤出厂;17 采购化工材料新区订单; 18 采购化工材料老区订单)(ORDER_TYPE,DECIMAL,0)
+     * 订单类型(1:销售订单;2:焦炭发运计划;3:水渣发运计划;4:内转到异地库;5:采购辅料订单;6:采购老区燃料订单;7:采购新区燃料订单;8:采购进口矿(万州-厂内);9:内转钢坯车 ; 10:采购内转(老区-厂内); 11:厂内内转;12:零星物资进厂、13:零星物资出厂:14:钢材退货 ;15 内转精煤进厂;16 内转精煤出厂;17 采购化工材料新区订单; 18 采购化工材料老区订单)(ORDER_TYPE,DECIMAL,0)
      */
-    @ApiModelProperty(value="订单类型(1:销售订单;2:焦炭发运计划;3:水渣发运计划;4:内转到异地库;5:采购辅料订单;6:采购老区燃料订单;7:采购新区燃料订单;8:采购进口矿(万州-厂内);9:采购内转(达州-厂内);10:采购内转(老区-厂内); 11:厂内内转;12:零星物资进厂、13:零星物资出厂:14:钢材退货 ;15 内转精煤进厂;16 内转精煤出厂;17 采购化工材料新区订单; 18 采购化工材料老区订单)",required=false)
+    @ApiModelProperty(value="订单类型(1:销售订单;2:焦炭发运计划;3:水渣发运计划;4:内转到异地库;5:采购辅料订单;6:采购老区燃料订单;7:采购新区燃料订单;8:采购进口矿(万州-厂内);9:内转钢坯车 ; 10:采购内转(老区-厂内); 11:厂内内转;12:零星物资进厂、13:零星物资出厂:14:钢材退货 ;15 内转精煤进厂;16 内转精煤出厂;17 采购化工材料新区订单; 18 采购化工材料老区订单)",required=false)
     private BigDecimal orderType;
 
     /**
@@ -147,6 +147,24 @@ public class OmstruckOrder implements IBasePO<BigDecimal> {
     @ApiModelProperty(value="订单所属承运商ID",required=false)
     private BigDecimal carrierId;
 
+    /**
+     * 行程ID(TRIP_ID,VARCHAR,200)
+     */
+    @ApiModelProperty(value="行程ID",required=false)
+    private String tripId;
+
+    /**
+     * 打印状态(ORDER_PRINT_STATUS,DECIMAL,0)
+     */
+    @ApiModelProperty(value="打印状态",required=false)
+    private BigDecimal orderPrintStatus;
+
+    /**
+     * 司机电话号码(DRIVER_TEL,VARCHAR,36)
+     */
+    @ApiModelProperty(value="司机电话号码",required=false)
+    private String driverTel;
+
     private static final long serialVersionUID = 1L;
 
     @Override
@@ -343,6 +361,30 @@ public class OmstruckOrder implements IBasePO<BigDecimal> {
         this.carrierId = carrierId;
     }
 
+    public String getTripId() {
+        return tripId;
+    }
+
+    public void setTripId(String tripId) {
+        this.tripId = tripId == null ? null : tripId.trim();
+    }
+
+    public BigDecimal getOrderPrintStatus() {
+        return orderPrintStatus;
+    }
+
+    public void setOrderPrintStatus(BigDecimal orderPrintStatus) {
+        this.orderPrintStatus = orderPrintStatus;
+    }
+
+    public String getDriverTel() {
+        return driverTel;
+    }
+
+    public void setDriverTel(String driverTel) {
+        this.driverTel = driverTel == null ? null : driverTel.trim();
+    }
+
     @Override
     public String toString() {
         StringBuilder sb = new StringBuilder();
@@ -372,6 +414,9 @@ public class OmstruckOrder implements IBasePO<BigDecimal> {
         sb.append(", driverConfirmation=").append(driverConfirmation);
         sb.append(", priceId=").append(priceId);
         sb.append(", carrierId=").append(carrierId);
+        sb.append(", tripId=").append(tripId);
+        sb.append(", orderPrintStatus=").append(orderPrintStatus);
+        sb.append(", driverTel=").append(driverTel);
         sb.append(", serialVersionUID=").append(serialVersionUID);
         sb.append("]");
         return sb.toString();

+ 98 - 17
src/main/resources/com/steerinfo/dil/mapper/OmstruckOrderMapper.xml

@@ -25,20 +25,24 @@
         <result column="DRIVER_CONFIRMATION" jdbcType="DECIMAL" property="driverConfirmation" />
         <result column="PRICE_ID" jdbcType="DECIMAL" property="priceId" />
         <result column="CARRIER_ID" jdbcType="DECIMAL" property="carrierId" />
+        <result column="TRIP_ID" jdbcType="VARCHAR" property="tripId" />
+        <result column="ORDER_PRINT_STATUS" jdbcType="DECIMAL" property="orderPrintStatus" />
+        <result column="DRIVER_TEL" jdbcType="VARCHAR" property="driverTel" />
     </resultMap>
     <sql id="columns">
-        ORDER_ID, ORDER_PLAN_ID, ORDER_NUMBER, CAPACITY_ID, ORDER_ISSUE_TIME, ORDER_RECEIVE_STATUS, 
-    ORDER_RECEIVE_REFUSE_TIME, ORDER_COMMUNICATION_DURATION, ORDER_STATUS, INSERT_USERNAME, 
-    INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK, DELETED, ORDER_TYPE, 
-    ORDER_LINE_SEQUENCE, LINE_ID, ORDER_ENTRY_TIME, UNLOAD_POINT_ID, DRIVER_CONFIRMATION, 
-    PRICE_ID, CARRIER_ID
+        ORDER_ID, ORDER_PLAN_ID, ORDER_NUMBER, CAPACITY_ID, ORDER_ISSUE_TIME, ORDER_RECEIVE_STATUS,
+    ORDER_RECEIVE_REFUSE_TIME, ORDER_COMMUNICATION_DURATION, ORDER_STATUS, INSERT_USERNAME,
+    INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK, DELETED, ORDER_TYPE,
+    ORDER_LINE_SEQUENCE, LINE_ID, ORDER_ENTRY_TIME, UNLOAD_POINT_ID, DRIVER_CONFIRMATION,
+    PRICE_ID, CARRIER_ID, TRIP_ID, ORDER_PRINT_STATUS, DRIVER_TEL
     </sql>
     <sql id="columns_alias">
-        t.ORDER_ID, t.ORDER_PLAN_ID, t.ORDER_NUMBER, t.CAPACITY_ID, t.ORDER_ISSUE_TIME, t.ORDER_RECEIVE_STATUS, 
-    t.ORDER_RECEIVE_REFUSE_TIME, t.ORDER_COMMUNICATION_DURATION, t.ORDER_STATUS, t.INSERT_USERNAME, 
-    t.INSERT_TIME, t.UPDATE_USERNAME, t.UPDATE_TIME, t.INSERT_UPDATE_REMARK, t.DELETED, 
-    t.ORDER_TYPE, t.ORDER_LINE_SEQUENCE, t.LINE_ID, t.ORDER_ENTRY_TIME, t.UNLOAD_POINT_ID, 
-    t.DRIVER_CONFIRMATION, t.PRICE_ID, t.CARRIER_ID
+        t.ORDER_ID, t.ORDER_PLAN_ID, t.ORDER_NUMBER, t.CAPACITY_ID, t.ORDER_ISSUE_TIME, t.ORDER_RECEIVE_STATUS,
+    t.ORDER_RECEIVE_REFUSE_TIME, t.ORDER_COMMUNICATION_DURATION, t.ORDER_STATUS, t.INSERT_USERNAME,
+    t.INSERT_TIME, t.UPDATE_USERNAME, t.UPDATE_TIME, t.INSERT_UPDATE_REMARK, t.DELETED,
+    t.ORDER_TYPE, t.ORDER_LINE_SEQUENCE, t.LINE_ID, t.ORDER_ENTRY_TIME, t.UNLOAD_POINT_ID,
+    t.DRIVER_CONFIRMATION, t.PRICE_ID, t.CARRIER_ID, t.TRIP_ID, t.ORDER_PRINT_STATUS,
+    t.DRIVER_TEL
     </sql>
     <sql id="select">
         SELECT <include refid="columns" /> FROM OMSTRUCK_ORDER
@@ -117,6 +121,15 @@
             <if test="carrierId != null">
                 and CARRIER_ID = #{carrierId}
             </if>
+            <if test="tripId != null and tripId != ''">
+                and TRIP_ID = #{tripId}
+            </if>
+            <if test="orderPrintStatus != null">
+                and ORDER_PRINT_STATUS = #{orderPrintStatus}
+            </if>
+            <if test="driverTel != null and driverTel != ''">
+                and DRIVER_TEL = #{driverTel}
+            </if>
         </where>
     </sql>
     <sql id="whereLike">
@@ -190,6 +203,15 @@
             <if test="carrierId != null">
                 and CARRIER_ID = #{carrierId}
             </if>
+            <if test="tripId != null and tripId != ''">
+                and TRIP_ID LIKE '%${tripId}%'
+            </if>
+            <if test="orderPrintStatus != null">
+                and ORDER_PRINT_STATUS = #{orderPrintStatus}
+            </if>
+            <if test="driverTel != null and driverTel != ''">
+                and DRIVER_TEL LIKE '%${driverTel}%'
+            </if>
         </where>
     </sql>
     <delete id="deleteByPrimaryKey" parameterType="java.lang.Short">
@@ -265,6 +287,15 @@
         <if test="carrierId != null">
             or CARRIER_ID = #{carrierId}
         </if>
+        <if test="tripId != null and tripId != ''">
+            or TRIP_ID = #{tripId}
+        </if>
+        <if test="orderPrintStatus != null">
+            or ORDER_PRINT_STATUS = #{orderPrintStatus}
+        </if>
+        <if test="driverTel != null and driverTel != ''">
+            or DRIVER_TEL = #{driverTel}
+        </if>
     </delete>
     <insert id="insert" parameterType="com.steerinfo.dil.model.OmstruckOrder">
         insert into OMSTRUCK_ORDER (ORDER_ID, ORDER_PLAN_ID, ORDER_NUMBER,
@@ -274,7 +305,8 @@
                                     UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK,
                                     DELETED, ORDER_TYPE, ORDER_LINE_SEQUENCE,
                                     LINE_ID, ORDER_ENTRY_TIME, UNLOAD_POINT_ID,
-                                    DRIVER_CONFIRMATION, PRICE_ID, CARRIER_ID
+                                    DRIVER_CONFIRMATION, PRICE_ID, CARRIER_ID,
+                                    TRIP_ID, ORDER_PRINT_STATUS, DRIVER_TEL
         )
         values (#{orderId,jdbcType=DECIMAL}, #{orderPlanId,jdbcType=DECIMAL}, #{orderNumber,jdbcType=VARCHAR},
                 #{capacityId,jdbcType=DECIMAL}, #{orderIssueTime,jdbcType=TIMESTAMP}, #{orderReceiveStatus,jdbcType=DECIMAL},
@@ -283,7 +315,8 @@
                 #{updateUsername,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{insertUpdateRemark,jdbcType=VARCHAR},
                 #{deleted,jdbcType=DECIMAL}, #{orderType,jdbcType=DECIMAL}, #{orderLineSequence,jdbcType=DECIMAL},
                 #{lineId,jdbcType=DECIMAL}, #{orderEntryTime,jdbcType=TIMESTAMP}, #{unloadPointId,jdbcType=DECIMAL},
-                #{driverConfirmation,jdbcType=DECIMAL}, #{priceId,jdbcType=DECIMAL}, #{carrierId,jdbcType=DECIMAL}
+                #{driverConfirmation,jdbcType=DECIMAL}, #{priceId,jdbcType=DECIMAL}, #{carrierId,jdbcType=DECIMAL},
+                #{tripId,jdbcType=VARCHAR}, #{orderPrintStatus,jdbcType=DECIMAL}, #{driverTel,jdbcType=VARCHAR}
                )
     </insert>
     <insert id="insertSelective" parameterType="com.steerinfo.dil.model.OmstruckOrder">
@@ -358,6 +391,15 @@
             <if test="carrierId != null">
                 CARRIER_ID,
             </if>
+            <if test="tripId != null">
+                TRIP_ID,
+            </if>
+            <if test="orderPrintStatus != null">
+                ORDER_PRINT_STATUS,
+            </if>
+            <if test="driverTel != null">
+                DRIVER_TEL,
+            </if>
         </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="orderId != null">
@@ -429,6 +471,15 @@
             <if test="carrierId != null">
                 #{carrierId,jdbcType=DECIMAL},
             </if>
+            <if test="tripId != null">
+                #{tripId,jdbcType=VARCHAR},
+            </if>
+            <if test="orderPrintStatus != null">
+                #{orderPrintStatus,jdbcType=DECIMAL},
+            </if>
+            <if test="driverTel != null">
+                #{driverTel,jdbcType=VARCHAR},
+            </if>
         </trim>
     </insert>
     <update id="updateByPrimaryKey" parameterType="com.steerinfo.dil.model.OmstruckOrder">
@@ -454,7 +505,10 @@
             UNLOAD_POINT_ID = #{unloadPointId,jdbcType=DECIMAL},
             DRIVER_CONFIRMATION = #{driverConfirmation,jdbcType=DECIMAL},
             PRICE_ID = #{priceId,jdbcType=DECIMAL},
-            CARRIER_ID = #{carrierId,jdbcType=DECIMAL}
+            CARRIER_ID = #{carrierId,jdbcType=DECIMAL},
+            TRIP_ID = #{tripId,jdbcType=VARCHAR},
+            ORDER_PRINT_STATUS = #{orderPrintStatus,jdbcType=DECIMAL},
+            DRIVER_TEL = #{driverTel,jdbcType=VARCHAR}
         where ORDER_ID = #{orderId,jdbcType=DECIMAL}
     </update>
     <update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.dil.model.OmstruckOrder">
@@ -526,10 +580,19 @@
             <if test="carrierId != null">
                 CARRIER_ID = #{carrierId,jdbcType=DECIMAL},
             </if>
+            <if test="tripId != null">
+                TRIP_ID = #{tripId,jdbcType=VARCHAR},
+            </if>
+            <if test="orderPrintStatus != null">
+                ORDER_PRINT_STATUS = #{orderPrintStatus,jdbcType=DECIMAL},
+            </if>
+            <if test="driverTel != null">
+                DRIVER_TEL = #{driverTel,jdbcType=VARCHAR},
+            </if>
         </set>
         where ORDER_ID = #{orderId,jdbcType=DECIMAL}
     </update>
-    <select id="selectByPrimaryKey" parameterType="java.math.BigDecimal" resultMap="BaseResultMap">
+    <select id="selectByPrimaryKey" parameterType="java.lang.Short" resultMap="BaseResultMap">
         <include refid="select" />
         where ORDER_ID = #{orderId,jdbcType=DECIMAL}
     </select>
@@ -553,7 +616,8 @@
         DELETED, ORDER_TYPE, ORDER_LINE_SEQUENCE,
         LINE_ID, ORDER_ENTRY_TIME, UNLOAD_POINT_ID,
         DRIVER_CONFIRMATION, PRICE_ID,
-        CARRIER_ID)
+        CARRIER_ID, TRIP_ID, ORDER_PRINT_STATUS,
+        DRIVER_TEL)
         ( <foreach collection="list" item="item" separator="union all">
         select
         #{item.orderId,jdbcType=DECIMAL},
@@ -566,7 +630,8 @@
         #{item.deleted,jdbcType=DECIMAL}, #{item.orderType,jdbcType=DECIMAL}, #{item.orderLineSequence,jdbcType=DECIMAL},
         #{item.lineId,jdbcType=DECIMAL}, #{item.orderEntryTime,jdbcType=TIMESTAMP}, #{item.unloadPointId,jdbcType=DECIMAL},
         #{item.driverConfirmation,jdbcType=DECIMAL}, #{item.priceId,jdbcType=DECIMAL},
-        #{item.carrierId,jdbcType=DECIMAL} from dual
+        #{item.carrierId,jdbcType=DECIMAL}, #{item.tripId,jdbcType=VARCHAR}, #{item.orderPrintStatus,jdbcType=DECIMAL},
+        #{item.driverTel,jdbcType=VARCHAR} from dual
     </foreach> )
     </insert>
     <update id="batchUpdate" parameterType="java.util.List">
@@ -664,6 +729,18 @@
         <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
             when #{item.orderId,jdbcType=DECIMAL} then #{item.carrierId,jdbcType=DECIMAL}
         </foreach>
+        ,TRIP_ID=
+        <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
+            when #{item.orderId,jdbcType=DECIMAL} then #{item.tripId,jdbcType=VARCHAR}
+        </foreach>
+        ,ORDER_PRINT_STATUS=
+        <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
+            when #{item.orderId,jdbcType=DECIMAL} then #{item.orderPrintStatus,jdbcType=DECIMAL}
+        </foreach>
+        ,DRIVER_TEL=
+        <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
+            when #{item.orderId,jdbcType=DECIMAL} then #{item.driverTel,jdbcType=VARCHAR}
+        </foreach>
         where ORDER_ID in
         <foreach close=")" collection="list" index="index" item="item" open="(" separator=",">
             #{item.orderId,jdbcType=DECIMAL}
@@ -1776,7 +1853,11 @@
                 and RC3.CARRIER_ID = #{carrierId}
             </if>
             <if test="orderTypee!=null">
-                and OO.ORDER_TYPE in (1, 2)
+                and OO.ORDER_TYPE = #{orderTypee}
+            </if>
+
+            <if test="shipperId!=null">
+                and ASO.SHIPPER_ID = #{shipperId}
             </if>
         </where>
         ) RRC