From 7d74f3fd087d4a8192ed556a6c2e3a2ea3c81cff Mon Sep 17 00:00:00 2001 From: feiyu02 <risaku@163.com> Date: 星期五, 28 三月 2025 17:43:48 +0800 Subject: [PATCH] 1. 新增扬尘监测数据上传功能 --- src/main/resources/mapper/ds1/ScenseMapper.xml | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 50 insertions(+), 0 deletions(-) diff --git a/src/main/resources/mapper/ds1/ScenseMapper.xml b/src/main/resources/mapper/ds1/ScenseMapper.xml index 52ef693..740e874 100644 --- a/src/main/resources/mapper/ds1/ScenseMapper.xml +++ b/src/main/resources/mapper/ds1/ScenseMapper.xml @@ -42,7 +42,57 @@ S_Contacts, S_CreateDate, S_UpdateDate, S_Extension1, S_Extension2, S_Index, S_Remark </sql> + <!-- 琛屾斂鍖哄垝鏉′欢 --> + <sql id="Where_Area"> + <if test="provincecode != null"> + AND ${tableAlias}.S_ProvinceCode = #{provincecode} + </if> + <if test="provincename != null"> + AND ${tableAlias}.S_ProvinceName = #{provincename} + </if> + <if test="citycode != null"> + AND ${tableAlias}.S_CityCode = #{citycode} + </if> + <if test="cityname != null"> + AND ${tableAlias}.S_CityName = #{cityname} + </if> + <if test="districtcode != null"> + AND ${tableAlias}.S_DistrictCode = #{districtcode} + </if> + <if test="districtname != null"> + AND ${tableAlias}.S_DistrictName = #{districtname} + </if> + <if test="towncode != null"> + AND ${tableAlias}.S_TownCode = #{towncode} + </if> + <if test="townname != null"> + AND ${tableAlias}.S_TownName = #{townname} + </if> + </sql> + + <!-- 鍦烘櫙绫诲瀷鏉′欢 --> + <sql id="Where_Type"> + <if test="scensetypeid != null"> + AND ${tableAlias}.S_TypeID = #{scensetypeid} + </if> + </sql> + <select id="selectNoAccountScene" resultMap="BaseResultMap"> select a.* FROM sm_t_scense as a LEFT JOIN sm_t_userinfo as b on a.S_GUID = b.D_GUID WHERE b.UI_GUID is null </select> + + <select id="getSceneByType" resultMap="BaseResultMap"> + select + b.* + from sm_t_monitorobjectversion as a + left join sm_t_scense as b + on a.S_GUID = b.S_GUID + where a.T_ID = #{param1} + <if test="param2 != null"> + and b.S_TypeID = #{param2} + </if> + <if test="param3 != null"> + and b.S_TownCode = #{param3} + </if> + </select> </mapper> \ No newline at end of file -- Gitblit v1.9.3