场外点位(定制化)

This commit is contained in:
Timer
2026-03-07 23:43:49 +08:00
parent 2f46cb817e
commit ba387a493b

View File

@ -149,11 +149,15 @@ public class MqttServiceImpl implements MqttService {
// 处理ES数据
MPointES esPoint = buildEsPoint(mPoint, value, date);
redisList.add(esPoint);
String tableName = "tb_mp_" + key;
if ("SSLL".equals(key) || "LJLL".equals(key)) {
// 场外点位(定制化)
tableName = "tb_mp_" + device + "_" + key;
}
MPointHistory mPointHistory = new MPointHistory();
mPointHistory.setMeasuredt(date);
mPointHistory.setParmvalue(value);
mPointHistory.setTbName("tb_mp_" + device + "_" + key);
mPointHistory.setTbName(tableName);
mPointHistory.setUserid(deviceName);
mPointHistory.setInsdt(new Date());
insertInsert(mPointHistory);