2021-07-22 19:03:27 +08:00
|
|
|
<?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.xhpc.payment.mapper.XhpcRechargeOrderMapper">
|
|
|
|
|
|
|
|
|
|
<resultMap type="com.xhpc.payment.domain.XhpcRechargeOrder" id="XhpcRechargeOrderResult">
|
|
|
|
|
<result column="recharge_order_id" property="rechargeOrderId" />
|
|
|
|
|
<result column="user_id" property="userId" />
|
|
|
|
|
<result column="prepay_id" property="prepayId" />
|
|
|
|
|
<result column="alipay_number" property="alipayNumber" />
|
|
|
|
|
<result column="amount" property="amount" />
|
|
|
|
|
<result column="type" property="type" />
|
|
|
|
|
<result column="status" property="status" />
|
|
|
|
|
<result column="del_flag" property="delFlag" />
|
|
|
|
|
<result column="create_time" property="createTime" />
|
|
|
|
|
<result column="create_by" property="createBy" />
|
|
|
|
|
<result column="update_time" property="updateTime" />
|
|
|
|
|
<result column="update_by" property="updateBy" />
|
|
|
|
|
<result column="remark" property="remark" />
|
|
|
|
|
</resultMap>
|
|
|
|
|
|
2021-07-23 18:55:28 +08:00
|
|
|
<insert id="insert" parameterType="com.xhpc.payment.domain.XhpcRechargeOrder">
|
2021-07-22 19:03:27 +08:00
|
|
|
INSERT INTO xhpc_recharge_order
|
|
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
|
<if test="null != rechargeOrderId and '' != rechargeOrderId">
|
|
|
|
|
recharge_order_id,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != userId and '' != userId">
|
|
|
|
|
user_id,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != prepayId and '' != prepayId">
|
|
|
|
|
prepay_id,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != alipayNumber and '' != alipayNumber">
|
|
|
|
|
alipay_number,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != amount and '' != amount">
|
|
|
|
|
amount,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != type and '' != type">
|
|
|
|
|
type,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != status and '' != status">
|
|
|
|
|
status,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != delFlag and '' != delFlag">
|
|
|
|
|
del_flag,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != createTime and '' != createTime">
|
|
|
|
|
create_time,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != createBy and '' != createBy">
|
|
|
|
|
create_by,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != updateTime and '' != updateTime">
|
|
|
|
|
update_time,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != updateBy and '' != updateBy">
|
|
|
|
|
update_by,
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != remark and '' != remark">
|
|
|
|
|
remark
|
|
|
|
|
</if>
|
|
|
|
|
</trim>
|
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
|
<if test="null != rechargeOrderId and '' != rechargeOrderId">
|
|
|
|
|
#{rechargeOrderId},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != userId and '' != userId">
|
|
|
|
|
#{userId},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != prepayId and '' != prepayId">
|
|
|
|
|
#{prepayId},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != alipayNumber and '' != alipayNumber">
|
|
|
|
|
#{alipayNumber},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != amount and '' != amount">
|
|
|
|
|
#{amount},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != type and '' != type">
|
|
|
|
|
#{type},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != status and '' != status">
|
|
|
|
|
#{status},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != delFlag and '' != delFlag">
|
|
|
|
|
#{delFlag},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != createTime and '' != createTime">
|
|
|
|
|
#{createTime},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != createBy and '' != createBy">
|
|
|
|
|
#{createBy},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != updateTime and '' != updateTime">
|
|
|
|
|
#{updateTime},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != updateBy and '' != updateBy">
|
|
|
|
|
#{updateBy},
|
|
|
|
|
</if>
|
|
|
|
|
<if test="null != remark and '' != remark">
|
|
|
|
|
#{remark}
|
|
|
|
|
</if>
|
|
|
|
|
</trim>
|
|
|
|
|
</insert>
|
|
|
|
|
|
2021-07-23 18:55:28 +08:00
|
|
|
<update id="update" parameterType="com.xhpc.payment.domain.XhpcRechargeOrder">
|
2021-07-22 19:03:27 +08:00
|
|
|
UPDATE xhpc_recharge_order
|
|
|
|
|
<set>
|
|
|
|
|
<if test="null != userId and '' != userId">user_id = #{userId},</if>
|
|
|
|
|
<if test="null != prepayId and '' != prepayId">prepay_id = #{prepayId},</if>
|
|
|
|
|
<if test="null != alipayNumber and '' != alipayNumber">alipay_number = #{alipayNumber},</if>
|
|
|
|
|
<if test="null != amount and '' != amount">amount = #{amount},</if>
|
|
|
|
|
<if test="null != type and '' != type">type = #{type},</if>
|
|
|
|
|
<if test="null != status and '' != status">status = #{status},</if>
|
|
|
|
|
<if test="null != delFlag and '' != delFlag">del_flag = #{delFlag},</if>
|
|
|
|
|
<if test="null != createTime and '' != createTime">create_time = #{createTime},</if>
|
|
|
|
|
<if test="null != createBy and '' != createBy">create_by = #{createBy},</if>
|
|
|
|
|
<if test="null != updateTime and '' != updateTime">update_time = #{updateTime},</if>
|
|
|
|
|
<if test="null != updateBy and '' != updateBy">update_by = #{updateBy},</if>
|
|
|
|
|
<if test="null != remark and '' != remark">remark = #{remark}</if>
|
|
|
|
|
</set>
|
|
|
|
|
WHERE recharge_order_id = #{rechargeOrderId}
|
|
|
|
|
</update>
|
|
|
|
|
|
|
|
|
|
<select id="info" parameterType="java.lang.Long" resultType="java.util.Map">
|
|
|
|
|
select *
|
|
|
|
|
from xhpc_recharge_order
|
|
|
|
|
WHERE del_flag = 0 and recharge_order_id = #{rechargeOrderId}
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
</mapper>
|