增加大屏X轴时间线
This commit is contained in:
parent
d214b89b56
commit
27b794328e
|
|
@ -40,6 +40,11 @@ public class DevAttributeVo {
|
||||||
*/
|
*/
|
||||||
private String jcTime;
|
private String jcTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* x轴时间
|
||||||
|
*/
|
||||||
|
private String xTime;
|
||||||
|
|
||||||
private String devJson;
|
private String devJson;
|
||||||
|
|
||||||
private String attributeId;
|
private String attributeId;
|
||||||
|
|
|
||||||
|
|
@ -44,6 +44,13 @@ public class ProjectDetailsViewServiceImpl {
|
||||||
if (records.isEmpty()) {
|
if (records.isEmpty()) {
|
||||||
return AjaxResult.error("暂无数据");
|
return AjaxResult.error("暂无数据");
|
||||||
}
|
}
|
||||||
|
for (DevAttributeVo record : records) {
|
||||||
|
// 截取时间 定义x轴
|
||||||
|
if (record != null && record.getJcTime() != null) {
|
||||||
|
// 从yyyy-MM-dd hh:mm:ss 截取小时分钟
|
||||||
|
record.setXTime(record.getJcTime().substring(11, 16));
|
||||||
|
}
|
||||||
|
}
|
||||||
Map<String, List<DevAttributeVo>> listMap = records.stream().collect(Collectors.groupingBy(DevAttributeVo::getJcName));
|
Map<String, List<DevAttributeVo>> listMap = records.stream().collect(Collectors.groupingBy(DevAttributeVo::getJcName));
|
||||||
return AjaxResult.success(listMap);
|
return AjaxResult.success(listMap);
|
||||||
}
|
}
|
||||||
|
|
@ -53,6 +60,13 @@ public class ProjectDetailsViewServiceImpl {
|
||||||
if (records.isEmpty()) {
|
if (records.isEmpty()) {
|
||||||
return AjaxResult.error("暂无数据");
|
return AjaxResult.error("暂无数据");
|
||||||
}
|
}
|
||||||
|
for (DevAttributeVo record : records) {
|
||||||
|
// 截取时间 定义x轴
|
||||||
|
if (record != null && record.getJcTime() != null) {
|
||||||
|
// 从yyyy-MM-dd hh:mm:ss 截取小时分钟
|
||||||
|
record.setXTime(record.getJcTime().substring(11, 16));
|
||||||
|
}
|
||||||
|
}
|
||||||
Map<String, List<DevAttributeVo>> listMap = records.stream().collect(Collectors.groupingBy(DevAttributeVo::getJcName));
|
Map<String, List<DevAttributeVo>> listMap = records.stream().collect(Collectors.groupingBy(DevAttributeVo::getJcName));
|
||||||
return AjaxResult.success(listMap);
|
return AjaxResult.success(listMap);
|
||||||
}
|
}
|
||||||
|
|
@ -62,6 +76,13 @@ public class ProjectDetailsViewServiceImpl {
|
||||||
if (records.isEmpty()) {
|
if (records.isEmpty()) {
|
||||||
return AjaxResult.error("暂无数据");
|
return AjaxResult.error("暂无数据");
|
||||||
}
|
}
|
||||||
|
for (DevAttributeVo record : records) {
|
||||||
|
// 截取时间 定义x轴
|
||||||
|
if (record != null && record.getJcTime() != null) {
|
||||||
|
// 从yyyy-MM-dd hh:mm:ss 截取小时分钟
|
||||||
|
record.setXTime(record.getJcTime().substring(11, 16));
|
||||||
|
}
|
||||||
|
}
|
||||||
return AjaxResult.success(records);
|
return AjaxResult.success(records);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -74,6 +95,13 @@ public class ProjectDetailsViewServiceImpl {
|
||||||
if (records.isEmpty()) {
|
if (records.isEmpty()) {
|
||||||
return AjaxResult.success("暂无数据");
|
return AjaxResult.success("暂无数据");
|
||||||
}
|
}
|
||||||
|
for (DevAttributeVo record : records) {
|
||||||
|
// 截取时间 定义x轴
|
||||||
|
if (record != null && record.getJcTime() != null) {
|
||||||
|
// 从yyyy-MM-dd hh:mm:ss 截取小时分钟
|
||||||
|
record.setXTime(record.getJcTime().substring(11, 16));
|
||||||
|
}
|
||||||
|
}
|
||||||
return AjaxResult.success(records);
|
return AjaxResult.success(records);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -82,6 +110,13 @@ public class ProjectDetailsViewServiceImpl {
|
||||||
if (records.isEmpty()) {
|
if (records.isEmpty()) {
|
||||||
return AjaxResult.success("暂无数据");
|
return AjaxResult.success("暂无数据");
|
||||||
}
|
}
|
||||||
|
for (DevAttributeVo record : records) {
|
||||||
|
// 截取时间 定义x轴
|
||||||
|
if (record != null && record.getJcTime() != null) {
|
||||||
|
// 从yyyy-MM-dd hh:mm:ss 截取小时分钟
|
||||||
|
record.setXTime(record.getJcTime().substring(11, 16));
|
||||||
|
}
|
||||||
|
}
|
||||||
return AjaxResult.success(records);
|
return AjaxResult.success(records);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -27,9 +27,9 @@
|
||||||
</if>
|
</if>
|
||||||
/**
|
/**
|
||||||
* 班组长条件筛选,一个班组长只可带领一个组,班组员条件筛选,一个组员只可在一个班组
|
* 班组长条件筛选,一个班组长只可带领一个组,班组员条件筛选,一个组员只可在一个班组
|
||||||
*/
|
*/
|
||||||
<if test="isAll != null and isAll == 0">
|
<if test="isAll != null and isAll == 0">
|
||||||
and (tp.team_id is null and tp.id not in (select rel_id from tb_team where del_flag = '0' and js_time is null))
|
and (tp.team_id is null and tp.id not in (select rel_id from tb_team where del_flag = '0' and rel_id is not null and js_time is null))
|
||||||
</if>
|
</if>
|
||||||
ORDER BY CASE WHEN tp.id = tt.rel_id THEN 0 ELSE 1 END, tp.id
|
ORDER BY CASE WHEN tp.id = tt.rel_id THEN 0 ELSE 1 END, tp.id
|
||||||
</select>
|
</select>
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@
|
||||||
ANY_VALUE( td.dev_code) AS devCode
|
ANY_VALUE( td.dev_code) AS devCode
|
||||||
FROM tb_dev_data_record tddr
|
FROM tb_dev_data_record tddr
|
||||||
LEFT JOIN tb_device td ON tddr.dev_id = td.id
|
LEFT JOIN tb_device td ON tddr.dev_id = td.id
|
||||||
LEFT JOIN tb_bd_device_record tbdr ON td.dev_code = tbdr.dev_code
|
LEFT JOIN tb_bd_device_record tbdr ON td.bd_id = tbdr.id
|
||||||
LEFT JOIN tb_project tp ON tbdr.pro_id = tp.id
|
LEFT JOIN tb_project tp ON tbdr.pro_id = tp.id
|
||||||
WHERE tddr.is_warn = 1
|
WHERE tddr.is_warn = 1
|
||||||
<if test="devTypeCode != null and devTypeCode != ''">
|
<if test="devTypeCode != null and devTypeCode != ''">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue