数据异常WARN状态同步SQL

This commit is contained in:
syruan 2024-11-23 17:52:26 +08:00
parent 57a1355a8e
commit 6b06af9340
2 changed files with 14 additions and 0 deletions

View File

@ -106,4 +106,10 @@ public interface DataCenterMapper {
* @param bdId
*/
void updateBdStatus(@Param("bdId") String bdId);
/**
* 更新设备预警状态
* @param id
*/
void updateDeviceIsWarn(@Param("id") String id);
}

View File

@ -65,6 +65,14 @@
set dev_status='1',status_time=now()
WHERE dev_code=#{bdId}
</update>
<!--更新设备预警状态-->
<update id="updateDeviceIsWarn" >
update tb_device
set dev_warn = '1'
WHERE id = #{id}
</update>
<!--依据级联id查询数据是否存在-->
<select id="getDevInfoNum" resultType="java.lang.Integer">
select count(1)