|
@@ -23,25 +23,28 @@
|
|
|
<result column="ORDER_ENTRY_TIME" jdbcType="TIMESTAMP" property="orderEntryTime" />
|
|
|
<result column="UNLOAD_POINT_ID" jdbcType="DECIMAL" property="unloadPointId" />
|
|
|
<result column="DRIVER_CONFIRMATION" jdbcType="DECIMAL" property="driverConfirmation" />
|
|
|
+ <result column="PRICE_ID" jdbcType="DECIMAL" property="priceId" />
|
|
|
+ <result column="CARRIER_ID" jdbcType="DECIMAL" property="carrierId" />
|
|
|
</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
|
|
|
+ ORDER_LINE_SEQUENCE, LINE_ID, ORDER_ENTRY_TIME, UNLOAD_POINT_ID, DRIVER_CONFIRMATION,
|
|
|
+ PRICE_ID, CARRIER_ID
|
|
|
</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.DRIVER_CONFIRMATION, t.PRICE_ID, t.CARRIER_ID
|
|
|
</sql>
|
|
|
<sql id="select">
|
|
|
- SELECT <include refid="columns"/> FROM OMSTRUCK_ORDER
|
|
|
+ SELECT <include refid="columns" /> FROM OMSTRUCK_ORDER
|
|
|
</sql>
|
|
|
<sql id="select_alias">
|
|
|
- SELECT <include refid="columns_alias"/> FROM OMSTRUCK_ORDER t
|
|
|
+ SELECT <include refid="columns_alias" /> FROM OMSTRUCK_ORDER t
|
|
|
</sql>
|
|
|
<sql id="where">
|
|
|
<where>
|
|
@@ -108,6 +111,12 @@
|
|
|
<if test="driverConfirmation != null">
|
|
|
and DRIVER_CONFIRMATION = #{driverConfirmation}
|
|
|
</if>
|
|
|
+ <if test="priceId != null">
|
|
|
+ and PRICE_ID = #{priceId}
|
|
|
+ </if>
|
|
|
+ <if test="carrierId != null">
|
|
|
+ and CARRIER_ID = #{carrierId}
|
|
|
+ </if>
|
|
|
</where>
|
|
|
</sql>
|
|
|
<sql id="whereLike">
|
|
@@ -175,6 +184,12 @@
|
|
|
<if test="driverConfirmation != null">
|
|
|
and DRIVER_CONFIRMATION = #{driverConfirmation}
|
|
|
</if>
|
|
|
+ <if test="priceId != null">
|
|
|
+ and PRICE_ID = #{priceId}
|
|
|
+ </if>
|
|
|
+ <if test="carrierId != null">
|
|
|
+ and CARRIER_ID = #{carrierId}
|
|
|
+ </if>
|
|
|
</where>
|
|
|
</sql>
|
|
|
<delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal">
|
|
@@ -244,6 +259,12 @@
|
|
|
<if test="driverConfirmation != null">
|
|
|
or DRIVER_CONFIRMATION = #{driverConfirmation}
|
|
|
</if>
|
|
|
+ <if test="priceId != null">
|
|
|
+ or PRICE_ID = #{priceId}
|
|
|
+ </if>
|
|
|
+ <if test="carrierId != null">
|
|
|
+ or CARRIER_ID = #{carrierId}
|
|
|
+ </if>
|
|
|
</delete>
|
|
|
<insert id="insert" parameterType="com.steerinfo.dil.model.OmstruckOrder">
|
|
|
insert into OMSTRUCK_ORDER (ORDER_ID, ORDER_PLAN_ID, ORDER_NUMBER,
|
|
@@ -253,7 +274,8 @@
|
|
|
UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK,
|
|
|
DELETED, ORDER_TYPE, ORDER_LINE_SEQUENCE,
|
|
|
LINE_ID, ORDER_ENTRY_TIME, UNLOAD_POINT_ID,
|
|
|
- DRIVER_CONFIRMATION)
|
|
|
+ DRIVER_CONFIRMATION, PRICE_ID, CARRIER_ID
|
|
|
+ )
|
|
|
values (#{orderId,jdbcType=DECIMAL}, #{orderPlanId,jdbcType=DECIMAL}, #{orderNumber,jdbcType=VARCHAR},
|
|
|
#{capacityId,jdbcType=DECIMAL}, #{orderIssueTime,jdbcType=TIMESTAMP}, #{orderReceiveStatus,jdbcType=DECIMAL},
|
|
|
#{orderReceiveRefuseTime,jdbcType=TIMESTAMP}, #{orderCommunicationDuration,jdbcType=DECIMAL},
|
|
@@ -261,7 +283,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})
|
|
|
+ #{driverConfirmation,jdbcType=DECIMAL}, #{priceId,jdbcType=DECIMAL}, #{carrierId,jdbcType=DECIMAL}
|
|
|
+ )
|
|
|
</insert>
|
|
|
<insert id="insertSelective" parameterType="com.steerinfo.dil.model.OmstruckOrder">
|
|
|
insert into OMSTRUCK_ORDER
|
|
@@ -329,6 +352,12 @@
|
|
|
<if test="driverConfirmation != null">
|
|
|
DRIVER_CONFIRMATION,
|
|
|
</if>
|
|
|
+ <if test="priceId != null">
|
|
|
+ PRICE_ID,
|
|
|
+ </if>
|
|
|
+ <if test="carrierId != null">
|
|
|
+ CARRIER_ID,
|
|
|
+ </if>
|
|
|
</trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="orderId != null">
|
|
@@ -394,6 +423,12 @@
|
|
|
<if test="driverConfirmation != null">
|
|
|
#{driverConfirmation,jdbcType=DECIMAL},
|
|
|
</if>
|
|
|
+ <if test="priceId != null">
|
|
|
+ #{priceId,jdbcType=DECIMAL},
|
|
|
+ </if>
|
|
|
+ <if test="carrierId != null">
|
|
|
+ #{carrierId,jdbcType=DECIMAL},
|
|
|
+ </if>
|
|
|
</trim>
|
|
|
</insert>
|
|
|
<update id="updateByPrimaryKey" parameterType="com.steerinfo.dil.model.OmstruckOrder">
|
|
@@ -417,7 +452,9 @@
|
|
|
LINE_ID = #{lineId,jdbcType=DECIMAL},
|
|
|
ORDER_ENTRY_TIME = #{orderEntryTime,jdbcType=TIMESTAMP},
|
|
|
UNLOAD_POINT_ID = #{unloadPointId,jdbcType=DECIMAL},
|
|
|
- DRIVER_CONFIRMATION = #{driverConfirmation,jdbcType=DECIMAL}
|
|
|
+ DRIVER_CONFIRMATION = #{driverConfirmation,jdbcType=DECIMAL},
|
|
|
+ PRICE_ID = #{priceId,jdbcType=DECIMAL},
|
|
|
+ CARRIER_ID = #{carrierId,jdbcType=DECIMAL}
|
|
|
where ORDER_ID = #{orderId,jdbcType=DECIMAL}
|
|
|
</update>
|
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.steerinfo.dil.model.OmstruckOrder">
|
|
@@ -483,20 +520,26 @@
|
|
|
<if test="driverConfirmation != null">
|
|
|
DRIVER_CONFIRMATION = #{driverConfirmation,jdbcType=DECIMAL},
|
|
|
</if>
|
|
|
+ <if test="priceId != null">
|
|
|
+ PRICE_ID = #{priceId,jdbcType=DECIMAL},
|
|
|
+ </if>
|
|
|
+ <if test="carrierId != null">
|
|
|
+ CARRIER_ID = #{carrierId,jdbcType=DECIMAL},
|
|
|
+ </if>
|
|
|
</set>
|
|
|
where ORDER_ID = #{orderId,jdbcType=DECIMAL}
|
|
|
</update>
|
|
|
<select id="selectByPrimaryKey" parameterType="java.math.BigDecimal" resultMap="BaseResultMap">
|
|
|
- <include refid="select"/>
|
|
|
+ <include refid="select" />
|
|
|
where ORDER_ID = #{orderId,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 OMSTRUCK_ORDER
|
|
@@ -509,7 +552,8 @@
|
|
|
UPDATE_TIME, INSERT_UPDATE_REMARK,
|
|
|
DELETED, ORDER_TYPE, ORDER_LINE_SEQUENCE,
|
|
|
LINE_ID, ORDER_ENTRY_TIME, UNLOAD_POINT_ID,
|
|
|
- DRIVER_CONFIRMATION)
|
|
|
+ DRIVER_CONFIRMATION, PRICE_ID,
|
|
|
+ CARRIER_ID)
|
|
|
( <foreach collection="list" item="item" separator="union all">
|
|
|
select
|
|
|
#{item.orderId,jdbcType=DECIMAL},
|
|
@@ -521,105 +565,114 @@
|
|
|
#{item.updateTime,jdbcType=TIMESTAMP}, #{item.insertUpdateRemark,jdbcType=VARCHAR},
|
|
|
#{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} from dual
|
|
|
+ #{item.driverConfirmation,jdbcType=DECIMAL}, #{item.priceId,jdbcType=DECIMAL},
|
|
|
+ #{item.carrierId,jdbcType=DECIMAL} from dual
|
|
|
</foreach> )
|
|
|
</insert>
|
|
|
<update id="batchUpdate" parameterType="java.util.List">
|
|
|
update OMSTRUCK_ORDER
|
|
|
set
|
|
|
ORDER_ID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,ORDER_PLAN_ID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderPlanId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,ORDER_NUMBER=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderNumber,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,CAPACITY_ID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.capacityId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,ORDER_ISSUE_TIME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderIssueTime,jdbcType=TIMESTAMP}
|
|
|
</foreach>
|
|
|
,ORDER_RECEIVE_STATUS=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderReceiveStatus,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,ORDER_RECEIVE_REFUSE_TIME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderReceiveRefuseTime,jdbcType=TIMESTAMP}
|
|
|
</foreach>
|
|
|
,ORDER_COMMUNICATION_DURATION=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderCommunicationDuration,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,ORDER_STATUS=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderStatus,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,INSERT_USERNAME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.insertUsername,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,INSERT_TIME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.insertTime,jdbcType=TIMESTAMP}
|
|
|
</foreach>
|
|
|
,UPDATE_USERNAME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.updateUsername,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,UPDATE_TIME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.updateTime,jdbcType=TIMESTAMP}
|
|
|
</foreach>
|
|
|
,INSERT_UPDATE_REMARK=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.insertUpdateRemark,jdbcType=VARCHAR}
|
|
|
</foreach>
|
|
|
,DELETED=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.deleted,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,ORDER_TYPE=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderType,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,ORDER_LINE_SEQUENCE=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderLineSequence,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,LINE_ID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.lineId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,ORDER_ENTRY_TIME=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.orderEntryTime,jdbcType=TIMESTAMP}
|
|
|
</foreach>
|
|
|
,UNLOAD_POINT_ID=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.unloadPointId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
,DRIVER_CONFIRMATION=
|
|
|
- <foreach collection="list" item="item" index="index" separator=" " open="case ORDER_ID" close="end">
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
when #{item.orderId,jdbcType=DECIMAL} then #{item.driverConfirmation,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
+ ,PRICE_ID=
|
|
|
+ <foreach close="end" collection="list" index="index" item="item" open="case ORDER_ID" separator=" ">
|
|
|
+ when #{item.orderId,jdbcType=DECIMAL} then #{item.priceId,jdbcType=DECIMAL}
|
|
|
+ </foreach>
|
|
|
+ ,CARRIER_ID=
|
|
|
+ <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>
|
|
|
where ORDER_ID in
|
|
|
- <foreach collection="list" index="index" item="item" separator="," open="(" close=")">
|
|
|
+ <foreach close=")" collection="list" index="index" item="item" open="(" separator=",">
|
|
|
#{item.orderId,jdbcType=DECIMAL}
|
|
|
</foreach>
|
|
|
</update>
|
|
|
<delete id="batchDelete" parameterType="java.util.List">
|
|
|
delete from OMSTRUCK_ORDER
|
|
|
where ORDER_ID in
|
|
|
- <foreach collection="list" item="id" open="(" close=")" separator=",">
|
|
|
+ <foreach close=")" collection="list" item="id" open="(" separator=",">
|
|
|
#{id}
|
|
|
</foreach>
|
|
|
</delete>
|