|
@@ -1,6 +1,7 @@
|
|
|
package com.genersoft.iot.vmp.extend.entity;
|
|
package com.genersoft.iot.vmp.extend.entity;
|
|
|
|
|
|
|
|
import cn.hutool.core.date.DateUtil;
|
|
import cn.hutool.core.date.DateUtil;
|
|
|
|
|
+import cn.hutool.core.util.StrUtil;
|
|
|
import com.baomidou.mybatisplus.annotation.TableField;
|
|
import com.baomidou.mybatisplus.annotation.TableField;
|
|
|
import com.baomidou.mybatisplus.annotation.TableName;
|
|
import com.baomidou.mybatisplus.annotation.TableName;
|
|
|
import com.genersoft.iot.vmp.service.bean.DownloadFileInfo;
|
|
import com.genersoft.iot.vmp.service.bean.DownloadFileInfo;
|
|
@@ -99,4 +100,24 @@ public class ExtendRecord {
|
|
|
return DateUtil.formatDateTime(new Date(endTime));
|
|
return DateUtil.formatDateTime(new Date(endTime));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
|
+ * 设备id
|
|
|
|
|
+ */
|
|
|
|
|
+ public String getDeviceId() {
|
|
|
|
|
+ if(StrUtil.isNotBlank(stream) && stream.contains("_")) {
|
|
|
|
|
+ return stream.substring(0,stream.indexOf("_"));
|
|
|
|
|
+ }
|
|
|
|
|
+ return stream;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ /**
|
|
|
|
|
+ * 通道id
|
|
|
|
|
+ */
|
|
|
|
|
+ public String getChannelId() {
|
|
|
|
|
+ if(StrUtil.isNotBlank(stream) && stream.contains("_")) {
|
|
|
|
|
+ return stream.substring(stream.indexOf("_"));
|
|
|
|
|
+ }
|
|
|
|
|
+ return stream;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
}
|
|
}
|