|
|
@@ -12,7 +12,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
`sort`,
|
|
|
`is_show`,
|
|
|
`created_at`,
|
|
|
- `updated_at`
|
|
|
+ `updated_at`,
|
|
|
+ `icon_url`
|
|
|
FROM news_category ${ew.customSqlSegment}
|
|
|
</select>
|
|
|
|
|
|
@@ -25,7 +26,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
`sort`,
|
|
|
`is_show`,
|
|
|
`created_at`,
|
|
|
- `updated_at`
|
|
|
+ `updated_at`,
|
|
|
+ `icon_url`
|
|
|
FROM news_category ${ew.customSqlSegment}
|
|
|
</select>
|
|
|
|
|
|
@@ -37,7 +39,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
`sort`,
|
|
|
`is_show`,
|
|
|
`created_at`,
|
|
|
- `updated_at`
|
|
|
+ `updated_at`,
|
|
|
+ `icon_url`
|
|
|
FROM news_category WHERE id = #{id}
|
|
|
</select>
|
|
|
|
|
|
@@ -56,6 +59,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="isShow != null and isShow != ''">
|
|
|
is_show = #{isShow},
|
|
|
</if>
|
|
|
+ <if test="iconUrl != null and iconUrl != ''">
|
|
|
+ icon_url = #{iconUrl},
|
|
|
+ </if>
|
|
|
updated_at = NOW()
|
|
|
</set>
|
|
|
WHERE id = #{id}
|
|
|
@@ -69,6 +75,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="code != null and code != ''">code,</if>
|
|
|
<if test="sort != null and sort != ''">sort,</if>
|
|
|
<if test="isShow != null and isShow != ''">is_show,</if>
|
|
|
+ <if test="iconUrl != null and iconUrl != ''">icon_url,</if>
|
|
|
created_at
|
|
|
</trim>
|
|
|
<trim prefix="VALUES (" suffix=")" suffixOverrides=",">
|
|
|
@@ -76,6 +83,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="code != null and code != ''">#{code},</if>
|
|
|
<if test="sort != null and sort != ''">#{sort},</if>
|
|
|
<if test="isShow != null and isShow != ''">#{isShow},</if>
|
|
|
+ <if test="iconUrl != null and iconUrl != ''">#{iconUrl},</if>
|
|
|
NOW()
|
|
|
</trim>
|
|
|
</insert>
|
|
|
@@ -112,7 +120,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
`sort`,
|
|
|
`is_show`,
|
|
|
`created_at`,
|
|
|
- `updated_at`
|
|
|
+ `updated_at`,
|
|
|
+ `icon_url`
|
|
|
FROM news_category where is_show=1
|
|
|
</select>
|
|
|
|