添加功能

This commit is contained in:
马宝龙
2026-07-04 22:09:57 +08:00
parent 6de7f1ffdf
commit 39c766bf46

View File

@@ -84,25 +84,25 @@
LEFT JOIN model_warning_indicator b ON a.indicator_code = b.indicator_code LEFT JOIN model_warning_indicator b ON a.indicator_code = b.indicator_code
<where> <where>
<if test="id != null "> <if test="id != null ">
AND id = #{id} AND a.id = #{id}
</if> </if>
<if test="indicatorCode != null and indicatorCode != ''"> <if test="indicatorCode != null and indicatorCode != ''">
AND indicator_code = #{indicatorCode} AND a.indicator_code = #{indicatorCode}
</if> </if>
<if test="year != null"> <if test="year != null">
AND year = #{year} AND a.year = #{year}
</if> </if>
<if test="month != null"> <if test="month != null">
AND month = #{month} AND a.month = #{month}
</if> </if>
<if test="regionCode != null and regionCode != ''"> <if test="regionCode != null and regionCode != ''">
AND region_code = #{regionCode} AND a.region_code = #{regionCode}
</if> </if>
<if test="regionName != null and regionName != ''"> <if test="regionName != null and regionName != ''">
AND region_name LIKE '%'||#{regionName}||'%' AND a.region_name LIKE '%'||#{regionName}||'%'
</if> </if>
</where> </where>
ORDER BY year DESC, month DESC, indicator_code ORDER BY a.year DESC, a.month DESC, a.indicator_code
</select> </select>