Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
黄嘉阳
/
iot-platform-server
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
d1910d0c
authored
Oct 27, 2023
by
huangjy
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
fix:跌倒记录
parent
af62f66a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
3 deletions
server-service/src/main/java/com/makeit/service/platform/elder/impl/PlatElderDayReportDayServiceImpl.java
server-service/src/main/java/com/makeit/service/platform/elder/impl/PlatElderDayReportDayServiceImpl.java
View file @
d1910d0c
...
...
@@ -328,11 +328,24 @@ public class PlatElderDayReportDayServiceImpl implements PlatElderDayReportDaySe
List
<
String
>
voList
=
new
ArrayList
<>(
10
);
platDeviceList
.
forEach
(
e
->
{
List
<
DeviceInfoContentFall
>
fallList
=
iotProductDeviceService
.
getDeviceLogByTimeRangeFall
(
e
.
getOriDeviceId
(),
2
*
24
*
3600
,
start
,
end
);
fallList
=
StreamUtil
.
filter
(
fallList
,
i
->
DeviceInfoContentFallEnum
.
PersonStateEnum
.
FALL
.
getValue
().
equals
(
i
.
getProperties
().
getPersonState
()));
voList
.
addAll
(
StreamUtil
.
map
(
fallList
,
i
->
dateTimeFormatter
.
format
(
LongTimestampUtil
.
toLocalDateTime
(
i
.
getTimestamp
()))));
List
<
PlatAlarmRecord
>
recordList
=
platAlarmRecordService
.
list
(
new
QueryWrapper
<
PlatAlarmRecord
>().
lambda
()
.
eq
(
PlatAlarmRecord:
:
getAlarmType
,
PlatAlarmConfigEnum
.
AlarmTypeEnum
.
FALL
.
getValue
())
.
in
(
PlatAlarmRecord:
:
getDeviceId
,
StreamUtil
.
mapId
(
platDeviceList
,
PlatDevice:
:
getId
))
.
eq
(
PlatAlarmRecord:
:
getElderIds
,
platElderIdDTO
.
getElderId
())
.
ge
(
PlatAlarmRecord:
:
getAlarmDate
,
start
)
.
le
(
PlatAlarmRecord:
:
getAlarmDate
,
end
)
.
orderByDesc
(
PlatAlarmRecord:
:
getAlarmDate
)
);
voList
.
addAll
(
StreamUtil
.
map
(
recordList
,
i
->
i
.
getAlarmDate
().
format
(
dateTimeFormatter
)));
/* List<DeviceInfoContentFall> fallList = iotProductDeviceService.getDeviceLogByTimeRangeFall(e.getOriDeviceId(), 2 * 24 * 3600, start, end);
fallList = StreamUtil.filter(fallList, i -> DeviceInfoContentFallEnum.PersonStateEnum.FALL.getValue().equals(i.getProperties().getPersonState()));
*/
});
...
...
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