|
@@ -38,11 +38,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
<select id="selectAlertConfigurationListFilter" resultType="java.lang.Integer">
|
|
|
SELECT
|
|
|
- count(*)
|
|
|
+ count(0)
|
|
|
FROM
|
|
|
alert_configuration
|
|
|
- WHERE alert_configuration.alert_status = 1
|
|
|
-
|
|
|
+ WHERE alert_status = 1
|
|
|
+ <if test="userType !=null and userType !=''">
|
|
|
+ and user_type = #{userType}
|
|
|
+ </if>
|
|
|
</select>
|
|
|
|
|
|
<select id="selectAlertConfigurationById" parameterType="Long" resultMap="AlertConfigurationResult">
|
|
@@ -51,10 +53,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</select>
|
|
|
|
|
|
<select id="selectAlertConfigurationByAlertStatus" parameterType="Long" resultMap="AlertConfigurationResult">
|
|
|
- select *
|
|
|
- FROM
|
|
|
- alert_configuration
|
|
|
- WHERE alert_configuration.alert_status = 1
|
|
|
+ <include refid="selectAlertConfigurationVo"/>
|
|
|
+ WHERE alert_status = 1
|
|
|
+ <if test="userType !=null and userType !=''">
|
|
|
+ and user_type = #{userType}
|
|
|
+ </if>
|
|
|
</select>
|
|
|
|
|
|
<insert id="insertAlertConfiguration" parameterType="AlertConfiguration" useGeneratedKeys="true" keyProperty="alertId">
|