Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
462a1045
Commit
462a1045
authored
Dec 30, 2022
by
lisong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改bug
parent
a3d2aa39
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
35 additions
and
8 deletions
+35
-8
SupervisionConfigureController.java
...quipmanage/controller/SupervisionConfigureController.java
+12
-6
FireFightingSystemMapper.xml
...ip/src/main/resources/mapper/FireFightingSystemMapper.xml
+23
-2
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/controller/SupervisionConfigureController.java
View file @
462a1045
...
@@ -381,18 +381,24 @@ public class SupervisionConfigureController extends AbstractBaseController {
...
@@ -381,18 +381,24 @@ public class SupervisionConfigureController extends AbstractBaseController {
}
catch
(
ParseException
e
)
{
}
catch
(
ParseException
e
)
{
throw
new
RuntimeException
(
e
);
throw
new
RuntimeException
(
e
);
}
}
long
res
=
start
-
end
;
long
res
=
0
;
if
(
start
>
end
){
res
=
start
-
end
;
}
else
{
res
=
end
-
start
;
}
diffMinute
=
res
/
1000
/
60
;
diffMinute
=
res
/
1000
/
60
;
}
}
long
finalDiffMinute
=
diffMinute
;
long
finalDiffMinute
=
diffMinute
;
pressurePumpInfo
.
getRecords
().
stream
(
pressurePumpInfo
.
getRecords
().
stream
(
).
map
(
item
->
{
).
map
(
item
->
{
item
.
put
(
"startAndStopInterval"
,
finalDiffMinute
);
item
.
put
(
"startAndStopInterval"
,
finalDiffMinute
);
//
if (finalDiffMinute > 5) {
if
(
finalDiffMinute
>
5
)
{
// item.put("stateDesc
", "异常");
item
.
put
(
"generalState
"
,
"异常"
);
//
} else {
}
else
{
// item.put("stateDesc
", "正常");
item
.
put
(
"generalState
"
,
"正常"
);
//
}
}
item
.
put
(
"nameKey"
,
pressurePumpStart
);
item
.
put
(
"nameKey"
,
pressurePumpStart
);
return
item
;
return
item
;
}).
collect
(
Collectors
.
toList
());
}).
collect
(
Collectors
.
toList
());
...
...
amos-boot-system-equip/src/main/resources/mapper/FireFightingSystemMapper.xml
View file @
462a1045
...
@@ -5009,6 +5009,26 @@
...
@@ -5009,6 +5009,26 @@
OR ( `is_alarm` = 0 AND `value` = 'false' ))
OR ( `is_alarm` = 0 AND `value` = 'false' ))
</select>
</select>
<select
id=
"queryStartAndStopBySpecificId"
resultType=
"java.util.Map"
>
<select
id=
"queryStartAndStopBySpecificId"
resultType=
"java.util.Map"
>
( SELECT
i.equipment_specific_id,
DATE_FORMAT(i.update_date,'%Y-%m-%d %H:%i:%S') update_date,
i.equipment_index_name
FROM
wl_equipment_specific_index i
WHERE
<if
test=
"ids != null and ids.size > 0"
>
i.equipment_specific_id IN
<foreach
collection=
"ids"
item=
"item"
index=
"index"
open=
"("
close=
")"
separator=
","
>
#{item}
</foreach>
AND
</if>
i.equipment_index_key in ('FHS_PressurePump_Start')
ORDER BY
i.update_date DESC
limit 1
) union
(
SELECT
SELECT
i.equipment_specific_id,
i.equipment_specific_id,
DATE_FORMAT(i.update_date,'%Y-%m-%d %H:%i:%S') update_date,
DATE_FORMAT(i.update_date,'%Y-%m-%d %H:%i:%S') update_date,
...
@@ -5023,10 +5043,11 @@
...
@@ -5023,10 +5043,11 @@
</foreach>
</foreach>
AND
AND
</if>
</if>
i.equipment_index_key in ('FHS_PressurePump_St
art', 'FHS_PressurePump_St
op')
i.equipment_index_key in ('FHS_PressurePump_Stop')
ORDER BY
ORDER BY
i.update_date DESC
i.update_date DESC
limit 2
limit 1
)
</select>
</select>
<select
id=
"queryStateBySpecificId"
resultType=
"java.util.Map"
>
<select
id=
"queryStateBySpecificId"
resultType=
"java.util.Map"
>
SELECT
SELECT
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment