更新清分历史订单字段更改

This commit is contained in:
panshuling321 2022-04-26 14:39:55 +08:00
parent 6c97020b06
commit 0243c7f7e5
5 changed files with 184 additions and 125 deletions

View File

@ -1037,7 +1037,7 @@ CREATE TABLE `xhpc_clearing_history_order`
`operator_id3rdpty_evcs` varchar(50) DEFAULT NULL COMMENT '流量方OperatorID',
`start_time` datetime DEFAULT NULL,
`end_time` datetime DEFAULT NULL COMMENT '结束时间',
`stop_reason_evcs` int(11) DEFAULT NULL,
`stop_reason_evcs` varchar(255) DEFAULT NULL,
`total_power` double(10, 4) DEFAULT NULL COMMENT '电量',
`user_name_evcs` varchar(100) DEFAULT NULL,
`phone` varchar(50) DEFAULT NULL,

View File

@ -220,7 +220,7 @@ public class XhpcClearingHistoryOrderDomain implements Serializable {
*/
private Date endTime;
private Integer stopReasonEvcs;
private String stopReasonEvcs;
/**
* 电量

View File

@ -45,7 +45,7 @@
<result column="operator_id3rdpty_evcs" jdbcType="VARCHAR" property="operatorId3rdptyEvcs"/>
<result column="start_time" jdbcType="TIMESTAMP" property="startTime"/>
<result column="end_time" jdbcType="TIMESTAMP" property="endTime"/>
<result column="stop_reason_evcs" jdbcType="INTEGER" property="stopReasonEvcs"/>
<result column="stop_reason_evcs" jdbcType="VARCHAR" property="stopReasonEvcs"/>
<result column="total_power" jdbcType="DOUBLE" property="totalPower"/>
<result column="user_name_evcs" jdbcType="VARCHAR" property="userNameEvcs"/>
<result column="phone" jdbcType="VARCHAR" property="phone"/>
@ -220,21 +220,21 @@
select
<include refid="Base_Column_List"/>
from xhpc_clearing_history_order
where clearing_order_id = #{clearingOrderId,jdbcType=BIGINT}
where clearing_order_id = #{clearingOrderId}
</select>
<update id="deleteLogicByPrimaryKey" parameterType="java.lang.Long">
update xhpc_clearing_history_order
set del_flag=2
where clearing_order_id = #{clearingOrderId,jdbcType=BIGINT}
where clearing_order_id = #{clearingOrderId}
</update>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete
from xhpc_clearing_history_order
where clearing_order_id = #{clearingOrderId,jdbcType=BIGINT}
where clearing_order_id = #{clearingOrderId}
</delete>
@ -261,42 +261,42 @@
operator_name, clearing_checkout_id, check_status)
values
<foreach collection="domainList" index="index" item="domain" separator=",">
(#{domain.clearingOrderId}, #{domain.chargingStationId,jdbcType=BIGINT}, #{domain.chargeOrderId,jdbcType=BIGINT},
#{domain.userId,jdbcType=BIGINT},
#{domain.terminalId,jdbcType=BIGINT}, #{domain.serialNumber,jdbcType=VARCHAR},
#{domain.internetSerialNumber,jdbcType=VARCHAR},
#{domain.powerPriceTotal,jdbcType=DECIMAL}, #{domain.servicePriceTotal,jdbcType=DECIMAL},
#{domain.totalPrice,jdbcType=DECIMAL},
#{domain.promotionDiscount,jdbcType=DECIMAL}, #{domain.actPrice,jdbcType=DECIMAL},
#{domain.actPowerPrice,jdbcType=DECIMAL},
#{domain.actServicePrice,jdbcType=DECIMAL}, #{domain.internetCommission,jdbcType=DECIMAL},
#{domain.internetSvcCommission,jdbcType=DECIMAL},
#{domain.platformCommission,jdbcType=DECIMAL}, #{domain.platformSvcCommisssion,jdbcType=DECIMAL},
#{domain.operationCommission,jdbcType=DECIMAL}, #{domain.operationSvcCommission,jdbcType=DECIMAL},
#{domain.startSoc,jdbcType=VARCHAR}, #{domain.endSoc,jdbcType=VARCHAR},
#{domain.reconciliationStatus,jdbcType=INTEGER},
#{domain.sortingStatus,jdbcType=INTEGER}, #{domain.type,jdbcType=TINYINT},
#{domain.status,jdbcType=INTEGER},
#{domain.delFlag,jdbcType=INTEGER}, #{domain.createTime,jdbcType=TIMESTAMP},
#{domain.createBy,jdbcType=VARCHAR},
#{domain.updateTime,jdbcType=TIMESTAMP}, #{domain.updateBy,jdbcType=VARCHAR},
#{domain.remark,jdbcType=VARCHAR},
#{domain.state,jdbcType=INTEGER}, #{domain.vinNormal,jdbcType=VARCHAR},
#{domain.searchValue,jdbcType=VARCHAR},
#{domain.operatorIdEvcs,jdbcType=VARCHAR}, #{domain.chargeModelEvcs,jdbcType=INTEGER},
#{domain.connectorPowerEvcs,jdbcType=DOUBLE},
#{domain.meterValueEndEvcs,jdbcType=DOUBLE}, #{domain.meterValueStartEvcs,jdbcType=DOUBLE},
#{domain.operatorId3rdptyEvcs,jdbcType=VARCHAR},
#{domain.startTime,jdbcType=TIMESTAMP}, #{domain.endTime,jdbcType=TIMESTAMP},
#{domain.stopReasonEvcs,jdbcType=INTEGER},
#{domain.totalPower,jdbcType=DOUBLE}, #{domain.userNameEvcs,jdbcType=VARCHAR},
#{domain.phone,jdbcType=VARCHAR},
#{domain.evcsOrderNo,jdbcType=VARCHAR}, #{domain.confirmResult,jdbcType=INTEGER},
#{domain.rateModelId,jdbcType=BIGINT},
#{domain.chargingMode,jdbcType=VARCHAR}, #{domain.internetDegreeCommission,jdbcType=DECIMAL},
#{domain.source,jdbcType=INTEGER}, #{domain.tenantId,jdbcType=VARCHAR},
#{domain.operatorId,jdbcType=BIGINT},
#{domain.operatorName,jdbcType=VARCHAR}, #{domain.clearingCheckoutId,jdbcType=BIGINT}, #{domain.checkStatus})
(#{domain.clearingOrderId}, #{domain.chargingStationId}, #{domain.chargeOrderId},
#{domain.userId},
#{domain.terminalId}, #{domain.serialNumber},
#{domain.internetSerialNumber},
#{domain.powerPriceTotal}, #{domain.servicePriceTotal},
#{domain.totalPrice},
#{domain.promotionDiscount}, #{domain.actPrice},
#{domain.actPowerPrice},
#{domain.actServicePrice}, #{domain.internetCommission},
#{domain.internetSvcCommission},
#{domain.platformCommission}, #{domain.platformSvcCommisssion},
#{domain.operationCommission}, #{domain.operationSvcCommission},
#{domain.startSoc}, #{domain.endSoc},
#{domain.reconciliationStatus},
#{domain.sortingStatus}, #{domain.type},
#{domain.status},
#{domain.delFlag}, #{domain.createTime},
#{domain.createBy},
#{domain.updateTime}, #{domain.updateBy},
#{domain.remark},
#{domain.state}, #{domain.vinNormal},
#{domain.searchValue},
#{domain.operatorIdEvcs}, #{domain.chargeModelEvcs},
#{domain.connectorPowerEvcs},
#{domain.meterValueEndEvcs}, #{domain.meterValueStartEvcs},
#{domain.operatorId3rdptyEvcs},
#{domain.startTime}, #{domain.endTime},
#{domain.stopReasonEvcs},
#{domain.totalPower}, #{domain.userNameEvcs},
#{domain.phone},
#{domain.evcsOrderNo}, #{domain.confirmResult},
#{domain.rateModelId},
#{domain.chargingMode}, #{domain.internetDegreeCommission},
#{domain.source}, #{domain.tenantId},
#{domain.operatorId},
#{domain.operatorName}, #{domain.clearingCheckoutId}, #{domain.checkStatus})
</foreach>
</insert>
@ -323,93 +323,93 @@
charging_mode, internet_degree_commission,
`source`, tenant_id, operator_id,
operator_name, clearing_checkout_id, check_status)
values (#{chargingStationId,jdbcType=BIGINT}, #{chargeOrderId,jdbcType=BIGINT}, #{userId,jdbcType=BIGINT},
#{terminalId,jdbcType=BIGINT}, #{serialNumber,jdbcType=VARCHAR},
#{internetSerialNumber,jdbcType=VARCHAR},
#{powerPriceTotal,jdbcType=DECIMAL}, #{servicePriceTotal,jdbcType=DECIMAL},
#{totalPrice,jdbcType=DECIMAL},
#{promotionDiscount,jdbcType=DECIMAL}, #{actPrice,jdbcType=DECIMAL}, #{actPowerPrice,jdbcType=DECIMAL},
#{actServicePrice,jdbcType=DECIMAL}, #{internetCommission,jdbcType=DECIMAL},
#{internetSvcCommission,jdbcType=DECIMAL},
#{platformCommission,jdbcType=DECIMAL}, #{platformSvcCommisssion,jdbcType=DECIMAL},
#{operationCommission,jdbcType=DECIMAL}, #{operationSvcCommission,jdbcType=DECIMAL},
#{startSoc,jdbcType=VARCHAR}, #{endSoc,jdbcType=VARCHAR}, #{reconciliationStatus,jdbcType=INTEGER},
#{sortingStatus,jdbcType=INTEGER}, #{type,jdbcType=TINYINT}, #{status,jdbcType=INTEGER},
#{delFlag,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, #{createBy,jdbcType=VARCHAR},
#{updateTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},
#{state,jdbcType=INTEGER}, #{vinNormal,jdbcType=VARCHAR}, #{searchValue,jdbcType=VARCHAR},
#{operatorIdEvcs,jdbcType=VARCHAR}, #{chargeModelEvcs,jdbcType=INTEGER},
#{connectorPowerEvcs,jdbcType=DOUBLE},
#{meterValueEndEvcs,jdbcType=DOUBLE}, #{meterValueStartEvcs,jdbcType=DOUBLE},
#{operatorId3rdptyEvcs,jdbcType=VARCHAR},
#{startTime,jdbcType=TIMESTAMP}, #{endTime,jdbcType=TIMESTAMP}, #{stopReasonEvcs,jdbcType=INTEGER},
#{totalPower,jdbcType=DOUBLE}, #{userNameEvcs,jdbcType=VARCHAR}, #{phone,jdbcType=VARCHAR},
#{evcsOrderNo,jdbcType=VARCHAR}, #{confirmResult,jdbcType=INTEGER}, #{rateModelId,jdbcType=BIGINT},
#{chargingMode,jdbcType=VARCHAR}, #{internetDegreeCommission,jdbcType=DECIMAL},
#{source,jdbcType=INTEGER}, #{tenantId,jdbcType=VARCHAR}, #{operatorId,jdbcType=BIGINT},
#{operatorName,jdbcType=VARCHAR}, #{clearingCheckoutId,jdbcType=BIGINT}, #{checkStatus})
values (#{chargingStationId}, #{chargeOrderId}, #{userId},
#{terminalId}, #{serialNumber},
#{internetSerialNumber},
#{powerPriceTotal}, #{servicePriceTotal},
#{totalPrice},
#{promotionDiscount}, #{actPrice}, #{actPowerPrice},
#{actServicePrice}, #{internetCommission},
#{internetSvcCommission},
#{platformCommission}, #{platformSvcCommisssion},
#{operationCommission}, #{operationSvcCommission},
#{startSoc}, #{endSoc}, #{reconciliationStatus},
#{sortingStatus}, #{type}, #{status},
#{delFlag}, #{createTime}, #{createBy},
#{updateTime}, #{updateBy}, #{remark},
#{state}, #{vinNormal}, #{searchValue},
#{operatorIdEvcs}, #{chargeModelEvcs},
#{connectorPowerEvcs},
#{meterValueEndEvcs}, #{meterValueStartEvcs},
#{operatorId3rdptyEvcs},
#{startTime}, #{endTime}, #{stopReasonEvcs},
#{totalPower}, #{userNameEvcs}, #{phone},
#{evcsOrderNo}, #{confirmResult}, #{rateModelId},
#{chargingMode}, #{internetDegreeCommission},
#{source}, #{tenantId}, #{operatorId},
#{operatorName}, #{clearingCheckoutId}, #{checkStatus})
</insert>
<update id="updateByPrimaryKey" parameterType="com.xhpc.activity.domain.XhpcClearingHistoryOrderDomain">
update xhpc_clearing_history_order
set charging_station_id = #{chargingStationId,jdbcType=BIGINT},
charge_order_id = #{chargeOrderId,jdbcType=BIGINT},
user_id = #{userId,jdbcType=BIGINT},
terminal_id = #{terminalId,jdbcType=BIGINT},
serial_number = #{serialNumber,jdbcType=VARCHAR},
internet_serial_number = #{internetSerialNumber,jdbcType=VARCHAR},
power_price_total = #{powerPriceTotal,jdbcType=DECIMAL},
service_price_total = #{servicePriceTotal,jdbcType=DECIMAL},
total_price = #{totalPrice,jdbcType=DECIMAL},
promotion_discount = #{promotionDiscount,jdbcType=DECIMAL},
act_price = #{actPrice,jdbcType=DECIMAL},
act_power_price = #{actPowerPrice,jdbcType=DECIMAL},
act_service_price = #{actServicePrice,jdbcType=DECIMAL},
internet_commission = #{internetCommission,jdbcType=DECIMAL},
internet_svc_commission = #{internetSvcCommission,jdbcType=DECIMAL},
platform_commission = #{platformCommission,jdbcType=DECIMAL},
platform_svc_commisssion = #{platformSvcCommisssion,jdbcType=DECIMAL},
operation_commission = #{operationCommission,jdbcType=DECIMAL},
operation_svc_commission = #{operationSvcCommission,jdbcType=DECIMAL},
start_soc = #{startSoc,jdbcType=VARCHAR},
end_soc = #{endSoc,jdbcType=VARCHAR},
reconciliation_status = #{reconciliationStatus,jdbcType=INTEGER},
sorting_status = #{sortingStatus,jdbcType=INTEGER},
`type` = #{type,jdbcType=TINYINT},
`status` = #{status,jdbcType=INTEGER},
del_flag = #{delFlag,jdbcType=INTEGER},
create_time = #{createTime,jdbcType=TIMESTAMP},
create_by = #{createBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
`state` = #{state,jdbcType=INTEGER},
vin_normal = #{vinNormal,jdbcType=VARCHAR},
search_value = #{searchValue,jdbcType=VARCHAR},
operator_id_evcs = #{operatorIdEvcs,jdbcType=VARCHAR},
charge_model_evcs = #{chargeModelEvcs,jdbcType=INTEGER},
connector_power_evcs = #{connectorPowerEvcs,jdbcType=DOUBLE},
meter_value_end_evcs = #{meterValueEndEvcs,jdbcType=DOUBLE},
meter_value_start_evcs = #{meterValueStartEvcs,jdbcType=DOUBLE},
operator_id3rdpty_evcs = #{operatorId3rdptyEvcs,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=TIMESTAMP},
end_time = #{endTime,jdbcType=TIMESTAMP},
stop_reason_evcs = #{stopReasonEvcs,jdbcType=INTEGER},
total_power = #{totalPower,jdbcType=DOUBLE},
user_name_evcs = #{userNameEvcs,jdbcType=VARCHAR},
phone = #{phone,jdbcType=VARCHAR},
evcs_order_no = #{evcsOrderNo,jdbcType=VARCHAR},
confirm_Result = #{confirmResult,jdbcType=INTEGER},
rate_model_id = #{rateModelId,jdbcType=BIGINT},
charging_mode = #{chargingMode,jdbcType=VARCHAR},
internet_degree_commission = #{internetDegreeCommission,jdbcType=DECIMAL},
`source` = #{source,jdbcType=INTEGER},
tenant_id = #{tenantId,jdbcType=VARCHAR},
operator_id = #{operatorId,jdbcType=BIGINT},
operator_name = #{operatorName,jdbcType=VARCHAR},
clearing_checkout_id = #{clearingCheckoutId,jdbcType=BIGINT}
where clearing_order_id = #{clearingOrderId,jdbcType=BIGINT}
set charging_station_id = #{chargingStationId},
charge_order_id = #{chargeOrderId},
user_id = #{userId},
terminal_id = #{terminalId},
serial_number = #{serialNumber},
internet_serial_number = #{internetSerialNumber},
power_price_total = #{powerPriceTotal},
service_price_total = #{servicePriceTotal},
total_price = #{totalPrice},
promotion_discount = #{promotionDiscount},
act_price = #{actPrice},
act_power_price = #{actPowerPrice},
act_service_price = #{actServicePrice},
internet_commission = #{internetCommission},
internet_svc_commission = #{internetSvcCommission},
platform_commission = #{platformCommission},
platform_svc_commisssion = #{platformSvcCommisssion},
operation_commission = #{operationCommission},
operation_svc_commission = #{operationSvcCommission},
start_soc = #{startSoc},
end_soc = #{endSoc},
reconciliation_status = #{reconciliationStatus},
sorting_status = #{sortingStatus},
`type` = #{type},
`status` = #{status},
del_flag = #{delFlag},
create_time = #{createTime},
create_by = #{createBy},
update_time = #{updateTime},
update_by = #{updateBy},
remark = #{remark},
`state` = #{state},
vin_normal = #{vinNormal},
search_value = #{searchValue},
operator_id_evcs = #{operatorIdEvcs},
charge_model_evcs = #{chargeModelEvcs},
connector_power_evcs = #{connectorPowerEvcs},
meter_value_end_evcs = #{meterValueEndEvcs},
meter_value_start_evcs = #{meterValueStartEvcs},
operator_id3rdpty_evcs = #{operatorId3rdptyEvcs},
start_time = #{startTime},
end_time = #{endTime},
stop_reason_evcs = #{stopReasonEvcs},
total_power = #{totalPower},
user_name_evcs = #{userNameEvcs},
phone = #{phone},
evcs_order_no = #{evcsOrderNo},
confirm_Result = #{confirmResult},
rate_model_id = #{rateModelId},
charging_mode = #{chargingMode},
internet_degree_commission = #{internetDegreeCommission},
`source` = #{source},
tenant_id = #{tenantId},
operator_id = #{operatorId},
operator_name = #{operatorName},
clearing_checkout_id = #{clearingCheckoutId}
where clearing_order_id = #{clearingOrderId}
</update>
<update id="updateCheckoutByOperator">
update xhpc_clearing_history_order set clearing_checkout_id=#{checkoutId}

View File

@ -48,7 +48,7 @@
<result column="operator_id3rdpty_evcs" jdbcType="VARCHAR" property="operatorId3rdptyEvcs" />
<result column="start_time" jdbcType="TIMESTAMP" property="startTime" />
<result column="end_time" jdbcType="TIMESTAMP" property="endTime" />
<result column="stop_reason_evcs" jdbcType="INTEGER" property="stopReasonEvcs" />
<result column="stop_reason_evcs" jdbcType="VARCHAR" property="stopReasonEvcs" />
<result column="total_power" jdbcType="DOUBLE" property="totalPower" />
<result column="user_name_evcs" jdbcType="VARCHAR" property="userNameEvcs" />
<result column="phone" jdbcType="VARCHAR" property="phone" />

View File

@ -0,0 +1,59 @@
<?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.activity.mapper.XhpcOperatorMapper">
<resultMap type="com.xhpc.activity.domain.XhpcOperatorDomain" id="BaseResultMap">
<result column="operator_id" property="operatorId"/>
<result column="name" property="name"/>
<result column="contact_name" property="contactName"/>
<result column="contact_phone" property="contactPhone"/>
<result column="phone" property="phone"/>
<result column="attribute" property="attribute"/>
<result column="duty_paragraph" property="dutyParagraph"/>
<result column="open_bank" property="openBank"/>
<result column="card_number" property="cardNumber"/>
<result column="area_code" property="areaCode"/>
<result column="address" property="address"/>
<result column="detailed_address" property="detailedAddress"/>
<result column="longitude" property="longitude"/>
<result column="latitude" property="latitude"/>
<result column="email" property="email"/>
<result column="commission_type" property="commissionType"/>
<result column="platform_commission_rate" property="platformCommissionRate"/>
<result column="maintenance_commission_rate" property="maintenanceCommissionRate"/>
<result column="business_license_id" property="businessLicenseId"/>
<result column="withdrawal_time" property="withdrawalTime"/>
<result column="soc" property="soc"/>
<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"/>
<result column="operator_id_evcs" property="operatorIdEvcs"/>
</resultMap>
<sql id="Base_Column_List">
operator_id, name, contact_name, contact_phone,
phone, attribute,open_bank,card_number, area_code, address,
detailed_address, duty_paragraph,
longitude, latitude, email, commission_type,
platform_commission_rate,
maintenance_commission_rate,
business_license_id, withdrawal_time, soc,
status, del_flag, create_time,
create_by, update_time, update_by, remark
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>
from xhpc_operator
where id = #{id}
</select>
</mapper>