Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
eshiled-new
/
ne-shield-trialdrive-admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit f7cb3408
authored
Dec 30, 2024
by
谢海旭
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
常驻点查询 增加百度经纬度字段返回
1 parent
fe977524
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
1 deletions
src/main/java/cn/com/glsx/admin/modules/converter/RiskAssessmentConvert.java
src/main/java/cn/com/glsx/admin/modules/model/vo/StayPointListVO.java
src/main/java/cn/com/glsx/admin/modules/service/RiskAssessmentService.java
src/main/java/cn/com/glsx/admin/modules/converter/RiskAssessmentConvert.java
View file @
f7cb340
...
...
@@ -29,6 +29,8 @@ public class RiskAssessmentConvert {
stayPointListVO
.
setLocationType
(
"GPS"
);
Optional
.
of
(
stayPointRecordDTO
).
map
(
StayPointRecordDTO:
:
getStayGps
).
map
(
GpsLocation:
:
getElat
).
ifPresent
(
stayPointListVO:
:
setElat
);
Optional
.
of
(
stayPointRecordDTO
).
map
(
StayPointRecordDTO:
:
getStayGps
).
map
(
GpsLocation:
:
getElng
).
ifPresent
(
stayPointListVO:
:
setElng
);
Optional
.
of
(
stayPointRecordDTO
).
map
(
StayPointRecordDTO:
:
getStayGps
).
map
(
GpsLocation:
:
getBlat
).
ifPresent
(
stayPointListVO:
:
setBlat
);
Optional
.
of
(
stayPointRecordDTO
).
map
(
StayPointRecordDTO:
:
getStayGps
).
map
(
GpsLocation:
:
getBlng
).
ifPresent
(
stayPointListVO:
:
setBlng
);
stayPointListVO
.
setAddress
(
address
);
return
stayPointListVO
;
}
...
...
src/main/java/cn/com/glsx/admin/modules/model/vo/StayPointListVO.java
View file @
f7cb340
...
...
@@ -84,6 +84,18 @@ public class StayPointListVO implements Serializable {
private
String
elng
;
/**
* 停留纬度-百度
* */
@ApiModelProperty
(
value
=
"停留纬度-百度"
)
private
String
blat
;
/**
* 停留经度-百度
* */
@ApiModelProperty
(
value
=
"停留经度-百度"
)
private
String
blng
;
/**
* 停留地址
* */
@ApiModelProperty
(
value
=
"停留地址"
)
...
...
src/main/java/cn/com/glsx/admin/modules/service/RiskAssessmentService.java
View file @
f7cb340
...
...
@@ -157,7 +157,10 @@ public class RiskAssessmentService {
List
<
LngLatDTO
>
lngLats
=
stayPointRecordList
.
stream
().
filter
(
e
->
Objects
.
nonNull
(
e
.
getStayGps
())).
map
(
e
->
new
LngLatDTO
(
e
.
getStayGps
().
getElng
(),
e
.
getStayGps
().
getElat
())).
collect
(
Collectors
.
toList
());
LngLatAddressDTO
addressDTO
=
remoteGpsBsService
.
getAddressMap
(
lngLats
);
Map
<
String
,
String
>
addressMap
=
Optional
.
ofNullable
(
addressDTO
).
map
(
LngLatAddressDTO:
:
getAddress
).
orElse
(
Maps
.
newHashMap
());
return
stayPointRecordList
.
stream
().
map
(
stayPoint
->
RiskAssessmentConvert
.
buildStayPointListVO
(
stayPoint
,
vehicle
,
sn
,
Optional
.
ofNullable
(
stayPoint
.
getStayGps
()).
map
(
e
->
e
.
getElat
()
+
e
.
getElng
()).
map
(
addressMap:
:
get
).
orElse
(
Constants
.
EMPTY_CONTENT_EXCEL
))).
collect
(
Collectors
.
toList
());
return
stayPointRecordList
.
stream
().
map
(
stayPoint
->
RiskAssessmentConvert
.
buildStayPointListVO
(
stayPoint
,
vehicle
,
sn
,
Optional
.
ofNullable
(
stayPoint
.
getStayGps
()).
map
(
e
->
e
.
getElat
()
+
e
.
getElng
()).
map
(
addressMap:
:
get
).
orElse
(
Constants
.
EMPTY_CONTENT_EXCEL
)))
.
collect
(
Collectors
.
toList
());
}
/**
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment