Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cloud-platform
Project
Project
Details
Activity
Releases
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
youjj
cloud-platform
Commits
24c992ee
Commit
24c992ee
authored
Sep 18, 2019
by
libin
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master-ucc-feature' into dev
parents
c08179f5
eb902b27
Changes
23
Show whitespace changes
Inline
Side-by-side
Showing
23 changed files
with
469 additions
and
64 deletions
+469
-64
CampsiteShopFindDTO.java
...a/com/xxfc/platform/campsite/dto/CampsiteShopFindDTO.java
+2
-0
CampsiteFeign.java
.../java/com/xxfc/platform/campsite/feign/CampsiteFeign.java
+11
-3
CampsiteShopBiz.java
.../java/com/xxfc/platform/campsite/biz/CampsiteShopBiz.java
+16
-6
CampsiteShopMapper.java
...com/xxfc/platform/campsite/mapper/CampsiteShopMapper.java
+5
-4
CampsiteShopController.java
...m/xxfc/platform/campsite/rest/CampsiteShopController.java
+15
-9
CampsiteShopMapper.xml
...e-server/src/main/resources/mapper/CampsiteShopMapper.xml
+6
-3
TourFeign.java
...src/main/java/com/xxfc/platform/tour/feign/TourFeign.java
+17
-12
TourGoodBiz.java
...src/main/java/com/xxfc/platform/tour/biz/TourGoodBiz.java
+1
-1
TourGoodController.java
.../java/com/xxfc/platform/tour/rest/TourGoodController.java
+5
-4
TourGwController.java
...in/java/com/xxfc/platform/tour/rest/TourGwController.java
+6
-4
ServiceConstant.java
.../java/com/xxfc/platform/uccn/comstnt/ServiceConstant.java
+41
-0
SearchResultVo.java
...c/main/java/com/xxfc/platform/uccn/vo/SearchResultVo.java
+18
-0
ServiceResultVo.java
.../main/java/com/xxfc/platform/uccn/vo/ServiceResultVo.java
+23
-0
ArticleBiz.java
.../src/main/java/com/xxfc/platform/uccn/biz/ArticleBiz.java
+4
-4
SearchBiz.java
...r/src/main/java/com/xxfc/platform/uccn/biz/SearchBiz.java
+233
-0
SummitActivityBiz.java
...in/java/com/xxfc/platform/uccn/biz/SummitActivityBiz.java
+5
-1
ArticleMapper.java
...ain/java/com/xxfc/platform/uccn/mapper/ArticleMapper.java
+1
-1
ArticleController.java
...n/java/com/xxfc/platform/uccn/rest/ArticleController.java
+3
-2
CampsiteUccnController.java
...a/com/xxfc/platform/uccn/rest/CampsiteUccnController.java
+9
-2
GwTourController.java
...in/java/com/xxfc/platform/uccn/rest/GwTourController.java
+9
-6
SearchController.java
...in/java/com/xxfc/platform/uccn/rest/SearchController.java
+33
-0
SummitActivityController.java
...com/xxfc/platform/uccn/rest/SummitActivityController.java
+3
-2
ArticleMapper.xml
...x-uccn-server/src/main/resources/mapper/ArticleMapper.xml
+3
-0
No files found.
xx-campsite/xx-campsite-api/src/main/java/com/xxfc/platform/campsite/dto/CampsiteShopFindDTO.java
View file @
24c992ee
...
@@ -17,4 +17,6 @@ public class CampsiteShopFindDTO extends PageParam {
...
@@ -17,4 +17,6 @@ public class CampsiteShopFindDTO extends PageParam {
private
Integer
addrCity
;
private
Integer
addrCity
;
private
Integer
type
;
private
Integer
type
;
private
String
name
;
}
}
xx-campsite/xx-campsite-api/src/main/java/com/xxfc/platform/campsite/feign/CampsiteFeign.java
View file @
24c992ee
...
@@ -4,11 +4,15 @@ package com.xxfc.platform.campsite.feign;
...
@@ -4,11 +4,15 @@ package com.xxfc.platform.campsite.feign;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.vo.GoodDataVO
;
import
com.github.wxiaoqi.security.common.vo.GoodDataVO
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.sun.org.apache.regexp.internal.RE
;
import
com.xxfc.platform.campsite.dto.CampsiteShopFindDTO
;
import
com.xxfc.platform.campsite.vo.CampsiteShopDetailVo
;
import
com.xxfc.platform.campsite.vo.CampsiteShopDetailVo
;
import
com.xxfc.platform.campsite.vo.CampsiteShopPageVo
;
import
com.xxfc.platform.campsite.vo.CampsiteShopPageVo
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.cloud.openfeign.FeignClient
;
import
org.springframework.cloud.openfeign.FeignClient
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
java.util.List
;
import
java.util.List
;
...
@@ -30,9 +34,10 @@ public interface CampsiteFeign {
...
@@ -30,9 +34,10 @@ public interface CampsiteFeign {
@ApiOperation
(
"分页查询营地列表"
)
@ApiOperation
(
"分页查询营地列表"
)
@GetMapping
(
"/app/unauth/shops"
)
@GetMapping
(
"/app/unauth/shops"
)
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsiteShopPageByType
(
@RequestParam
(
value
=
"type"
,
required
=
false
)
Integer
type
,
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsiteShopPageByType
AndName
(
@RequestParam
(
value
=
"type"
,
required
=
false
)
Integer
type
,
@RequestParam
(
value
=
"pageNo"
,
required
=
false
,
defaultValue
=
"1"
)
Integer
pageNo
,
@RequestParam
(
value
=
"pageNo"
,
required
=
false
,
defaultValue
=
"1"
)
Integer
pageNo
,
@RequestParam
(
value
=
"pageSize"
,
required
=
false
,
defaultValue
=
"6"
)
Integer
pageSize
);
@RequestParam
(
value
=
"pageSize"
,
required
=
false
,
defaultValue
=
"6"
)
Integer
pageSize
,
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
);
/**
/**
* @param longitude 经度
* @param longitude 经度
...
@@ -44,4 +49,7 @@ public interface CampsiteFeign {
...
@@ -44,4 +49,7 @@ public interface CampsiteFeign {
ObjectRestResponse
<
CampsiteShopDetailVo
>
findCampsiteShopDetailById
(
@RequestParam
(
value
=
"id"
)
Integer
id
,
ObjectRestResponse
<
CampsiteShopDetailVo
>
findCampsiteShopDetailById
(
@RequestParam
(
value
=
"id"
)
Integer
id
,
@RequestParam
(
value
=
"longitude"
,
required
=
false
)
Double
longitude
,
@RequestParam
(
value
=
"longitude"
,
required
=
false
)
Double
longitude
,
@RequestParam
(
value
=
"latitude"
,
required
=
false
)
Double
latitude
);
@RequestParam
(
value
=
"latitude"
,
required
=
false
)
Double
latitude
);
@PostMapping
(
value
=
"/app/unauth/campsites"
)
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsiteShopPageForUncc
(
@RequestBody
CampsiteShopFindDTO
campsiteShopFindDTO
);
}
}
xx-campsite/xx-campsite-server/src/main/java/com/xxfc/platform/campsite/biz/CampsiteShopBiz.java
View file @
24c992ee
...
@@ -91,9 +91,17 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
...
@@ -91,9 +91,17 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
return
JSONObject
.
parseObject
(
result
,
new
TypeReference
<
PageDataVO
<
CampsiteShopPageVo
>>()
{
return
JSONObject
.
parseObject
(
result
,
new
TypeReference
<
PageDataVO
<
CampsiteShopPageVo
>>()
{
});
});
}
}
PageDataVO
<
CampsiteShopPageVo
>
campsiteShopPageDataVO
=
new
PageDataVO
<>();
PageDataVO
<
CampsiteShopPageVo
>
campsiteShopPageDataVO
=
findCampsiteShopPageByTypeAndName
(
campsiteShopFindDTO
);
campHashOperations
.
put
(
CAMPSITE_LIST_CACHE_PREKEY
,
campsite_cache_key
,
JSONObject
.
toJSONString
(
campsiteShopPageDataVO
));
return
campsiteShopPageDataVO
;
}
PageDataVO
<
CampsiteShopPageDTO
>
pageDataVO
=
PageDataVO
.
pageInfo
(
campsiteShopFindDTO
.
getPage
(),
campsiteShopFindDTO
.
getLimit
(),
()
->
mapper
.
findAllCampsiteShopsByTypeOrCode
(
campsiteShopFindDTO
.
getType
(),
campsiteShopFindDTO
.
getAddrProvince
(),
campsiteShopFindDTO
.
getAddrCity
()));
public
PageDataVO
<
CampsiteShopPageVo
>
findCampsiteShopPageByTypeAndName
(
CampsiteShopFindDTO
campsiteShopFindDTO
){
PageDataVO
<
CampsiteShopPageVo
>
campsiteShopPageDataVO
=
new
PageDataVO
<>();
PageDataVO
<
CampsiteShopPageDTO
>
pageDataVO
=
PageDataVO
.
pageInfo
(
campsiteShopFindDTO
.
getPage
(),
campsiteShopFindDTO
.
getLimit
(),
()
->
mapper
.
findAllCampsiteShopsByTypeOrCodeOrName
(
campsiteShopFindDTO
.
getType
(),
campsiteShopFindDTO
.
getAddrProvince
(),
campsiteShopFindDTO
.
getAddrCity
(),
campsiteShopFindDTO
.
getName
()));
List
<
CampsiteShopPageDTO
>
campsiteShopPageDTOS
=
pageDataVO
.
getData
();
List
<
CampsiteShopPageDTO
>
campsiteShopPageDTOS
=
pageDataVO
.
getData
();
if
(
CollectionUtils
.
isEmpty
(
campsiteShopPageDTOS
))
{
if
(
CollectionUtils
.
isEmpty
(
campsiteShopPageDTOS
))
{
campsiteShopPageDataVO
.
setPageNum
(
campsiteShopFindDTO
.
getPage
());
campsiteShopPageDataVO
.
setPageNum
(
campsiteShopFindDTO
.
getPage
());
...
@@ -106,7 +114,6 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
...
@@ -106,7 +114,6 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
if
(
log
.
isDebugEnabled
())
{
if
(
log
.
isDebugEnabled
())
{
log
.
debug
(
"根据type=【{}】查询到的店铺数据:【{}】"
,
campsiteShopFindDTO
.
getType
(),
campsiteShopPageDTOS
);
log
.
debug
(
"根据type=【{}】查询到的店铺数据:【{}】"
,
campsiteShopFindDTO
.
getType
(),
campsiteShopPageDTOS
);
}
}
List
<
CampsiteShopPageVo
>
campsiteShopPageVoList
=
new
ArrayList
<>();
List
<
CampsiteShopPageVo
>
campsiteShopPageVoList
=
new
ArrayList
<>();
campsiteShopPageDTOS
=
campsiteShopPageDTOS
.
stream
().
distinct
().
collect
(
Collectors
.
toList
());
campsiteShopPageDTOS
=
campsiteShopPageDTOS
.
stream
().
distinct
().
collect
(
Collectors
.
toList
());
for
(
CampsiteShopPageDTO
campsiteShopPageDTO
:
campsiteShopPageDTOS
)
{
for
(
CampsiteShopPageDTO
campsiteShopPageDTO
:
campsiteShopPageDTOS
)
{
...
@@ -115,14 +122,11 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
...
@@ -115,14 +122,11 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
campsiteShopPageVoList
.
add
(
campsiteShopPageVo
);
campsiteShopPageVoList
.
add
(
campsiteShopPageVo
);
}
}
campsiteShopPageVoList
.
sort
(
Comparator
.
comparing
(
CampsiteShopPageVo:
:
getHot
).
reversed
().
thenComparing
(
CampsiteShopPageVo:
:
getCrtTime
).
reversed
());
campsiteShopPageVoList
.
sort
(
Comparator
.
comparing
(
CampsiteShopPageVo:
:
getHot
).
reversed
().
thenComparing
(
CampsiteShopPageVo:
:
getCrtTime
).
reversed
());
campsiteShopPageDataVO
.
setTotalPage
(
pageDataVO
.
getTotalPage
());
campsiteShopPageDataVO
.
setTotalPage
(
pageDataVO
.
getTotalPage
());
campsiteShopPageDataVO
.
setTotalCount
(
pageDataVO
.
getTotalCount
());
campsiteShopPageDataVO
.
setTotalCount
(
pageDataVO
.
getTotalCount
());
campsiteShopPageDataVO
.
setPageSize
(
pageDataVO
.
getPageSize
());
campsiteShopPageDataVO
.
setPageSize
(
pageDataVO
.
getPageSize
());
campsiteShopPageDataVO
.
setPageNum
(
pageDataVO
.
getPageNum
());
campsiteShopPageDataVO
.
setPageNum
(
pageDataVO
.
getPageNum
());
campsiteShopPageDataVO
.
setData
(
campsiteShopPageVoList
);
campsiteShopPageDataVO
.
setData
(
campsiteShopPageVoList
);
campHashOperations
.
put
(
CAMPSITE_LIST_CACHE_PREKEY
,
campsite_cache_key
,
JSONObject
.
toJSONString
(
campsiteShopPageDataVO
));
return
campsiteShopPageDataVO
;
return
campsiteShopPageDataVO
;
}
}
...
@@ -329,6 +333,11 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
...
@@ -329,6 +333,11 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
return
true
;
return
true
;
}
}
public
PageDataVO
<
CampsiteShopPageVo
>
findCampsiteShopPageForUncc
(
CampsiteShopFindDTO
campsiteShopFindDTO
)
{
return
findCampsiteShopPageByTypeAndName
(
campsiteShopFindDTO
);
}
private
long
transformStartTime
(
Long
startTime
)
{
private
long
transformStartTime
(
Long
startTime
)
{
return
LocalDateTime
.
ofInstant
(
new
Date
(
startTime
).
toInstant
(),
ZoneOffset
.
ofHours
(+
8
))
return
LocalDateTime
.
ofInstant
(
new
Date
(
startTime
).
toInstant
(),
ZoneOffset
.
ofHours
(+
8
))
.
withHour
(
0
)
.
withHour
(
0
)
...
@@ -399,4 +408,5 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
...
@@ -399,4 +408,5 @@ public class CampsiteShopBiz extends BaseBiz<CampsiteShopMapper, CampsiteShop> {
s
=
s
*
EARTH_RADIUS
;
s
=
s
*
EARTH_RADIUS
;
return
s
;
return
s
;
}
}
}
}
\ No newline at end of file
xx-campsite/xx-campsite-server/src/main/java/com/xxfc/platform/campsite/mapper/CampsiteShopMapper.java
View file @
24c992ee
...
@@ -26,9 +26,10 @@ public interface CampsiteShopMapper extends Mapper<CampsiteShop> {
...
@@ -26,9 +26,10 @@ public interface CampsiteShopMapper extends Mapper<CampsiteShop> {
*
*
* @param typeId
* @param typeId
*/
*/
List
<
CampsiteShopPageDTO
>
findAllCampsiteShopsByTypeOrCode
(
@Param
(
"typeId"
)
Integer
typeId
,
List
<
CampsiteShopPageDTO
>
findAllCampsiteShopsByTypeOrCode
OrName
(
@Param
(
"typeId"
)
Integer
typeId
,
@Param
(
"proviceCode"
)
Integer
proviceCode
,
@Param
(
"proviceCode"
)
Integer
proviceCode
,
@Param
(
"cityCode"
)
Integer
cityCode
);
@Param
(
"cityCode"
)
Integer
cityCode
,
@Param
(
"name"
)
String
name
);
/**
/**
* 首页营地列表
* 首页营地列表
...
@@ -82,7 +83,7 @@ public interface CampsiteShopMapper extends Mapper<CampsiteShop> {
...
@@ -82,7 +83,7 @@ public interface CampsiteShopMapper extends Mapper<CampsiteShop> {
* @param name
* @param name
* @return
* @return
*/
*/
int
checkNameExist
(
@Param
(
"id"
)
Integer
id
,
@Param
(
"name"
)
String
name
);
int
checkNameExist
(
@Param
(
"id"
)
Integer
id
,
@Param
(
"name"
)
String
name
);
}
}
xx-campsite/xx-campsite-server/src/main/java/com/xxfc/platform/campsite/rest/CampsiteShopController.java
View file @
24c992ee
...
@@ -29,7 +29,7 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
...
@@ -29,7 +29,7 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
@ApiOperation
(
"分页查询营地列表"
)
@ApiOperation
(
"分页查询营地列表"
)
@GetMapping
(
"/app/unauth/shops"
)
@GetMapping
(
"/app/unauth/shops"
)
public
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsiteShopPageByType
(
@RequestParam
(
value
=
"type"
,
required
=
false
)
Integer
type
,
public
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsiteShopPageByType
AndName
(
@RequestParam
(
value
=
"type"
,
required
=
false
)
Integer
type
,
@RequestParam
(
value
=
"pageNo"
,
required
=
false
,
defaultValue
=
"1"
)
Integer
pageNo
,
@RequestParam
(
value
=
"pageNo"
,
required
=
false
,
defaultValue
=
"1"
)
Integer
pageNo
,
@RequestParam
(
value
=
"pageSize"
,
required
=
false
,
defaultValue
=
"6"
)
Integer
pageSize
)
{
@RequestParam
(
value
=
"pageSize"
,
required
=
false
,
defaultValue
=
"6"
)
Integer
pageSize
)
{
CampsiteShopFindDTO
campsiteShopFindDTO
=
new
CampsiteShopFindDTO
();
CampsiteShopFindDTO
campsiteShopFindDTO
=
new
CampsiteShopFindDTO
();
...
@@ -38,8 +38,13 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
...
@@ -38,8 +38,13 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
campsiteShopFindDTO
.
setLimit
(
pageSize
);
campsiteShopFindDTO
.
setLimit
(
pageSize
);
PageDataVO
<
CampsiteShopPageVo
>
pageDataVO
=
getBaseBiz
().
findCampsiteShopPageByType
(
campsiteShopFindDTO
);
PageDataVO
<
CampsiteShopPageVo
>
pageDataVO
=
getBaseBiz
().
findCampsiteShopPageByType
(
campsiteShopFindDTO
);
return
ObjectRestResponse
.
succ
(
pageDataVO
);
return
ObjectRestResponse
.
succ
(
pageDataVO
);
}
}
@PostMapping
(
value
=
"/app/unauth/campsites"
)
public
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsiteShopPageForUncc
(
@RequestBody
CampsiteShopFindDTO
campsiteShopFindDTO
)
{
PageDataVO
<
CampsiteShopPageVo
>
campsiteShops
=
baseBiz
.
findCampsiteShopPageForUncc
(
campsiteShopFindDTO
);
return
ObjectRestResponse
.
succ
(
campsiteShops
);
}
/**
/**
* @param longitude 经度
* @param longitude 经度
...
@@ -49,8 +54,8 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
...
@@ -49,8 +54,8 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
@ApiOperation
(
"查询营地详情"
)
@ApiOperation
(
"查询营地详情"
)
@GetMapping
(
"/app/unauth/shop"
)
@GetMapping
(
"/app/unauth/shop"
)
public
ObjectRestResponse
<
CampsiteShopDetailVo
>
findCampsiteShopDetailById
(
@RequestParam
(
value
=
"id"
)
Integer
id
,
public
ObjectRestResponse
<
CampsiteShopDetailVo
>
findCampsiteShopDetailById
(
@RequestParam
(
value
=
"id"
)
Integer
id
,
@RequestParam
(
value
=
"longitude"
,
required
=
false
)
Double
longitude
,
@RequestParam
(
value
=
"longitude"
,
required
=
false
)
Double
longitude
,
@RequestParam
(
value
=
"latitude"
,
required
=
false
)
Double
latitude
)
{
@RequestParam
(
value
=
"latitude"
,
required
=
false
)
Double
latitude
)
{
CampsiteShopDetailVo
campsiteShopDetailVo
=
getBaseBiz
().
findCampsiteShopDetailById
(
id
,
longitude
,
latitude
);
CampsiteShopDetailVo
campsiteShopDetailVo
=
getBaseBiz
().
findCampsiteShopDetailById
(
id
,
longitude
,
latitude
);
return
ObjectRestResponse
.
succ
(
campsiteShopDetailVo
);
return
ObjectRestResponse
.
succ
(
campsiteShopDetailVo
);
}
}
...
@@ -58,8 +63,8 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
...
@@ -58,8 +63,8 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
@ApiOperation
(
"首页营地列表"
)
@ApiOperation
(
"首页营地列表"
)
@GetMapping
(
value
=
"/app/shopList"
)
@GetMapping
(
value
=
"/app/shopList"
)
public
List
<
GoodDataVO
>
goodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
public
List
<
GoodDataVO
>
goodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"4"
)
Integer
limit
)
{
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"4"
)
Integer
limit
)
{
return
getBaseBiz
().
getAllByHome
(
page
,
limit
);
return
getBaseBiz
().
getAllByHome
(
page
,
limit
);
}
}
@ApiOperation
(
"随机获取营地"
)
@ApiOperation
(
"随机获取营地"
)
...
@@ -67,8 +72,9 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
...
@@ -67,8 +72,9 @@ public class CampsiteShopController extends BaseController<CampsiteShopBiz, Camp
public
ObjectRestResponse
findRandomVehicle
(
Integer
number
)
{
public
ObjectRestResponse
findRandomVehicle
(
Integer
number
)
{
return
baseBiz
.
findRandomVehicle
(
number
);
return
baseBiz
.
findRandomVehicle
(
number
);
}
}
@PostMapping
(
value
=
"/app/unauth/webchat_official/campsites"
)
@PostMapping
(
value
=
"/app/unauth/webchat_official/campsites"
)
public
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsitesForPublicNumber
(
@RequestBody
CampsiteShopFindDTO
campsiteShopFindDTO
)
{
public
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsitesForPublicNumber
(
@RequestBody
CampsiteShopFindDTO
campsiteShopFindDTO
)
{
PageDataVO
<
CampsiteShopPageVo
>
campsiteShops
=
baseBiz
.
findCampsiteShopPageByType
(
campsiteShopFindDTO
);
PageDataVO
<
CampsiteShopPageVo
>
campsiteShops
=
baseBiz
.
findCampsiteShopPageByType
(
campsiteShopFindDTO
);
return
ObjectRestResponse
.
succ
(
campsiteShops
);
return
ObjectRestResponse
.
succ
(
campsiteShops
);
...
...
xx-campsite/xx-campsite-server/src/main/resources/mapper/CampsiteShopMapper.xml
View file @
24c992ee
...
@@ -36,7 +36,7 @@
...
@@ -36,7 +36,7 @@
</resultMap>
</resultMap>
<!--根据类型查询全部-->
<!--根据类型查询全部-->
<select
id=
"findAllCampsiteShopsByTypeOrCode"
resultType=
"com.xxfc.platform.campsite.dto.CampsiteShopPageDTO"
>
<select
id=
"findAllCampsiteShopsByTypeOrCode
OrName
"
resultType=
"com.xxfc.platform.campsite.dto.CampsiteShopPageDTO"
>
SELECT
SELECT
cs.id AS `id`,
cs.id AS `id`,
cs. NAME AS `name`,
cs. NAME AS `name`,
...
@@ -63,10 +63,13 @@
...
@@ -63,10 +63,13 @@
and cst.tag_id=#{typeId}
and cst.tag_id=#{typeId}
</if>
</if>
<if
test=
"proviceCode != null"
>
<if
test=
"proviceCode != null"
>
and `province`=#{proviceCode}
and
cs.
`province`=#{proviceCode}
</if>
</if>
<if
test=
"cityCode != null"
>
<if
test=
"cityCode != null"
>
and `city`=#{cityCode}
and cs.`city`=#{cityCode}
</if>
<if
test=
"name!=null and name!=''"
>
and cs.`name` like concat('%',#{name},'%')
</if>
</if>
GROUP BY cs.id
GROUP BY cs.id
order by cs.hot DESC,cs.crt_time DESC
order by cs.hot DESC,cs.crt_time DESC
...
...
xx-tour/xx-tour-api/src/main/java/com/xxfc/platform/tour/feign/TourFeign.java
View file @
24c992ee
...
@@ -37,6 +37,7 @@ public interface TourFeign {
...
@@ -37,6 +37,7 @@ public interface TourFeign {
/**
/**
* 计算价格
* 计算价格
*
* @param spePriceDto
* @param spePriceDto
* @return
* @return
*/
*/
...
@@ -44,7 +45,6 @@ public interface TourFeign {
...
@@ -44,7 +45,6 @@ public interface TourFeign {
public
ObjectRestResponse
<
TourSpePriceVo
>
refund
(
@RequestBody
TourSpePriceDTO
spePriceDto
);
public
ObjectRestResponse
<
TourSpePriceVo
>
refund
(
@RequestBody
TourSpePriceDTO
spePriceDto
);
/**
/**
*
* @param speId
* @param speId
* @param number
* @param number
* @param type 1--减库存,2--加库存
* @param type 1--减库存,2--加库存
...
@@ -65,6 +65,7 @@ public interface TourFeign {
...
@@ -65,6 +65,7 @@ public interface TourFeign {
/**
/**
* 更新发车状态
* 更新发车状态
*
* @param verficationId
* @param verficationId
* @return
* @return
*/
*/
...
@@ -73,15 +74,17 @@ public interface TourFeign {
...
@@ -73,15 +74,17 @@ public interface TourFeign {
/**
/**
* 更新总人数或上车人数
* 更新总人数或上车人数
*
* @param verficationId
* @param verficationId
* @param properties
* @param properties
* @return
* @return
*/
*/
@PutMapping
(
"/tourGood/verfication/personnums"
)
@PutMapping
(
"/tourGood/verfication/personnums"
)
ObjectRestResponse
<
Void
>
updateTourGoodPersonNum
(
@RequestParam
(
"verficationId"
)
Integer
verficationId
,
@RequestParam
(
"properties"
)
String
properties
,
@RequestParam
(
"number"
)
Integer
number
);
ObjectRestResponse
<
Void
>
updateTourGoodPersonNum
(
@RequestParam
(
"verficationId"
)
Integer
verficationId
,
@RequestParam
(
"properties"
)
String
properties
,
@RequestParam
(
"number"
)
Integer
number
);
/**
/**
* 查询订单列表
* 查询订单列表
*
* @param tourGoodOrderFindVo
* @param tourGoodOrderFindVo
* @return
* @return
*/
*/
...
@@ -91,11 +94,11 @@ public interface TourFeign {
...
@@ -91,11 +94,11 @@ public interface TourFeign {
@ApiOperation
(
"首页旅游列表"
)
@ApiOperation
(
"首页旅游列表"
)
@GetMapping
(
value
=
"/tourGood/app/shopList"
)
@GetMapping
(
value
=
"/tourGood/app/shopList"
)
public
List
<
GoodDataVO
>
goodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
public
List
<
GoodDataVO
>
goodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"4"
)
Integer
limit
);
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"4"
)
Integer
limit
);
//获取商品信息
//获取商品信息
@RequestMapping
(
value
=
"/good/app/unauth/one"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
value
=
"/good/app/unauth/one"
,
method
=
RequestMethod
.
GET
)
public
TourGood
one
(
@RequestParam
(
value
=
"goodId"
,
defaultValue
=
"0"
)
Integer
goodId
);
public
TourGood
one
(
@RequestParam
(
value
=
"goodId"
,
defaultValue
=
"0"
)
Integer
goodId
);
@GetMapping
(
"/tourGoodSite/departure_time"
)
@GetMapping
(
"/tourGoodSite/departure_time"
)
Long
selectDepartureTimeByStartCompanyIdAndRouteId
(
@RequestParam
(
value
=
"companyId"
)
Integer
companyId
,
@RequestParam
(
value
=
"goodId"
)
Integer
routeId
);
Long
selectDepartureTimeByStartCompanyIdAndRouteId
(
@RequestParam
(
value
=
"companyId"
)
Integer
companyId
,
@RequestParam
(
value
=
"goodId"
)
Integer
routeId
);
...
@@ -107,13 +110,15 @@ public interface TourFeign {
...
@@ -107,13 +110,15 @@ public interface TourFeign {
Date
selectDepartureDataBySpeId
(
@RequestParam
(
value
=
"speIds"
)
Integer
speIds
);
Date
selectDepartureDataBySpeId
(
@RequestParam
(
value
=
"speIds"
)
Integer
speIds
);
@GetMapping
(
value
=
"/tourGood/app/unauth/findRandomVehicle"
)
@GetMapping
(
value
=
"/tourGood/app/unauth/findRandomVehicle"
)
public
ObjectRestResponse
findRandomVehicle
(
@RequestParam
(
value
=
"number"
)
Integer
number
);
public
ObjectRestResponse
findRandomVehicle
(
@RequestParam
(
value
=
"number"
)
Integer
number
);
//查询旅游路线列表
//查询旅游路线列表
@RequestMapping
(
value
=
"/gw/app/unauth/getGoodList"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
value
=
"/gw/app/unauth/getGoodList"
,
method
=
RequestMethod
.
GET
)
ObjectRestResponse
getGoodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
ObjectRestResponse
<
PageDataVO
<
TourGood
>>
getGoodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
@RequestParam
(
value
=
"tagId"
,
required
=
false
)
Integer
tagId
);
@RequestParam
(
value
=
"tagId"
,
required
=
false
)
Integer
tagId
,
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
);
//获取公司详情
//获取公司详情
@GetMapping
(
"/gw/app/unauth/detail/{id}"
)
@GetMapping
(
"/gw/app/unauth/detail/{id}"
)
ObjectRestResponse
getOne
(
@PathVariable
Integer
id
);
ObjectRestResponse
getOne
(
@PathVariable
Integer
id
);
...
@@ -121,11 +126,11 @@ public interface TourFeign {
...
@@ -121,11 +126,11 @@ public interface TourFeign {
//首页旅游列表
//首页旅游列表
@GetMapping
(
value
=
"/gw/shopList"
)
@GetMapping
(
value
=
"/gw/shopList"
)
List
<
GoodDataVO
>
goodListAll
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
List
<
GoodDataVO
>
goodListAll
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"4"
)
Integer
limit
);
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"4"
)
Integer
limit
);
//旅游标签列表
//旅游标签列表
@GetMapping
(
value
=
"/gw/tagList"
)
@GetMapping
(
value
=
"/gw/tagList"
)
List
<
TourTag
>
tagList
(
@RequestParam
(
value
=
"isHot"
,
defaultValue
=
"0"
)
Integer
isHot
);
List
<
TourTag
>
tagList
(
@RequestParam
(
value
=
"isHot"
,
defaultValue
=
"0"
)
Integer
isHot
);
}
}
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/biz/TourGoodBiz.java
View file @
24c992ee
...
@@ -63,7 +63,7 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
...
@@ -63,7 +63,7 @@ public class TourGoodBiz extends BaseBiz<TourGoodMapper, TourGood> {
* @param distance
* @param distance
* @return
* @return
*/
*/
public
ObjectRestResponse
<
TourGood
>
getGoodList
(
int
page
,
int
limit
,
String
query
,
Double
latitude
,
Double
longitude
,
Integer
tagId
,
Double
distance
){
public
ObjectRestResponse
<
PageDataVO
<
TourGood
>
>
getGoodList
(
int
page
,
int
limit
,
String
query
,
Double
latitude
,
Double
longitude
,
Integer
tagId
,
Double
distance
){
Map
<
String
,
Object
>
params
=
initParam
(
page
,
limit
,
query
,
latitude
,
longitude
,
tagId
,
distance
);
Map
<
String
,
Object
>
params
=
initParam
(
page
,
limit
,
query
,
latitude
,
longitude
,
tagId
,
distance
);
PageDataVO
<
TourGood
>
dataVO
=
null
;
PageDataVO
<
TourGood
>
dataVO
=
null
;
if
(
latitude
!=
null
&&
latitude
>
0
&&
longitude
!=
null
&&
longitude
>
0
){
if
(
latitude
!=
null
&&
latitude
>
0
&&
longitude
!=
null
&&
longitude
>
0
){
...
...
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/rest/TourGoodController.java
View file @
24c992ee
...
@@ -4,6 +4,7 @@ import com.github.wxiaoqi.security.auth.client.annotation.IgnoreClientToken;
...
@@ -4,6 +4,7 @@ import com.github.wxiaoqi.security.auth.client.annotation.IgnoreClientToken;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.github.wxiaoqi.security.common.vo.GoodDataVO
;
import
com.github.wxiaoqi.security.common.vo.GoodDataVO
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.xxfc.platform.tour.biz.TourGoodBiz
;
import
com.xxfc.platform.tour.biz.TourGoodBiz
;
import
com.xxfc.platform.tour.dto.GoodSearchDTO
;
import
com.xxfc.platform.tour.dto.GoodSearchDTO
;
import
com.xxfc.platform.tour.entity.TourGood
;
import
com.xxfc.platform.tour.entity.TourGood
;
...
@@ -33,7 +34,7 @@ public class TourGoodController extends BaseController<TourGoodBiz, TourGood> {
...
@@ -33,7 +34,7 @@ public class TourGoodController extends BaseController<TourGoodBiz, TourGood> {
@RequestMapping
(
value
=
"/app/unauth/getGoodList"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
value
=
"/app/unauth/getGoodList"
,
method
=
RequestMethod
.
GET
)
@IgnoreClientToken
@IgnoreClientToken
@ResponseBody
@ResponseBody
public
ObjectRestResponse
<
TourGood
>
getGoodList
(
@RequestParam
(
value
=
"page"
,
required
=
true
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
public
ObjectRestResponse
<
PageDataVO
<
TourGood
>
>
getGoodList
(
@RequestParam
(
value
=
"page"
,
required
=
true
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
@RequestParam
(
value
=
"query"
,
required
=
false
)
String
query
,
@RequestParam
(
value
=
"latitude"
,
required
=
false
)
Double
latitude
,
@RequestParam
(
value
=
"query"
,
required
=
false
)
String
query
,
@RequestParam
(
value
=
"latitude"
,
required
=
false
)
Double
latitude
,
@RequestParam
(
value
=
"longitude"
,
required
=
false
)
Double
longitude
,
@RequestParam
(
value
=
"tagId"
,
required
=
false
)
Integer
tagId
,
@RequestParam
(
value
=
"longitude"
,
required
=
false
)
Double
longitude
,
@RequestParam
(
value
=
"tagId"
,
required
=
false
)
Integer
tagId
,
@RequestParam
(
value
=
"distance"
,
defaultValue
=
"100"
)
Double
distance
)
{
@RequestParam
(
value
=
"distance"
,
defaultValue
=
"100"
)
Double
distance
)
{
...
...
xx-tour/xx-tour-server/src/main/java/com/xxfc/platform/tour/rest/TourGwController.java
View file @
24c992ee
...
@@ -5,6 +5,7 @@ import com.github.wxiaoqi.security.auth.client.annotation.IgnoreUserToken;
...
@@ -5,6 +5,7 @@ import com.github.wxiaoqi.security.auth.client.annotation.IgnoreUserToken;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.github.wxiaoqi.security.common.rest.BaseController
;
import
com.github.wxiaoqi.security.common.vo.GoodDataVO
;
import
com.github.wxiaoqi.security.common.vo.GoodDataVO
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.xxfc.platform.tour.biz.TourGoodBiz
;
import
com.xxfc.platform.tour.biz.TourGoodBiz
;
import
com.xxfc.platform.tour.biz.TourGoodDetailBiz
;
import
com.xxfc.platform.tour.biz.TourGoodDetailBiz
;
import
com.xxfc.platform.tour.biz.TourTagBiz
;
import
com.xxfc.platform.tour.biz.TourTagBiz
;
...
@@ -38,10 +39,11 @@ public class TourGwController extends BaseController<TourGoodBiz, TourGood> {
...
@@ -38,10 +39,11 @@ public class TourGwController extends BaseController<TourGoodBiz, TourGood> {
*/
*/
@ApiOperation
(
"查询旅游路线列表"
)
@ApiOperation
(
"查询旅游路线列表"
)
@RequestMapping
(
value
=
"/app/unauth/getGoodList"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
value
=
"/app/unauth/getGoodList"
,
method
=
RequestMethod
.
GET
)
public
ObjectRestResponse
getGoodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
public
ObjectRestResponse
<
PageDataVO
<
TourGood
>>
getGoodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
@RequestParam
(
value
=
"tagId"
,
required
=
false
)
Integer
tagId
)
{
@RequestParam
(
value
=
"tagId"
,
required
=
false
)
Integer
tagId
,
return
baseBiz
.
getGoodList
(
page
,
limit
,
""
,
null
,
null
,
tagId
,
null
);
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
)
{
return
baseBiz
.
getGoodList
(
page
,
limit
,
name
,
null
,
null
,
tagId
,
null
);
}
}
@GetMapping
(
"/app/unauth/detail/{id}"
)
@GetMapping
(
"/app/unauth/detail/{id}"
)
...
...
xx-uccn/xx-uccn-api/src/main/java/com/xxfc/platform/uccn/comstnt/ServiceConstant.java
0 → 100644
View file @
24c992ee
package
com
.
xxfc
.
platform
.
uccn
.
comstnt
;
/**
* @author libin
* @version 1.0
* @description
* @data 2019/9/18 9:21
*/
public
class
ServiceConstant
{
/**
* 车型
*/
public
static
final
String
VEHICLE
=
"vehicle"
;
public
static
final
Integer
VEHICLE_LIMIT
=
2
;
/**
* 分公司
*/
public
static
final
String
BRANCH_COMPANY
=
"company"
;
public
static
final
Integer
BRANCH_COMPANY_LIMIT
=
4
;
/**
* 旅游
*/
public
static
final
String
TROUR
=
"tour"
;
public
static
final
Integer
TOUR_LIMIT
=
2
;
/**
* 营地
*/
public
static
final
String
CAMPSITE
=
"campsite"
;
public
static
final
Integer
CAMPSITE_LIMIT
=
2
;
/**
* 新闻
*/
public
static
final
String
NEWS
=
"news"
;
public
static
final
Integer
NEWS_LIMIT
=
4
;
/**
* 活动
*/
public
static
final
String
ACTIVITY
=
"activity"
;
public
static
final
Integer
ACTIVITY_LIMIT
=
4
;
}
xx-uccn/xx-uccn-api/src/main/java/com/xxfc/platform/uccn/vo/SearchResultVo.java
0 → 100644
View file @
24c992ee
package
com
.
xxfc
.
platform
.
uccn
.
vo
;
import
lombok.Builder
;
import
lombok.NoArgsConstructor
;
import
java.util.HashMap
;
/**
* @author libin
* @version 1.0
* @description
* @data 2019/9/17 10:00
*/
@Builder
(
toBuilder
=
true
)
@NoArgsConstructor
public
class
SearchResultVo
extends
HashMap
<
String
,
Object
>
{
}
xx-uccn/xx-uccn-api/src/main/java/com/xxfc/platform/uccn/vo/ServiceResultVo.java
0 → 100644
View file @
24c992ee
package
com
.
xxfc
.
platform
.
uccn
.
vo
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.util.List
;
/**
* @author libin
* @version 1.0
* @description
* @data 2019/9/18 9:30
*/
@Data
@Builder
(
toBuilder
=
true
)
@NoArgsConstructor
@AllArgsConstructor
public
class
ServiceResultVo
<
T
>
{
private
long
totalCount
;
private
List
<
T
>
data
;
}
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/biz/ArticleBiz.java
View file @
24c992ee
...
@@ -43,9 +43,9 @@ public class ArticleBiz extends BaseBiz<ArticleMapper, Article> {
...
@@ -43,9 +43,9 @@ public class ArticleBiz extends BaseBiz<ArticleMapper, Article> {
* @param type
* @param type
* @return
* @return
*/
*/
public
PageInfo
getArticleList
(
Integer
page
,
Integer
limit
,
Integer
type
)
{
public
PageInfo
getArticleList
(
Integer
page
,
Integer
limit
,
Integer
type
,
String
title
)
{
PageHelper
.
startPage
(
page
,
limit
);
PageHelper
.
startPage
(
page
,
limit
);
List
articleList
=
mapper
.
getArticleList
(
type
,
null
,
null
);
List
articleList
=
mapper
.
getArticleList
(
type
,
null
,
null
,
title
);
return
PageInfo
.
of
(
articleList
);
return
PageInfo
.
of
(
articleList
);
}
}
...
@@ -81,7 +81,7 @@ public class ArticleBiz extends BaseBiz<ArticleMapper, Article> {
...
@@ -81,7 +81,7 @@ public class ArticleBiz extends BaseBiz<ArticleMapper, Article> {
*/
*/
public
List
getThree
(
Integer
type
,
Integer
number
,
Integer
id
)
{
public
List
getThree
(
Integer
type
,
Integer
number
,
Integer
id
)
{
number
=
number
==
null
?
RANDOM_NUMBER
:
number
;
number
=
number
==
null
?
RANDOM_NUMBER
:
number
;
List
<
Article
>
articleList
=
mapper
.
getArticleList
(
type
,
null
,
id
);
List
<
Article
>
articleList
=
mapper
.
getArticleList
(
type
,
null
,
id
,
null
);
if
(!
Objects
.
isNull
(
articleList
))
{
if
(!
Objects
.
isNull
(
articleList
))
{
int
size
=
articleList
.
size
();
int
size
=
articleList
.
size
();
if
(
number
>=
size
)
{
if
(
number
>=
size
)
{
...
@@ -108,7 +108,7 @@ public class ArticleBiz extends BaseBiz<ArticleMapper, Article> {
...
@@ -108,7 +108,7 @@ public class ArticleBiz extends BaseBiz<ArticleMapper, Article> {
* @return
* @return
*/
*/
public
List
getHomePageArticle
(
Integer
type
)
{
public
List
getHomePageArticle
(
Integer
type
)
{
List
<
Article
>
articleList
=
mapper
.
getArticleList
(
type
,
HOME_PAGE_NUMBER
,
null
);
List
<
Article
>
articleList
=
mapper
.
getArticleList
(
type
,
HOME_PAGE_NUMBER
,
null
,
null
);
// if (Objects.isNull(articleList)) {
// if (Objects.isNull(articleList)) {
// return new ArrayList();
// return new ArrayList();
// } else {
// } else {
...
...
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/biz/SearchBiz.java
0 → 100644
View file @
24c992ee
package
com
.
xxfc
.
platform
.
uccn
.
biz
;
import
cn.hutool.core.util.ArrayUtil
;
import
cn.hutool.core.util.StrUtil
;
import
com.github.pagehelper.PageInfo
;
import
com.github.wxiaoqi.security.common.exception.BaseException
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.xxfc.platform.campsite.dto.CampsiteShopFindDTO
;
import
com.xxfc.platform.campsite.feign.CampsiteFeign
;
import
com.xxfc.platform.campsite.vo.CampsiteShopPageVo
;
import
com.xxfc.platform.tour.entity.TourGood
;
import
com.xxfc.platform.tour.feign.TourFeign
;
import
com.xxfc.platform.uccn.comstnt.ServiceConstant
;
import
com.xxfc.platform.uccn.entity.Article
;
import
com.xxfc.platform.uccn.vo.SearchResultVo
;
import
com.xxfc.platform.uccn.vo.ServiceResultVo
;
import
com.xxfc.platform.uccn.vo.SummitActivityVo
;
import
com.xxfc.platform.vehicle.entity.VehiclePlatCata
;
import
com.xxfc.platform.vehicle.feign.VehicleFeign
;
import
com.xxfc.platform.vehicle.pojo.VehicleModelQueryCondition
;
import
com.xxfc.platform.vehicle.pojo.VehicleModelVo
;
import
com.xxfc.platform.vehicle.pojo.dto.BranchCompanyFindDTO
;
import
com.xxfc.platform.vehicle.pojo.vo.BranchCompanyListVO
;
import
lombok.RequiredArgsConstructor
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor
;
import
org.springframework.stereotype.Service
;
import
java.util.Comparator
;
import
java.util.List
;
import
java.util.concurrent.CountDownLatch
;
import
java.util.stream.Collectors
;
/**
* @author libin
* @version 1.0
* @description
* @data 2019/9/17 10:19
*/
@Service
@RequiredArgsConstructor
(
onConstructor
=
@__
(
@Autowired
))
public
class
SearchBiz
{
/**
* 车型与分公司
*/
private
final
VehicleFeign
vehicleFeign
;
/**
* 旅游
*/
private
final
TourFeign
tourFeign
;
/**
* 营地
*/
private
final
CampsiteFeign
campsiteFeign
;
/**
* 新闻
*/
private
final
ArticleBiz
articleBiz
;
/**
* 活动
*/
private
final
SummitActivityBiz
summitActivityBiz
;
/**
* 业务个数
*/
private
static
final
int
SERVICE_COUNT
=
5
;
private
final
ThreadPoolTaskExecutor
threadPoolTaskExecutor
;
/**
* 综合搜索
*
* @param keyWord 关键字
* @return
*/
public
SearchResultVo
searchWithKeyWords
(
String
keyWord
)
{
SearchResultVo
searchResultVo
=
new
SearchResultVo
();
CountDownLatch
latch
=
new
CountDownLatch
(
SERVICE_COUNT
);
//车型
threadPoolTaskExecutor
.
execute
(
new
Runnable
()
{
@Override
public
void
run
()
{
try
{
ServiceResultVo
<
VehicleModelVo
>
vehicleModelVoServiceResultVo
=
new
ServiceResultVo
<>();
VehicleModelQueryCondition
vmqc
=
new
VehicleModelQueryCondition
();
vmqc
.
setNotInIds
(
"67"
);
vmqc
.
setPage
(
1
);
vmqc
.
setLimit
(
ServiceConstant
.
VEHICLE_LIMIT
);
vmqc
.
setVehicleName
(
keyWord
);
ObjectRestResponse
<
PageDataVO
<
VehicleModelVo
>>
objectRestResponse
=
vehicleFeign
.
findVehicleModelPageUnauthfind
(
vmqc
);
PageDataVO
<
VehicleModelVo
>
pageDataVOs
=
objectRestResponse
.
getData
();
pageDataVOs
.
getData
().
forEach
(
v
->
{
v
.
setUccnCataList
(
initUccnCataCollect
(
v
.
getConfig
()));
});
vehicleModelVoServiceResultVo
.
setTotalCount
(
pageDataVOs
.
getTotalCount
());
vehicleModelVoServiceResultVo
.
setData
(
pageDataVOs
.
getData
());
searchResultVo
.
put
(
ServiceConstant
.
VEHICLE
,
vehicleModelVoServiceResultVo
);
}
catch
(
Exception
ex
)
{
ex
.
printStackTrace
();
}
finally
{
latch
.
countDown
();
}
}
});
//分公司
threadPoolTaskExecutor
.
execute
(
new
Runnable
()
{
@Override
public
void
run
()
{
try
{
ServiceResultVo
<
BranchCompanyListVO
>
branchCompanyListVOServiceResultVo
=
new
ServiceResultVo
<>();
BranchCompanyFindDTO
branchCompanyFindDTO
=
new
BranchCompanyFindDTO
();
branchCompanyFindDTO
.
setPage
(
1
);
branchCompanyFindDTO
.
setLimit
(
ServiceConstant
.
BRANCH_COMPANY_LIMIT
);
branchCompanyFindDTO
.
setName
(
keyWord
);
PageDataVO
<
BranchCompanyListVO
>
branchCompanyWithPage
=
vehicleFeign
.
findBranchCompanyWithPage
(
branchCompanyFindDTO
);
branchCompanyListVOServiceResultVo
.
setTotalCount
(
branchCompanyWithPage
.
getTotalCount
());
branchCompanyListVOServiceResultVo
.
setData
(
branchCompanyWithPage
.
getData
());
searchResultVo
.
put
(
ServiceConstant
.
BRANCH_COMPANY
,
branchCompanyListVOServiceResultVo
);
}
catch
(
Exception
ex
)
{
ex
.
printStackTrace
();
}
finally
{
latch
.
countDown
();
}
}
});
//旅游
threadPoolTaskExecutor
.
execute
(
new
Runnable
()
{
@Override
public
void
run
()
{
try
{
ServiceResultVo
<
TourGood
>
tourGoodServiceResultVo
=
new
ServiceResultVo
<>();
ObjectRestResponse
<
PageDataVO
<
TourGood
>>
goodList
=
tourFeign
.
getGoodList
(
1
,
ServiceConstant
.
TOUR_LIMIT
,
null
,
keyWord
);
PageDataVO
<
TourGood
>
data
=
goodList
.
getData
();
tourGoodServiceResultVo
.
setData
(
data
.
getData
());
tourGoodServiceResultVo
.
setTotalCount
(
data
.
getTotalCount
());
searchResultVo
.
put
(
ServiceConstant
.
TROUR
,
tourGoodServiceResultVo
);
}
catch
(
Exception
ex
)
{
ex
.
printStackTrace
();
}
finally
{
latch
.
countDown
();
}
}
});
//营地
threadPoolTaskExecutor
.
execute
(
new
Runnable
()
{
@Override
public
void
run
()
{
try
{
ServiceResultVo
<
CampsiteShopPageVo
>
campsiteShopPageVoServiceResultVo
=
new
ServiceResultVo
<>();
CampsiteShopFindDTO
campsiteShopFindDTO
=
new
CampsiteShopFindDTO
();
campsiteShopFindDTO
.
setPage
(
1
);
campsiteShopFindDTO
.
setLimit
(
ServiceConstant
.
CAMPSITE_LIMIT
);
campsiteShopFindDTO
.
setName
(
keyWord
);
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
campsiteShopPageForUncc
=
campsiteFeign
.
findCampsiteShopPageForUncc
(
campsiteShopFindDTO
);
PageDataVO
<
CampsiteShopPageVo
>
data
=
campsiteShopPageForUncc
.
getData
();
campsiteShopPageVoServiceResultVo
.
setData
(
data
.
getData
());
campsiteShopPageVoServiceResultVo
.
setTotalCount
(
data
.
getTotalCount
());
searchResultVo
.
put
(
ServiceConstant
.
CAMPSITE
,
campsiteShopPageVoServiceResultVo
);
}
catch
(
Exception
ex
)
{
ex
.
printStackTrace
();
}
finally
{
latch
.
countDown
();
}
}
});
//活动
threadPoolTaskExecutor
.
execute
(
new
Runnable
()
{
@Override
public
void
run
()
{
try
{
ServiceResultVo
<
SummitActivityVo
>
activityVoServiceResultVo
=
new
ServiceResultVo
<>();
PageDataVO
<
SummitActivityVo
>
summitActivityWithPage
=
summitActivityBiz
.
findSummitActivityWithPage
(
1
,
ServiceConstant
.
ACTIVITY_LIMIT
,
null
,
keyWord
);
activityVoServiceResultVo
.
setTotalCount
(
summitActivityWithPage
.
getTotalCount
());
activityVoServiceResultVo
.
setData
(
summitActivityWithPage
.
getData
());
searchResultVo
.
put
(
ServiceConstant
.
ACTIVITY
,
activityVoServiceResultVo
);
}
catch
(
Exception
ex
)
{
ex
.
printStackTrace
();
}
finally
{
latch
.
countDown
();
}
}
});
//新闻
threadPoolTaskExecutor
.
execute
(
new
Runnable
()
{
@Override
public
void
run
()
{
try
{
ServiceResultVo
<
Article
>
articleServiceResultVo
=
new
ServiceResultVo
<>();
PageInfo
articleList
=
articleBiz
.
getArticleList
(
1
,
ServiceConstant
.
NEWS_LIMIT
,
1
,
keyWord
);
articleServiceResultVo
.
setData
(
articleList
.
getList
());
articleServiceResultVo
.
setTotalCount
(
articleList
.
getTotal
());
searchResultVo
.
put
(
ServiceConstant
.
NEWS
,
articleServiceResultVo
);
}
catch
(
Exception
ex
)
{
ex
.
printStackTrace
();
}
finally
{
latch
.
countDown
();
}
}
});
try
{
latch
.
await
();
}
catch
(
InterruptedException
e
)
{
throw
new
BaseException
(
e
);
}
return
searchResultVo
;
}
private
List
<
VehiclePlatCata
>
initUccnCataCollect
(
String
modelConfig
)
{
List
<
VehiclePlatCata
>
vehiclePlatCataList
=
vehicleFeign
.
getCatasByIds
(
modelConfig
).
getData
();
int
[]
array
=
StrUtil
.
splitToInt
(
"14,7,11"
,
","
);
return
vehiclePlatCataList
.
parallelStream
()
.
filter
(
v1
->
{
return
ArrayUtil
.
contains
(
array
,
v1
.
getParentId
());
})
.
sorted
(
Comparator
.
comparing
(
VehiclePlatCata:
:
getParentId
,
(
x
,
y
)
->
{
int
xx
=
0
,
yy
=
0
;
for
(
int
i
=
0
;
i
<
array
.
length
;
i
++)
{
if
(
x
==
array
[
i
])
{
xx
=
i
;
}
else
if
(
y
==
array
[
i
])
{
yy
=
i
;
}
}
return
(
xx
-
yy
);
})).
collect
(
Collectors
.
toList
());
}
}
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/biz/SummitActivityBiz.java
View file @
24c992ee
...
@@ -204,7 +204,7 @@ public class SummitActivityBiz extends BaseBiz<SummitActivityMapper, SummitActiv
...
@@ -204,7 +204,7 @@ public class SummitActivityBiz extends BaseBiz<SummitActivityMapper, SummitActiv
return
summitActivityVos
;
return
summitActivityVos
;
}
}
public
PageDataVO
<
SummitActivityVo
>
findSummitActivityWithPage
(
Integer
page
,
Integer
limit
,
Integer
location
)
{
public
PageDataVO
<
SummitActivityVo
>
findSummitActivityWithPage
(
Integer
page
,
Integer
limit
,
Integer
location
,
String
title
)
{
PageDataVO
<
SummitActivityVo
>
dataVO
=
new
PageDataVO
<>();
PageDataVO
<
SummitActivityVo
>
dataVO
=
new
PageDataVO
<>();
Example
example
=
new
Example
(
SummitActivity
.
class
);
Example
example
=
new
Example
(
SummitActivity
.
class
);
...
@@ -218,6 +218,10 @@ public class SummitActivityBiz extends BaseBiz<SummitActivityMapper, SummitActiv
...
@@ -218,6 +218,10 @@ public class SummitActivityBiz extends BaseBiz<SummitActivityMapper, SummitActiv
criteria
.
andEqualTo
(
"isShow"
,
1
);
criteria
.
andEqualTo
(
"isShow"
,
1
);
//位置
//位置
criteria
.
andIn
(
"location"
,
Arrays
.
asList
(
location
,
0
));
criteria
.
andIn
(
"location"
,
Arrays
.
asList
(
location
,
0
));
//标题
if
(
StringUtils
.
isNotEmpty
(
title
)){
criteria
.
andLike
(
"title"
,
String
.
format
(
"%%%s%%"
,
title
.
trim
()));
}
PageDataVO
<
SummitActivity
>
summitActivityPageDataVO
=
PageDataVO
.
pageInfo
(
page
,
limit
,
()
->
mapper
.
selectByExample
(
example
));
PageDataVO
<
SummitActivity
>
summitActivityPageDataVO
=
PageDataVO
.
pageInfo
(
page
,
limit
,
()
->
mapper
.
selectByExample
(
example
));
List
<
SummitActivity
>
summitActivities
=
summitActivityPageDataVO
.
getData
();
List
<
SummitActivity
>
summitActivities
=
summitActivityPageDataVO
.
getData
();
if
(
CollectionUtils
.
isEmpty
(
summitActivities
)){
if
(
CollectionUtils
.
isEmpty
(
summitActivities
)){
...
...
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/mapper/ArticleMapper.java
View file @
24c992ee
...
@@ -17,5 +17,5 @@ public interface ArticleMapper extends Mapper<Article> {
...
@@ -17,5 +17,5 @@ public interface ArticleMapper extends Mapper<Article> {
* @param id 当前文章id ,无就传null
* @param id 当前文章id ,无就传null
* @return
* @return
*/
*/
List
<
Article
>
getArticleList
(
@Param
(
"type"
)
Integer
type
,
@Param
(
"limit"
)
Integer
limit
,
@Param
(
"id"
)
Integer
id
);
List
<
Article
>
getArticleList
(
@Param
(
"type"
)
Integer
type
,
@Param
(
"limit"
)
Integer
limit
,
@Param
(
"id"
)
Integer
id
,
@Param
(
"title"
)
String
title
);
}
}
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/rest/ArticleController.java
View file @
24c992ee
...
@@ -25,8 +25,9 @@ public class ArticleController extends BaseController<ArticleBiz, Article> {
...
@@ -25,8 +25,9 @@ public class ArticleController extends BaseController<ArticleBiz, Article> {
public
ObjectRestResponse
getArticleList
(
public
ObjectRestResponse
getArticleList
(
@RequestParam
(
name
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
name
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
name
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
@RequestParam
(
name
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
@RequestParam
(
name
=
"type"
,
defaultValue
=
"1"
)
Integer
type
)
{
@RequestParam
(
name
=
"type"
,
defaultValue
=
"1"
)
Integer
type
,
return
ObjectRestResponse
.
succ
(
baseBiz
.
getArticleList
(
page
,
limit
,
type
));
@RequestParam
(
value
=
"title"
,
required
=
false
)
String
title
)
{
return
ObjectRestResponse
.
succ
(
baseBiz
.
getArticleList
(
page
,
limit
,
type
,
title
));
}
}
@GetMapping
(
"/app/unauth/one"
)
@GetMapping
(
"/app/unauth/one"
)
...
...
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/rest/CampsiteUccnController.java
View file @
24c992ee
...
@@ -2,6 +2,7 @@ package com.xxfc.platform.uccn.rest;
...
@@ -2,6 +2,7 @@ package com.xxfc.platform.uccn.rest;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.github.wxiaoqi.security.common.vo.PageDataVO
;
import
com.xxfc.platform.campsite.dto.CampsiteShopFindDTO
;
import
com.xxfc.platform.campsite.feign.CampsiteFeign
;
import
com.xxfc.platform.campsite.feign.CampsiteFeign
;
import
com.xxfc.platform.campsite.vo.CampsiteShopDetailVo
;
import
com.xxfc.platform.campsite.vo.CampsiteShopDetailVo
;
import
com.xxfc.platform.campsite.vo.CampsiteShopPageVo
;
import
com.xxfc.platform.campsite.vo.CampsiteShopPageVo
;
...
@@ -31,8 +32,14 @@ public class CampsiteUccnController {
...
@@ -31,8 +32,14 @@ public class CampsiteUccnController {
@GetMapping
(
"/shops"
)
@GetMapping
(
"/shops"
)
public
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsiteShopPageByType
(
@RequestParam
(
value
=
"type"
,
required
=
false
)
Integer
type
,
public
ObjectRestResponse
<
PageDataVO
<
CampsiteShopPageVo
>>
findCampsiteShopPageByType
(
@RequestParam
(
value
=
"type"
,
required
=
false
)
Integer
type
,
@RequestParam
(
value
=
"pageNo"
,
required
=
false
,
defaultValue
=
"1"
)
Integer
pageNo
,
@RequestParam
(
value
=
"pageNo"
,
required
=
false
,
defaultValue
=
"1"
)
Integer
pageNo
,
@RequestParam
(
value
=
"pageSize"
,
required
=
false
,
defaultValue
=
"6"
)
Integer
pageSize
)
{
@RequestParam
(
value
=
"pageSize"
,
required
=
false
,
defaultValue
=
"6"
)
Integer
pageSize
,
return
campsiteFeign
.
findCampsiteShopPageByType
(
type
,
pageNo
,
pageSize
);
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
)
{
CampsiteShopFindDTO
campsiteShopFindDTO
=
new
CampsiteShopFindDTO
();
campsiteShopFindDTO
.
setType
(
type
);
campsiteShopFindDTO
.
setPage
(
pageNo
);
campsiteShopFindDTO
.
setLimit
(
pageSize
);
campsiteShopFindDTO
.
setName
(
name
);
return
campsiteFeign
.
findCampsiteShopPageForUncc
(
campsiteShopFindDTO
);
}
}
/**
/**
...
...
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/rest/GwTourController.java
View file @
24c992ee
...
@@ -23,9 +23,11 @@ public class GwTourController extends CommonBaseController {
...
@@ -23,9 +23,11 @@ public class GwTourController extends CommonBaseController {
@ApiOperation
(
"查询旅游路线列表"
)
@ApiOperation
(
"查询旅游路线列表"
)
@RequestMapping
(
value
=
"/getGoodList"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
value
=
"/getGoodList"
,
method
=
RequestMethod
.
GET
)
@IgnoreUserToken
@IgnoreUserToken
public
ObjectRestResponse
getGoodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
public
ObjectRestResponse
getGoodList
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
value
=
"tagId"
,
required
=
false
)
Integer
tagId
)
{
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"10"
)
Integer
limit
,
return
tourFeign
.
getGoodList
(
page
,
limit
,
tagId
);
@RequestParam
(
value
=
"tagId"
,
required
=
false
)
Integer
tagId
,
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
)
{
return
tourFeign
.
getGoodList
(
page
,
limit
,
tagId
,
name
);
}
}
@GetMapping
(
"/detail/{id}"
)
@GetMapping
(
"/detail/{id}"
)
...
@@ -38,12 +40,13 @@ public class GwTourController extends CommonBaseController {
...
@@ -38,12 +40,13 @@ public class GwTourController extends CommonBaseController {
@GetMapping
(
value
=
"/shopList"
)
@GetMapping
(
value
=
"/shopList"
)
@IgnoreUserToken
@IgnoreUserToken
public
ObjectRestResponse
goodListAll
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
public
ObjectRestResponse
goodListAll
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"4"
)
Integer
limit
)
{
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"4"
)
Integer
limit
)
{
return
ObjectRestResponse
.
succ
(
tourFeign
.
goodListAll
(
page
,
limit
));
return
ObjectRestResponse
.
succ
(
tourFeign
.
goodListAll
(
page
,
limit
));
}
}
@GetMapping
(
"/tagList"
)
@GetMapping
(
"/tagList"
)
@IgnoreUserToken
@IgnoreUserToken
public
ObjectRestResponse
getTagList
(
@RequestParam
(
value
=
"isHot"
,
defaultValue
=
"0"
)
Integer
isHot
)
{
public
ObjectRestResponse
getTagList
(
@RequestParam
(
value
=
"isHot"
,
defaultValue
=
"0"
)
Integer
isHot
)
{
return
ObjectRestResponse
.
succ
(
tourFeign
.
tagList
(
isHot
));
return
ObjectRestResponse
.
succ
(
tourFeign
.
tagList
(
isHot
));
}
}
...
...
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/rest/SearchController.java
0 → 100644
View file @
24c992ee
package
com
.
xxfc
.
platform
.
uccn
.
rest
;
import
com.github.wxiaoqi.security.common.msg.ObjectRestResponse
;
import
com.xxfc.platform.uccn.biz.SearchBiz
;
import
com.xxfc.platform.uccn.vo.SearchResultVo
;
import
io.swagger.annotations.Api
;
import
lombok.RequiredArgsConstructor
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
/**
* @author libin
* @version 1.0
* @description
* @data 2019/9/17 9:47
*/
@RestController
@RequestMapping
(
"/app/unauth/search"
)
@RequiredArgsConstructor
(
onConstructor
=
@__
(
@Autowired
))
@Api
(
tags
=
"官网*综合搜索"
)
public
class
SearchController
{
private
final
SearchBiz
searchBiz
;
@GetMapping
public
ObjectRestResponse
<
SearchResultVo
>
search
(
@RequestParam
(
value
=
"keyword"
,
required
=
false
)
String
keyWord
){
SearchResultVo
searchResultVo
=
searchBiz
.
searchWithKeyWords
(
keyWord
);
return
ObjectRestResponse
.
succ
(
searchResultVo
);
}
}
xx-uccn/xx-uccn-server/src/main/java/com/xxfc/platform/uccn/rest/SummitActivityController.java
View file @
24c992ee
...
@@ -55,8 +55,9 @@ public class SummitActivityController {
...
@@ -55,8 +55,9 @@ public class SummitActivityController {
@GetMapping
(
"/list"
)
@GetMapping
(
"/list"
)
public
ObjectRestResponse
<
PageDataVO
<
SummitActivityVo
>>
findSummitActivityWithPage
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
,
required
=
false
)
Integer
page
,
public
ObjectRestResponse
<
PageDataVO
<
SummitActivityVo
>>
findSummitActivityWithPage
(
@RequestParam
(
value
=
"page"
,
defaultValue
=
"1"
,
required
=
false
)
Integer
page
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"6"
,
required
=
false
)
Integer
limit
,
@RequestParam
(
value
=
"limit"
,
defaultValue
=
"6"
,
required
=
false
)
Integer
limit
,
@RequestParam
(
value
=
"location"
,
defaultValue
=
"0"
,
required
=
false
)
Integer
location
)
{
@RequestParam
(
value
=
"location"
,
defaultValue
=
"0"
,
required
=
false
)
Integer
location
,
PageDataVO
<
SummitActivityVo
>
pageDataVO
=
summitActivityBiz
.
findSummitActivityWithPage
(
page
,
limit
,
location
);
@RequestParam
(
value
=
"title"
,
required
=
false
)
String
title
)
{
PageDataVO
<
SummitActivityVo
>
pageDataVO
=
summitActivityBiz
.
findSummitActivityWithPage
(
page
,
limit
,
location
,
title
);
return
ObjectRestResponse
.
succ
(
pageDataVO
);
return
ObjectRestResponse
.
succ
(
pageDataVO
);
}
}
...
...
xx-uccn/xx-uccn-server/src/main/resources/mapper/ArticleMapper.xml
View file @
24c992ee
...
@@ -11,6 +11,9 @@
...
@@ -11,6 +11,9 @@
<if
test=
"id != null"
>
<if
test=
"id != null"
>
and id != #{id}
and id != #{id}
</if>
</if>
<if
test=
"title !=null and title !=''"
>
and `title` like concat('%',#{title},'%')
</if>
and (type=#{type} or type=0)
and (type=#{type} or type=0)
order by
order by
...
...
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