Commit 79dd3e4a by 111-PC\111

[+]kafka消费数据修改

1 parent 54e2ee6a
......@@ -23,7 +23,8 @@ public class SmartDeviceStatusService {
private SceneService sceneService;
public void saveEvent(Event event) {
SmartDevideStatus smartDevideStatus=smartDevideStatusMapper.findDevStatusByIdAndCode(event.getSn(), Constants.MACHINE_STATUS_ORDER);
log.info("开始消费,设备{}号,操作{}",event.getSn(),event);
SmartDevideStatus smartDevideStatus=smartDevideStatusMapper.findDevStatusByIdAndCode(event.getSn(), event.getDeviceType());
if(smartDevideStatus==null){
smartDevideStatus=new SmartDevideStatus();
smartDevideStatus.setDeviceOrderCode(event.getDeviceType());
......
......@@ -104,10 +104,11 @@ public class Event implements Serializable{
"userId='" + userId + '\'' +
", sn='" + sn + '\'' +
", type='" + type + '\'' +
", time='" + time + '\'' +
", time=" + time +
", deviceType='" + deviceType + '\'' +
", accessTime='" + accessTime + '\'' +
", receiveTime='" + receiveTime + '\'' +
", value='" + value + '\'' +
'}';
}
}
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!