|
@@ -10,6 +10,7 @@
|
|
<result column="order_no" jdbcType="VARCHAR" property="orderNo" />
|
|
<result column="order_no" jdbcType="VARCHAR" property="orderNo" />
|
|
<result column="oil_gun" jdbcType="VARCHAR" property="oilGun" />
|
|
<result column="oil_gun" jdbcType="VARCHAR" property="oilGun" />
|
|
<result column="oil_name" jdbcType="VARCHAR" property="oilName" />
|
|
<result column="oil_name" jdbcType="VARCHAR" property="oilName" />
|
|
|
|
+ <result column="oil_price" jdbcType="VARCHAR" property="oilPirce" />
|
|
<result column="consumer_id" jdbcType="INTEGER" property="consumerId" />
|
|
<result column="consumer_id" jdbcType="INTEGER" property="consumerId" />
|
|
<result column="consumer" jdbcType="VARCHAR" property="consumer" />
|
|
<result column="consumer" jdbcType="VARCHAR" property="consumer" />
|
|
<result column="amt" jdbcType="VARCHAR" property="amt" />
|
|
<result column="amt" jdbcType="VARCHAR" property="amt" />
|
|
@@ -22,6 +23,7 @@
|
|
<result column="oil_personnel" jdbcType="VARCHAR" property="oilPersonnel" />
|
|
<result column="oil_personnel" jdbcType="VARCHAR" property="oilPersonnel" />
|
|
<result column="created_date" jdbcType="TIMESTAMP" property="createdDate" />
|
|
<result column="created_date" jdbcType="TIMESTAMP" property="createdDate" />
|
|
<result column="order_type" jdbcType="CHAR" property="orderType" />
|
|
<result column="order_type" jdbcType="CHAR" property="orderType" />
|
|
|
|
+ <result column="station_name" jdbcType="CHAR" property="stationName" />
|
|
</resultMap>
|
|
</resultMap>
|
|
<sql id="Example_Where_Clause">
|
|
<sql id="Example_Where_Clause">
|
|
<!--
|
|
<!--
|
|
@@ -94,19 +96,21 @@
|
|
WARNING - @mbg.generated
|
|
WARNING - @mbg.generated
|
|
This element is automatically generated by MyBatis Generator, do not modify.
|
|
This element is automatically generated by MyBatis Generator, do not modify.
|
|
-->
|
|
-->
|
|
- order_id, order_no, oil_gun, oil_name, consumer_id, consumer, amt, station_id, status,
|
|
|
|
- order_liters, pay_type, pay_way, pay_date, oil_personnel, created_date, order_type
|
|
|
|
|
|
+ order_id, order_no, oil_gun, oil_name, oil_pirce, consumer_id, consumer, amt, station_id, status,
|
|
|
|
+ order_liters, pay_type, pay_way, pay_date, oil_personnel, created_date, order_type, station_name
|
|
</sql>
|
|
</sql>
|
|
|
|
|
|
<!-- 根据油品名称和油站查询油枪编号和价格 -->
|
|
<!-- 根据油品名称和油站查询油枪编号和价格 -->
|
|
<select id="selectOilGunNoAndOilPrice" parameterType="map" resultType="map">
|
|
<select id="selectOilGunNoAndOilPrice" parameterType="map" resultType="map">
|
|
SELECT
|
|
SELECT
|
|
- A.oil_gun_no AS oliGunNo,
|
|
|
|
- A.oil_name AS oilName,
|
|
|
|
- A.station_name AS stationName,
|
|
|
|
- B.oil_price AS oilPrice
|
|
|
|
|
|
+ A.oil_gun_no AS oliGunNo,
|
|
|
|
+ A.oil_name AS oilName,
|
|
|
|
+ A.station_name AS stationName,
|
|
|
|
+ B.oil_price AS oilPrice,
|
|
|
|
+ C.personnel_name AS personnelName
|
|
FROM station_oil_gun AS A
|
|
FROM station_oil_gun AS A
|
|
LEFT JOIN station_oil_price AS B ON A.oil_name = B.oil_name AND A.station_id = B.station_id
|
|
LEFT JOIN station_oil_price AS B ON A.oil_name = B.oil_name AND A.station_id = B.station_id
|
|
|
|
+ LEFT JOIN station_personnel AS C ON A.oil_gun_no = C.gun_no AND A.station_id = C.station_id
|
|
<where>
|
|
<where>
|
|
<if test="oilGunId != null and oilGunId !=''">
|
|
<if test="oilGunId != null and oilGunId !=''">
|
|
A.oil_gun_id = #{oilGunId}
|
|
A.oil_gun_id = #{oilGunId}
|
|
@@ -167,7 +171,7 @@
|
|
WARNING - @mbg.generated
|
|
WARNING - @mbg.generated
|
|
This element is automatically generated by MyBatis Generator, do not modify.
|
|
This element is automatically generated by MyBatis Generator, do not modify.
|
|
-->
|
|
-->
|
|
- select
|
|
|
|
|
|
+ select
|
|
<include refid="Base_Column_List" />
|
|
<include refid="Base_Column_List" />
|
|
from pay_order
|
|
from pay_order
|
|
where order_id = #{orderId,jdbcType=INTEGER}
|
|
where order_id = #{orderId,jdbcType=INTEGER}
|
|
@@ -195,18 +199,18 @@
|
|
WARNING - @mbg.generated
|
|
WARNING - @mbg.generated
|
|
This element is automatically generated by MyBatis Generator, do not modify.
|
|
This element is automatically generated by MyBatis Generator, do not modify.
|
|
-->
|
|
-->
|
|
- insert into pay_order (order_id, order_no, oil_gun,
|
|
|
|
- oil_name, consumer_id, consumer,
|
|
|
|
- amt, station_id, status,
|
|
|
|
- order_liters, pay_type, pay_way,
|
|
|
|
- pay_date, oil_personnel, created_date,
|
|
|
|
- order_type)
|
|
|
|
- values (#{orderId,jdbcType=INTEGER}, #{orderNo,jdbcType=VARCHAR}, #{oilGun,jdbcType=VARCHAR},
|
|
|
|
- #{oilName,jdbcType=VARCHAR}, #{consumerId,jdbcType=INTEGER}, #{consumer,jdbcType=VARCHAR},
|
|
|
|
- #{amt,jdbcType=VARCHAR}, #{stationId,jdbcType=INTEGER}, #{status,jdbcType=VARCHAR},
|
|
|
|
- #{orderLiters,jdbcType=VARCHAR}, #{payType,jdbcType=VARCHAR}, #{payWay,jdbcType=VARCHAR},
|
|
|
|
- #{payDate,jdbcType=TIMESTAMP}, #{oilPersonnel,jdbcType=VARCHAR}, #{createdDate,jdbcType=TIMESTAMP},
|
|
|
|
- #{orderType,jdbcType=CHAR})
|
|
|
|
|
|
+ insert into pay_order (order_id, order_no, oil_gun,
|
|
|
|
+ oil_name, oli_price, consumer_id, consumer,
|
|
|
|
+ amt, station_id, status,
|
|
|
|
+ order_liters, pay_type, pay_way,
|
|
|
|
+ pay_date, oil_personnel, created_date,
|
|
|
|
+ order_type, station_name)
|
|
|
|
+ values (#{orderId,jdbcType=INTEGER}, #{orderNo,jdbcType=VARCHAR}, #{oilGun,jdbcType=VARCHAR},
|
|
|
|
+ #{oilName,jdbcType=VARCHAR}, #{oilPirce,jdbcType=VARCHAR}, #{consumerId,jdbcType=INTEGER}, #{consumer,jdbcType=VARCHAR},
|
|
|
|
+ #{amt,jdbcType=VARCHAR}, #{stationId,jdbcType=INTEGER}, #{status,jdbcType=VARCHAR},
|
|
|
|
+ #{orderLiters,jdbcType=VARCHAR}, #{payType,jdbcType=VARCHAR}, #{payWay,jdbcType=VARCHAR},
|
|
|
|
+ #{payDate,jdbcType=TIMESTAMP}, #{oilPersonnel,jdbcType=VARCHAR}, #{createdDate,jdbcType=TIMESTAMP},
|
|
|
|
+ #{orderType,jdbcType=CHAR}, #{stationName,jdbcType=VARCHAR})
|
|
</insert>
|
|
</insert>
|
|
<insert id="insertSelective" parameterType="com.platform.yijia.pojo.PayOrder">
|
|
<insert id="insertSelective" parameterType="com.platform.yijia.pojo.PayOrder">
|
|
<!--
|
|
<!--
|
|
@@ -227,6 +231,9 @@
|
|
<if test="oilName != null">
|
|
<if test="oilName != null">
|
|
oil_name,
|
|
oil_name,
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="oilPirce != null">
|
|
|
|
+ oil_pirce,
|
|
|
|
+ </if>
|
|
<if test="consumerId != null">
|
|
<if test="consumerId != null">
|
|
consumer_id,
|
|
consumer_id,
|
|
</if>
|
|
</if>
|
|
@@ -263,6 +270,9 @@
|
|
<if test="orderType != null">
|
|
<if test="orderType != null">
|
|
order_type,
|
|
order_type,
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="stationName != null">
|
|
|
|
+ station_name,
|
|
|
|
+ </if>
|
|
</trim>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="orderId != null">
|
|
<if test="orderId != null">
|
|
@@ -277,6 +287,9 @@
|
|
<if test="oilName != null">
|
|
<if test="oilName != null">
|
|
#{oilName,jdbcType=VARCHAR},
|
|
#{oilName,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="oilPirce != null">
|
|
|
|
+ #{oilPirce,jdbcType=VARCHAR},
|
|
|
|
+ </if>
|
|
<if test="consumerId != null">
|
|
<if test="consumerId != null">
|
|
#{consumerId,jdbcType=INTEGER},
|
|
#{consumerId,jdbcType=INTEGER},
|
|
</if>
|
|
</if>
|
|
@@ -313,6 +326,9 @@
|
|
<if test="orderType != null">
|
|
<if test="orderType != null">
|
|
#{orderType,jdbcType=CHAR},
|
|
#{orderType,jdbcType=CHAR},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="stationName != null">
|
|
|
|
+ #{stationName,jdbcType=VARCHAR},
|
|
|
|
+ </if>
|
|
</trim>
|
|
</trim>
|
|
</insert>
|
|
</insert>
|
|
<select id="countByExample" parameterType="com.platform.yijia.pojo.PayOrderExample" resultType="java.lang.Long">
|
|
<select id="countByExample" parameterType="com.platform.yijia.pojo.PayOrderExample" resultType="java.lang.Long">
|
|
@@ -344,6 +360,9 @@
|
|
<if test="record.oilName != null">
|
|
<if test="record.oilName != null">
|
|
oil_name = #{record.oilName,jdbcType=VARCHAR},
|
|
oil_name = #{record.oilName,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="record.oilPirce != null">
|
|
|
|
+ oil_pirce = #{record.oilPirce,jdbcType=VARCHAR},
|
|
|
|
+ </if>
|
|
<if test="record.consumerId != null">
|
|
<if test="record.consumerId != null">
|
|
consumer_id = #{record.consumerId,jdbcType=INTEGER},
|
|
consumer_id = #{record.consumerId,jdbcType=INTEGER},
|
|
</if>
|
|
</if>
|
|
@@ -380,6 +399,9 @@
|
|
<if test="record.orderType != null">
|
|
<if test="record.orderType != null">
|
|
order_type = #{record.orderType,jdbcType=CHAR},
|
|
order_type = #{record.orderType,jdbcType=CHAR},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="record.stationName != null">
|
|
|
|
+ station_name = #{record.stationName,jdbcType=VARCHAR},
|
|
|
|
+ </if>
|
|
</set>
|
|
</set>
|
|
<if test="_parameter != null">
|
|
<if test="_parameter != null">
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
@@ -395,6 +417,7 @@
|
|
order_no = #{record.orderNo,jdbcType=VARCHAR},
|
|
order_no = #{record.orderNo,jdbcType=VARCHAR},
|
|
oil_gun = #{record.oilGun,jdbcType=VARCHAR},
|
|
oil_gun = #{record.oilGun,jdbcType=VARCHAR},
|
|
oil_name = #{record.oilName,jdbcType=VARCHAR},
|
|
oil_name = #{record.oilName,jdbcType=VARCHAR},
|
|
|
|
+ oil_pirce = #{record.oilPirce,jdbcType=VARCHAR},
|
|
consumer_id = #{record.consumerId,jdbcType=INTEGER},
|
|
consumer_id = #{record.consumerId,jdbcType=INTEGER},
|
|
consumer = #{record.consumer,jdbcType=VARCHAR},
|
|
consumer = #{record.consumer,jdbcType=VARCHAR},
|
|
amt = #{record.amt,jdbcType=VARCHAR},
|
|
amt = #{record.amt,jdbcType=VARCHAR},
|
|
@@ -406,7 +429,8 @@
|
|
pay_date = #{record.payDate,jdbcType=TIMESTAMP},
|
|
pay_date = #{record.payDate,jdbcType=TIMESTAMP},
|
|
oil_personnel = #{record.oilPersonnel,jdbcType=VARCHAR},
|
|
oil_personnel = #{record.oilPersonnel,jdbcType=VARCHAR},
|
|
created_date = #{record.createdDate,jdbcType=TIMESTAMP},
|
|
created_date = #{record.createdDate,jdbcType=TIMESTAMP},
|
|
- order_type = #{record.orderType,jdbcType=CHAR}
|
|
|
|
|
|
+ order_type = #{record.orderType,jdbcType=CHAR},
|
|
|
|
+ station_name = #{record.stationName,jdbcType=VARCHAR}
|
|
<if test="_parameter != null">
|
|
<if test="_parameter != null">
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
</if>
|
|
</if>
|
|
@@ -427,6 +451,9 @@
|
|
<if test="oilName != null">
|
|
<if test="oilName != null">
|
|
oil_name = #{oilName,jdbcType=VARCHAR},
|
|
oil_name = #{oilName,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="oilPirce != null">
|
|
|
|
+ oil_pirce = #{oilPirce,jdbcType=VARCHAR},
|
|
|
|
+ </if>
|
|
<if test="consumerId != null">
|
|
<if test="consumerId != null">
|
|
consumer_id = #{consumerId,jdbcType=INTEGER},
|
|
consumer_id = #{consumerId,jdbcType=INTEGER},
|
|
</if>
|
|
</if>
|
|
@@ -463,6 +490,9 @@
|
|
<if test="orderType != null">
|
|
<if test="orderType != null">
|
|
order_type = #{orderType,jdbcType=CHAR},
|
|
order_type = #{orderType,jdbcType=CHAR},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="stationName != null">
|
|
|
|
+ station_name = #{stationName,jdbcType=CHAR},
|
|
|
|
+ </if>
|
|
</set>
|
|
</set>
|
|
where order_id = #{orderId,jdbcType=INTEGER}
|
|
where order_id = #{orderId,jdbcType=INTEGER}
|
|
</update>
|
|
</update>
|
|
@@ -475,6 +505,7 @@
|
|
set order_no = #{orderNo,jdbcType=VARCHAR},
|
|
set order_no = #{orderNo,jdbcType=VARCHAR},
|
|
oil_gun = #{oilGun,jdbcType=VARCHAR},
|
|
oil_gun = #{oilGun,jdbcType=VARCHAR},
|
|
oil_name = #{oilName,jdbcType=VARCHAR},
|
|
oil_name = #{oilName,jdbcType=VARCHAR},
|
|
|
|
+ oil_pirce = #{oilPirce,jdbcType=VARCHAR},
|
|
consumer_id = #{consumerId,jdbcType=INTEGER},
|
|
consumer_id = #{consumerId,jdbcType=INTEGER},
|
|
consumer = #{consumer,jdbcType=VARCHAR},
|
|
consumer = #{consumer,jdbcType=VARCHAR},
|
|
amt = #{amt,jdbcType=VARCHAR},
|
|
amt = #{amt,jdbcType=VARCHAR},
|
|
@@ -487,6 +518,7 @@
|
|
oil_personnel = #{oilPersonnel,jdbcType=VARCHAR},
|
|
oil_personnel = #{oilPersonnel,jdbcType=VARCHAR},
|
|
created_date = #{createdDate,jdbcType=TIMESTAMP},
|
|
created_date = #{createdDate,jdbcType=TIMESTAMP},
|
|
order_type = #{orderType,jdbcType=CHAR}
|
|
order_type = #{orderType,jdbcType=CHAR}
|
|
|
|
+ station_name = #{stationName,jdbcType=VARCHAR},
|
|
where order_id = #{orderId,jdbcType=INTEGER}
|
|
where order_id = #{orderId,jdbcType=INTEGER}
|
|
</update>
|
|
</update>
|
|
-</mapper>
|
|
|
|
|
|
+</mapper>
|