This commit is contained in:
Lemon
2024-07-30 14:19:40 +08:00
44 changed files with 1065 additions and 271 deletions

View File

@@ -2950,8 +2950,8 @@
where t1.del_flag = '0'
and `t1`.`member_id` = #{memberId,jdbcType=VARCHAR}
and `t1`.`station_id` = #{stationId,jdbcType=VARCHAR}
and `t1`.`create_time` <![CDATA[ >= ]]> #{endTime,jdbcType=VARCHAR}
and `t1`.`update_time` <![CDATA[ <= ]]> #{startTime,jdbcType=VARCHAR}
and `t1`.`charge_start_time` <![CDATA[ <= ]]> #{endTime,jdbcType=VARCHAR}
and `t1`.`charge_end_time` <![CDATA[ >= ]]> #{startTime,jdbcType=VARCHAR}
</select>
<select id="getOrderDetailByStationIds" resultType="com.jsowell.pile.vo.BusinessOrderDetailInfoVO">

View File

@@ -10,6 +10,7 @@
<result column="pile_connector_code" jdbcType="VARCHAR" property="pileConnectorCode" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="reservation_type" jdbcType="VARCHAR" property="reservationType" />
<result column="verify_identity" jdbcType="VARCHAR" property="verifyIdentity" />
<result column="start_time" jdbcType="TIME" property="startTime" />
<result column="end_time" jdbcType="TIME" property="endTime" />
<result column="freq" jdbcType="VARCHAR" property="freq" />
@@ -21,8 +22,8 @@
</resultMap>
<sql id="Base_Column_List">
<!--@mbg.generated-->
id, member_id, pile_sn, pile_connector_code, `status`, reservation_type, start_time,
end_time, freq, create_by, create_time, update_by, update_time, del_flag
id, member_id, pile_sn, pile_connector_code, `status`, reservation_type, verify_identity,
start_time, end_time, freq, create_by, create_time, update_by, update_time, del_flag
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
<!--@mbg.generated-->
@@ -38,16 +39,16 @@
</delete>
<insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.jsowell.pile.domain.PileReservationInfo" useGeneratedKeys="true">
<!--@mbg.generated-->
insert into pile_reservation_info (member_id, pile_sn, pile_connector_code,
`status`, reservation_type, start_time,
end_time, freq, create_by,
create_time, update_by, update_time,
del_flag)
values (#{memberId,jdbcType=VARCHAR}, #{pileSn,jdbcType=VARCHAR}, #{pileConnectorCode,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR}, #{reservationType,jdbcType=VARCHAR}, #{startTime,jdbcType=TIME},
#{endTime,jdbcType=TIME}, #{freq,jdbcType=VARCHAR}, #{createBy,jdbcType=VARCHAR},
#{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP},
#{delFlag,jdbcType=CHAR})
insert into pile_reservation_info (member_id, pile_sn, pile_connector_code,
`status`, reservation_type, verify_identity,
start_time, end_time, freq,
create_by, create_time, update_by,
update_time, del_flag)
values (#{memberId,jdbcType=VARCHAR}, #{pileSn,jdbcType=VARCHAR}, #{pileConnectorCode,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR}, #{reservationType,jdbcType=VARCHAR}, #{verifyIdentity,jdbcType=VARCHAR},
#{startTime,jdbcType=TIME}, #{endTime,jdbcType=TIME}, #{freq,jdbcType=VARCHAR},
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR},
#{updateTime,jdbcType=TIMESTAMP}, #{delFlag,jdbcType=CHAR})
</insert>
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.jsowell.pile.domain.PileReservationInfo" useGeneratedKeys="true">
<!--@mbg.generated-->
@@ -68,6 +69,9 @@
<if test="reservationType != null">
reservation_type,
</if>
<if test="verifyIdentity != null">
verify_identity,
</if>
<if test="startTime != null">
start_time,
</if>
@@ -109,6 +113,9 @@
<if test="reservationType != null">
#{reservationType,jdbcType=VARCHAR},
</if>
<if test="verifyIdentity != null">
#{verifyIdentity,jdbcType=VARCHAR},
</if>
<if test="startTime != null">
#{startTime,jdbcType=TIME},
</if>
@@ -154,6 +161,9 @@
<if test="reservationType != null">
reservation_type = #{reservationType,jdbcType=VARCHAR},
</if>
<if test="verifyIdentity != null">
verify_identity = #{verifyIdentity,jdbcType=VARCHAR},
</if>
<if test="startTime != null">
start_time = #{startTime,jdbcType=TIME},
</if>
@@ -185,18 +195,19 @@
<!--@mbg.generated-->
update pile_reservation_info
set member_id = #{memberId,jdbcType=VARCHAR},
pile_sn = #{pileSn,jdbcType=VARCHAR},
pile_connector_code = #{pileConnectorCode,jdbcType=VARCHAR},
`status` = #{status,jdbcType=VARCHAR},
reservation_type = #{reservationType,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=TIME},
end_time = #{endTime,jdbcType=TIME},
freq = #{freq,jdbcType=VARCHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
del_flag = #{delFlag,jdbcType=CHAR}
pile_sn = #{pileSn,jdbcType=VARCHAR},
pile_connector_code = #{pileConnectorCode,jdbcType=VARCHAR},
`status` = #{status,jdbcType=VARCHAR},
reservation_type = #{reservationType,jdbcType=VARCHAR},
verify_identity = #{verifyIdentity,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=TIME},
end_time = #{endTime,jdbcType=TIME},
freq = #{freq,jdbcType=VARCHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
del_flag = #{delFlag,jdbcType=CHAR}
where id = #{id,jdbcType=INTEGER}
</update>
<update id="updateBatch" parameterType="java.util.List">
@@ -228,6 +239,11 @@
when id = #{item.id,jdbcType=INTEGER} then #{item.reservationType,jdbcType=VARCHAR}
</foreach>
</trim>
<trim prefix="verify_identity = case" suffix="end,">
<foreach collection="list" index="index" item="item">
when id = #{item.id,jdbcType=INTEGER} then #{item.verifyIdentity,jdbcType=VARCHAR}
</foreach>
</trim>
<trim prefix="start_time = case" suffix="end,">
<foreach collection="list" index="index" item="item">
when id = #{item.id,jdbcType=INTEGER} then #{item.startTime,jdbcType=TIME}
@@ -313,6 +329,13 @@
</if>
</foreach>
</trim>
<trim prefix="verify_identity = case" suffix="end,">
<foreach collection="list" index="index" item="item">
<if test="item.verifyIdentity != null">
when id = #{item.id,jdbcType=INTEGER} then #{item.verifyIdentity,jdbcType=VARCHAR}
</if>
</foreach>
</trim>
<trim prefix="start_time = case" suffix="end,">
<foreach collection="list" index="index" item="item">
<if test="item.startTime != null">
@@ -378,15 +401,16 @@
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
<!--@mbg.generated-->
insert into pile_reservation_info
(member_id, pile_sn, pile_connector_code, `status`, reservation_type, start_time, end_time,
freq, create_by, create_time, update_by, update_time, del_flag)
(member_id, pile_sn, pile_connector_code, `status`, reservation_type, verify_identity,
start_time, end_time, freq, create_by, create_time, update_by, update_time, del_flag
)
values
<foreach collection="list" item="item" separator=",">
(#{item.memberId,jdbcType=VARCHAR}, #{item.pileSn,jdbcType=VARCHAR}, #{item.pileConnectorCode,jdbcType=VARCHAR},
#{item.status,jdbcType=VARCHAR}, #{item.reservationType,jdbcType=VARCHAR}, #{item.startTime,jdbcType=TIME},
#{item.endTime,jdbcType=TIME}, #{item.freq,jdbcType=VARCHAR}, #{item.createBy,jdbcType=VARCHAR},
#{item.createTime,jdbcType=TIMESTAMP}, #{item.updateBy,jdbcType=VARCHAR}, #{item.updateTime,jdbcType=TIMESTAMP},
#{item.delFlag,jdbcType=CHAR})
(#{item.memberId,jdbcType=VARCHAR}, #{item.pileSn,jdbcType=VARCHAR}, #{item.pileConnectorCode,jdbcType=VARCHAR},
#{item.status,jdbcType=VARCHAR}, #{item.reservationType,jdbcType=VARCHAR}, #{item.verifyIdentity,jdbcType=VARCHAR},
#{item.startTime,jdbcType=TIME}, #{item.endTime,jdbcType=TIME}, #{item.freq,jdbcType=VARCHAR},
#{item.createBy,jdbcType=VARCHAR}, #{item.createTime,jdbcType=TIMESTAMP}, #{item.updateBy,jdbcType=VARCHAR},
#{item.updateTime,jdbcType=TIMESTAMP}, #{item.delFlag,jdbcType=CHAR})
</foreach>
</insert>
<insert id="insertOrUpdate" keyColumn="id" keyProperty="id" parameterType="com.jsowell.pile.domain.PileReservationInfo" useGeneratedKeys="true">
@@ -401,6 +425,7 @@
pile_connector_code,
`status`,
reservation_type,
verify_identity,
start_time,
end_time,
freq,
@@ -420,6 +445,7 @@
#{pileConnectorCode,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR},
#{reservationType,jdbcType=VARCHAR},
#{verifyIdentity,jdbcType=VARCHAR},
#{startTime,jdbcType=TIME},
#{endTime,jdbcType=TIME},
#{freq,jdbcType=VARCHAR},
@@ -439,6 +465,7 @@
pile_connector_code = #{pileConnectorCode,jdbcType=VARCHAR},
`status` = #{status,jdbcType=VARCHAR},
reservation_type = #{reservationType,jdbcType=VARCHAR},
verify_identity = #{verifyIdentity,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=TIME},
end_time = #{endTime,jdbcType=TIME},
freq = #{freq,jdbcType=VARCHAR},
@@ -471,6 +498,9 @@
<if test="reservationType != null">
reservation_type,
</if>
<if test="verifyIdentity != null">
verify_identity,
</if>
<if test="startTime != null">
start_time,
</if>
@@ -516,6 +546,9 @@
<if test="reservationType != null">
#{reservationType,jdbcType=VARCHAR},
</if>
<if test="verifyIdentity != null">
#{verifyIdentity,jdbcType=VARCHAR},
</if>
<if test="startTime != null">
#{startTime,jdbcType=TIME},
</if>
@@ -561,6 +594,9 @@
<if test="reservationType != null">
reservation_type = #{reservationType,jdbcType=VARCHAR},
</if>
<if test="verifyIdentity != null">
verify_identity = #{verifyIdentity,jdbcType=VARCHAR},
</if>
<if test="startTime != null">
start_time = #{startTime,jdbcType=TIME},
</if>
@@ -616,4 +652,12 @@
and status = '1'
and pile_connector_code = #{pileConnectorCode,jdbcType=VARCHAR}
</select>
<select id="selectByPileConnectorCode" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from pile_reservation_info
where del_flag = '0'
and pile_connector_code = #{pileConnectorCode,jdbcType=VARCHAR}
</select>
</mapper>