feat(iot): 添加设备状态监控和地理坐标属性

- 在 Device 模型中添加 deviceState 字段,用于表示设备运行状态- 在 DeviceDto 中添加 longitude 和 latitude 字段,用于表示设备经纬度
- 修改 RecordDataServiceImpl 中的数据处理逻辑,增加设备状态更新
- 在数据库中添加相关字段和默认值设置
This commit is contained in:
zhuangtianxiang 2025-03-24 18:31:57 +08:00
parent a8beca1640
commit 42a9f9490f

View File

@ -82,7 +82,7 @@
where d.id = #{id}
</select>
<select id="selectPageByConditions" resultType="com.zsc.edu.gateway.modules.iot.device.entity.Device">
<select id="selectPageByConditions" resultMap="BaseResultMap">
SELECT d.*, p.*
FROM iot_device d
LEFT JOIN iot_product p ON d.product_id = p.id
@ -96,7 +96,7 @@
<if test="query.state != null and query.state != ''">
AND d.state = #{query.state}
</if>
<if test="query.isOnline != null and query.isOnline != ''">
<if test="query.isOnline != null">
AND d.online = #{query.isOnline}
</if>
<if test="query.productId != null and query.productId != ''">