mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-07-10 08:58:02 +08:00
订单分账记录表 加字段
This commit is contained in:
@@ -1,7 +1,5 @@
|
|||||||
package com.jsowell.pile.domain;
|
package com.jsowell.pile.domain;
|
||||||
|
|
||||||
import java.math.BigDecimal;
|
|
||||||
import java.util.Date;
|
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Builder;
|
import lombok.Builder;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
@@ -9,6 +7,9 @@ import lombok.NoArgsConstructor;
|
|||||||
import lombok.experimental.Accessors;
|
import lombok.experimental.Accessors;
|
||||||
import lombok.experimental.SuperBuilder;
|
import lombok.experimental.SuperBuilder;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 订单分账记录表
|
* 订单分账记录表
|
||||||
*/
|
*/
|
||||||
@@ -39,6 +40,21 @@ public class OrderSplitRecord {
|
|||||||
*/
|
*/
|
||||||
private BigDecimal settleAmount;
|
private BigDecimal settleAmount;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 订单电费金额
|
||||||
|
*/
|
||||||
|
private BigDecimal electricityAmount;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 订单服务费金额
|
||||||
|
*/
|
||||||
|
private BigDecimal serviceAmount;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 交易日期 yyyy-MM-dd
|
||||||
|
*/
|
||||||
|
private String tradeDate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 汇付用户id
|
* 汇付用户id
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
package com.jsowell.pile.mapper;
|
package com.jsowell.pile.mapper;
|
||||||
|
|
||||||
import com.jsowell.pile.domain.OrderSplitRecord;
|
import com.jsowell.pile.domain.OrderSplitRecord;
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
public interface OrderSplitRecordMapper {
|
public interface OrderSplitRecordMapper {
|
||||||
int deleteByPrimaryKey(Integer id);
|
int deleteByPrimaryKey(Integer id);
|
||||||
|
|
||||||
|
|||||||
@@ -8,6 +8,9 @@
|
|||||||
<result column="order_code" jdbcType="VARCHAR" property="orderCode" />
|
<result column="order_code" jdbcType="VARCHAR" property="orderCode" />
|
||||||
<result column="status" jdbcType="VARCHAR" property="status" />
|
<result column="status" jdbcType="VARCHAR" property="status" />
|
||||||
<result column="settle_amount" jdbcType="DECIMAL" property="settleAmount" />
|
<result column="settle_amount" jdbcType="DECIMAL" property="settleAmount" />
|
||||||
|
<result column="electricity_amount" jdbcType="DECIMAL" property="electricityAmount" />
|
||||||
|
<result column="service_amount" jdbcType="DECIMAL" property="serviceAmount" />
|
||||||
|
<result column="trade_date" jdbcType="VARCHAR" property="tradeDate" />
|
||||||
<result column="adapay_member_id" jdbcType="VARCHAR" property="adapayMemberId" />
|
<result column="adapay_member_id" jdbcType="VARCHAR" property="adapayMemberId" />
|
||||||
<result column="payment_id" jdbcType="VARCHAR" property="paymentId" />
|
<result column="payment_id" jdbcType="VARCHAR" property="paymentId" />
|
||||||
<result column="payment_confirm_id" jdbcType="VARCHAR" property="paymentConfirmId" />
|
<result column="payment_confirm_id" jdbcType="VARCHAR" property="paymentConfirmId" />
|
||||||
@@ -24,9 +27,10 @@
|
|||||||
</resultMap>
|
</resultMap>
|
||||||
<sql id="Base_Column_List">
|
<sql id="Base_Column_List">
|
||||||
<!--@mbg.generated-->
|
<!--@mbg.generated-->
|
||||||
id, order_code, `status`, settle_amount, adapay_member_id, payment_id, payment_confirm_id,
|
id, order_code, `status`, settle_amount, electricity_amount, service_amount, trade_date,
|
||||||
electricity_split_ratio, electricity_split_amount, service_split_ratio, service_split_amount,
|
adapay_member_id, payment_id, payment_confirm_id, electricity_split_ratio, electricity_split_amount,
|
||||||
remark, create_by, create_time, update_by, update_time, del_flag
|
service_split_ratio, service_split_amount, remark, create_by, create_time, update_by,
|
||||||
|
update_time, del_flag
|
||||||
</sql>
|
</sql>
|
||||||
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
||||||
<!--@mbg.generated-->
|
<!--@mbg.generated-->
|
||||||
@@ -53,6 +57,15 @@
|
|||||||
<if test="settleAmount != null">
|
<if test="settleAmount != null">
|
||||||
settle_amount,
|
settle_amount,
|
||||||
</if>
|
</if>
|
||||||
|
<if test="electricityAmount != null">
|
||||||
|
electricity_amount,
|
||||||
|
</if>
|
||||||
|
<if test="serviceAmount != null">
|
||||||
|
service_amount,
|
||||||
|
</if>
|
||||||
|
<if test="tradeDate != null">
|
||||||
|
trade_date,
|
||||||
|
</if>
|
||||||
<if test="adapayMemberId != null">
|
<if test="adapayMemberId != null">
|
||||||
adapay_member_id,
|
adapay_member_id,
|
||||||
</if>
|
</if>
|
||||||
@@ -103,6 +116,15 @@
|
|||||||
<if test="settleAmount != null">
|
<if test="settleAmount != null">
|
||||||
#{settleAmount,jdbcType=DECIMAL},
|
#{settleAmount,jdbcType=DECIMAL},
|
||||||
</if>
|
</if>
|
||||||
|
<if test="electricityAmount != null">
|
||||||
|
#{electricityAmount,jdbcType=DECIMAL},
|
||||||
|
</if>
|
||||||
|
<if test="serviceAmount != null">
|
||||||
|
#{serviceAmount,jdbcType=DECIMAL},
|
||||||
|
</if>
|
||||||
|
<if test="tradeDate != null">
|
||||||
|
#{tradeDate,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
<if test="adapayMemberId != null">
|
<if test="adapayMemberId != null">
|
||||||
#{adapayMemberId,jdbcType=VARCHAR},
|
#{adapayMemberId,jdbcType=VARCHAR},
|
||||||
</if>
|
</if>
|
||||||
@@ -157,6 +179,15 @@
|
|||||||
<if test="settleAmount != null">
|
<if test="settleAmount != null">
|
||||||
settle_amount = #{settleAmount,jdbcType=DECIMAL},
|
settle_amount = #{settleAmount,jdbcType=DECIMAL},
|
||||||
</if>
|
</if>
|
||||||
|
<if test="electricityAmount != null">
|
||||||
|
electricity_amount = #{electricityAmount,jdbcType=DECIMAL},
|
||||||
|
</if>
|
||||||
|
<if test="serviceAmount != null">
|
||||||
|
service_amount = #{serviceAmount,jdbcType=DECIMAL},
|
||||||
|
</if>
|
||||||
|
<if test="tradeDate != null">
|
||||||
|
trade_date = #{tradeDate,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
<if test="adapayMemberId != null">
|
<if test="adapayMemberId != null">
|
||||||
adapay_member_id = #{adapayMemberId,jdbcType=VARCHAR},
|
adapay_member_id = #{adapayMemberId,jdbcType=VARCHAR},
|
||||||
</if>
|
</if>
|
||||||
@@ -224,6 +255,27 @@
|
|||||||
</if>
|
</if>
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</trim>
|
||||||
|
<trim prefix="electricity_amount = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
<if test="item.electricityAmount != null">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.electricityAmount,jdbcType=DECIMAL}
|
||||||
|
</if>
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="service_amount = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
<if test="item.serviceAmount != null">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.serviceAmount,jdbcType=DECIMAL}
|
||||||
|
</if>
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="trade_date = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
<if test="item.tradeDate != null">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.tradeDate,jdbcType=VARCHAR}
|
||||||
|
</if>
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
<trim prefix="adapay_member_id = case" suffix="end,">
|
<trim prefix="adapay_member_id = case" suffix="end,">
|
||||||
<foreach collection="list" index="index" item="item">
|
<foreach collection="list" index="index" item="item">
|
||||||
<if test="item.adapayMemberId != null">
|
<if test="item.adapayMemberId != null">
|
||||||
@@ -324,18 +376,20 @@
|
|||||||
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
|
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
|
||||||
<!--@mbg.generated-->
|
<!--@mbg.generated-->
|
||||||
insert into order_split_record
|
insert into order_split_record
|
||||||
(order_code, `status`, settle_amount, adapay_member_id, payment_id, payment_confirm_id,
|
(order_code, `status`, settle_amount, electricity_amount, service_amount, trade_date,
|
||||||
electricity_split_ratio, electricity_split_amount, service_split_ratio, service_split_amount,
|
adapay_member_id, payment_id, payment_confirm_id, electricity_split_ratio, electricity_split_amount,
|
||||||
remark, create_by, create_time, update_by, update_time, del_flag)
|
service_split_ratio, service_split_amount, remark, create_by, create_time, update_by,
|
||||||
|
update_time, del_flag)
|
||||||
values
|
values
|
||||||
<foreach collection="list" item="item" separator=",">
|
<foreach collection="list" item="item" separator=",">
|
||||||
(#{item.orderCode,jdbcType=VARCHAR}, #{item.status,jdbcType=VARCHAR}, #{item.settleAmount,jdbcType=DECIMAL},
|
(#{item.orderCode,jdbcType=VARCHAR}, #{item.status,jdbcType=VARCHAR}, #{item.settleAmount,jdbcType=DECIMAL},
|
||||||
#{item.adapayMemberId,jdbcType=VARCHAR}, #{item.paymentId,jdbcType=VARCHAR}, #{item.paymentConfirmId,jdbcType=VARCHAR},
|
#{item.electricityAmount,jdbcType=DECIMAL}, #{item.serviceAmount,jdbcType=DECIMAL},
|
||||||
#{item.electricitySplitRatio,jdbcType=DECIMAL}, #{item.electricitySplitAmount,jdbcType=DECIMAL},
|
#{item.tradeDate,jdbcType=VARCHAR}, #{item.adapayMemberId,jdbcType=VARCHAR}, #{item.paymentId,jdbcType=VARCHAR},
|
||||||
#{item.serviceSplitRatio,jdbcType=DECIMAL}, #{item.serviceSplitAmount,jdbcType=DECIMAL},
|
#{item.paymentConfirmId,jdbcType=VARCHAR}, #{item.electricitySplitRatio,jdbcType=DECIMAL},
|
||||||
#{item.remark,jdbcType=VARCHAR}, #{item.createBy,jdbcType=VARCHAR}, #{item.createTime,jdbcType=TIMESTAMP},
|
#{item.electricitySplitAmount,jdbcType=DECIMAL}, #{item.serviceSplitRatio,jdbcType=DECIMAL},
|
||||||
#{item.updateBy,jdbcType=VARCHAR}, #{item.updateTime,jdbcType=TIMESTAMP}, #{item.delFlag,jdbcType=VARCHAR}
|
#{item.serviceSplitAmount,jdbcType=DECIMAL}, #{item.remark,jdbcType=VARCHAR}, #{item.createBy,jdbcType=VARCHAR},
|
||||||
)
|
#{item.createTime,jdbcType=TIMESTAMP}, #{item.updateBy,jdbcType=VARCHAR}, #{item.updateTime,jdbcType=TIMESTAMP},
|
||||||
|
#{item.delFlag,jdbcType=VARCHAR})
|
||||||
</foreach>
|
</foreach>
|
||||||
</insert>
|
</insert>
|
||||||
<insert id="insertOrUpdate" keyColumn="id" keyProperty="id" parameterType="com.jsowell.pile.domain.OrderSplitRecord" useGeneratedKeys="true">
|
<insert id="insertOrUpdate" keyColumn="id" keyProperty="id" parameterType="com.jsowell.pile.domain.OrderSplitRecord" useGeneratedKeys="true">
|
||||||
@@ -348,6 +402,9 @@
|
|||||||
order_code,
|
order_code,
|
||||||
`status`,
|
`status`,
|
||||||
settle_amount,
|
settle_amount,
|
||||||
|
electricity_amount,
|
||||||
|
service_amount,
|
||||||
|
trade_date,
|
||||||
adapay_member_id,
|
adapay_member_id,
|
||||||
payment_id,
|
payment_id,
|
||||||
payment_confirm_id,
|
payment_confirm_id,
|
||||||
@@ -370,6 +427,9 @@
|
|||||||
#{orderCode,jdbcType=VARCHAR},
|
#{orderCode,jdbcType=VARCHAR},
|
||||||
#{status,jdbcType=VARCHAR},
|
#{status,jdbcType=VARCHAR},
|
||||||
#{settleAmount,jdbcType=DECIMAL},
|
#{settleAmount,jdbcType=DECIMAL},
|
||||||
|
#{electricityAmount,jdbcType=DECIMAL},
|
||||||
|
#{serviceAmount,jdbcType=DECIMAL},
|
||||||
|
#{tradeDate,jdbcType=VARCHAR},
|
||||||
#{adapayMemberId,jdbcType=VARCHAR},
|
#{adapayMemberId,jdbcType=VARCHAR},
|
||||||
#{paymentId,jdbcType=VARCHAR},
|
#{paymentId,jdbcType=VARCHAR},
|
||||||
#{paymentConfirmId,jdbcType=VARCHAR},
|
#{paymentConfirmId,jdbcType=VARCHAR},
|
||||||
@@ -392,6 +452,9 @@
|
|||||||
order_code = #{orderCode,jdbcType=VARCHAR},
|
order_code = #{orderCode,jdbcType=VARCHAR},
|
||||||
`status` = #{status,jdbcType=VARCHAR},
|
`status` = #{status,jdbcType=VARCHAR},
|
||||||
settle_amount = #{settleAmount,jdbcType=DECIMAL},
|
settle_amount = #{settleAmount,jdbcType=DECIMAL},
|
||||||
|
electricity_amount = #{electricityAmount,jdbcType=DECIMAL},
|
||||||
|
service_amount = #{serviceAmount,jdbcType=DECIMAL},
|
||||||
|
trade_date = #{tradeDate,jdbcType=VARCHAR},
|
||||||
adapay_member_id = #{adapayMemberId,jdbcType=VARCHAR},
|
adapay_member_id = #{adapayMemberId,jdbcType=VARCHAR},
|
||||||
payment_id = #{paymentId,jdbcType=VARCHAR},
|
payment_id = #{paymentId,jdbcType=VARCHAR},
|
||||||
payment_confirm_id = #{paymentConfirmId,jdbcType=VARCHAR},
|
payment_confirm_id = #{paymentConfirmId,jdbcType=VARCHAR},
|
||||||
@@ -423,6 +486,15 @@
|
|||||||
<if test="settleAmount != null">
|
<if test="settleAmount != null">
|
||||||
settle_amount,
|
settle_amount,
|
||||||
</if>
|
</if>
|
||||||
|
<if test="electricityAmount != null">
|
||||||
|
electricity_amount,
|
||||||
|
</if>
|
||||||
|
<if test="serviceAmount != null">
|
||||||
|
service_amount,
|
||||||
|
</if>
|
||||||
|
<if test="tradeDate != null">
|
||||||
|
trade_date,
|
||||||
|
</if>
|
||||||
<if test="adapayMemberId != null">
|
<if test="adapayMemberId != null">
|
||||||
adapay_member_id,
|
adapay_member_id,
|
||||||
</if>
|
</if>
|
||||||
@@ -477,6 +549,15 @@
|
|||||||
<if test="settleAmount != null">
|
<if test="settleAmount != null">
|
||||||
#{settleAmount,jdbcType=DECIMAL},
|
#{settleAmount,jdbcType=DECIMAL},
|
||||||
</if>
|
</if>
|
||||||
|
<if test="electricityAmount != null">
|
||||||
|
#{electricityAmount,jdbcType=DECIMAL},
|
||||||
|
</if>
|
||||||
|
<if test="serviceAmount != null">
|
||||||
|
#{serviceAmount,jdbcType=DECIMAL},
|
||||||
|
</if>
|
||||||
|
<if test="tradeDate != null">
|
||||||
|
#{tradeDate,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
<if test="adapayMemberId != null">
|
<if test="adapayMemberId != null">
|
||||||
#{adapayMemberId,jdbcType=VARCHAR},
|
#{adapayMemberId,jdbcType=VARCHAR},
|
||||||
</if>
|
</if>
|
||||||
@@ -531,6 +612,15 @@
|
|||||||
<if test="settleAmount != null">
|
<if test="settleAmount != null">
|
||||||
settle_amount = #{settleAmount,jdbcType=DECIMAL},
|
settle_amount = #{settleAmount,jdbcType=DECIMAL},
|
||||||
</if>
|
</if>
|
||||||
|
<if test="electricityAmount != null">
|
||||||
|
electricity_amount = #{electricityAmount,jdbcType=DECIMAL},
|
||||||
|
</if>
|
||||||
|
<if test="serviceAmount != null">
|
||||||
|
service_amount = #{serviceAmount,jdbcType=DECIMAL},
|
||||||
|
</if>
|
||||||
|
<if test="tradeDate != null">
|
||||||
|
trade_date = #{tradeDate,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
<if test="adapayMemberId != null">
|
<if test="adapayMemberId != null">
|
||||||
adapay_member_id = #{adapayMemberId,jdbcType=VARCHAR},
|
adapay_member_id = #{adapayMemberId,jdbcType=VARCHAR},
|
||||||
</if>
|
</if>
|
||||||
|
|||||||
Reference in New Issue
Block a user