Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
C
cms
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
iuav
cms
Commits
671aed15
提交
671aed15
authored
7月 17, 2023
作者:
xiaowang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
新增:返回网点资质及星级
上级
c1e73fcb
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
29 行增加
和
16 行删除
+29
-16
WebsiteRangeDTO.java
...ain/java/com/mmc/iuav/user/model/dto/WebsiteRangeDTO.java
+2
-0
CooperationController.java
...a/com/mmc/iuav/user/controller/CooperationController.java
+7
-6
WebsiteInfoDO.java
...src/main/java/com/mmc/iuav/user/entity/WebsiteInfoDO.java
+5
-0
CooperationDao.xml
...service-user/src/main/resources/mapper/CooperationDao.xml
+15
-10
没有找到文件。
cms-common/cms-common-model/src/main/java/com/mmc/iuav/user/model/dto/WebsiteRangeDTO.java
浏览文件 @
671aed15
...
@@ -22,4 +22,6 @@ public class WebsiteRangeDTO implements Serializable {
...
@@ -22,4 +22,6 @@ public class WebsiteRangeDTO implements Serializable {
private
Double
lon
;
private
Double
lon
;
private
Double
lat
;
private
Double
lat
;
private
Double
distance
;
private
Double
distance
;
private
String
content
;
private
Integer
score
;
}
}
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/controller/CooperationController.java
浏览文件 @
671aed15
...
@@ -3,6 +3,7 @@ package com.mmc.iuav.user.controller;
...
@@ -3,6 +3,7 @@ package com.mmc.iuav.user.controller;
import
com.mmc.iuav.group.Insert
;
import
com.mmc.iuav.group.Insert
;
import
com.mmc.iuav.group.Update
;
import
com.mmc.iuav.group.Update
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.response.ResultBody
;
import
com.mmc.iuav.user.model.dto.WebsiteRangeDTO
;
import
com.mmc.iuav.user.model.qo.ApplyQO
;
import
com.mmc.iuav.user.model.qo.ApplyQO
;
import
com.mmc.iuav.user.model.vo.*
;
import
com.mmc.iuav.user.model.vo.*
;
import
com.mmc.iuav.user.service.CooperationService
;
import
com.mmc.iuav.user.service.CooperationService
;
...
@@ -71,13 +72,13 @@ public class CooperationController extends BaseController {
...
@@ -71,13 +72,13 @@ public class CooperationController extends BaseController {
}
}
@ApiOperation
(
value
=
"服务商网点数据"
)
@ApiOperation
(
value
=
"服务商网点数据"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
WebsiteRangeDTO
.
class
)})
@GetMapping
(
"service/bitmap"
)
@GetMapping
(
"service/bitmap"
)
public
ResultBody
listServiceBitmapData
(
@ApiParam
(
value
=
"类型 注:按照渠道标签的id传入即可"
)
@RequestParam
Integer
type
,
public
ResultBody
<
WebsiteRangeDTO
>
listServiceBitmapData
(
@ApiParam
(
value
=
"类型 注:按照渠道标签的id传入即可"
)
@RequestParam
Integer
type
,
@RequestParam
Integer
pageNo
,
@RequestParam
Integer
pageNo
,
@RequestParam
Integer
pageSize
,
@RequestParam
Integer
pageSize
,
@RequestParam
Double
lon
,
@RequestParam
Double
lon
,
@RequestParam
Double
lat
)
{
@RequestParam
Double
lat
)
{
return
ResultBody
.
success
(
cooperationService
.
listServiceBitmapData
(
type
,
pageNo
,
pageSize
,
lon
,
lat
));
return
ResultBody
.
success
(
cooperationService
.
listServiceBitmapData
(
type
,
pageNo
,
pageSize
,
lon
,
lat
));
}
}
...
...
csm-service/cms-service-user/src/main/java/com/mmc/iuav/user/entity/WebsiteInfoDO.java
浏览文件 @
671aed15
...
@@ -25,6 +25,9 @@ public class WebsiteInfoDO implements Serializable {
...
@@ -25,6 +25,9 @@ public class WebsiteInfoDO implements Serializable {
private
Integer
type
;
private
Integer
type
;
private
Integer
userApplyTag
;
private
Integer
userApplyTag
;
private
String
content
;
private
Integer
score
;
public
WebsiteRangeDTO
buildWebsiteRangeDTO
()
{
public
WebsiteRangeDTO
buildWebsiteRangeDTO
()
{
this
.
distance
=
this
.
distance
==
null
?
0
:
(
BigDecimal
.
valueOf
(
this
.
distance
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_DOWN
)).
doubleValue
();
this
.
distance
=
this
.
distance
==
null
?
0
:
(
BigDecimal
.
valueOf
(
this
.
distance
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_DOWN
)).
doubleValue
();
...
@@ -33,6 +36,8 @@ public class WebsiteInfoDO implements Serializable {
...
@@ -33,6 +36,8 @@ public class WebsiteInfoDO implements Serializable {
.
address
(
address
)
.
address
(
address
)
.
lon
(
this
.
lon
)
.
lon
(
this
.
lon
)
.
lat
(
this
.
lat
)
.
lat
(
this
.
lat
)
.
content
(
content
)
.
score
(
score
)
.
distance
(
this
.
distance
/
1000
)
.
distance
(
this
.
distance
/
1000
)
.
build
();
.
build
();
}
}
...
...
csm-service/cms-service-user/src/main/resources/mapper/CooperationDao.xml
浏览文件 @
671aed15
...
@@ -247,16 +247,21 @@
...
@@ -247,16 +247,21 @@
where type = #{type}
where type = #{type}
</select>
</select>
<select
id=
"listServiceBitmapData"
resultType=
"com.mmc.iuav.user.entity.WebsiteInfoDO"
>
<select
id=
"listServiceBitmapData"
resultType=
"com.mmc.iuav.user.entity.WebsiteInfoDO"
>
SELECT id,
SELECT wi.id,
`name`,
wi.`name`,
address,
wi.address,
lat,
wi.lat,
lon,
wi.lon,
`type`,
wi.type,
user_apply_tag,
wi.user_apply_tag,
st_distance_sphere(point(lon, lat), point(${lon}, ${lat})) as distance
st_distance_sphere(
FROM website_info
point(wi.lon, wi.lat),
where type = #{type}
point(${lon}, ${lat})) AS distance,
ua.content,
ua.score
FROM website_info wi
INNER JOIN user_apply_tag ua ON wi.user_apply_tag = ua.id
WHERE wi.type = #{type}
ORDER BY distance ASC
ORDER BY distance ASC
LIMIT #{pageNo}, #{pageSize}
LIMIT #{pageNo}, #{pageSize}
</select>
</select>
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论