|
|
|
@ -5,37 +5,37 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
@@ -5,37 +5,37 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<mapper namespace="com.ruoyi.system.mapper.Iso3166CountryMapper"> |
|
|
|
|
|
|
|
|
|
<resultMap type="Iso3166Country" id="Iso3166CountryResult"> |
|
|
|
|
<result property="id" column="id" /> |
|
|
|
|
<result property="alpha2" column="alpha_2" /> |
|
|
|
|
<result property="alpha3" column="alpha_3" /> |
|
|
|
|
<result property="numeric" column="numeric" /> |
|
|
|
|
<result property="nameZh" column="name_zh" /> |
|
|
|
|
<result property="nameEn" column="name_en" /> |
|
|
|
|
<result property="region" column="region" /> |
|
|
|
|
<result property="subRegion" column="sub_region" /> |
|
|
|
|
<result property="isIndependent" column="is_independent" /> |
|
|
|
|
<result property="isEnabled" column="is_enabled" /> |
|
|
|
|
<result property="createTime" column="create_time" /> |
|
|
|
|
<result property="updateTime" column="update_time" /> |
|
|
|
|
<result property="id" column="id" /> |
|
|
|
|
<result property="alpha2" column="alpha_2" /> |
|
|
|
|
<result property="alpha3" column="alpha_3" /> |
|
|
|
|
<result property="numeric" column="`numeric`" /> |
|
|
|
|
<result property="nameZh" column="name_zh" /> |
|
|
|
|
<result property="nameEn" column="name_en" /> |
|
|
|
|
<result property="region" column="region" /> |
|
|
|
|
<result property="subRegion" column="sub_region" /> |
|
|
|
|
<result property="isIndependent" column="is_independent" /> |
|
|
|
|
<result property="isEnabled" column="is_enabled" /> |
|
|
|
|
<result property="createTime" column="create_time" /> |
|
|
|
|
<result property="updateTime" column="update_time" /> |
|
|
|
|
</resultMap> |
|
|
|
|
|
|
|
|
|
<sql id="selectIso3166CountryVo"> |
|
|
|
|
select id, alpha_2, alpha_3, numeric, name_zh, name_en, region, sub_region, is_independent, is_enabled, create_time, update_time |
|
|
|
|
select id, alpha_2, alpha_3, `numeric`, name_zh, name_en, region, sub_region, is_independent, is_enabled, create_time, update_time |
|
|
|
|
from iso3166_country |
|
|
|
|
</sql> |
|
|
|
|
|
|
|
|
|
<select id="selectIso3166CountryList" parameterType="Iso3166Country" resultMap="Iso3166CountryResult"> |
|
|
|
|
<include refid="selectIso3166CountryVo"/> |
|
|
|
|
<where> |
|
|
|
|
<if test="alpha2 != null and alpha2 != ''"> and alpha_2 = #{alpha2}</if> |
|
|
|
|
<if test="alpha3 != null and alpha3 != ''"> and alpha_3 = #{alpha3}</if> |
|
|
|
|
<if test="numeric != null and numeric != ''"> and numeric = #{numeric}</if> |
|
|
|
|
<if test="nameZh != null and nameZh != ''"> and name_zh like concat('%', #{nameZh}, '%')</if> |
|
|
|
|
<if test="nameEn != null and nameEn != ''"> and name_en like concat('%', #{nameEn}, '%')</if> |
|
|
|
|
<if test="region != null and region != ''"> and region = #{region}</if> |
|
|
|
|
<if test="subRegion != null and subRegion != ''"> and sub_region = #{subRegion}</if> |
|
|
|
|
<if test="isIndependent != null "> and is_independent = #{isIndependent}</if> |
|
|
|
|
<if test="isEnabled != null "> and is_enabled = #{isEnabled}</if> |
|
|
|
|
<where> |
|
|
|
|
<if test="alpha2 != null and alpha2 != ''"> and alpha_2 = #{alpha2}</if> |
|
|
|
|
<if test="alpha3 != null and alpha3 != ''"> and alpha_3 = #{alpha3}</if> |
|
|
|
|
<if test="numeric != null and numeric != ''"> and `numeric` = #{numeric}</if> |
|
|
|
|
<if test="nameZh != null and nameZh != ''"> and name_zh like concat('%', #{nameZh}, '%')</if> |
|
|
|
|
<if test="nameEn != null and nameEn != ''"> and name_en like concat('%', #{nameEn}, '%')</if> |
|
|
|
|
<if test="region != null and region != ''"> and region = #{region}</if> |
|
|
|
|
<if test="subRegion != null and subRegion != ''"> and sub_region = #{subRegion}</if> |
|
|
|
|
<if test="isIndependent != null"> and is_independent = #{isIndependent}</if> |
|
|
|
|
<if test="isEnabled != null"> and is_enabled = #{isEnabled}</if> |
|
|
|
|
</where> |
|
|
|
|
order by id asc |
|
|
|
|
</select> |
|
|
|
|