2025-04-03 11:20:05 +08:00
|
|
|
<?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.ff.game.mapper.PlatformMapper">
|
|
|
|
|
|
|
|
<resultMap type="Platform" id="PlatformResult">
|
|
|
|
<result property="id" column="id" />
|
|
|
|
<result property="sortNo" column="sort_no" />
|
|
|
|
<result property="platformCode" column="platform_code" />
|
|
|
|
<result property="platformName" column="platform_name" />
|
|
|
|
<result property="platformInfo" column="platform_info" typeHandler="com.ff.base.handler.JsonListHandler" javaType="com.ff.game.domain.PlatformInfo"/>
|
|
|
|
<result property="urlInfo" column="url_info" typeHandler="com.ff.base.handler.JsonHandler" javaType="com.ff.game.domain.UrlInfo"/>
|
|
|
|
<result property="keyInfo" column="key_info" typeHandler="com.ff.base.handler.JsonListHandler" javaType="com.ff.game.domain.KeyInfo"/>
|
|
|
|
<result property="langInfo" column="lang_info" typeHandler="com.ff.base.handler.JsonHandler" javaType="com.ff.game.domain.LangInfo"/>
|
|
|
|
<result property="currencyInfo" column="currency_info" typeHandler="com.ff.base.handler.JsonHandler" javaType="com.ff.game.domain.CurrencyInfo"/>
|
2025-04-07 15:22:12 +08:00
|
|
|
<result property="extInfo" column="ext_info" typeHandler="com.ff.base.handler.JsonHandler" javaType="com.ff.game.domain.ExtInfo"/>
|
|
|
|
|
2025-04-03 11:20:05 +08:00
|
|
|
<result property="stopStatus" column="stop_status" />
|
|
|
|
<result property="createBy" column="create_by" />
|
|
|
|
<result property="createTime" column="create_time" />
|
|
|
|
<result property="updateBy" column="update_by" />
|
|
|
|
<result property="updateTime" column="update_time" />
|
|
|
|
</resultMap>
|
|
|
|
|
|
|
|
<sql id="selectVO">
|
|
|
|
select * from ff_platform
|
|
|
|
</sql>
|
|
|
|
|
|
|
|
<select id="selectList" parameterType="Platform" resultMap="PlatformResult">
|
|
|
|
<include refid="selectVO"/>
|
|
|
|
<where>
|
|
|
|
<if test="platformCode != null and platformCode != ''"> and platform_code = #{platformCode}</if>
|
|
|
|
<if test="platformName != null and platformName != ''"> and instr(platform_name,#{platformName}) > 0</if>
|
|
|
|
<if test="stopStatus != null"> and stop_status = #{stopStatus}</if>
|
|
|
|
|
|
|
|
</where>
|
|
|
|
</select>
|
|
|
|
|
|
|
|
<select id="selectByPlatformCode" parameterType="String" resultMap="PlatformResult">
|
|
|
|
<include refid="selectVO"/>
|
|
|
|
where platform_code = #{platformCode}
|
|
|
|
</select>
|
|
|
|
<insert id="insertPlatform" parameterType="Platform">
|
|
|
|
insert into ff_platform
|
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
<if test="id != null">id,</if>
|
|
|
|
<if test="sortNo != null">sort_no,</if>
|
|
|
|
<if test="platformCode != null and platformCode != ''">platform_code,</if>
|
|
|
|
<if test="platformName != null and platformName != ''">platform_name,</if>
|
|
|
|
<if test="platformInfo != null and platformInfo != ''">platform_info,</if>
|
|
|
|
<if test="urlInfo != null and urlInfo != ''">url_info,</if>
|
|
|
|
|
|
|
|
<if test="keyInfo != null and keyInfo != ''">key_info,</if>
|
|
|
|
<if test="langInfo != null and langInfo != ''">lang_info,</if>
|
|
|
|
<if test="currencyInfo != null and currencyInfo != ''">currency_info,</if>
|
2025-04-07 15:22:12 +08:00
|
|
|
<if test="extInfo != null and extInfo != ''">ext_info,</if>
|
|
|
|
|
2025-04-03 11:20:05 +08:00
|
|
|
<if test="stopStatus != null">stop_status,</if>
|
|
|
|
<if test="createBy != null">create_by,</if>
|
|
|
|
<if test="createTime != null">create_time,</if>
|
|
|
|
<if test="updateBy != null">update_by,</if>
|
|
|
|
<if test="updateTime != null">update_time,</if>
|
|
|
|
</trim>
|
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
<if test="id != null">#{id},</if>
|
|
|
|
<if test="sortNo != null">#{sortNo}</if>
|
|
|
|
<if test="platformCode != null and platformCode != ''">#{platformCode},</if>
|
|
|
|
<if test="platformName != null and platformName != ''">#{platformName},</if>
|
|
|
|
<if test="platformInfo != null and platformInfo != ''">#{platformInfo},</if>
|
|
|
|
<if test="urlInfo != null and urlInfo != ''">#{urlInfo},</if>
|
|
|
|
<if test="keyInfo != null and keyInfo != ''">#{keyInfo},</if>
|
|
|
|
<if test="langInfo != null and langInfo != ''">#{langInfo},</if>
|
|
|
|
<if test="currencyInfo != null and currencyInfo != ''">#{currencyInfo},</if>
|
|
|
|
<if test="stopStatus != null">#{stopStatus},</if>
|
|
|
|
<if test="createBy != null">#{createBy},</if>
|
|
|
|
<if test="createTime != null">#{createTime},</if>
|
|
|
|
<if test="updateBy != null">#{updateBy},</if>
|
|
|
|
<if test="updateTime != null">#{updateTime},</if>
|
|
|
|
</trim>
|
|
|
|
</insert>
|
|
|
|
|
|
|
|
<update id="updatePlatform" parameterType="Platform">
|
|
|
|
update ff_platform
|
|
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
|
|
<if test="sortNo != null">sort_no = #{sortNo},</if>
|
|
|
|
<if test="platformCode != null and platformCode != ''">platform_code = #{platformCode},</if>
|
|
|
|
<if test="platformName != null and platformName != ''">platform_name = #{platformName},</if>
|
|
|
|
<if test="platformInfo != null and platformInfo != ''">platform_info = #{platformInfo},</if>
|
|
|
|
<if test="urlInfo != null and urlInfo != ''">url_info = #{urlInfo},</if>
|
|
|
|
|
|
|
|
<if test="keyInfo != null and keyInfo != ''">key_info = #{keyInfo},</if>
|
|
|
|
<if test="langInfo != null and langInfo != ''">lang_info = #{langInfo},</if>
|
|
|
|
<if test="currencyInfo != null and currencyInfo != ''">currency_info = #{currencyInfo},</if>
|
2025-04-07 15:22:12 +08:00
|
|
|
<if test="extInfo != null and extInfo != ''">ext_info = #{extInfo},</if>
|
|
|
|
|
2025-04-03 11:20:05 +08:00
|
|
|
<if test="stopStatus != null">stop_status = #{stopStatus},</if>
|
|
|
|
<if test="createBy != null">create_by = #{createBy},</if>
|
|
|
|
<if test="createTime != null">create_time = #{updateTime},</if>
|
|
|
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
|
|
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
|
</trim>
|
|
|
|
where id = #{id}
|
|
|
|
</update>
|
|
|
|
|
|
|
|
<delete id="deleteById" parameterType="Long">
|
|
|
|
delete from ff_platform where id = #{id}
|
|
|
|
</delete>
|
|
|
|
|
|
|
|
<delete id="deleteByIds" parameterType="String">
|
|
|
|
delete from ff_platform where id in
|
|
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
|
|
|
#{id}
|
|
|
|
</foreach>
|
|
|
|
</delete>
|
|
|
|
</mapper>
|