This commit is contained in:
linfso 2024-04-11 12:31:24 +08:00
parent 29fa518bda
commit 6dff931118
6 changed files with 140 additions and 97 deletions

View File

@ -2,7 +2,7 @@
* @Project: emis
* @Title: EmisCountry.java
* @author linfso
* @date 2024-04-10 07:21:30
* @date 2024-04-11 03:47:51
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 国家 实体类 </p>
@ -26,7 +26,7 @@ import lombok.Data;
* @ClassName EmisCountry
* @Description 国家
* @author linfso
* @date 2024-04-10 07:21:30
* @date 2024-04-11 03:47:51
*/
@Data
public class EmisCountry extends BaseEntity
@ -53,5 +53,9 @@ public class EmisCountry extends BaseEntity
private String twoCode;
/* 三字码 */
private String threeCode;
/* 创建网点 */
private String createSite;
/* 更新网点 */
private String updateSite;
}

View File

@ -1,10 +1,10 @@
/**
/**
* @Project: emis
* @Title: EmisCountryArea.java
* @author linfso
* @date 2023-11-16 16:18:40
* @date 2024-04-11 04:29:45
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @version v1.0
* @Description: <p> 国家大区表 实体类 </p>
*/
@ -17,6 +17,7 @@ import com.xdadan.erp.common.annotation.Excel;
import com.xdadan.erp.common.core.domain.BaseEntity;
import com.xdadan.erp.common.core.domain.TreeEntity;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.Data;
@ -25,9 +26,9 @@ import lombok.Data;
* @ClassName EmisCountryArea
* @Description 国家大区表
* @author linfso
* @date 2023-11-16 16:18:40
* @date 2024-04-11 04:29:45
*/
@Data
@Data
public class EmisCountryArea extends BaseEntity
{
private static final long serialVersionUID = 1L;
@ -38,9 +39,13 @@ public class EmisCountryArea extends BaseEntity
private String name;
/* 英文名称 */
private String nameEn;
/* 编码 */
private String code;
/* 国家id */
private Integer countryId;
/* 国家编码 */
private String countryCode;
/* 国际名称 */
private String countryName;
/* 创建网点 */
private String createSite;
/* 更新网点 */
private String updateSite;
}

View File

@ -2,7 +2,7 @@
* @Project: emis
* @Title: EmisRegion.java
* @author linfso
* @date 2023-12-13 05:49:14
* @date 2024-04-11 04:30:28
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 四级省市区镇表 实体类 </p>
@ -17,6 +17,7 @@ import com.xdadan.erp.common.annotation.Excel;
import com.xdadan.erp.common.core.domain.BaseEntity;
import com.xdadan.erp.common.core.domain.TreeEntity;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.Data;
@ -25,7 +26,7 @@ import lombok.Data;
* @ClassName EmisRegion
* @Description 四级省市区镇表
* @author linfso
* @date 2023-12-13 05:49:14
* @date 2024-04-11 04:30:28
*/
@Data
public class EmisRegion extends BaseEntity
@ -33,30 +34,34 @@ public class EmisRegion extends BaseEntity
private static final long serialVersionUID = 1L;
/* id */
private Integer id;
private Long id;
/* 代码 */
private String regionCode;
/* 区域名称 */
private String regionName;
/* 英文名称 */
private String regionNameEn;
/* 类型 1-省 2-市 3-区 4-镇 */
private Integer regionType;
/* 简称 */
private String shortName;
/* 父区域 */
private Integer parentId;
/* 代码 */
private String code;
/* 国家id */
private Integer countryId;
/* 国家大区id */
private Long countryAreaId;
/* 类型 */
private Integer regionType;
/* 邮编 */
private String zipCode;
/* 区域名称 */
/* 父代码 */
private String parentCode;
/* 所属片区id */
private Long areaId;
/* 所属片区名称 */
private String areaName;
/* 国家代码 */
private String countryCode;
/* 国家名称 */
private String countryName;
/* 邮编 */
private String zipCode;
/* 显示顺序 */
private Integer orderNum;
/* 创建网点 */
private String createSite;
/* 更新网点 */
private String updateSite;
}

View File

@ -1,15 +1,15 @@
<?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">
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.xdadan.erp.emis.mapper.EmisCountryAreaMapper">
<resultMap type="EmisCountryArea" id="EmisCountryAreaResult">
<result property="id" column="id" />
<result property="name" column="name" />
<result property="nameEn" column="name_en" />
<result property="code" column="code" />
<result property="countryId" column="country_id" />
<result property="countryCode" column="country_code" />
<result property="countryName" column="country_name" />
<result property="remark" column="remark" />
<result property="tenantId" column="tenant_id" />
<result property="delFlag" column="del_flag" />
@ -17,20 +17,22 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="createSite" column="create_site" />
<result property="updateSite" column="update_site" />
</resultMap>
<sql id="selectEmisCountryAreaVo">
select id, name, name_en, code, country_id, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time from emis_country_area
select id, name, name_en, country_code, country_name, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site from emis_country_area
</sql>
<select id="selectEmisCountryAreaList" parameterType="EmisCountryArea" resultMap="EmisCountryAreaResult">
<include refid="selectEmisCountryAreaVo"/>
<where>
<where>
<if test="id != null "> and id = #{id}</if>
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
<if test="nameEn != null and nameEn != ''"> and name_en like concat('%', #{nameEn}, '%')</if>
<if test="code != null and code != ''"> and code like concat('%', #{code}, '%')</if>
<if test="countryId != null "> and country_id = #{countryId}</if>
<if test="countryCode != null and countryCode != ''"> and country_code like concat('%', #{countryCode}, '%')</if>
<if test="countryName != null and countryName != ''"> and country_name like concat('%', #{countryName}, '%')</if>
<if test="remark != null and remark != ''"> and remark like concat('%', #{remark}, '%')</if>
<if test="tenantId != null and tenantId != ''"> and tenant_id like concat('%', #{tenantId}, '%')</if>
<if test="delFlag != null and delFlag != ''"> and del_flag like concat('%', #{delFlag}, '%')</if>
@ -38,24 +40,26 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null "> and create_time = #{createTime}</if>
<if test="updateBy != null and updateBy != ''"> and update_by like concat('%', #{updateBy}, '%')</if>
<if test="updateTime != null "> and update_time = #{updateTime}</if>
<if test="createSite != null and createSite != ''"> and create_site like concat('%', #{createSite}, '%')</if>
<if test="updateSite != null and updateSite != ''"> and update_site like concat('%', #{updateSite}, '%')</if>
</where>
order by create_time desc
</select>
<select id="selectEmisCountryAreaById" parameterType="Long" resultMap="EmisCountryAreaResult">
select id, name, name_en, code, country_id, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time
select id, name, name_en, country_code, country_name, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site
from emis_country_area a
where a.id = #{id}
</select>
<insert id="insertEmisCountryArea" parameterType="EmisCountryArea">
insert into emis_country_area
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">id,</if>
<if test="name != null and name != ''">name,</if>
<if test="nameEn != null and nameEn != ''">name_en,</if>
<if test="code != null and code != ''">code,</if>
<if test="countryId != null">country_id,</if>
<if test="countryCode != null and countryCode != ''">country_code,</if>
<if test="countryName != null and countryName != ''">country_name,</if>
<if test="remark != null and remark != ''">remark,</if>
<if test="tenantId != null and tenantId != ''">tenant_id,</if>
<if test="delFlag != null and delFlag != ''">del_flag,</if>
@ -63,13 +67,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null">create_time,</if>
<if test="updateBy != null and updateBy != ''">update_by,</if>
<if test="updateTime != null">update_time,</if>
</trim>
<if test="createSite != null and createSite != ''">create_site,</if>
<if test="updateSite != null and updateSite != ''">update_site,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if>
<if test="name != null and name != ''">#{name},</if>
<if test="nameEn != null and nameEn != ''">#{nameEn},</if>
<if test="code != null and code != ''">#{code},</if>
<if test="countryId != null">#{countryId},</if>
<if test="countryCode != null and countryCode != ''">#{countryCode},</if>
<if test="countryName != null and countryName != ''">#{countryName},</if>
<if test="remark != null and remark != ''">#{remark},</if>
<if test="tenantId != null and tenantId != ''">#{tenantId},</if>
<if test="delFlag != null and delFlag != ''">#{delFlag},</if>
@ -77,7 +83,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null and updateBy != ''">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
<if test="createSite != null and createSite != ''">#{createSite},</if>
<if test="updateSite != null and updateSite != ''">#{updateSite},</if>
</trim>
</insert>
<update id="updateEmisCountryArea" parameterType="EmisCountryArea">
@ -85,8 +93,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<trim prefix="SET" suffixOverrides=",">
<if test="name != null and name != ''">name = #{name},</if>
<if test="nameEn != null and nameEn != ''">name_en = #{nameEn},</if>
<if test="code != null and code != ''">code = #{code},</if>
<if test="countryId != null">country_id = #{countryId},</if>
<if test="countryCode != null and countryCode != ''">country_code = #{countryCode},</if>
<if test="countryName != null and countryName != ''">country_name = #{countryName},</if>
<if test="remark != null and remark != ''">remark = #{remark},</if>
<if test="tenantId != null and tenantId != ''">tenant_id = #{tenantId},</if>
<if test="delFlag != null and delFlag != ''">del_flag = #{delFlag},</if>
@ -94,6 +102,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="createSite != null and createSite != ''">create_site = #{createSite},</if>
<if test="updateSite != null and updateSite != ''">update_site = #{updateSite},</if>
</trim>
where id = #{id}
</update>
@ -103,7 +113,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</delete>
<delete id="deleteEmisCountryAreaByIds" parameterType="String">
delete from emis_country_area where id in
delete from emis_country_area where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>

View File

@ -22,10 +22,12 @@
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="createSite" column="create_site" />
<result property="updateSite" column="update_site" />
</resultMap>
<sql id="selectEmisCountryVo">
select id, name, name_en, code, tel_area_code, iso_code, continent_id, order_num, two_code, three_code, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time from emis_country
select id, name, name_en, code, tel_area_code, iso_code, continent_id, order_num, two_code, three_code, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site from emis_country
</sql>
<select id="selectEmisCountryList" parameterType="EmisCountry" resultMap="EmisCountryResult">
@ -37,8 +39,7 @@
<if test="code != null and code != ''"> and code like concat('%', #{code}, '%')</if>
<if test="telAreaCode != null and telAreaCode != ''"> and tel_area_code like concat('%', #{telAreaCode}, '%')</if>
<if test="isoCode != null and isoCode != ''"> and iso_code like concat('%', #{isoCode}, '%')</if>
<if test="continentId != null and continentId != ''"> and find_in_set(#{continentId},continent_id)</if>
<if test="orderNum != null "> and order_num = #{orderNum}</if>
<if test="continentId != null and continentId != ''"> and find_in_set(#{continentId},continent_id)</if> <if test="orderNum != null "> and order_num = #{orderNum}</if>
<if test="twoCode != null and twoCode != ''"> and two_code like concat('%', #{twoCode}, '%')</if>
<if test="threeCode != null and threeCode != ''"> and three_code like concat('%', #{threeCode}, '%')</if>
<if test="remark != null and remark != ''"> and remark like concat('%', #{remark}, '%')</if>
@ -48,12 +49,14 @@
<if test="createTime != null "> and create_time = #{createTime}</if>
<if test="updateBy != null and updateBy != ''"> and update_by like concat('%', #{updateBy}, '%')</if>
<if test="updateTime != null "> and update_time = #{updateTime}</if>
<if test="createSite != null and createSite != ''"> and create_site like concat('%', #{createSite}, '%')</if>
<if test="updateSite != null and updateSite != ''"> and update_site like concat('%', #{updateSite}, '%')</if>
</where>
order by create_time desc
</select>
<select id="selectEmisCountryById" parameterType="Integer" resultMap="EmisCountryResult">
select id, name, name_en, code, tel_area_code, iso_code, continent_id, order_num, two_code, three_code, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time
select id, name, name_en, code, tel_area_code, iso_code, continent_id, order_num, two_code, three_code, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site
from emis_country a
where a.id = #{id}
</select>
@ -78,6 +81,8 @@
<if test="createTime != null">create_time,</if>
<if test="updateBy != null and updateBy != ''">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="createSite != null and createSite != ''">create_site,</if>
<if test="updateSite != null and updateSite != ''">update_site,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if>
@ -97,6 +102,8 @@
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null and updateBy != ''">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="createSite != null and createSite != ''">#{createSite},</if>
<if test="updateSite != null and updateSite != ''">#{updateSite},</if>
</trim>
</insert>
@ -119,6 +126,8 @@
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="createSite != null and createSite != ''">create_site = #{createSite},</if>
<if test="updateSite != null and updateSite != ''">update_site = #{updateSite},</if>
</trim>
where id = #{id}
</update>

View File

@ -6,15 +6,18 @@
<resultMap type="EmisRegion" id="EmisRegionResult">
<result property="id" column="id" />
<result property="regionCode" column="region_code" />
<result property="regionName" column="region_name" />
<result property="regionNameEn" column="region_name_en" />
<result property="shortName" column="short_name" />
<result property="parentId" column="parent_id" />
<result property="code" column="code" />
<result property="countryId" column="country_id" />
<result property="countryAreaId" column="country_area_id" />
<result property="regionType" column="region_type" />
<result property="shortName" column="short_name" />
<result property="parentCode" column="parent_code" />
<result property="areaId" column="area_id" />
<result property="areaName" column="area_name" />
<result property="countryCode" column="country_code" />
<result property="countryName" column="country_name" />
<result property="zipCode" column="zip_code" />
<result property="orderNum" column="order_num" />
<result property="remark" column="remark" />
<result property="tenantId" column="tenant_id" />
<result property="delFlag" column="del_flag" />
@ -22,28 +25,30 @@
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="areaName" column="area_name" />
<result property="countryCode" column="country_code" />
<result property="countryName" column="country_name" />
<result property="createSite" column="create_site" />
<result property="updateSite" column="update_site" />
</resultMap>
<sql id="selectEmisRegionVo">
select id, region_name, region_name_en, short_name, parent_id, code, country_id, country_area_id, region_type, zip_code, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, area_name, country_code, country_name from emis_region
select id, region_code, region_name, region_name_en, region_type, short_name, parent_code, area_id, area_name, country_code, country_name, zip_code, order_num, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site from emis_region
</sql>
<select id="selectEmisRegionList" parameterType="EmisRegion" resultMap="EmisRegionResult">
<include refid="selectEmisRegionVo"/>
<where>
<if test="id != null "> and id = #{id}</if>
<if test="regionCode != null and regionCode != ''"> and region_code like concat('%', #{regionCode}, '%')</if>
<if test="regionName != null and regionName != ''"> and region_name like concat('%', #{regionName}, '%')</if>
<if test="regionNameEn != null and regionNameEn != ''"> and region_name_en like concat('%', #{regionNameEn}, '%')</if>
<if test="shortName != null and shortName != ''"> and short_name like concat('%', #{shortName}, '%')</if>
<if test="parentId != null "> and parent_id = #{parentId}</if>
<if test="code != null and code != ''"> and code like concat('%', #{code}, '%')</if>
<if test="countryId != null "> and country_id = #{countryId}</if>
<if test="countryAreaId != null "> and country_area_id = #{countryAreaId}</if>
<if test="regionType != null "> and region_type = #{regionType}</if>
<if test="shortName != null and shortName != ''"> and short_name like concat('%', #{shortName}, '%')</if>
<if test="parentCode != null and parentCode != ''"> and parent_code like concat('%', #{parentCode}, '%')</if>
<if test="areaId != null "> and area_id = #{areaId}</if>
<if test="areaName != null and areaName != ''"> and area_name like concat('%', #{areaName}, '%')</if>
<if test="countryCode != null and countryCode != ''"> and country_code like concat('%', #{countryCode}, '%')</if>
<if test="countryName != null and countryName != ''"> and country_name like concat('%', #{countryName}, '%')</if>
<if test="zipCode != null and zipCode != ''"> and zip_code like concat('%', #{zipCode}, '%')</if>
<if test="orderNum != null "> and order_num = #{orderNum}</if>
<if test="remark != null and remark != ''"> and remark like concat('%', #{remark}, '%')</if>
<if test="tenantId != null and tenantId != ''"> and tenant_id like concat('%', #{tenantId}, '%')</if>
<if test="delFlag != null and delFlag != ''"> and del_flag like concat('%', #{delFlag}, '%')</if>
@ -51,15 +56,14 @@
<if test="createTime != null "> and create_time = #{createTime}</if>
<if test="updateBy != null and updateBy != ''"> and update_by like concat('%', #{updateBy}, '%')</if>
<if test="updateTime != null "> and update_time = #{updateTime}</if>
<if test="areaName != null and areaName != ''"> and area_name like concat('%', #{areaName}, '%')</if>
<if test="countryCode != null and countryCode != ''"> and country_code like concat('%', #{countryCode}, '%')</if>
<if test="countryName != null and countryName != ''"> and country_name like concat('%', #{countryName}, '%')</if>
<if test="createSite != null and createSite != ''"> and create_site like concat('%', #{createSite}, '%')</if>
<if test="updateSite != null and updateSite != ''"> and update_site like concat('%', #{updateSite}, '%')</if>
</where>
order by id asc
order by create_time desc
</select>
<select id="selectEmisRegionById" parameterType="Integer" resultMap="EmisRegionResult">
select id, region_name, region_name_en, short_name, parent_id, code, country_id, country_area_id, region_type, zip_code, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, area_name, country_code, country_name
<select id="selectEmisRegionById" parameterType="Long" resultMap="EmisRegionResult">
select id, region_code, region_name, region_name_en, region_type, short_name, parent_code, area_id, area_name, country_code, country_name, zip_code, order_num, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site
from emis_region a
where a.id = #{id}
</select>
@ -68,15 +72,18 @@
insert into emis_region
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">id,</if>
<if test="regionCode != null and regionCode != ''">region_code,</if>
<if test="regionName != null and regionName != ''">region_name,</if>
<if test="regionNameEn != null and regionNameEn != ''">region_name_en,</if>
<if test="shortName != null and shortName != ''">short_name,</if>
<if test="parentId != null">parent_id,</if>
<if test="code != null and code != ''">code,</if>
<if test="countryId != null">country_id,</if>
<if test="countryAreaId != null">country_area_id,</if>
<if test="regionType != null">region_type,</if>
<if test="shortName != null and shortName != ''">short_name,</if>
<if test="parentCode != null and parentCode != ''">parent_code,</if>
<if test="areaId != null">area_id,</if>
<if test="areaName != null and areaName != ''">area_name,</if>
<if test="countryCode != null and countryCode != ''">country_code,</if>
<if test="countryName != null and countryName != ''">country_name,</if>
<if test="zipCode != null and zipCode != ''">zip_code,</if>
<if test="orderNum != null">order_num,</if>
<if test="remark != null and remark != ''">remark,</if>
<if test="tenantId != null and tenantId != ''">tenant_id,</if>
<if test="delFlag != null and delFlag != ''">del_flag,</if>
@ -84,21 +91,23 @@
<if test="createTime != null">create_time,</if>
<if test="updateBy != null and updateBy != ''">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="areaName != null and areaName != ''">area_name,</if>
<if test="countryCode != null and countryCode != ''">country_code,</if>
<if test="countryName != null and countryName != ''">country_name,</if>
<if test="createSite != null and createSite != ''">create_site,</if>
<if test="updateSite != null and updateSite != ''">update_site,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if>
<if test="regionCode != null and regionCode != ''">#{regionCode},</if>
<if test="regionName != null and regionName != ''">#{regionName},</if>
<if test="regionNameEn != null and regionNameEn != ''">#{regionNameEn},</if>
<if test="shortName != null and shortName != ''">#{shortName},</if>
<if test="parentId != null">#{parentId},</if>
<if test="code != null and code != ''">#{code},</if>
<if test="countryId != null">#{countryId},</if>
<if test="countryAreaId != null">#{countryAreaId},</if>
<if test="regionType != null">#{regionType},</if>
<if test="shortName != null and shortName != ''">#{shortName},</if>
<if test="parentCode != null and parentCode != ''">#{parentCode},</if>
<if test="areaId != null">#{areaId},</if>
<if test="areaName != null and areaName != ''">#{areaName},</if>
<if test="countryCode != null and countryCode != ''">#{countryCode},</if>
<if test="countryName != null and countryName != ''">#{countryName},</if>
<if test="zipCode != null and zipCode != ''">#{zipCode},</if>
<if test="orderNum != null">#{orderNum},</if>
<if test="remark != null and remark != ''">#{remark},</if>
<if test="tenantId != null and tenantId != ''">#{tenantId},</if>
<if test="delFlag != null and delFlag != ''">#{delFlag},</if>
@ -106,24 +115,26 @@
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null and updateBy != ''">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="areaName != null and areaName != ''">#{areaName},</if>
<if test="countryCode != null and countryCode != ''">#{countryCode},</if>
<if test="countryName != null and countryName != ''">#{countryName},</if>
<if test="createSite != null and createSite != ''">#{createSite},</if>
<if test="updateSite != null and updateSite != ''">#{updateSite},</if>
</trim>
</insert>
<update id="updateEmisRegion" parameterType="EmisRegion">
update emis_region
<trim prefix="SET" suffixOverrides=",">
<if test="regionCode != null and regionCode != ''">region_code = #{regionCode},</if>
<if test="regionName != null and regionName != ''">region_name = #{regionName},</if>
<if test="regionNameEn != null and regionNameEn != ''">region_name_en = #{regionNameEn},</if>
<if test="shortName != null and shortName != ''">short_name = #{shortName},</if>
<if test="parentId != null">parent_id = #{parentId},</if>
<if test="code != null and code != ''">code = #{code},</if>
<if test="countryId != null">country_id = #{countryId},</if>
<if test="countryAreaId != null">country_area_id = #{countryAreaId},</if>
<if test="regionType != null">region_type = #{regionType},</if>
<if test="shortName != null and shortName != ''">short_name = #{shortName},</if>
<if test="parentCode != null and parentCode != ''">parent_code = #{parentCode},</if>
<if test="areaId != null">area_id = #{areaId},</if>
<if test="areaName != null and areaName != ''">area_name = #{areaName},</if>
<if test="countryCode != null and countryCode != ''">country_code = #{countryCode},</if>
<if test="countryName != null and countryName != ''">country_name = #{countryName},</if>
<if test="zipCode != null and zipCode != ''">zip_code = #{zipCode},</if>
<if test="orderNum != null">order_num = #{orderNum},</if>
<if test="remark != null and remark != ''">remark = #{remark},</if>
<if test="tenantId != null and tenantId != ''">tenant_id = #{tenantId},</if>
<if test="delFlag != null and delFlag != ''">del_flag = #{delFlag},</if>
@ -131,14 +142,13 @@
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="areaName != null and areaName != ''">area_name = #{areaName},</if>
<if test="countryCode != null and countryCode != ''">country_code = #{countryCode},</if>
<if test="countryName != null and countryName != ''">country_name = #{countryName},</if>
<if test="createSite != null and createSite != ''">create_site = #{createSite},</if>
<if test="updateSite != null and updateSite != ''">update_site = #{updateSite},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteEmisRegionById" parameterType="Integer">
<delete id="deleteEmisRegionById" parameterType="Long">
delete from emis_region where id = #{id}
</delete>