'代码合并'

This commit is contained in:
fengtianyangyang
2022-03-03 17:22:13 +08:00
42 changed files with 1357 additions and 39 deletions

View File

@@ -22,6 +22,7 @@ import cn.lili.modules.store.entity.dto.FuLuConfigureDTO;
import cn.lili.modules.store.service.StoreDetailService;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONArray;
import cn.lili.modules.store.service.StoreDetailService;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import io.swagger.annotations.Api;
@@ -33,6 +34,8 @@ import org.springframework.web.bind.annotation.*;
import javax.validation.Valid;
import java.util.*;
import java.util.List;
import java.util.Objects;
import java.util.stream.Collectors;
/**
@@ -278,5 +281,4 @@ public class GoodsStoreController {
return ResultUtil.success();
}
}

View File

@@ -0,0 +1,98 @@
package cn.lili.controller.other;
import cn.lili.common.aop.annotation.DemoSite;
import cn.lili.common.enums.ResultUtil;
import cn.lili.common.security.context.UserContext;
import cn.lili.common.vo.PageVO;
import cn.lili.common.vo.ResultMessage;
import cn.lili.modules.page.entity.dos.PageData;
import cn.lili.modules.page.entity.dto.PageDataDTO;
import cn.lili.modules.page.entity.enums.PageEnum;
import cn.lili.modules.page.entity.vos.PageDataListVO;
import cn.lili.modules.page.service.PageDataService;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import javax.validation.Valid;
import javax.validation.constraints.NotNull;
/**
* 店铺端,页面设置管理接口
*
* @author paulGao
* @since 2020-05-06 15:18:56
*/
@RestController
@Api(tags = "店铺端,页面设置管理接口")
@RequestMapping("/store/other/pageData")
public class PageDataStoreController {
@Autowired
private PageDataService pageDataService;
@ApiOperation(value = "获取页面信息")
@ApiImplicitParam(name = "id", value = "页面ID", required = true, dataType = "String", paramType = "path")
@GetMapping(value = "/{id}")
public ResultMessage<PageData> getPageData(@PathVariable String id) {
//查询当前店铺下的页面数据
PageData pageData = pageDataService.getOne(
new LambdaQueryWrapper<PageData>()
.eq(PageData::getPageType, PageEnum.STORE.name())
.eq(PageData::getNum, UserContext.getCurrentUser().getStoreId())
.eq(PageData::getId, id));
return ResultUtil.data(pageData);
}
@ApiOperation(value = "添加页面")
@PostMapping("/add")
public ResultMessage<PageData> addPageData(@Valid PageData pageData) {
//添加店铺类型填写店铺ID
pageData.setPageType(PageEnum.STORE.name());
pageData.setNum(UserContext.getCurrentUser().getStoreId());
return ResultUtil.data(pageDataService.addPageData(pageData));
}
@ApiOperation(value = "修改页面")
@ApiImplicitParams({
@ApiImplicitParam(name = "id", value = "页面ID", required = true, dataType = "String", paramType = "path")
})
@DemoSite
@PutMapping("/update/{id}")
public ResultMessage<PageData> updatePageData(@Valid PageData pageData, @NotNull @PathVariable String id) {
pageData.setId(id);
//添加店铺类型填写店铺ID
pageData.setPageType(PageEnum.STORE.name());
pageData.setNum(UserContext.getCurrentUser().getStoreId());
return ResultUtil.data(pageDataService.updatePageData(pageData));
}
@ApiOperation(value = "页面列表")
@GetMapping("/pageDataList")
public ResultMessage<IPage<PageDataListVO>> pageDataList(PageVO pageVO, PageDataDTO pageDataDTO) {
pageDataDTO.setPageType(PageEnum.STORE.name());
pageDataDTO.setNum(UserContext.getCurrentUser().getStoreId());
return ResultUtil.data(pageDataService.getPageDataList(pageVO, pageDataDTO));
}
@ApiOperation(value = "发布页面")
@ApiImplicitParam(name = "id", value = "页面ID", required = true, dataType = "String", paramType = "path")
@PutMapping("/release/{id}")
@DemoSite
public ResultMessage<PageData> release(@PathVariable String id) {
return ResultUtil.data(pageDataService.releasePageData(id));
}
@ApiOperation(value = "删除页面")
@DemoSite
@ApiImplicitParam(name = "id", value = "页面ID", required = true, dataType = "String", paramType = "path")
@DeleteMapping("/remove/{id}")
public ResultMessage<Object> remove(@PathVariable String id) {
return ResultUtil.data(pageDataService.removePageData(id));
}
}

View File

@@ -33,9 +33,15 @@ spring:
type: redis
# Redis
redis:
<<<<<<< HEAD
host: 120.71.145.134
port: 6379
password: ekLhvPGraSj8DGO0
=======
host: 127.0.0.1
port: 6379
password: lilishop
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
lettuce:
pool:
# 连接池最大连接数(使用负值表示没有限制) 默认 8
@@ -64,9 +70,15 @@ spring:
default-datasource:
type: com.alibaba.druid.pool.DruidDataSource
driverClassName: com.mysql.cj.jdbc.Driver
<<<<<<< HEAD
url: jdbc:mysql://120.71.183.195:3306/zyt_shop?useUnicode=true&characterEncoding=UTF-8&serverTimezone=UTC&allowPublicKeyRetrieval=true&verifyServerCertificate=false&useSSL=false
username: zyt_shop
password: Gb84505016@zytshop
=======
url: jdbc:mysql://127.0.0.1:3306/lilishop?useUnicode=true&characterEncoding=utf-8&useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
username: root
password: lilishop
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
maxActive: 20
initialSize: 5
maxWait: 60000
@@ -108,7 +120,11 @@ spring:
props:
#是否打印逻辑SQL语句和实际SQL语句建议调试时打印在生产环境关闭
sql:
<<<<<<< HEAD
show: true
=======
show: false
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
# 忽略鉴权url
ignored:
@@ -137,6 +153,7 @@ ignored:
# Swagger界面内容配置
swagger:
<<<<<<< HEAD
title: API接口文档
description: Api Documentation
version: 1.0.0
@@ -145,6 +162,16 @@ swagger:
name: rx
url:
email:
=======
title: lili API接口文档
description: lili Api Documentation
version: 1.0.0
termsOfServiceUrl: https://pickmall.cn
contact:
name: lili
url: https://pickmall.cn
email: admin@pickmall.com
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
# Mybatis-plus
mybatis-plus:
@@ -179,7 +206,11 @@ jasypt:
lili:
system:
<<<<<<< HEAD
isDemoSite: false
=======
isDemoSite: true
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
statistics:
# 在线人数统计 X 小时。这里设置48即统计过去48小时每小时在线人数
onlineMember: 48
@@ -191,6 +222,7 @@ lili:
sk: zhNKVrJK6UPOhqIjn8AQvG37b9sz6
#域名
domain:
<<<<<<< HEAD
pc: https://zbuyer.sx1788.cn
wap: https://zshop.sx1788.cn
store: https://zseller.sx1788.cn
@@ -201,6 +233,18 @@ lili:
common: https://zshop-api.sx1788.cn/common-api
manager: https://zshop-api.sx1788.cn/manager-api
store: https://zshop-api.sx1788.cn/seller-api
=======
pc: https://pc.b2b2c.pickmall.cn
wap: https://m.b2b2c.pickmall.cn
store: https://store.b2b2c.pickmall.cn
admin: https://admin.b2b2c.pickmall.cn
#api地址
api:
buyer: https://buyer-api.pickmall.cn
common: https://common-api.pickmall.cn
manager: https://admin-api.pickmall.cn
store: https://store-api.pickmall.cn
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
# jwt 细节设定
jwt-setting:
@@ -219,7 +263,11 @@ lili:
data:
elasticsearch:
cluster-name: elasticsearch
<<<<<<< HEAD
cluster-nodes: 106.124.130.167:9200
=======
cluster-nodes: 127.0.0.1:9200
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
index:
number-of-replicas: 0
number-of-shards: 3
@@ -229,7 +277,11 @@ lili:
# username: elastic
# password: LiLiShopES
logstash:
<<<<<<< HEAD
server: 106.124.130.167:4560
=======
server: 127.0.0.1:4560
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
rocketmq:
promotion-topic: lili_promotion_topic
promotion-group: lili_promotion_group
@@ -250,7 +302,11 @@ lili:
after-sale-topic: lili_after_sale_topic
after-sale-group: lili_after_sale_group
rocketmq:
<<<<<<< HEAD
name-server: 106.124.130.167:9876
=======
name-server: 127.0.0.1:9876
>>>>>>> ae0c4aea12996d3d72eca7c6ccdc97922373e4d7
producer:
group: lili_group
send-message-timeout: 30000