| | |
| | | <update id="update"> |
| | | update t_hidden_danger |
| | | <set> |
| | | <if test="dangerLocation != null"> |
| | | <if test="dangerLocation != null and dangerLocation !=''"> |
| | | dangerLocation = #{dangerLocation,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="title != null"> |
| | | <if test="title != null and title !=''"> |
| | | title = #{title,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="createTime != null"> |
| | |
| | | <if test="level != null"> |
| | | `level` = #{level,jdbcType=INTEGER}, |
| | | </if> |
| | | |
| | | <if test="auditUser != null"> |
| | | auditUser = #{auditUser,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="auditTime != null"> |
| | | auditTime = #{auditTime,jdbcType=TIMESTAMP}, |
| | | </if> |
| | | </set> |
| | | where id=#{id,jdbcType=VARCHAR} |
| | | </update> |
| | |
| | | <select id="selectInfo" resultType="com.thhy.secure.modules.biz.hiddenDanger.entity.HiddenDangerEntity"> |
| | | select |
| | | t.id, |
| | | t.dangerLocation, |
| | | sd.dict_name dangerLocation, |
| | | sd.dict_id dictId, |
| | | t.title, |
| | | t.createTime, |
| | | t.auditStatus, |
| | |
| | | t.companyId, |
| | | t.level, |
| | | t.integral, |
| | | su.real_name reporter |
| | | su.real_name reporter, |
| | | t.integral, |
| | | t.level, |
| | | su2.real_name auditUser, |
| | | t.auditTime |
| | | from t_hidden_danger t |
| | | LEFT JOIN sys_users su ON su.user_id = t.createUser |
| | | LEFT JOIN sys_users su1 ON su1.user_id = t.updateUser |
| | | LEFT JOIN sys_users su2 ON su2.user_id = t.auditUser |
| | | LEFT JOIN sys_dict sd on sd.dict_id = t.dangerLocation |
| | | where t.id=#{id} |
| | | </select> |
| | | |
| | |
| | | <select id="selectPageList" resultType="com.thhy.secure.modules.biz.hiddenDanger.entity.HiddenDangerEntity"> |
| | | SELECT |
| | | t.id, |
| | | t.dangerLocation, |
| | | sd.dict_name dangerLocation, |
| | | sd.dict_id dictId, |
| | | t.title, |
| | | t.createTime, |
| | | t.auditStatus, |
| | |
| | | t.companyId, |
| | | t.level, |
| | | t.integral, |
| | | su2.real_name auditUser, |
| | | t.auditTime, |
| | | su.real_name reporter |
| | | from t_hidden_danger t |
| | | LEFT JOIN sys_users su ON su.user_id = t.createUser |
| | | LEFT JOIN sys_users su1 ON su1.user_id = t.updateUser |
| | | LEFT JOIN sys_users su2 ON su2.user_id = t.auditUser |
| | | LEFT JOIN sys_dict sd on sd.dict_id = t.dangerLocation |
| | | WHERE |
| | | t.isUse = 1 |
| | | and t.companyId = #{companyId} |
| | | <if test="startTime!= null and endTime!=null and startTime != '' and endTime !=''"> |
| | | and t.createTime BETWEEN #{startTime} and #{endTime} |
| | | </if> |
| | | <if test="createUser!= null and createUser != ''"> |
| | | and t.createUser =#{createUser} |
| | | </if> |
| | | order by t.createTime desc |
| | | </select> |
| | |
| | | <select id="selectAppList" resultType="com.thhy.secure.modules.biz.hiddenDanger.entity.HiddenDangerEntity"> |
| | | SELECT |
| | | t.id, |
| | | t.dangerLocation, |
| | | sd.dict_name dangerLocation, |
| | | sd.dict_id dictId, |
| | | t.title, |
| | | t.createTime, |
| | | t.auditStatus, |
| | |
| | | t.companyId, |
| | | t.level, |
| | | t.integral, |
| | | su2.real_name auditUser, |
| | | t.auditTime, |
| | | su.real_name reporter |
| | | from t_hidden_danger t |
| | | LEFT JOIN sys_users su ON su.user_id = t.createUser |
| | | LEFT JOIN sys_users su1 ON su1.user_id = t.updateUser |
| | | LEFT JOIN sys_users su2 ON su2.user_id = t.auditUser |
| | | LEFT JOIN sys_dict sd on sd.dict_id = t.dangerLocation |
| | | WHERE |
| | | t.isUse = 1 |
| | | and t.companyId = #{companyId} |
| | | <if test="startTime!= null and endTime!=null and startTime != '' and endTime !=''"> |
| | | and t.createTime BETWEEN #{startTime} and #{endTime} |
| | | </if> |
| | | <if test="createUser!= null and createUser != ''"> |
| | | and t.createUser =#{createUser} |
| | | </if> |
| | | ORDER BY |
| | | t.auditStatus, |
| | | case when t.auditStatus = 0 then t.createTime END, |