This commit is contained in:
lu7213 committed 2025-12-02 23:07:47 +08:00
1 parent 81eca8933a
commit 345f906c35
540 files changed
+494222 -90

No files matched your search

@@ -0,0 +1,101 @@
<?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.ruoyi.custom.mapper.CustomCallbackMapper">
<resultMap type="CustomCallback" id="CustomCallbackResult">
<result property="id" column="id" />
<result property="userId" column="user_id" />
<result property="customsCode" column="customs_code" />
<result property="declareOrderNo" column="declare_order_no" />
<result property="sessionId" column="session_id" />
<result property="serviceTime" column="service_time" />
<result property="status" column="status" />
<result property="addTime" column="add_time" />
<result property="postResult" column="post_result" />
<result property="sendNumber" column="send_number" />
<result property="sendTime" column="send_time" />
</resultMap>
<sql id="selectCustomCallbackVo">
select id, user_id, customs_code, declare_order_no, session_id, service_time, status, add_time, post_result, send_number, send_time from custom_callback
</sql>
<select id="selectCustomCallbackList" parameterType="CustomCallback" resultMap="CustomCallbackResult">
<include refid="selectCustomCallbackVo"/>
<where>
<if test="userId != null "> and user_id = #{userId}</if>
<if test="customsCode != null and customsCode != ''"> and customs_code = #{customsCode}</if>
<if test="declareOrderNo != null and declareOrderNo != ''"> and declare_order_no = #{declareOrderNo}</if>
<if test="sessionId != null and sessionId != ''"> and session_id = #{sessionId}</if>
<if test="serviceTime != null "> and service_time = #{serviceTime}</if>
<if test="status != null "> and status = #{status}</if>
<if test="addTime != null "> and add_time = #{addTime}</if>
<if test="postResult != null and postResult != ''"> and post_result = #{postResult}</if>
<if test="sendNumber != null "> and send_number = #{sendNumber}</if>
<if test="sendTime != null "> and send_time = #{sendTime}</if>
</where>
</select>
<select id="selectCustomCallbackById" parameterType="Long" resultMap="CustomCallbackResult">
<include refid="selectCustomCallbackVo"/>
where id = #{id}
</select>
<insert id="insertCustomCallback" parameterType="CustomCallback" useGeneratedKeys="true" keyProperty="id">
insert into custom_callback
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="userId != null">user_id,</if>
<if test="customsCode != null">customs_code,</if>
<if test="declareOrderNo != null">declare_order_no,</if>
<if test="sessionId != null">session_id,</if>
<if test="serviceTime != null">service_time,</if>
<if test="status != null">status,</if>
<if test="addTime != null">add_time,</if>
<if test="postResult != null">post_result,</if>
<if test="sendNumber != null">send_number,</if>
<if test="sendTime != null">send_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="userId != null">#{userId},</if>
<if test="customsCode != null">#{customsCode},</if>
<if test="declareOrderNo != null">#{declareOrderNo},</if>
<if test="sessionId != null">#{sessionId},</if>
<if test="serviceTime != null">#{serviceTime},</if>
<if test="status != null">#{status},</if>
<if test="addTime != null">#{addTime},</if>
<if test="postResult != null">#{postResult},</if>
<if test="sendNumber != null">#{sendNumber},</if>
<if test="sendTime != null">#{sendTime},</if>
</trim>
</insert>
<update id="updateCustomCallback" parameterType="CustomCallback">
update custom_callback
<trim prefix="SET" suffixOverrides=",">
<if test="userId != null">user_id = #{userId},</if>
<if test="customsCode != null">customs_code = #{customsCode},</if>
<if test="declareOrderNo != null">declare_order_no = #{declareOrderNo},</if>
<if test="sessionId != null">session_id = #{sessionId},</if>
<if test="serviceTime != null">service_time = #{serviceTime},</if>
<if test="status != null">status = #{status},</if>
<if test="addTime != null">add_time = #{addTime},</if>
<if test="postResult != null">post_result = #{postResult},</if>
<if test="sendNumber != null">send_number = #{sendNumber},</if>
<if test="sendTime != null">send_time = #{sendTime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomCallbackById" parameterType="Long">
delete from custom_callback where id = #{id}
</delete>
<delete id="deleteCustomCallbackByIds" parameterType="String">
delete from custom_callback where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,65 @@
<?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.ruoyi.custom.mapper.CustomCountryCodeMapper">
<resultMap type="CustomCountryCode" id="CustomCountryCodeResult">
<result property="id" column="id" />
<result property="code" column="code" />
<result property="name" column="name" />
<result property="remark" column="remark" />
</resultMap>
<sql id="selectCustomCountryCodeVo">
select id, code, name, remark from custom_country_code
</sql>
<select id="selectCustomCountryCodeList" parameterType="CustomCountryCode" resultMap="CustomCountryCodeResult">
<include refid="selectCustomCountryCodeVo"/>
<where>
<if test="code != null and code != ''"> and code = #{code}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
</where>
</select>
<select id="selectCustomCountryCodeById" parameterType="Long" resultMap="CustomCountryCodeResult">
<include refid="selectCustomCountryCodeVo"/>
where id = #{id}
</select>
<insert id="insertCustomCountryCode" parameterType="CustomCountryCode" useGeneratedKeys="true" keyProperty="id">
insert into custom_country_code
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="code != null and code != ''">code,</if>
<if test="name != null and name != ''">name,</if>
<if test="remark != null">remark,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="code != null and code != ''">#{code},</if>
<if test="name != null and name != ''">#{name},</if>
<if test="remark != null">#{remark},</if>
</trim>
</insert>
<update id="updateCustomCountryCode" parameterType="CustomCountryCode">
update custom_country_code
<trim prefix="SET" suffixOverrides=",">
<if test="code != null and code != ''">code = #{code},</if>
<if test="name != null and name != ''">name = #{name},</if>
<if test="remark != null">remark = #{remark},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomCountryCodeById" parameterType="Long">
delete from custom_country_code where id = #{id}
</delete>
<delete id="deleteCustomCountryCodeByIds" parameterType="String">
delete from custom_country_code where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,81 @@
<?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.ruoyi.custom.mapper.CustomDeclarePortMapper">
<resultMap type="CustomDeclarePort" id="CustomDeclarePortResult">
<result property="id" column="id" />
<result property="name" column="name" />
<result property="code" column="code" />
<result property="describe" column="describe" />
<result property="directlyName" column="directly_name" />
<result property="shortName" column="short_name" />
<result property="isUse" column="is_use" />
</resultMap>
<sql id="selectCustomDeclarePortVo">
select id, name, code, describe, directly_name, short_name, is_use from custom_declare_port
</sql>
<select id="selectCustomDeclarePortList" parameterType="CustomDeclarePort" resultMap="CustomDeclarePortResult">
<include refid="selectCustomDeclarePortVo"/>
<where>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="code != null and code != ''"> and code = #{code}</if>
<if test="describe != null and describe != ''"> and describe = #{describe}</if>
<if test="directlyName != null and directlyName != ''"> and directly_name like concat('%', #{directlyName}, '%')</if>
<if test="shortName != null and shortName != ''"> and short_name like concat('%', #{shortName}, '%')</if>
<if test="isUse != null "> and is_use = #{isUse}</if>
</where>
</select>
<select id="selectCustomDeclarePortById" parameterType="Long" resultMap="CustomDeclarePortResult">
<include refid="selectCustomDeclarePortVo"/>
where id = #{id}
</select>
<insert id="insertCustomDeclarePort" parameterType="CustomDeclarePort" useGeneratedKeys="true" keyProperty="id">
insert into custom_declare_port
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="name != null">name,</if>
<if test="code != null">code,</if>
<if test="describe != null">describe,</if>
<if test="directlyName != null">directly_name,</if>
<if test="shortName != null">short_name,</if>
<if test="isUse != null">is_use,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="name != null">#{name},</if>
<if test="code != null">#{code},</if>
<if test="describe != null">#{describe},</if>
<if test="directlyName != null">#{directlyName},</if>
<if test="shortName != null">#{shortName},</if>
<if test="isUse != null">#{isUse},</if>
</trim>
</insert>
<update id="updateCustomDeclarePort" parameterType="CustomDeclarePort">
update custom_declare_port
<trim prefix="SET" suffixOverrides=",">
<if test="name != null">name = #{name},</if>
<if test="code != null">code = #{code},</if>
<if test="describe != null">describe = #{describe},</if>
<if test="directlyName != null">directly_name = #{directlyName},</if>
<if test="shortName != null">short_name = #{shortName},</if>
<if test="isUse != null">is_use = #{isUse},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomDeclarePortById" parameterType="Long">
delete from custom_declare_port where id = #{id}
</delete>
<delete id="deleteCustomDeclarePortByIds" parameterType="String">
delete from custom_declare_port where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,130 @@
<?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.ruoyi.custom.mapper.CustomEnterpriseRecordMapper">
<resultMap type="CustomEnterpriseRecord" id="CustomEnterpriseRecordResult">
<result property="id" column="id" />
<result property="declarePortId" column="declare_port_id" />
<result property="userId" column="user_id" />
<result property="domainName" column="domain_name" />
<result property="enterpriseName" column="enterprise_name" />
<result property="platformShort" column="platform_short" />
<result property="businessShort" column="business_short" />
<result property="creditCode" column="credit_code" />
<result property="customsCode" column="customs_code" />
<result property="nationalCode" column="national_code" />
<result property="encryptUrl" column="encrypt_url" />
<result property="geCode" column="ge_code" />
<result property="messageCode" column="message_code" />
<result property="kjdsKey" column="kjds_key" />
<result property="ftpServerIp" column="ftp_server_ip" />
<result property="ftpPassword" column="ftp_password" />
<result property="remark" column="remark" />
</resultMap>
<sql id="selectCustomEnterpriseRecordVo">
select id, declare_port_id, user_id, domain_name, enterprise_name, platform_short, business_short, credit_code, customs_code, national_code, encrypt_url, ge_code, message_code, kjds_key, ftp_server_ip, ftp_password, remark from custom_enterprise_record
</sql>
<select id="selectCustomEnterpriseRecordList" parameterType="CustomEnterpriseRecord" resultMap="CustomEnterpriseRecordResult">
<include refid="selectCustomEnterpriseRecordVo"/>
<where>
<if test="declarePortId != null "> and declare_port_id = #{declarePortId}</if>
<if test="userId != null "> and user_id = #{userId}</if>
<if test="domainName != null and domainName != ''"> and domain_name like concat('%', #{domainName}, '%')</if>
<if test="enterpriseName != null and enterpriseName != ''"> and enterprise_name like concat('%', #{enterpriseName}, '%')</if>
<if test="platformShort != null and platformShort != ''"> and platform_short = #{platformShort}</if>
<if test="businessShort != null and businessShort != ''"> and business_short = #{businessShort}</if>
<if test="creditCode != null and creditCode != ''"> and credit_code = #{creditCode}</if>
<if test="customsCode != null and customsCode != ''"> and customs_code = #{customsCode}</if>
<if test="nationalCode != null and nationalCode != ''"> and national_code = #{nationalCode}</if>
<if test="encryptUrl != null and encryptUrl != ''"> and encrypt_url = #{encryptUrl}</if>
<if test="geCode != null and geCode != ''"> and ge_code = #{geCode}</if>
<if test="messageCode != null and messageCode != ''"> and message_code = #{messageCode}</if>
<if test="kjdsKey != null and kjdsKey != ''"> and kjds_key = #{kjdsKey}</if>
<if test="ftpServerIp != null and ftpServerIp != ''"> and ftp_server_ip = #{ftpServerIp}</if>
<if test="ftpPassword != null and ftpPassword != ''"> and ftp_password = #{ftpPassword}</if>
</where>
</select>
<select id="selectCustomEnterpriseRecordById" parameterType="Long" resultMap="CustomEnterpriseRecordResult">
<include refid="selectCustomEnterpriseRecordVo"/>
where id = #{id}
</select>
<insert id="insertCustomEnterpriseRecord" parameterType="CustomEnterpriseRecord" useGeneratedKeys="true" keyProperty="id">
insert into custom_enterprise_record
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="declarePortId != null">declare_port_id,</if>
<if test="userId != null">user_id,</if>
<if test="domainName != null">domain_name,</if>
<if test="enterpriseName != null">enterprise_name,</if>
<if test="platformShort != null">platform_short,</if>
<if test="businessShort != null">business_short,</if>
<if test="creditCode != null">credit_code,</if>
<if test="customsCode != null">customs_code,</if>
<if test="nationalCode != null">national_code,</if>
<if test="encryptUrl != null">encrypt_url,</if>
<if test="geCode != null">ge_code,</if>
<if test="messageCode != null">message_code,</if>
<if test="kjdsKey != null">kjds_key,</if>
<if test="ftpServerIp != null">ftp_server_ip,</if>
<if test="ftpPassword != null">ftp_password,</if>
<if test="remark != null">remark,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="declarePortId != null">#{declarePortId},</if>
<if test="userId != null">#{userId},</if>
<if test="domainName != null">#{domainName},</if>
<if test="enterpriseName != null">#{enterpriseName},</if>
<if test="platformShort != null">#{platformShort},</if>
<if test="businessShort != null">#{businessShort},</if>
<if test="creditCode != null">#{creditCode},</if>
<if test="customsCode != null">#{customsCode},</if>
<if test="nationalCode != null">#{nationalCode},</if>
<if test="encryptUrl != null">#{encryptUrl},</if>
<if test="geCode != null">#{geCode},</if>
<if test="messageCode != null">#{messageCode},</if>
<if test="kjdsKey != null">#{kjdsKey},</if>
<if test="ftpServerIp != null">#{ftpServerIp},</if>
<if test="ftpPassword != null">#{ftpPassword},</if>
<if test="remark != null">#{remark},</if>
</trim>
</insert>
<update id="updateCustomEnterpriseRecord" parameterType="CustomEnterpriseRecord">
update custom_enterprise_record
<trim prefix="SET" suffixOverrides=",">
<if test="declarePortId != null">declare_port_id = #{declarePortId},</if>
<if test="userId != null">user_id = #{userId},</if>
<if test="domainName != null">domain_name = #{domainName},</if>
<if test="enterpriseName != null">enterprise_name = #{enterpriseName},</if>
<if test="platformShort != null">platform_short = #{platformShort},</if>
<if test="businessShort != null">business_short = #{businessShort},</if>
<if test="creditCode != null">credit_code = #{creditCode},</if>
<if test="customsCode != null">customs_code = #{customsCode},</if>
<if test="nationalCode != null">national_code = #{nationalCode},</if>
<if test="encryptUrl != null">encrypt_url = #{encryptUrl},</if>
<if test="geCode != null">ge_code = #{geCode},</if>
<if test="messageCode != null">message_code = #{messageCode},</if>
<if test="kjdsKey != null">kjds_key = #{kjdsKey},</if>
<if test="ftpServerIp != null">ftp_server_ip = #{ftpServerIp},</if>
<if test="ftpPassword != null">ftp_password = #{ftpPassword},</if>
<if test="remark != null">remark = #{remark},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomEnterpriseRecordById" parameterType="Long">
delete from custom_enterprise_record where id = #{id}
</delete>
<delete id="deleteCustomEnterpriseRecordByIds" parameterType="String">
delete from custom_enterprise_record where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,185 @@
<?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.ruoyi.custom.mapper.CustomFlightInfoMapper">
<resultMap type="CustomFlightInfo" id="CustomFlightInfoResult">
<result property="id" column="id" />
<result property="userId" column="user_id" />
<result property="warehouseId" column="warehouse_id" />
<result property="declarePortId" column="declare_port_id" />
<result property="mode" column="mode" />
<result property="batchNumber" column="batch_number" />
<result property="deliveryNumber" column="delivery_number" />
<result property="trafMode" column="traf_mode" />
<result property="airline" column="airline" />
<result property="departureCountry" column="departure_country" />
<result property="departureCity" column="departure_city" />
<result property="departureAirport" column="departure_airport" />
<result property="transitAirport" column="transit_airport" />
<result property="arriveAirport" column="arrive_airport" />
<result property="flightNumber" column="flight_number" />
<result property="isDirectFlight" column="is_direct_flight" />
<result property="isOurBooking" column="is_our_booking" />
<result property="departureLocalTime" column="departure_local_time" />
<result property="departureTime" column="departure_time" />
<result property="arriveTime" column="arrive_time" />
<result property="actualArriveTime" column="actual_arrive_time" />
<result property="trayNumber" column="tray_number" />
<result property="packageNumber" column="package_number" />
<result property="weight" column="weight" />
<result property="chargeableWeight" column="chargeable_weight" />
<result property="volume" column="volume" />
<result property="remark" column="remark" />
<result property="addTime" column="add_time" />
</resultMap>
<sql id="selectCustomFlightInfoVo">
select id, user_id, warehouse_id, declare_port_id, mode, batch_number, delivery_number, traf_mode, airline, departure_country, departure_city, departure_airport, transit_airport, arrive_airport, flight_number, is_direct_flight, is_our_booking, departure_local_time, departure_time, arrive_time, actual_arrive_time, tray_number, package_number, weight, chargeable_weight, volume, remark, add_time from custom_flight_info
</sql>
<select id="selectCustomFlightInfoList" parameterType="CustomFlightInfo" resultMap="CustomFlightInfoResult">
<include refid="selectCustomFlightInfoVo"/>
<where>
<if test="userId != null "> and user_id = #{userId}</if>
<if test="warehouseId != null "> and warehouse_id = #{warehouseId}</if>
<if test="declarePortId != null "> and declare_port_id = #{declarePortId}</if>
<if test="mode != null "> and mode = #{mode}</if>
<if test="batchNumber != null and batchNumber != ''"> and batch_number = #{batchNumber}</if>
<if test="deliveryNumber != null and deliveryNumber != ''"> and delivery_number = #{deliveryNumber}</if>
<if test="trafMode != null "> and traf_mode = #{trafMode}</if>
<if test="airline != null and airline != ''"> and airline = #{airline}</if>
<if test="departureCountry != null and departureCountry != ''"> and departure_country = #{departureCountry}</if>
<if test="departureCity != null and departureCity != ''"> and departure_city = #{departureCity}</if>
<if test="departureAirport != null and departureAirport != ''"> and departure_airport = #{departureAirport}</if>
<if test="transitAirport != null and transitAirport != ''"> and transit_airport = #{transitAirport}</if>
<if test="arriveAirport != null and arriveAirport != ''"> and arrive_airport = #{arriveAirport}</if>
<if test="flightNumber != null and flightNumber != ''"> and flight_number = #{flightNumber}</if>
<if test="isDirectFlight != null "> and is_direct_flight = #{isDirectFlight}</if>
<if test="isOurBooking != null "> and is_our_booking = #{isOurBooking}</if>
<if test="departureLocalTime != null "> and departure_local_time = #{departureLocalTime}</if>
<if test="departureTime != null "> and departure_time = #{departureTime}</if>
<if test="arriveTime != null "> and arrive_time = #{arriveTime}</if>
<if test="actualArriveTime != null "> and actual_arrive_time = #{actualArriveTime}</if>
<if test="trayNumber != null "> and tray_number = #{trayNumber}</if>
<if test="packageNumber != null "> and package_number = #{packageNumber}</if>
<if test="weight != null "> and weight = #{weight}</if>
<if test="chargeableWeight != null "> and chargeable_weight = #{chargeableWeight}</if>
<if test="volume != null "> and volume = #{volume}</if>
<if test="addTime != null "> and add_time = #{addTime}</if>
</where>
</select>
<select id="selectCustomFlightInfoById" parameterType="Long" resultMap="CustomFlightInfoResult">
<include refid="selectCustomFlightInfoVo"/>
where id = #{id}
</select>
<insert id="insertCustomFlightInfo" parameterType="CustomFlightInfo" useGeneratedKeys="true" keyProperty="id">
insert into custom_flight_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="userId != null">user_id,</if>
<if test="warehouseId != null">warehouse_id,</if>
<if test="declarePortId != null">declare_port_id,</if>
<if test="mode != null">mode,</if>
<if test="batchNumber != null">batch_number,</if>
<if test="deliveryNumber != null">delivery_number,</if>
<if test="trafMode != null">traf_mode,</if>
<if test="airline != null">airline,</if>
<if test="departureCountry != null">departure_country,</if>
<if test="departureCity != null">departure_city,</if>
<if test="departureAirport != null">departure_airport,</if>
<if test="transitAirport != null">transit_airport,</if>
<if test="arriveAirport != null">arrive_airport,</if>
<if test="flightNumber != null">flight_number,</if>
<if test="isDirectFlight != null">is_direct_flight,</if>
<if test="isOurBooking != null">is_our_booking,</if>
<if test="departureLocalTime != null">departure_local_time,</if>
<if test="departureTime != null">departure_time,</if>
<if test="arriveTime != null">arrive_time,</if>
<if test="actualArriveTime != null">actual_arrive_time,</if>
<if test="trayNumber != null">tray_number,</if>
<if test="packageNumber != null">package_number,</if>
<if test="weight != null">weight,</if>
<if test="chargeableWeight != null">chargeable_weight,</if>
<if test="volume != null">volume,</if>
<if test="remark != null">remark,</if>
<if test="addTime != null">add_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="userId != null">#{userId},</if>
<if test="warehouseId != null">#{warehouseId},</if>
<if test="declarePortId != null">#{declarePortId},</if>
<if test="mode != null">#{mode},</if>
<if test="batchNumber != null">#{batchNumber},</if>
<if test="deliveryNumber != null">#{deliveryNumber},</if>
<if test="trafMode != null">#{trafMode},</if>
<if test="airline != null">#{airline},</if>
<if test="departureCountry != null">#{departureCountry},</if>
<if test="departureCity != null">#{departureCity},</if>
<if test="departureAirport != null">#{departureAirport},</if>
<if test="transitAirport != null">#{transitAirport},</if>
<if test="arriveAirport != null">#{arriveAirport},</if>
<if test="flightNumber != null">#{flightNumber},</if>
<if test="isDirectFlight != null">#{isDirectFlight},</if>
<if test="isOurBooking != null">#{isOurBooking},</if>
<if test="departureLocalTime != null">#{departureLocalTime},</if>
<if test="departureTime != null">#{departureTime},</if>
<if test="arriveTime != null">#{arriveTime},</if>
<if test="actualArriveTime != null">#{actualArriveTime},</if>
<if test="trayNumber != null">#{trayNumber},</if>
<if test="packageNumber != null">#{packageNumber},</if>
<if test="weight != null">#{weight},</if>
<if test="chargeableWeight != null">#{chargeableWeight},</if>
<if test="volume != null">#{volume},</if>
<if test="remark != null">#{remark},</if>
<if test="addTime != null">#{addTime},</if>
</trim>
</insert>
<update id="updateCustomFlightInfo" parameterType="CustomFlightInfo">
update custom_flight_info
<trim prefix="SET" suffixOverrides=",">
<if test="userId != null">user_id = #{userId},</if>
<if test="warehouseId != null">warehouse_id = #{warehouseId},</if>
<if test="declarePortId != null">declare_port_id = #{declarePortId},</if>
<if test="mode != null">mode = #{mode},</if>
<if test="batchNumber != null">batch_number = #{batchNumber},</if>
<if test="deliveryNumber != null">delivery_number = #{deliveryNumber},</if>
<if test="trafMode != null">traf_mode = #{trafMode},</if>
<if test="airline != null">airline = #{airline},</if>
<if test="departureCountry != null">departure_country = #{departureCountry},</if>
<if test="departureCity != null">departure_city = #{departureCity},</if>
<if test="departureAirport != null">departure_airport = #{departureAirport},</if>
<if test="transitAirport != null">transit_airport = #{transitAirport},</if>
<if test="arriveAirport != null">arrive_airport = #{arriveAirport},</if>
<if test="flightNumber != null">flight_number = #{flightNumber},</if>
<if test="isDirectFlight != null">is_direct_flight = #{isDirectFlight},</if>
<if test="isOurBooking != null">is_our_booking = #{isOurBooking},</if>
<if test="departureLocalTime != null">departure_local_time = #{departureLocalTime},</if>
<if test="departureTime != null">departure_time = #{departureTime},</if>
<if test="arriveTime != null">arrive_time = #{arriveTime},</if>
<if test="actualArriveTime != null">actual_arrive_time = #{actualArriveTime},</if>
<if test="trayNumber != null">tray_number = #{trayNumber},</if>
<if test="packageNumber != null">package_number = #{packageNumber},</if>
<if test="weight != null">weight = #{weight},</if>
<if test="chargeableWeight != null">chargeable_weight = #{chargeableWeight},</if>
<if test="volume != null">volume = #{volume},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="addTime != null">add_time = #{addTime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomFlightInfoById" parameterType="Long">
delete from custom_flight_info where id = #{id}
</delete>
<delete id="deleteCustomFlightInfoByIds" parameterType="String">
delete from custom_flight_info where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,115 @@
<?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.ruoyi.custom.mapper.CustomHsCodeMapper">
<resultMap type="CustomHsCode" id="CustomHsCodeResult">
<result property="id" column="id" />
<result property="code" column="code" />
<result property="name" column="name" />
<result property="licenseCode" column="license_code" />
<result property="generalTaxRate" column="general_tax_rate" />
<result property="preferentialTaxRate" column="preferential_tax_rate" />
<result property="remark" column="remark" />
<result property="exportTaxRate" column="export_tax_rate" />
<result property="consumptionTaxRate" column="consumption_tax_rate" />
<result property="vatRate" column="vat_rate" />
<result property="firstLegalUnit" column="first_legal_unit" />
<result property="secondLegalUnit" column="second_legal_unit" />
<result property="declareReason" column="declare_reason" />
<result property="isExistInventory" column="is_exist_inventory" />
</resultMap>
<sql id="selectCustomHsCodeVo">
select id, code, name, license_code, general_tax_rate, preferential_tax_rate, remark, export_tax_rate, consumption_tax_rate, vat_rate, first_legal_unit, second_legal_unit, declare_reason, is_exist_inventory from custom_hs_code
</sql>
<select id="selectCustomHsCodeList" parameterType="CustomHsCode" resultMap="CustomHsCodeResult">
<include refid="selectCustomHsCodeVo"/>
<where>
<if test="code != null and code != ''"> and code = #{code}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="licenseCode != null and licenseCode != ''"> and license_code = #{licenseCode}</if>
<if test="generalTaxRate != null "> and general_tax_rate = #{generalTaxRate}</if>
<if test="preferentialTaxRate != null "> and preferential_tax_rate = #{preferentialTaxRate}</if>
<if test="exportTaxRate != null "> and export_tax_rate = #{exportTaxRate}</if>
<if test="consumptionTaxRate != null "> and consumption_tax_rate = #{consumptionTaxRate}</if>
<if test="vatRate != null "> and vat_rate = #{vatRate}</if>
<if test="firstLegalUnit != null and firstLegalUnit != ''"> and first_legal_unit = #{firstLegalUnit}</if>
<if test="secondLegalUnit != null and secondLegalUnit != ''"> and second_legal_unit = #{secondLegalUnit}</if>
<if test="declareReason != null and declareReason != ''"> and declare_reason = #{declareReason}</if>
<if test="isExistInventory != null "> and is_exist_inventory = #{isExistInventory}</if>
</where>
</select>
<select id="selectCustomHsCodeById" parameterType="Long" resultMap="CustomHsCodeResult">
<include refid="selectCustomHsCodeVo"/>
where id = #{id}
</select>
<insert id="insertCustomHsCode" parameterType="CustomHsCode" useGeneratedKeys="true" keyProperty="id">
insert into custom_hs_code
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="code != null">code,</if>
<if test="name != null">name,</if>
<if test="licenseCode != null">license_code,</if>
<if test="generalTaxRate != null">general_tax_rate,</if>
<if test="preferentialTaxRate != null">preferential_tax_rate,</if>
<if test="remark != null">remark,</if>
<if test="exportTaxRate != null">export_tax_rate,</if>
<if test="consumptionTaxRate != null">consumption_tax_rate,</if>
<if test="vatRate != null">vat_rate,</if>
<if test="firstLegalUnit != null">first_legal_unit,</if>
<if test="secondLegalUnit != null">second_legal_unit,</if>
<if test="declareReason != null">declare_reason,</if>
<if test="isExistInventory != null">is_exist_inventory,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="code != null">#{code},</if>
<if test="name != null">#{name},</if>
<if test="licenseCode != null">#{licenseCode},</if>
<if test="generalTaxRate != null">#{generalTaxRate},</if>
<if test="preferentialTaxRate != null">#{preferentialTaxRate},</if>
<if test="remark != null">#{remark},</if>
<if test="exportTaxRate != null">#{exportTaxRate},</if>
<if test="consumptionTaxRate != null">#{consumptionTaxRate},</if>
<if test="vatRate != null">#{vatRate},</if>
<if test="firstLegalUnit != null">#{firstLegalUnit},</if>
<if test="secondLegalUnit != null">#{secondLegalUnit},</if>
<if test="declareReason != null">#{declareReason},</if>
<if test="isExistInventory != null">#{isExistInventory},</if>
</trim>
</insert>
<update id="updateCustomHsCode" parameterType="CustomHsCode">
update custom_hs_code
<trim prefix="SET" suffixOverrides=",">
<if test="code != null">code = #{code},</if>
<if test="name != null">name = #{name},</if>
<if test="licenseCode != null">license_code = #{licenseCode},</if>
<if test="generalTaxRate != null">general_tax_rate = #{generalTaxRate},</if>
<if test="preferentialTaxRate != null">preferential_tax_rate = #{preferentialTaxRate},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="exportTaxRate != null">export_tax_rate = #{exportTaxRate},</if>
<if test="consumptionTaxRate != null">consumption_tax_rate = #{consumptionTaxRate},</if>
<if test="vatRate != null">vat_rate = #{vatRate},</if>
<if test="firstLegalUnit != null">first_legal_unit = #{firstLegalUnit},</if>
<if test="secondLegalUnit != null">second_legal_unit = #{secondLegalUnit},</if>
<if test="declareReason != null">declare_reason = #{declareReason},</if>
<if test="isExistInventory != null">is_exist_inventory = #{isExistInventory},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomHsCodeById" parameterType="Long">
delete from custom_hs_code where id = #{id}
</delete>
<delete id="deleteCustomHsCodeByIds" parameterType="String">
delete from custom_hs_code where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,65 @@
<?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.ruoyi.custom.mapper.CustomInventoryMapper">
<resultMap type="CustomInventory" id="CustomInventoryResult">
<result property="id" column="id" />
<result property="name" column="name" />
<result property="code" column="code" />
<result property="remark" column="remark" />
</resultMap>
<sql id="selectCustomInventoryVo">
select id, name, code, remark from custom_inventory
</sql>
<select id="selectCustomInventoryList" parameterType="CustomInventory" resultMap="CustomInventoryResult">
<include refid="selectCustomInventoryVo"/>
<where>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="code != null and code != ''"> and code = #{code}</if>
</where>
</select>
<select id="selectCustomInventoryById" parameterType="Long" resultMap="CustomInventoryResult">
<include refid="selectCustomInventoryVo"/>
where id = #{id}
</select>
<insert id="insertCustomInventory" parameterType="CustomInventory" useGeneratedKeys="true" keyProperty="id">
insert into custom_inventory
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="name != null">name,</if>
<if test="code != null">code,</if>
<if test="remark != null">remark,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="name != null">#{name},</if>
<if test="code != null">#{code},</if>
<if test="remark != null">#{remark},</if>
</trim>
</insert>
<update id="updateCustomInventory" parameterType="CustomInventory">
update custom_inventory
<trim prefix="SET" suffixOverrides=",">
<if test="name != null">name = #{name},</if>
<if test="code != null">code = #{code},</if>
<if test="remark != null">remark = #{remark},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomInventoryById" parameterType="Long">
delete from custom_inventory where id = #{id}
</delete>
<delete id="deleteCustomInventoryByIds" parameterType="String">
delete from custom_inventory where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,191 @@
<?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.ruoyi.custom.mapper.CustomOrderItemMapper">
<resultMap type="CustomOrderItem" id="CustomOrderItemResult">
<result property="id" column="id" />
<result property="orderId" column="order_id" />
<result property="declarePortId" column="declare_port_id" />
<result property="warehouseId" column="warehouse_id" />
<result property="barCode" column="bar_code" />
<result property="quantity" column="quantity" />
<result property="price" column="price" />
<result property="shopPrice" column="shop_price" />
<result property="freight" column="freight" />
<result property="taxAmount" column="tax_amount" />
<result property="itemLink" column="item_link" />
<result property="bookNumber" column="book_number" />
<result property="productCode" column="product_code" />
<result property="name" column="name" />
<result property="brand" column="brand" />
<result property="specificationModel" column="specification_model" />
<result property="description" column="description" />
<result property="quantityUnit" column="quantity_unit" />
<result property="produceCountry" column="produce_country" />
<result property="inspectionAndQuarantineCode" column="inspection_and_quarantine_code" />
<result property="hsCode" column="hs_code" />
<result property="taxRate" column="tax_rate" />
<result property="declaredCount" column="declared_count" />
<result property="legalMeteringUnit" column="legal_metering_unit" />
<result property="secondDeclaredCount" column="second_declared_count" />
<result property="secondMeteringUnit" column="second_metering_unit" />
<result property="grossWeight" column="gross_weight" />
<result property="netWeight" column="net_weight" />
<result property="skuCode" column="sku_code" />
</resultMap>
<sql id="selectCustomOrderItemVo">
select id, order_id, declare_port_id, warehouse_id, bar_code, quantity, price, shop_price, freight, tax_amount, item_link, book_number, product_code, name, brand, specification_model, description, quantity_unit, produce_country, inspection_and_quarantine_code, hs_code, tax_rate, declared_count, legal_metering_unit, second_declared_count, second_metering_unit, gross_weight, net_weight from custom_order_item
</sql>
<select id="selectCustomOrderItemList" parameterType="CustomOrderItem" resultMap="CustomOrderItemResult">
<include refid="selectCustomOrderItemVo"/>
<where>
<if test="orderId != null "> and order_id = #{orderId}</if>
<if test="declarePortId != null "> and declare_port_id = #{declarePortId}</if>
<if test="warehouseId != null "> and warehouse_id = #{warehouseId}</if>
<if test="barCode != null and barCode != ''"> and bar_code = #{barCode}</if>
<if test="quantity != null "> and quantity = #{quantity}</if>
<if test="price != null "> and price = #{price}</if>
<if test="shopPrice != null "> and shop_price = #{shopPrice}</if>
<if test="freight != null "> and freight = #{freight}</if>
<if test="taxAmount != null "> and tax_amount = #{taxAmount}</if>
<if test="itemLink != null and itemLink != ''"> and item_link = #{itemLink}</if>
<if test="bookNumber != null and bookNumber != ''"> and book_number = #{bookNumber}</if>
<if test="productCode != null and productCode != ''"> and product_code = #{productCode}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="brand != null and brand != ''"> and brand = #{brand}</if>
<if test="specificationModel != null and specificationModel != ''"> and specification_model = #{specificationModel}</if>
<if test="description != null and description != ''"> and description = #{description}</if>
<if test="quantityUnit != null and quantityUnit != ''"> and quantity_unit = #{quantityUnit}</if>
<if test="produceCountry != null and produceCountry != ''"> and produce_country = #{produceCountry}</if>
<if test="inspectionAndQuarantineCode != null and inspectionAndQuarantineCode != ''"> and inspection_and_quarantine_code = #{inspectionAndQuarantineCode}</if>
<if test="hsCode != null and hsCode != ''"> and hs_code = #{hsCode}</if>
<if test="taxRate != null "> and tax_rate = #{taxRate}</if>
<if test="declaredCount != null "> and declared_count = #{declaredCount}</if>
<if test="legalMeteringUnit != null and legalMeteringUnit != ''"> and legal_metering_unit = #{legalMeteringUnit}</if>
<if test="secondDeclaredCount != null "> and second_declared_count = #{secondDeclaredCount}</if>
<if test="secondMeteringUnit != null and secondMeteringUnit != ''"> and second_metering_unit = #{secondMeteringUnit}</if>
<if test="grossWeight != null "> and gross_weight = #{grossWeight}</if>
<if test="netWeight != null "> and net_weight = #{netWeight}</if>
<if test="skuCode != null "> and sku_code = #{skuCode}</if>
</where>
</select>
<select id="selectCustomOrderItemById" parameterType="Long" resultMap="CustomOrderItemResult">
<include refid="selectCustomOrderItemVo"/>
where id = #{id}
</select>
<insert id="insertCustomOrderItem" parameterType="CustomOrderItem" useGeneratedKeys="true" keyProperty="id">
insert into custom_order_item
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="orderId != null">order_id,</if>
<if test="declarePortId != null">declare_port_id,</if>
<if test="warehouseId != null">warehouse_id,</if>
<if test="barCode != null">bar_code,</if>
<if test="quantity != null">quantity,</if>
<if test="price != null">price,</if>
<if test="shopPrice != null">shop_price,</if>
<if test="freight != null">freight,</if>
<if test="taxAmount != null">tax_amount,</if>
<if test="itemLink != null">item_link,</if>
<if test="bookNumber != null">book_number,</if>
<if test="productCode != null">product_code,</if>
<if test="name != null">name,</if>
<if test="brand != null">brand,</if>
<if test="specificationModel != null">specification_model,</if>
<if test="description != null">description,</if>
<if test="quantityUnit != null">quantity_unit,</if>
<if test="produceCountry != null">produce_country,</if>
<if test="inspectionAndQuarantineCode != null">inspection_and_quarantine_code,</if>
<if test="hsCode != null">hs_code,</if>
<if test="taxRate != null">tax_rate,</if>
<if test="declaredCount != null">declared_count,</if>
<if test="legalMeteringUnit != null">legal_metering_unit,</if>
<if test="secondDeclaredCount != null">second_declared_count,</if>
<if test="secondMeteringUnit != null">second_metering_unit,</if>
<if test="grossWeight != null">gross_weight,</if>
<if test="netWeight != null">net_weight,</if>
<if test="skuCode != null">sku_code,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="orderId != null">#{orderId},</if>
<if test="declarePortId != null">#{declarePortId},</if>
<if test="warehouseId != null">#{warehouseId},</if>
<if test="barCode != null">#{barCode},</if>
<if test="quantity != null">#{quantity},</if>
<if test="price != null">#{price},</if>
<if test="shopPrice != null">#{shopPrice},</if>
<if test="freight != null">#{freight},</if>
<if test="taxAmount != null">#{taxAmount},</if>
<if test="itemLink != null">#{itemLink},</if>
<if test="bookNumber != null">#{bookNumber},</if>
<if test="productCode != null">#{productCode},</if>
<if test="name != null">#{name},</if>
<if test="brand != null">#{brand},</if>
<if test="specificationModel != null">#{specificationModel},</if>
<if test="description != null">#{description},</if>
<if test="quantityUnit != null">#{quantityUnit},</if>
<if test="produceCountry != null">#{produceCountry},</if>
<if test="inspectionAndQuarantineCode != null">#{inspectionAndQuarantineCode},</if>
<if test="hsCode != null">#{hsCode},</if>
<if test="taxRate != null">#{taxRate},</if>
<if test="declaredCount != null">#{declaredCount},</if>
<if test="legalMeteringUnit != null">#{legalMeteringUnit},</if>
<if test="secondDeclaredCount != null">#{secondDeclaredCount},</if>
<if test="secondMeteringUnit != null">#{secondMeteringUnit},</if>
<if test="grossWeight != null">#{grossWeight},</if>
<if test="netWeight != null">#{netWeight},</if>
<if test="skuCode != null">#{skuCode},</if>
</trim>
</insert>
<update id="updateCustomOrderItem" parameterType="CustomOrderItem">
update custom_order_item
<trim prefix="SET" suffixOverrides=",">
<if test="orderId != null">order_id = #{orderId},</if>
<if test="declarePortId != null">declare_port_id = #{declarePortId},</if>
<if test="warehouseId != null">warehouse_id = #{warehouseId},</if>
<if test="barCode != null">bar_code = #{barCode},</if>
<if test="quantity != null">quantity = #{quantity},</if>
<if test="price != null">price = #{price},</if>
<if test="shopPrice != null">shop_price = #{shopPrice},</if>
<if test="freight != null">freight = #{freight},</if>
<if test="taxAmount != null">tax_amount = #{taxAmount},</if>
<if test="itemLink != null">item_link = #{itemLink},</if>
<if test="bookNumber != null">book_number = #{bookNumber},</if>
<if test="productCode != null">product_code = #{productCode},</if>
<if test="name != null">name = #{name},</if>
<if test="brand != null">brand = #{brand},</if>
<if test="specificationModel != null">specification_model = #{specificationModel},</if>
<if test="description != null">description = #{description},</if>
<if test="quantityUnit != null">quantity_unit = #{quantityUnit},</if>
<if test="produceCountry != null">produce_country = #{produceCountry},</if>
<if test="inspectionAndQuarantineCode != null">inspection_and_quarantine_code = #{inspectionAndQuarantineCode},</if>
<if test="hsCode != null">hs_code = #{hsCode},</if>
<if test="taxRate != null">tax_rate = #{taxRate},</if>
<if test="declaredCount != null">declared_count = #{declaredCount},</if>
<if test="legalMeteringUnit != null">legal_metering_unit = #{legalMeteringUnit},</if>
<if test="secondDeclaredCount != null">second_declared_count = #{secondDeclaredCount},</if>
<if test="secondMeteringUnit != null">second_metering_unit = #{secondMeteringUnit},</if>
<if test="grossWeight != null">gross_weight = #{grossWeight},</if>
<if test="netWeight != null">net_weight = #{netWeight},</if>
<if test="skuCode != null">sku_code = #{skuCode},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomOrderItemById" parameterType="Long">
delete from custom_order_item where id = #{id}
</delete>
<delete id="deleteCustomOrderItemByIds" parameterType="String">
delete from custom_order_item where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,361 @@
<?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.ruoyi.custom.mapper.CustomOrderMapper">
<resultMap type="CustomOrder" id="CustomOrderResult">
<result property="id" column="id" />
<result property="declarePortId" column="declare_port_id" />
<result property="warehouseId" column="warehouse_id" />
<result property="mode" column="mode" />
<result property="userId" column="user_id" />
<result property="sOrderNo" column="s_order_no" />
<result property="declareOrderNo" column="declare_order_no" />
<result property="status" column="status" />
<result property="expressName" column="express_name" />
<result property="shipOrderNumber" column="ship_order_number" />
<result property="buyerRegNo" column="buyer_reg_no" />
<result property="buyerName" column="buyer_name" />
<result property="buyerTelephone" column="buyer_telephone" />
<result property="buyerIdType" column="buyer_id_type" />
<result property="buyerIdNumber" column="buyer_id_number" />
<result property="consignee" column="consignee" />
<result property="consigneeTelephone" column="consignee_telephone" />
<result property="consigneeAddress" column="consignee_address" />
<result property="consigneeProvince" column="consignee_province" />
<result property="consigneeCity" column="consignee_city" />
<result property="consigneeDistrict" column="consignee_district" />
<result property="totalAmount" column="total_amount" />
<result property="discountAmount" column="discount_amount" />
<result property="payTotalAmount" column="pay_total_amount" />
<result property="taxTotalAmount" column="tax_total_amount" />
<result property="shopTaxTotalAmount" column="shop_tax_total_amount" />
<result property="freightAmount" column="freight_amount" />
<result property="totalGrossWeight" column="total_gross_weight" />
<result property="totalNetWeight" column="total_net_weight" />
<result property="totalQuantity" column="total_quantity" />
<result property="payName" column="pay_name" />
<result property="payCode" column="pay_code" />
<result property="payTime" column="pay_time" />
<result property="gatewayOrderId" column="gateway_order_id" />
<result property="consignor" column="consignor" />
<result property="consignorAddress" column="consignor_address" />
<result property="consignorTelephone" column="consignor_telephone" />
<result property="consignorCountry" column="consignor_country" />
<result property="consignorProvince" column="consignor_province" />
<result property="consignorCity" column="consignor_city" />
<result property="consignorDistrict" column="consignor_district" />
<result property="receiptAccount" column="receipt_account" />
<result property="verDept" column="ver_dept" />
<result property="payType" column="pay_type" />
<result property="initalRequest" column="inital_request" />
<result property="initalResponse" column="inital_response" />
<result property="remark" column="remark" />
<result property="expressReturn" column="express_return" />
<result property="process" column="process" />
<result property="addTime" column="add_time" />
<result property="inventoryNo" column="inventory_no" />
<result property="batchNumber" column="batch_number" />
</resultMap>
<resultMap id="CustomOrderCustomOrderItemResult" type="CustomOrder" extends="CustomOrderResult">
<collection property="customOrderItemList" notNullColumn="id" javaType="java.util.List" resultMap="CustomOrderItemResult" />
</resultMap>
<resultMap type="CustomOrderItem" id="CustomOrderItemResult">
<result property="id" column="id" />
<result property="orderId" column="order_id" />
<result property="declarePortId" column="declare_port_id" />
<result property="warehouseId" column="warehouse_id" />
<result property="barCode" column="bar_code" />
<result property="quantity" column="quantity" />
<result property="price" column="price" />
<result property="shopPrice" column="shop_price" />
<result property="freight" column="freight" />
<result property="taxAmount" column="tax_amount" />
<result property="itemLink" column="item_link" />
<result property="bookNumber" column="book_number" />
<result property="productCode" column="product_code" />
<result property="name" column="name" />
<result property="brand" column="brand" />
<result property="specificationModel" column="specification_model" />
<result property="description" column="description" />
<result property="quantityUnit" column="quantity_unit" />
<result property="produceCountry" column="produce_country" />
<result property="inspectionAndQuarantineCode" column="inspection_and_quarantine_code" />
<result property="hsCode" column="hs_code" />
<result property="taxRate" column="tax_rate" />
<result property="declaredCount" column="declared_count" />
<result property="legalMeteringUnit" column="legal_metering_unit" />
<result property="secondDeclaredCount" column="second_declared_count" />
<result property="secondMeteringUnit" column="second_metering_unit" />
<result property="grossWeight" column="gross_weight" />
<result property="netWeight" column="net_weight" />
</resultMap>
<sql id="selectCustomOrderVo">
select id, declare_port_id, warehouse_id, mode, user_id, s_order_no, declare_order_no, status, express_name, ship_order_number, buyer_reg_no, buyer_name, buyer_telephone, buyer_id_type, buyer_id_number, consignee, consignee_telephone, consignee_address, consignee_province, consignee_city, consignee_district, total_amount, discount_amount, pay_total_amount, tax_total_amount, shop_tax_total_amount, freight_amount, total_gross_weight, total_net_weight, total_quantity, pay_name, pay_code, pay_time, gateway_order_id, consignor, consignor_address, consignor_telephone, consignor_country, consignor_province, consignor_city, consignor_district, receipt_account, ver_dept, pay_type, inital_request, inital_response, remark, express_return, process, add_time, inventory_no, batch_number from custom_order
</sql>
<select id="selectCustomOrderList" parameterType="CustomOrder" resultMap="CustomOrderResult">
<include refid="selectCustomOrderVo"/>
<where>
<if test="declarePortId != null "> and declare_port_id = #{declarePortId}</if>
<if test="warehouseId != null "> and warehouse_id = #{warehouseId}</if>
<if test="mode != null "> and mode = #{mode}</if>
<if test="userId != null "> and user_id = #{userId}</if>
<if test="sOrderNo != null and sOrderNo != ''"> and s_order_no = #{sOrderNo}</if>
<if test="declareOrderNo != null and declareOrderNo != ''"> and declare_order_no = #{declareOrderNo}</if>
<if test="status != null "> and status = #{status}</if>
<if test="expressName != null and expressName != ''"> and express_name like concat('%', #{expressName}, '%')</if>
<if test="shipOrderNumber != null and shipOrderNumber != ''"> and ship_order_number = #{shipOrderNumber}</if>
<if test="buyerRegNo != null and buyerRegNo != ''"> and buyer_reg_no = #{buyerRegNo}</if>
<if test="buyerName != null and buyerName != ''"> and buyer_name like concat('%', #{buyerName}, '%')</if>
<if test="buyerTelephone != null and buyerTelephone != ''"> and buyer_telephone = #{buyerTelephone}</if>
<if test="buyerIdType != null "> and buyer_id_type = #{buyerIdType}</if>
<if test="buyerIdNumber != null and buyerIdNumber != ''"> and buyer_id_number = #{buyerIdNumber}</if>
<if test="consignee != null and consignee != ''"> and consignee = #{consignee}</if>
<if test="consigneeTelephone != null and consigneeTelephone != ''"> and consignee_telephone = #{consigneeTelephone}</if>
<if test="consigneeAddress != null and consigneeAddress != ''"> and consignee_address = #{consigneeAddress}</if>
<if test="consigneeProvince != null and consigneeProvince != ''"> and consignee_province = #{consigneeProvince}</if>
<if test="consigneeCity != null and consigneeCity != ''"> and consignee_city = #{consigneeCity}</if>
<if test="consigneeDistrict != null and consigneeDistrict != ''"> and consignee_district = #{consigneeDistrict}</if>
<if test="totalAmount != null "> and total_amount = #{totalAmount}</if>
<if test="discountAmount != null "> and discount_amount = #{discountAmount}</if>
<if test="payTotalAmount != null "> and pay_total_amount = #{payTotalAmount}</if>
<if test="taxTotalAmount != null "> and tax_total_amount = #{taxTotalAmount}</if>
<if test="shopTaxTotalAmount != null "> and shop_tax_total_amount = #{shopTaxTotalAmount}</if>
<if test="freightAmount != null "> and freight_amount = #{freightAmount}</if>
<if test="totalGrossWeight != null "> and total_gross_weight = #{totalGrossWeight}</if>
<if test="totalNetWeight != null "> and total_net_weight = #{totalNetWeight}</if>
<if test="totalQuantity != null "> and total_quantity = #{totalQuantity}</if>
<if test="payName != null and payName != ''"> and pay_name like concat('%', #{payName}, '%')</if>
<if test="payCode != null and payCode != ''"> and pay_code = #{payCode}</if>
<if test="payTime != null "> and pay_time = #{payTime}</if>
<if test="gatewayOrderId != null and gatewayOrderId != ''"> and gateway_order_id = #{gatewayOrderId}</if>
<if test="consignor != null and consignor != ''"> and consignor = #{consignor}</if>
<if test="consignorAddress != null and consignorAddress != ''"> and consignor_address = #{consignorAddress}</if>
<if test="consignorTelephone != null and consignorTelephone != ''"> and consignor_telephone = #{consignorTelephone}</if>
<if test="consignorCountry != null and consignorCountry != ''"> and consignor_country = #{consignorCountry}</if>
<if test="consignorProvince != null and consignorProvince != ''"> and consignor_province = #{consignorProvince}</if>
<if test="consignorCity != null and consignorCity != ''"> and consignor_city = #{consignorCity}</if>
<if test="consignorDistrict != null and consignorDistrict != ''"> and consignor_district = #{consignorDistrict}</if>
<if test="receiptAccount != null and receiptAccount != ''"> and receipt_account = #{receiptAccount}</if>
<if test="verDept != null "> and ver_dept = #{verDept}</if>
<if test="payType != null "> and pay_type = #{payType}</if>
<if test="initalRequest != null and initalRequest != ''"> and inital_request = #{initalRequest}</if>
<if test="initalResponse != null and initalResponse != ''"> and inital_response = #{initalResponse}</if>
<if test="expressReturn != null and expressReturn != ''"> and express_return = #{expressReturn}</if>
<if test="process != null and process != ''"> and process = #{process}</if>
<if test="addTime != null "> and add_time = #{addTime}</if>
<if test="inventoryNo != null and inventoryNo != ''"> and inventory_no = #{inventoryNo}</if>
<if test="batchNumber != null and batchNumber != ''"> and batch_number = #{batchNumber}</if>
</where>
</select>
<select id="selectCustomOrderById" parameterType="Long" resultMap="CustomOrderCustomOrderItemResult">
select a.id, a.declare_port_id, a.warehouse_id, a.mode, a.user_id, a.s_order_no, a.declare_order_no, a.status, a.express_name, a.ship_order_number, a.buyer_reg_no, a.buyer_name, a.buyer_telephone, a.buyer_id_type, a.buyer_id_number, a.consignee, a.consignee_telephone, a.consignee_address, a.consignee_province, a.consignee_city, a.consignee_district, a.total_amount, a.discount_amount, a.pay_total_amount, a.tax_total_amount, a.shop_tax_total_amount, a.freight_amount, a.total_gross_weight, a.total_net_weight, a.total_quantity, a.pay_name, a.pay_code, a.pay_time, a.gateway_order_id, a.consignor, a.consignor_address, a.consignor_telephone, a.consignor_country, a.consignor_province, a.consignor_city, a.consignor_district, a.receipt_account, a.ver_dept, a.pay_type, a.inital_request, a.inital_response, a.remark, a.express_return, a.process, a.add_time, a.inventory_no, a.batch_number,
b.id, b.order_id, b.declare_port_id, b.warehouse_id, b.bar_code, b.quantity, b.price, b.shop_price, b.freight, b.tax_amount, b.item_link, b.book_number, b.product_code, b.name, b.brand, b.specification_model, b.description, b.quantity_unit, b.produce_country, b.inspection_and_quarantine_code, b.hs_code, b.tax_rate, b.declared_count, b.legal_metering_unit, b.second_declared_count, b.second_metering_unit, b.gross_weight, b.net_weight
from custom_order a
left join custom_order_item b on b.order_id = a.id
where a.id = #{id}
</select>
<insert id="insertCustomOrder" parameterType="CustomOrder" useGeneratedKeys="true" keyProperty="id">
insert into custom_order
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="declarePortId != null">declare_port_id,</if>
<if test="warehouseId != null">warehouse_id,</if>
<if test="mode != null">mode,</if>
<if test="userId != null">user_id,</if>
<if test="sOrderNo != null">s_order_no,</if>
<if test="declareOrderNo != null">declare_order_no,</if>
<if test="status != null">status,</if>
<if test="expressName != null">express_name,</if>
<if test="shipOrderNumber != null">ship_order_number,</if>
<if test="buyerRegNo != null">buyer_reg_no,</if>
<if test="buyerName != null">buyer_name,</if>
<if test="buyerTelephone != null">buyer_telephone,</if>
<if test="buyerIdType != null">buyer_id_type,</if>
<if test="buyerIdNumber != null">buyer_id_number,</if>
<if test="consignee != null">consignee,</if>
<if test="consigneeTelephone != null">consignee_telephone,</if>
<if test="consigneeAddress != null">consignee_address,</if>
<if test="consigneeProvince != null">consignee_province,</if>
<if test="consigneeCity != null">consignee_city,</if>
<if test="consigneeDistrict != null">consignee_district,</if>
<if test="totalAmount != null">total_amount,</if>
<if test="discountAmount != null">discount_amount,</if>
<if test="payTotalAmount != null">pay_total_amount,</if>
<if test="taxTotalAmount != null">tax_total_amount,</if>
<if test="shopTaxTotalAmount != null">shop_tax_total_amount,</if>
<if test="freightAmount != null">freight_amount,</if>
<if test="totalGrossWeight != null">total_gross_weight,</if>
<if test="totalNetWeight != null">total_net_weight,</if>
<if test="totalQuantity != null">total_quantity,</if>
<if test="payName != null">pay_name,</if>
<if test="payCode != null">pay_code,</if>
<if test="payTime != null">pay_time,</if>
<if test="gatewayOrderId != null">gateway_order_id,</if>
<if test="consignor != null">consignor,</if>
<if test="consignorAddress != null">consignor_address,</if>
<if test="consignorTelephone != null">consignor_telephone,</if>
<if test="consignorCountry != null">consignor_country,</if>
<if test="consignorProvince != null">consignor_province,</if>
<if test="consignorCity != null">consignor_city,</if>
<if test="consignorDistrict != null">consignor_district,</if>
<if test="receiptAccount != null">receipt_account,</if>
<if test="verDept != null">ver_dept,</if>
<if test="payType != null">pay_type,</if>
<if test="initalRequest != null">inital_request,</if>
<if test="initalResponse != null">inital_response,</if>
<if test="remark != null">remark,</if>
<if test="expressReturn != null">express_return,</if>
<if test="process != null">process,</if>
<if test="addTime != null">add_time,</if>
<if test="inventoryNo != null">inventory_no,</if>
<if test="batchNumber != null">batch_number,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="declarePortId != null">#{declarePortId},</if>
<if test="warehouseId != null">#{warehouseId},</if>
<if test="mode != null">#{mode},</if>
<if test="userId != null">#{userId},</if>
<if test="sOrderNo != null">#{sOrderNo},</if>
<if test="declareOrderNo != null">#{declareOrderNo},</if>
<if test="status != null">#{status},</if>
<if test="expressName != null">#{expressName},</if>
<if test="shipOrderNumber != null">#{shipOrderNumber},</if>
<if test="buyerRegNo != null">#{buyerRegNo},</if>
<if test="buyerName != null">#{buyerName},</if>
<if test="buyerTelephone != null">#{buyerTelephone},</if>
<if test="buyerIdType != null">#{buyerIdType},</if>
<if test="buyerIdNumber != null">#{buyerIdNumber},</if>
<if test="consignee != null">#{consignee},</if>
<if test="consigneeTelephone != null">#{consigneeTelephone},</if>
<if test="consigneeAddress != null">#{consigneeAddress},</if>
<if test="consigneeProvince != null">#{consigneeProvince},</if>
<if test="consigneeCity != null">#{consigneeCity},</if>
<if test="consigneeDistrict != null">#{consigneeDistrict},</if>
<if test="totalAmount != null">#{totalAmount},</if>
<if test="discountAmount != null">#{discountAmount},</if>
<if test="payTotalAmount != null">#{payTotalAmount},</if>
<if test="taxTotalAmount != null">#{taxTotalAmount},</if>
<if test="shopTaxTotalAmount != null">#{shopTaxTotalAmount},</if>
<if test="freightAmount != null">#{freightAmount},</if>
<if test="totalGrossWeight != null">#{totalGrossWeight},</if>
<if test="totalNetWeight != null">#{totalNetWeight},</if>
<if test="totalQuantity != null">#{totalQuantity},</if>
<if test="payName != null">#{payName},</if>
<if test="payCode != null">#{payCode},</if>
<if test="payTime != null">#{payTime},</if>
<if test="gatewayOrderId != null">#{gatewayOrderId},</if>
<if test="consignor != null">#{consignor},</if>
<if test="consignorAddress != null">#{consignorAddress},</if>
<if test="consignorTelephone != null">#{consignorTelephone},</if>
<if test="consignorCountry != null">#{consignorCountry},</if>
<if test="consignorProvince != null">#{consignorProvince},</if>
<if test="consignorCity != null">#{consignorCity},</if>
<if test="consignorDistrict != null">#{consignorDistrict},</if>
<if test="receiptAccount != null">#{receiptAccount},</if>
<if test="verDept != null">#{verDept},</if>
<if test="payType != null">#{payType},</if>
<if test="initalRequest != null">#{initalRequest},</if>
<if test="initalResponse != null">#{initalResponse},</if>
<if test="remark != null">#{remark},</if>
<if test="expressReturn != null">#{expressReturn},</if>
<if test="process != null">#{process},</if>
<if test="addTime != null">#{addTime},</if>
<if test="inventoryNo != null">#{inventoryNo},</if>
<if test="batchNumber != null">#{batchNumber},</if>
</trim>
</insert>
<update id="updateCustomOrder" parameterType="CustomOrder">
update custom_order
<trim prefix="SET" suffixOverrides=",">
<if test="declarePortId != null">declare_port_id = #{declarePortId},</if>
<if test="warehouseId != null">warehouse_id = #{warehouseId},</if>
<if test="mode != null">mode = #{mode},</if>
<if test="userId != null">user_id = #{userId},</if>
<if test="sOrderNo != null">s_order_no = #{sOrderNo},</if>
<if test="declareOrderNo != null">declare_order_no = #{declareOrderNo},</if>
<if test="status != null">status = #{status},</if>
<if test="expressName != null">express_name = #{expressName},</if>
<if test="shipOrderNumber != null">ship_order_number = #{shipOrderNumber},</if>
<if test="buyerRegNo != null">buyer_reg_no = #{buyerRegNo},</if>
<if test="buyerName != null">buyer_name = #{buyerName},</if>
<if test="buyerTelephone != null">buyer_telephone = #{buyerTelephone},</if>
<if test="buyerIdType != null">buyer_id_type = #{buyerIdType},</if>
<if test="buyerIdNumber != null">buyer_id_number = #{buyerIdNumber},</if>
<if test="consignee != null">consignee = #{consignee},</if>
<if test="consigneeTelephone != null">consignee_telephone = #{consigneeTelephone},</if>
<if test="consigneeAddress != null">consignee_address = #{consigneeAddress},</if>
<if test="consigneeProvince != null">consignee_province = #{consigneeProvince},</if>
<if test="consigneeCity != null">consignee_city = #{consigneeCity},</if>
<if test="consigneeDistrict != null">consignee_district = #{consigneeDistrict},</if>
<if test="totalAmount != null">total_amount = #{totalAmount},</if>
<if test="discountAmount != null">discount_amount = #{discountAmount},</if>
<if test="payTotalAmount != null">pay_total_amount = #{payTotalAmount},</if>
<if test="taxTotalAmount != null">tax_total_amount = #{taxTotalAmount},</if>
<if test="shopTaxTotalAmount != null">shop_tax_total_amount = #{shopTaxTotalAmount},</if>
<if test="freightAmount != null">freight_amount = #{freightAmount},</if>
<if test="totalGrossWeight != null">total_gross_weight = #{totalGrossWeight},</if>
<if test="totalNetWeight != null">total_net_weight = #{totalNetWeight},</if>
<if test="totalQuantity != null">total_quantity = #{totalQuantity},</if>
<if test="payName != null">pay_name = #{payName},</if>
<if test="payCode != null">pay_code = #{payCode},</if>
<if test="payTime != null">pay_time = #{payTime},</if>
<if test="gatewayOrderId != null">gateway_order_id = #{gatewayOrderId},</if>
<if test="consignor != null">consignor = #{consignor},</if>
<if test="consignorAddress != null">consignor_address = #{consignorAddress},</if>
<if test="consignorTelephone != null">consignor_telephone = #{consignorTelephone},</if>
<if test="consignorCountry != null">consignor_country = #{consignorCountry},</if>
<if test="consignorProvince != null">consignor_province = #{consignorProvince},</if>
<if test="consignorCity != null">consignor_city = #{consignorCity},</if>
<if test="consignorDistrict != null">consignor_district = #{consignorDistrict},</if>
<if test="receiptAccount != null">receipt_account = #{receiptAccount},</if>
<if test="verDept != null">ver_dept = #{verDept},</if>
<if test="payType != null">pay_type = #{payType},</if>
<if test="initalRequest != null">inital_request = #{initalRequest},</if>
<if test="initalResponse != null">inital_response = #{initalResponse},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="expressReturn != null">express_return = #{expressReturn},</if>
<if test="process != null">process = #{process},</if>
<if test="addTime != null">add_time = #{addTime},</if>
<if test="inventoryNo != null">inventory_no = #{inventoryNo},</if>
<if test="batchNumber != null">batch_number = #{batchNumber},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomOrderById" parameterType="Long">
delete from custom_order where id = #{id}
</delete>
<delete id="deleteCustomOrderByIds" parameterType="String">
delete from custom_order where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
<delete id="deleteCustomOrderItemByOrderIds" parameterType="String">
delete from custom_order_item where order_id in
<foreach item="orderId" collection="array" open="(" separator="," close=")">
#{orderId}
</foreach>
</delete>
<delete id="deleteCustomOrderItemByOrderId" parameterType="Long">
delete from custom_order_item where order_id = #{orderId}
</delete>
<insert id="batchCustomOrderItem">
insert into custom_order_item( id, order_id, declare_port_id, warehouse_id, bar_code, quantity, price, shop_price, freight, tax_amount, item_link, book_number, product_code, name, brand, specification_model, description, quantity_unit, produce_country, inspection_and_quarantine_code, hs_code, tax_rate, declared_count, legal_metering_unit, second_declared_count, second_metering_unit, gross_weight, net_weight) values
<foreach item="item" index="index" collection="list" separator=",">
( #{item.id}, #{item.orderId}, #{item.declarePortId}, #{item.warehouseId}, #{item.barCode}, #{item.quantity}, #{item.price}, #{item.shopPrice}, #{item.freight}, #{item.taxAmount}, #{item.itemLink}, #{item.bookNumber}, #{item.productCode}, #{item.name}, #{item.brand}, #{item.specificationModel}, #{item.description}, #{item.quantityUnit}, #{item.produceCountry}, #{item.inspectionAndQuarantineCode}, #{item.hsCode}, #{item.taxRate}, #{item.declaredCount}, #{item.legalMeteringUnit}, #{item.secondDeclaredCount}, #{item.secondMeteringUnit}, #{item.grossWeight}, #{item.netWeight})
</foreach>
</insert>
</mapper>
@@ -0,0 +1,94 @@
<?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.ruoyi.custom.mapper.CustomParcelNumberMapper">
<resultMap type="CustomParcelNumber" id="CustomParcelNumberResult">
<result property="id" column="id" />
<result property="parcelNumber" column="parcel_number" />
<result property="name" column="name" />
<result property="unit" column="unit" />
<result property="price" column="price" />
<result property="taxRate" column="tax_rate" />
<result property="taxAmount" column="tax_amount" />
<result property="remark" column="remark" />
<result property="addTime" column="add_time" />
<result property="updateTime" column="update_time" />
</resultMap>
<sql id="selectCustomParcelNumberVo">
select id, parcel_number, name, unit, price, tax_rate, tax_amount, remark, add_time, update_time from custom_parcel_number
</sql>
<select id="selectCustomParcelNumberList" parameterType="CustomParcelNumber" resultMap="CustomParcelNumberResult">
<include refid="selectCustomParcelNumberVo"/>
<where>
<if test="parcelNumber != null and parcelNumber != ''"> and parcel_number = #{parcelNumber}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="unit != null and unit != ''"> and unit = #{unit}</if>
<if test="price != null "> and price = #{price}</if>
<if test="taxRate != null "> and tax_rate = #{taxRate}</if>
<if test="taxAmount != null "> and tax_amount = #{taxAmount}</if>
<if test="addTime != null "> and add_time = #{addTime}</if>
</where>
</select>
<select id="selectCustomParcelNumberById" parameterType="Long" resultMap="CustomParcelNumberResult">
<include refid="selectCustomParcelNumberVo"/>
where id = #{id}
</select>
<insert id="insertCustomParcelNumber" parameterType="CustomParcelNumber" useGeneratedKeys="true" keyProperty="id">
insert into custom_parcel_number
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="parcelNumber != null">parcel_number,</if>
<if test="name != null">name,</if>
<if test="unit != null">unit,</if>
<if test="price != null">price,</if>
<if test="taxRate != null">tax_rate,</if>
<if test="taxAmount != null">tax_amount,</if>
<if test="remark != null">remark,</if>
<if test="addTime != null">add_time,</if>
<if test="updateTime != null">update_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="parcelNumber != null">#{parcelNumber},</if>
<if test="name != null">#{name},</if>
<if test="unit != null">#{unit},</if>
<if test="price != null">#{price},</if>
<if test="taxRate != null">#{taxRate},</if>
<if test="taxAmount != null">#{taxAmount},</if>
<if test="remark != null">#{remark},</if>
<if test="addTime != null">#{addTime},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
</insert>
<update id="updateCustomParcelNumber" parameterType="CustomParcelNumber">
update custom_parcel_number
<trim prefix="SET" suffixOverrides=",">
<if test="parcelNumber != null">parcel_number = #{parcelNumber},</if>
<if test="name != null">name = #{name},</if>
<if test="unit != null">unit = #{unit},</if>
<if test="price != null">price = #{price},</if>
<if test="taxRate != null">tax_rate = #{taxRate},</if>
<if test="taxAmount != null">tax_amount = #{taxAmount},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="addTime != null">add_time = #{addTime},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomParcelNumberById" parameterType="Long">
delete from custom_parcel_number where id = #{id}
</delete>
<delete id="deleteCustomParcelNumberByIds" parameterType="String">
delete from custom_parcel_number where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,234 @@
<?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.ruoyi.custom.mapper.CustomProductRecordMapper">
<resultMap type="CustomProductRecord" id="CustomProductRecordResult">
<result property="id" column="id" />
<result property="skuCode" column="sku_code" />
<result property="barCode" column="bar_code" />
<result property="productCode" column="product_code" />
<result property="hsCode" column="hs_code" />
<result property="name" column="name" />
<result property="brand" column="brand" />
<result property="description" column="description" />
<result property="specificationModel" column="specification_model" />
<result property="produceCountry" column="produce_country" />
<result property="produceCountryCode" column="produce_country_code" />
<result property="quantityUnit" column="quantity_unit" />
<result property="quantityUnitCode" column="quantity_unit_code" />
<result property="declaredCount" column="declared_count" />
<result property="legalMeteringUnit" column="legal_metering_unit" />
<result property="legalMeteringUnitCode" column="legal_metering_unit_code" />
<result property="secondDeclaredCount" column="second_declared_count" />
<result property="secondMeteringUnit" column="second_metering_unit" />
<result property="secondMeteringUnitCode" column="second_metering_unit_code" />
<result property="price" column="price" />
<result property="grossWeight" column="gross_weight" />
<result property="netWeight" column="net_weight" />
<result property="remark" column="remark" />
<result property="inspectionAndQuarantineCode" column="inspection_and_quarantine_code" />
<result property="userId" column="user_id" />
<result property="warehouseId" column="warehouse_id" />
<result property="declarePortId" column="declare_port_id" />
<result property="taxRate" column="tax_rate" />
<result property="ingredient" column="ingredient" />
<result property="bookNumber" column="book_number" />
<result property="type" column="type" />
<result property="addTime" column="add_time" />
<result property="parcelNumber" column="parcel_number" />
<result property="parcelNumberTaxRate" column="parcel_number_tax_rate" />
<result property="englishName" column="english_name" />
<result property="dutyPrice" column="duty_price" />
<result property="taxAmount" column="tax_amount" />
<result property="updateTime" column="update_time" />
</resultMap>
<sql id="selectCustomProductRecordVo">
select id, sku_code, bar_code, product_code, hs_code, name, brand, description, specification_model, produce_country, produce_country_code, quantity_unit, quantity_unit_code, declared_count, legal_metering_unit, legal_metering_unit_code, second_declared_count, second_metering_unit, second_metering_unit_code, price, gross_weight, net_weight, remark, inspection_and_quarantine_code, user_id, warehouse_id, declare_port_id, tax_rate, ingredient, book_number, type, add_time, parcel_number, parcel_number_tax_rate, english_name, duty_price, tax_amount, update_time from custom_product_record
</sql>
<select id="selectCustomProductRecordList" parameterType="CustomProductRecord" resultMap="CustomProductRecordResult">
<include refid="selectCustomProductRecordVo"/>
<where>
<if test="skuCode != null and skuCode != ''"> and sku_code = #{skuCode}</if>
<if test="barCode != null and barCode != ''"> and bar_code = #{barCode}</if>
<if test="productCode != null and productCode != ''"> and product_code = #{productCode}</if>
<if test="hsCode != null and hsCode != ''"> and hs_code = #{hsCode}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="brand != null and brand != ''"> and brand = #{brand}</if>
<if test="description != null and description != ''"> and description = #{description}</if>
<if test="specificationModel != null and specificationModel != ''"> and specification_model = #{specificationModel}</if>
<if test="produceCountry != null and produceCountry != ''"> and produce_country = #{produceCountry}</if>
<if test="produceCountryCode != null and produceCountryCode != ''"> and produce_country_code = #{produceCountryCode}</if>
<if test="quantityUnit != null and quantityUnit != ''"> and quantity_unit = #{quantityUnit}</if>
<if test="quantityUnitCode != null and quantityUnitCode != ''"> and quantity_unit_code = #{quantityUnitCode}</if>
<if test="declaredCount != null "> and declared_count = #{declaredCount}</if>
<if test="legalMeteringUnit != null and legalMeteringUnit != ''"> and legal_metering_unit = #{legalMeteringUnit}</if>
<if test="legalMeteringUnitCode != null and legalMeteringUnitCode != ''"> and legal_metering_unit_code = #{legalMeteringUnitCode}</if>
<if test="secondDeclaredCount != null "> and second_declared_count = #{secondDeclaredCount}</if>
<if test="secondMeteringUnit != null and secondMeteringUnit != ''"> and second_metering_unit = #{secondMeteringUnit}</if>
<if test="secondMeteringUnitCode != null and secondMeteringUnitCode != ''"> and second_metering_unit_code = #{secondMeteringUnitCode}</if>
<if test="price != null "> and price = #{price}</if>
<if test="grossWeight != null "> and gross_weight = #{grossWeight}</if>
<if test="netWeight != null "> and net_weight = #{netWeight}</if>
<if test="inspectionAndQuarantineCode != null and inspectionAndQuarantineCode != ''"> and inspection_and_quarantine_code = #{inspectionAndQuarantineCode}</if>
<if test="userId != null "> and user_id = #{userId}</if>
<if test="warehouseId != null "> and warehouse_id = #{warehouseId}</if>
<if test="declarePortId != null "> and declare_port_id = #{declarePortId}</if>
<if test="taxRate != null "> and tax_rate = #{taxRate}</if>
<if test="ingredient != null and ingredient != ''"> and ingredient = #{ingredient}</if>
<if test="bookNumber != null and bookNumber != ''"> and book_number = #{bookNumber}</if>
<if test="type != null "> and type = #{type}</if>
<if test="addTime != null "> and add_time = #{addTime}</if>
<if test="parcelNumber != null and parcelNumber != ''"> and parcel_number = #{parcelNumber}</if>
<if test="parcelNumberTaxRate != null "> and parcel_number_tax_rate = #{parcelNumberTaxRate}</if>
<if test="englishName != null and englishName != ''"> and english_name like concat('%', #{englishName}, '%')</if>
<if test="dutyPrice != null "> and duty_price = #{dutyPrice}</if>
<if test="taxAmount != null "> and tax_amount = #{taxAmount}</if>
</where>
</select>
<select id="selectCustomProductRecordById" parameterType="Long" resultMap="CustomProductRecordResult">
<include refid="selectCustomProductRecordVo"/>
where id = #{id}
</select>
<insert id="insertCustomProductRecord" parameterType="CustomProductRecord" useGeneratedKeys="true" keyProperty="id">
insert into custom_product_record
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="skuCode != null and skuCode != ''">sku_code,</if>
<if test="barCode != null and barCode != ''">bar_code,</if>
<if test="productCode != null">product_code,</if>
<if test="hsCode != null and hsCode != ''">hs_code,</if>
<if test="name != null and name != ''">name,</if>
<if test="brand != null and brand != ''">brand,</if>
<if test="description != null and description != ''">description,</if>
<if test="specificationModel != null and specificationModel != ''">specification_model,</if>
<if test="produceCountry != null and produceCountry != ''">produce_country,</if>
<if test="produceCountryCode != null and produceCountryCode != ''">produce_country_code,</if>
<if test="quantityUnit != null and quantityUnit != ''">quantity_unit,</if>
<if test="quantityUnitCode != null and quantityUnitCode != ''">quantity_unit_code,</if>
<if test="declaredCount != null">declared_count,</if>
<if test="legalMeteringUnit != null and legalMeteringUnit != ''">legal_metering_unit,</if>
<if test="legalMeteringUnitCode != null and legalMeteringUnitCode != ''">legal_metering_unit_code,</if>
<if test="secondDeclaredCount != null">second_declared_count,</if>
<if test="secondMeteringUnit != null">second_metering_unit,</if>
<if test="secondMeteringUnitCode != null">second_metering_unit_code,</if>
<if test="price != null">price,</if>
<if test="grossWeight != null">gross_weight,</if>
<if test="netWeight != null">net_weight,</if>
<if test="remark != null">remark,</if>
<if test="inspectionAndQuarantineCode != null">inspection_and_quarantine_code,</if>
<if test="userId != null">user_id,</if>
<if test="warehouseId != null">warehouse_id,</if>
<if test="declarePortId != null">declare_port_id,</if>
<if test="taxRate != null">tax_rate,</if>
<if test="ingredient != null">ingredient,</if>
<if test="bookNumber != null">book_number,</if>
<if test="type != null">type,</if>
<if test="addTime != null">add_time,</if>
<if test="parcelNumber != null">parcel_number,</if>
<if test="parcelNumberTaxRate != null">parcel_number_tax_rate,</if>
<if test="englishName != null">english_name,</if>
<if test="dutyPrice != null">duty_price,</if>
<if test="taxAmount != null">tax_amount,</if>
<if test="updateTime != null">update_time,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="skuCode != null and skuCode != ''">#{skuCode},</if>
<if test="barCode != null and barCode != ''">#{barCode},</if>
<if test="productCode != null">#{productCode},</if>
<if test="hsCode != null and hsCode != ''">#{hsCode},</if>
<if test="name != null and name != ''">#{name},</if>
<if test="brand != null and brand != ''">#{brand},</if>
<if test="description != null and description != ''">#{description},</if>
<if test="specificationModel != null and specificationModel != ''">#{specificationModel},</if>
<if test="produceCountry != null and produceCountry != ''">#{produceCountry},</if>
<if test="produceCountryCode != null and produceCountryCode != ''">#{produceCountryCode},</if>
<if test="quantityUnit != null and quantityUnit != ''">#{quantityUnit},</if>
<if test="quantityUnitCode != null and quantityUnitCode != ''">#{quantityUnitCode},</if>
<if test="declaredCount != null">#{declaredCount},</if>
<if test="legalMeteringUnit != null and legalMeteringUnit != ''">#{legalMeteringUnit},</if>
<if test="legalMeteringUnitCode != null and legalMeteringUnitCode != ''">#{legalMeteringUnitCode},</if>
<if test="secondDeclaredCount != null">#{secondDeclaredCount},</if>
<if test="secondMeteringUnit != null">#{secondMeteringUnit},</if>
<if test="secondMeteringUnitCode != null">#{secondMeteringUnitCode},</if>
<if test="price != null">#{price},</if>
<if test="grossWeight != null">#{grossWeight},</if>
<if test="netWeight != null">#{netWeight},</if>
<if test="remark != null">#{remark},</if>
<if test="inspectionAndQuarantineCode != null">#{inspectionAndQuarantineCode},</if>
<if test="userId != null">#{userId},</if>
<if test="warehouseId != null">#{warehouseId},</if>
<if test="declarePortId != null">#{declarePortId},</if>
<if test="taxRate != null">#{taxRate},</if>
<if test="ingredient != null">#{ingredient},</if>
<if test="bookNumber != null">#{bookNumber},</if>
<if test="type != null">#{type},</if>
<if test="addTime != null">#{addTime},</if>
<if test="parcelNumber != null">#{parcelNumber},</if>
<if test="parcelNumberTaxRate != null">#{parcelNumberTaxRate},</if>
<if test="englishName != null">#{englishName},</if>
<if test="dutyPrice != null">#{dutyPrice},</if>
<if test="taxAmount != null">#{taxAmount},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
</insert>
<update id="updateCustomProductRecord" parameterType="CustomProductRecord">
update custom_product_record
<trim prefix="SET" suffixOverrides=",">
<if test="skuCode != null and skuCode != ''">sku_code = #{skuCode},</if>
<if test="barCode != null and barCode != ''">bar_code = #{barCode},</if>
<if test="productCode != null">product_code = #{productCode},</if>
<if test="hsCode != null and hsCode != ''">hs_code = #{hsCode},</if>
<if test="name != null and name != ''">name = #{name},</if>
<if test="brand != null and brand != ''">brand = #{brand},</if>
<if test="description != null and description != ''">description = #{description},</if>
<if test="specificationModel != null and specificationModel != ''">specification_model = #{specificationModel},</if>
<if test="produceCountry != null and produceCountry != ''">produce_country = #{produceCountry},</if>
<if test="produceCountryCode != null and produceCountryCode != ''">produce_country_code = #{produceCountryCode},</if>
<if test="quantityUnit != null and quantityUnit != ''">quantity_unit = #{quantityUnit},</if>
<if test="quantityUnitCode != null and quantityUnitCode != ''">quantity_unit_code = #{quantityUnitCode},</if>
<if test="declaredCount != null">declared_count = #{declaredCount},</if>
<if test="legalMeteringUnit != null and legalMeteringUnit != ''">legal_metering_unit = #{legalMeteringUnit},</if>
<if test="legalMeteringUnitCode != null and legalMeteringUnitCode != ''">legal_metering_unit_code = #{legalMeteringUnitCode},</if>
<if test="secondDeclaredCount != null">second_declared_count = #{secondDeclaredCount},</if>
<if test="secondMeteringUnit != null">second_metering_unit = #{secondMeteringUnit},</if>
<if test="secondMeteringUnitCode != null">second_metering_unit_code = #{secondMeteringUnitCode},</if>
<if test="price != null">price = #{price},</if>
<if test="grossWeight != null">gross_weight = #{grossWeight},</if>
<if test="netWeight != null">net_weight = #{netWeight},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="inspectionAndQuarantineCode != null">inspection_and_quarantine_code = #{inspectionAndQuarantineCode},</if>
<if test="userId != null">user_id = #{userId},</if>
<if test="warehouseId != null">warehouse_id = #{warehouseId},</if>
<if test="declarePortId != null">declare_port_id = #{declarePortId},</if>
<if test="taxRate != null">tax_rate = #{taxRate},</if>
<if test="ingredient != null">ingredient = #{ingredient},</if>
<if test="bookNumber != null">book_number = #{bookNumber},</if>
<if test="type != null">type = #{type},</if>
<if test="addTime != null">add_time = #{addTime},</if>
<if test="parcelNumber != null">parcel_number = #{parcelNumber},</if>
<if test="parcelNumberTaxRate != null">parcel_number_tax_rate = #{parcelNumberTaxRate},</if>
<if test="englishName != null">english_name = #{englishName},</if>
<if test="dutyPrice != null">duty_price = #{dutyPrice},</if>
<if test="taxAmount != null">tax_amount = #{taxAmount},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomProductRecordById" parameterType="Long">
delete from custom_product_record where id = #{id}
</delete>
<delete id="deleteCustomProductRecordByIds" parameterType="String">
delete from custom_product_record where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,75 @@
<?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.ruoyi.custom.mapper.CustomRegionCodeMapper">
<resultMap type="CustomRegionCode" id="CustomRegionCodeResult">
<result property="id" column="id" />
<result property="parentId" column="parent_id" />
<result property="code" column="code" />
<result property="name" column="name" />
<result property="remark" column="remark" />
<result property="grade" column="grade" />
</resultMap>
<sql id="selectCustomRegionCodeVo">
select id, parent_id, code, name, remark, grade from custom_region_code
</sql>
<select id="selectCustomRegionCodeList" parameterType="CustomRegionCode" resultMap="CustomRegionCodeResult">
<include refid="selectCustomRegionCodeVo"/>
<where>
<if test="parentId != null "> and parent_id = #{parentId}</if>
<if test="code != null and code != ''"> and code = #{code}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="grade != null "> and grade = #{grade}</if>
</where>
</select>
<select id="selectCustomRegionCodeById" parameterType="Long" resultMap="CustomRegionCodeResult">
<include refid="selectCustomRegionCodeVo"/>
where id = #{id}
</select>
<insert id="insertCustomRegionCode" parameterType="CustomRegionCode" useGeneratedKeys="true" keyProperty="id">
insert into custom_region_code
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="parentId != null">parent_id,</if>
<if test="code != null">code,</if>
<if test="name != null">name,</if>
<if test="remark != null">remark,</if>
<if test="grade != null">grade,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="parentId != null">#{parentId},</if>
<if test="code != null">#{code},</if>
<if test="name != null">#{name},</if>
<if test="remark != null">#{remark},</if>
<if test="grade != null">#{grade},</if>
</trim>
</insert>
<update id="updateCustomRegionCode" parameterType="CustomRegionCode">
update custom_region_code
<trim prefix="SET" suffixOverrides=",">
<if test="parentId != null">parent_id = #{parentId},</if>
<if test="code != null">code = #{code},</if>
<if test="name != null">name = #{name},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="grade != null">grade = #{grade},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomRegionCodeById" parameterType="Long">
delete from custom_region_code where id = #{id}
</delete>
<delete id="deleteCustomRegionCodeByIds" parameterType="String">
delete from custom_region_code where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,65 @@
<?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.ruoyi.custom.mapper.CustomUnitCodeMapper">
<resultMap type="CustomUnitCode" id="CustomUnitCodeResult">
<result property="id" column="id" />
<result property="code" column="code" />
<result property="name" column="name" />
<result property="remark" column="remark" />
</resultMap>
<sql id="selectCustomUnitCodeVo">
select id, code, name, remark from custom_unit_code
</sql>
<select id="selectCustomUnitCodeList" parameterType="CustomUnitCode" resultMap="CustomUnitCodeResult">
<include refid="selectCustomUnitCodeVo"/>
<where>
<if test="code != null and code != ''"> and code = #{code}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
</where>
</select>
<select id="selectCustomUnitCodeById" parameterType="Long" resultMap="CustomUnitCodeResult">
<include refid="selectCustomUnitCodeVo"/>
where id = #{id}
</select>
<insert id="insertCustomUnitCode" parameterType="CustomUnitCode" useGeneratedKeys="true" keyProperty="id">
insert into custom_unit_code
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="code != null and code != ''">code,</if>
<if test="name != null and name != ''">name,</if>
<if test="remark != null">remark,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="code != null and code != ''">#{code},</if>
<if test="name != null and name != ''">#{name},</if>
<if test="remark != null">#{remark},</if>
</trim>
</insert>
<update id="updateCustomUnitCode" parameterType="CustomUnitCode">
update custom_unit_code
<trim prefix="SET" suffixOverrides=",">
<if test="code != null and code != ''">code = #{code},</if>
<if test="name != null and name != ''">name = #{name},</if>
<if test="remark != null">remark = #{remark},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomUnitCodeById" parameterType="Long">
delete from custom_unit_code where id = #{id}
</delete>
<delete id="deleteCustomUnitCodeByIds" parameterType="String">
delete from custom_unit_code where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
@@ -0,0 +1,111 @@
<?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.ruoyi.custom.mapper.CustomWarehouseMapper">
<resultMap type="CustomWarehouse" id="CustomWarehouseResult">
<result property="id" column="id" />
<result property="declarePortId" column="declare_port_id" />
<result property="name" column="name" />
<result property="code" column="code" />
<result property="describe" column="describe" />
<result property="consignor" column="consignor" />
<result property="consignorAddress" column="consignor_address" />
<result property="consignorTelephone" column="consignor_telephone" />
<result property="consignorCountry" column="consignor_country" />
<result property="consignorProvince" column="consignor_province" />
<result property="consignorCity" column="consignor_city" />
<result property="consignorDistrict" column="consignor_district" />
<result property="type" column="type" />
</resultMap>
<sql id="selectCustomWarehouseVo">
select id, declare_port_id, name, code, describe, consignor, consignor_address, consignor_telephone, consignor_country, consignor_province, consignor_city, consignor_district, type from custom_warehouse
</sql>
<select id="selectCustomWarehouseList" parameterType="CustomWarehouse" resultMap="CustomWarehouseResult">
<include refid="selectCustomWarehouseVo"/>
<where>
<if test="declarePortId != null "> and declare_port_id = #{declarePortId}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="code != null and code != ''"> and code = #{code}</if>
<if test="describe != null and describe != ''"> and describe = #{describe}</if>
<if test="consignor != null and consignor != ''"> and consignor = #{consignor}</if>
<if test="consignorAddress != null and consignorAddress != ''"> and consignor_address = #{consignorAddress}</if>
<if test="consignorTelephone != null and consignorTelephone != ''"> and consignor_telephone = #{consignorTelephone}</if>
<if test="consignorCountry != null and consignorCountry != ''"> and consignor_country = #{consignorCountry}</if>
<if test="consignorProvince != null and consignorProvince != ''"> and consignor_province = #{consignorProvince}</if>
<if test="consignorCity != null and consignorCity != ''"> and consignor_city = #{consignorCity}</if>
<if test="consignorDistrict != null and consignorDistrict != ''"> and consignor_district = #{consignorDistrict}</if>
<if test="type != null "> and type = #{type}</if>
</where>
</select>
<select id="selectCustomWarehouseById" parameterType="Long" resultMap="CustomWarehouseResult">
<include refid="selectCustomWarehouseVo"/>
where id = #{id}
</select>
<insert id="insertCustomWarehouse" parameterType="CustomWarehouse" useGeneratedKeys="true" keyProperty="id">
insert into custom_warehouse
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="declarePortId != null">declare_port_id,</if>
<if test="name != null">name,</if>
<if test="code != null">code,</if>
<if test="describe != null">describe,</if>
<if test="consignor != null">consignor,</if>
<if test="consignorAddress != null">consignor_address,</if>
<if test="consignorTelephone != null">consignor_telephone,</if>
<if test="consignorCountry != null">consignor_country,</if>
<if test="consignorProvince != null">consignor_province,</if>
<if test="consignorCity != null">consignor_city,</if>
<if test="consignorDistrict != null">consignor_district,</if>
<if test="type != null">type,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="declarePortId != null">#{declarePortId},</if>
<if test="name != null">#{name},</if>
<if test="code != null">#{code},</if>
<if test="describe != null">#{describe},</if>
<if test="consignor != null">#{consignor},</if>
<if test="consignorAddress != null">#{consignorAddress},</if>
<if test="consignorTelephone != null">#{consignorTelephone},</if>
<if test="consignorCountry != null">#{consignorCountry},</if>
<if test="consignorProvince != null">#{consignorProvince},</if>
<if test="consignorCity != null">#{consignorCity},</if>
<if test="consignorDistrict != null">#{consignorDistrict},</if>
<if test="type != null">#{type},</if>
</trim>
</insert>
<update id="updateCustomWarehouse" parameterType="CustomWarehouse">
update custom_warehouse
<trim prefix="SET" suffixOverrides=",">
<if test="declarePortId != null">declare_port_id = #{declarePortId},</if>
<if test="name != null">name = #{name},</if>
<if test="code != null">code = #{code},</if>
<if test="describe != null">describe = #{describe},</if>
<if test="consignor != null">consignor = #{consignor},</if>
<if test="consignorAddress != null">consignor_address = #{consignorAddress},</if>
<if test="consignorTelephone != null">consignor_telephone = #{consignorTelephone},</if>
<if test="consignorCountry != null">consignor_country = #{consignorCountry},</if>
<if test="consignorProvince != null">consignor_province = #{consignorProvince},</if>
<if test="consignorCity != null">consignor_city = #{consignorCity},</if>
<if test="consignorDistrict != null">consignor_district = #{consignorDistrict},</if>
<if test="type != null">type = #{type},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteCustomWarehouseById" parameterType="Long">
delete from custom_warehouse where id = #{id}
</delete>
<delete id="deleteCustomWarehouseByIds" parameterType="String">
delete from custom_warehouse where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>