Oam,Mall,Jambox Api结构调整;果酱官网重名修改
This commit is contained in:
parent
6ce6022d63
commit
9e85c7fee9
@ -26,8 +26,8 @@ import java.net.URLEncoder;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "果酱-放心学订单表接口")
|
||||
@RequestMapping("/easyLearn")
|
||||
public class EasyLearnController {
|
||||
@RequestMapping("/backstage/easyLearn")
|
||||
public class BackstageEasyLearnController {
|
||||
|
||||
@Autowired
|
||||
private EasyLearnOrderService easyLearnOrderService;
|
||||
@ -1,6 +1,8 @@
|
||||
package com.cpop.jambox.business.controller.backstage.website;
|
||||
|
||||
import com.cpop.core.base.R;
|
||||
import com.cpop.jambox.business.entity.website.WebProduct;
|
||||
import com.cpop.jambox.business.service.WebProductService;
|
||||
import com.mybatisflex.core.paginate.Page;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
@ -10,8 +12,6 @@ import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import com.cpop.jambox.business.entity.website.Product;
|
||||
import com.cpop.jambox.business.service.ProductService;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
@ -31,7 +31,7 @@ import java.util.List;
|
||||
public class ProductController {
|
||||
|
||||
@Autowired
|
||||
private ProductService productService;
|
||||
private WebProductService productService;
|
||||
|
||||
/**
|
||||
* 添加果酱模块化官网 核心产品表。
|
||||
@ -41,7 +41,7 @@ public class ProductController {
|
||||
*/
|
||||
@PostMapping("/save")
|
||||
@ApiOperation("保存果酱模块化官网 核心产品表")
|
||||
public R<Void> save(@RequestBody @ApiParam("果酱模块化官网 核心产品表") Product product) {
|
||||
public R<Void> save(@RequestBody @ApiParam("果酱模块化官网 核心产品表") WebProduct product) {
|
||||
productService.save(product);
|
||||
return R.ok();
|
||||
}
|
||||
@ -67,7 +67,7 @@ public class ProductController {
|
||||
*/
|
||||
@PutMapping("/update")
|
||||
@ApiOperation("根据主键更新果酱模块化官网 核心产品表")
|
||||
public R<Void> update(@RequestBody @ApiParam("果酱模块化官网 核心产品表主键") Product product) {
|
||||
public R<Void> update(@RequestBody @ApiParam("果酱模块化官网 核心产品表主键") WebProduct product) {
|
||||
productService.updateById(product);
|
||||
return R.ok();
|
||||
}
|
||||
@ -79,7 +79,7 @@ public class ProductController {
|
||||
*/
|
||||
@GetMapping("/list")
|
||||
@ApiOperation("查询所有果酱模块化官网 核心产品表")
|
||||
public R<List<Product>> list() {
|
||||
public R<List<WebProduct>> list() {
|
||||
return R.ok(productService.list());
|
||||
}
|
||||
|
||||
@ -91,7 +91,7 @@ public class ProductController {
|
||||
*/
|
||||
@GetMapping("/getInfo/{id}")
|
||||
@ApiOperation("根据主键获取果酱模块化官网 核心产品表")
|
||||
public R<Product> getInfo(@PathVariable @ApiParam("果酱模块化官网 核心产品表主键") Serializable id) {
|
||||
public R<WebProduct> getInfo(@PathVariable @ApiParam("果酱模块化官网 核心产品表主键") Serializable id) {
|
||||
return R.ok(productService.getById(id));
|
||||
}
|
||||
|
||||
@ -103,7 +103,7 @@ public class ProductController {
|
||||
*/
|
||||
@GetMapping("/page")
|
||||
@ApiOperation("分页查询果酱模块化官网 核心产品表")
|
||||
public R<Page<Product>> page(@ApiParam("分页信息") Page<Product> page) {
|
||||
public R<Page<WebProduct>> page(@ApiParam("分页信息") Page<WebProduct> page) {
|
||||
return R.ok(productService.page(page));
|
||||
}
|
||||
|
||||
|
||||
@ -48,4 +48,30 @@ public class CallBackEasyLearnController {
|
||||
easyLearnOrderService.userServiceOrderSuccess(notifyData);
|
||||
return WxPayNotifyResponse.success("成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 微信支付订单通知
|
||||
* @author DB
|
||||
* @since 2023/12/21
|
||||
* @param xmlData 数据
|
||||
* @return java.lang.String
|
||||
*/
|
||||
@ApiOperation("微信支付订单通知")
|
||||
@PostMapping("/notify/oncePay")
|
||||
public String oncePayResult(@RequestBody String xmlData){
|
||||
easyLearnOrderService.oncePayResult(xmlData);
|
||||
return WxPayNotifyResponse.success("成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 微信支付联合支付订单通知
|
||||
* @param xmlData 数据
|
||||
* @return java.lang.String
|
||||
*/
|
||||
@ApiOperation("微信支付联合支付订单通知")
|
||||
@PostMapping("/notify/unionPay")
|
||||
public String unionPay(@RequestBody String xmlData){
|
||||
easyLearnOrderService.unionPayResult(xmlData);
|
||||
return WxPayNotifyResponse.success("成功");
|
||||
}
|
||||
}
|
||||
|
||||
@ -17,6 +17,7 @@ import org.springframework.web.bind.annotation.RestController;
|
||||
@RestController
|
||||
@Api(tags = "果酱-放心学回调接口")
|
||||
@RequestMapping("/easyLearn/callback")
|
||||
@Deprecated
|
||||
public class EasyLearnCallBackController {
|
||||
|
||||
@Autowired
|
||||
|
||||
@ -18,7 +18,7 @@ public class WebsiteController {
|
||||
@Autowired
|
||||
private BusinessDataService businessDataService;
|
||||
@Autowired
|
||||
private ProductService productService;
|
||||
private WebProductService productService;
|
||||
@Autowired
|
||||
private WebsiteService websiteService;
|
||||
|
||||
|
||||
@ -26,7 +26,7 @@ import lombok.experimental.Accessors;
|
||||
@AllArgsConstructor
|
||||
@Accessors(chain = true)
|
||||
@Table(value = "cp_j_web_product", onInsert = BaseInsertListener.class, onUpdate = BaseUpdateListener.class, mapperGenerateEnable = false)
|
||||
public class Product extends BaseEntity implements Serializable {
|
||||
public class WebProduct extends BaseEntity implements Serializable {
|
||||
|
||||
@Id
|
||||
private String id;
|
||||
@ -1,7 +1,7 @@
|
||||
package com.cpop.jambox.business.mapper;
|
||||
|
||||
import com.cpop.jambox.business.entity.website.WebProduct;
|
||||
import com.mybatisflex.core.BaseMapper;
|
||||
import com.cpop.jambox.business.entity.website.Product;
|
||||
|
||||
/**
|
||||
* 果酱模块化官网 核心产品表 映射层。
|
||||
@ -9,6 +9,6 @@ import com.cpop.jambox.business.entity.website.Product;
|
||||
* @author Yxz
|
||||
* @since 2024-01-19
|
||||
*/
|
||||
public interface ProductMapper extends BaseMapper<Product> {
|
||||
public interface WebProductMapper extends BaseMapper<WebProduct> {
|
||||
|
||||
}
|
||||
@ -1,7 +1,7 @@
|
||||
package com.cpop.jambox.business.service;
|
||||
|
||||
import com.cpop.jambox.business.entity.website.WebProduct;
|
||||
import com.mybatisflex.core.service.IService;
|
||||
import com.cpop.jambox.business.entity.website.Product;
|
||||
|
||||
/**
|
||||
* 果酱模块化官网 核心产品表 服务层。
|
||||
@ -9,6 +9,6 @@ import com.cpop.jambox.business.entity.website.Product;
|
||||
* @author Yxz
|
||||
* @since 2024-01-19
|
||||
*/
|
||||
public interface ProductService extends IService<Product> {
|
||||
public interface WebProductService extends IService<WebProduct> {
|
||||
|
||||
}
|
||||
@ -97,12 +97,12 @@ public class EasyLearnOrderServiceImpl extends ServiceImpl<EasyLearnOrderMapper,
|
||||
/**
|
||||
* 一次性支付回调地址(本地内网穿透)
|
||||
*/
|
||||
private final String ONCE_PAY_DEV_NOTIFY_URL = "https://frp-bid.top:60778/Cpop-Oam/easyLearn/callback/notify/oncePay";
|
||||
private final String ONCE_PAY_DEV_NOTIFY_URL = "https://frp-bid.top:60778/Cpop-Oam/callback/easyLearn/notify/oncePay";
|
||||
|
||||
/**
|
||||
* 一次性支付回调地址(测试地址)
|
||||
*/
|
||||
private final String ONCE_PAY_TEST_NOTIFY_URL = "https://test.cpopsz.com/Cpop-Oam/easyLearn/callback/notify/oncePay";
|
||||
private final String ONCE_PAY_TEST_NOTIFY_URL = "https://test.cpopsz.com/Cpop-Oam/callback/easyLearn/notify/oncePay";
|
||||
|
||||
/**
|
||||
* 获取放心学分页
|
||||
@ -519,12 +519,12 @@ public class EasyLearnOrderServiceImpl extends ServiceImpl<EasyLearnOrderMapper,
|
||||
/**
|
||||
* 联合支付回调地址(本地内网穿透)
|
||||
*/
|
||||
private final String UNION_PAY_DEV_NOTIFY_URL = "https://frp-bid.top:60778/Cpop-Oam/easyLearn/callback/notify/unionPay";
|
||||
private final String UNION_PAY_DEV_NOTIFY_URL = "https://frp-bid.top:60778/Cpop-Oam/callback/easyLearn/notify/unionPay";
|
||||
|
||||
/**
|
||||
* 联合支付回调地址(测试地址)
|
||||
*/
|
||||
private final String UNION_PAY_TEST_NOTIFY_URL = "https://test.cpopsz.com/Cpop-Oam/easyLearn/callback/notify/unionPay";
|
||||
private final String UNION_PAY_TEST_NOTIFY_URL = "https://test.cpopsz.com/Cpop-Oam/callback/easyLearn/notify/unionPay";
|
||||
|
||||
/**
|
||||
* 放心学统一支付
|
||||
|
||||
@ -1,18 +0,0 @@
|
||||
package com.cpop.jambox.business.service.impl;
|
||||
|
||||
import com.mybatisflex.spring.service.impl.ServiceImpl;
|
||||
import com.cpop.jambox.business.entity.website.Product;
|
||||
import com.cpop.jambox.business.mapper.ProductMapper;
|
||||
import com.cpop.jambox.business.service.ProductService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 果酱模块化官网 核心产品表 服务层实现。
|
||||
*
|
||||
* @author Yxz
|
||||
* @since 2024-01-19
|
||||
*/
|
||||
@Service("productService")
|
||||
public class ProductServiceImpl extends ServiceImpl<ProductMapper, Product> implements ProductService {
|
||||
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
package com.cpop.jambox.business.service.impl;
|
||||
|
||||
import com.cpop.jambox.business.entity.website.WebProduct;
|
||||
import com.cpop.jambox.business.mapper.WebProductMapper;
|
||||
import com.cpop.jambox.business.service.WebProductService;
|
||||
import com.mybatisflex.spring.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 果酱模块化官网 核心产品表 服务层实现。
|
||||
*
|
||||
* @author Yxz
|
||||
* @since 2024-01-19
|
||||
*/
|
||||
@Service("webProductService")
|
||||
public class WebProductServiceImpl extends ServiceImpl<WebProductMapper, WebProduct> implements WebProductService {
|
||||
|
||||
}
|
||||
@ -33,7 +33,7 @@ public class WebsiteServiceImpl implements WebsiteService {
|
||||
@Autowired
|
||||
private BusinessIntroService businessIntroService;
|
||||
@Autowired
|
||||
private ProductService productService;
|
||||
private WebProductService productService;
|
||||
@Autowired
|
||||
private DevelopmentMapper developmentMapper;
|
||||
|
||||
|
||||
@ -1,8 +1,6 @@
|
||||
wx:
|
||||
pay:
|
||||
#支付通知地址
|
||||
notify-url: https://oamapi.cpopsz.com/Cpop-Oam/easyLearn/callback/notify/oncePay
|
||||
#支付通知地址
|
||||
easy-learn-once-pay-notify-url: https://oamapi.cpopsz.com/Cpop-Oam/easyLearn/callback/notify/oncePay
|
||||
easy-learn-once-pay-notify-url: https://oamapi.cpopsz.com/Cpop-Oam/callback/easyLearn/notify/oncePay
|
||||
#放心学联合支付
|
||||
easy-learn-union-pay-notify-url: https://oamapi.cpopsz.com/Cpop-Oam/easyLearn/callback/notify/unionPay
|
||||
easy-learn-union-pay-notify-url: https://oamapi.cpopsz.com/Cpop-Oam/callback/easyLearn/notify/unionPay
|
||||
@ -2,6 +2,6 @@
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.cpop.jambox.business.mapper.ProductMapper">
|
||||
<mapper namespace="com.cpop.jambox.business.mapper.WebProductMapper">
|
||||
|
||||
</mapper>
|
||||
@ -4,7 +4,7 @@ cpop:
|
||||
profile: E:/Cpop/uploadPath
|
||||
jwt:
|
||||
#白名单
|
||||
whiteList: /login,/miniLogin,/test/**,/wxPay/callback/notify/**,/mini/brand/jamboxBrandIsInMall/*,/profile/**,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources
|
||||
whiteList: /login,/miniLogin,/wxPay/callback/notify/**,/mini/brand/jamboxBrandIsInMall/*,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources
|
||||
gateway:
|
||||
rsa-keypair:
|
||||
# 公钥文件
|
||||
@ -104,10 +104,6 @@ knife4j:
|
||||
api-rule-resources:
|
||||
- com.cpop.system
|
||||
|
||||
logging:
|
||||
level:
|
||||
com.github.binarywang.wxpay: debug
|
||||
|
||||
#商城相关配置文件
|
||||
mall:
|
||||
cloudBaseUrl: https://test.cpopsz.com/test/ass/
|
||||
@ -122,6 +118,6 @@ wx:
|
||||
# 私钥文件
|
||||
privateCertPath: E:/Cpop/Cpop-Union/Cpop-Core/src/main/resources/static/keyPair/wxPay_cert.pem
|
||||
#支付通知地址
|
||||
notifyUrl: https://frp-oak.top:11899/Cpop-Mall/wxPay/callback/notify/order
|
||||
notifyUrl: https://frp-oak.top:11899/Cpop-Mall/callback/wxPay/notify/order
|
||||
#退款通知地址
|
||||
notifyRefund: https://frp-oak.top:11899/Cpop-Mall/wxPay/callback/notify/refund
|
||||
notifyRefund: https://frp-oak.top:11899/Cpop-Mall/callback/wxPay/notify/refund
|
||||
|
||||
@ -4,7 +4,7 @@ cpop:
|
||||
profile: D:\WorkSpace\Cpop\uploadPath
|
||||
jwt:
|
||||
#白名单
|
||||
whiteList: /login,/miniLogin,/wxPay/callback/notify/**,/getCaptcha,/profile/**,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources
|
||||
whiteList: /login,/miniLogin,/wxPay/callback/notify/**,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources,/callback/wxPay/notify/**
|
||||
gateway:
|
||||
rsa-keypair:
|
||||
# 公钥文件
|
||||
@ -98,10 +98,6 @@ knife4j:
|
||||
api-rule-resources:
|
||||
- com.cpop.system
|
||||
|
||||
logging:
|
||||
level:
|
||||
com.github.binarywang.wxpay: debug
|
||||
|
||||
#微信支付
|
||||
wx:
|
||||
pay:
|
||||
|
||||
@ -4,7 +4,7 @@ cpop:
|
||||
profile: /root/cpop-union/cpop-mall/upload
|
||||
jwt:
|
||||
#白名单
|
||||
whiteList: /login,/miniLogin,/mini/brand/jamboxBrandIsInMall/*,/wxPay/callback/notify/**,/profile/**
|
||||
whiteList: /login,/miniLogin,/mini/brand/jamboxBrandIsInMall/*,/wxPay/callback/notify/**,/callback/wxPay/notify/**
|
||||
#拦截
|
||||
gateway:
|
||||
rsa-keypair:
|
||||
@ -69,10 +69,6 @@ mybatis-flex:
|
||||
username: root
|
||||
password: Customer0401
|
||||
|
||||
logging:
|
||||
level:
|
||||
com.github.binarywang.wxpay: error
|
||||
|
||||
#商城相关配置文件
|
||||
mall:
|
||||
cloudBaseUrl: https://api.jamboxsys.com/jambox/ass/
|
||||
@ -87,6 +83,6 @@ wx:
|
||||
# 私钥文件
|
||||
privateCertPath: /root/cpop-union/cpop-mall/script/secretKey/wxPay_cert.pem
|
||||
#支付通知地址
|
||||
notifyUrl: https://api.jamboxsys.com/Cpop-Mall/wxPay/callback/notify/order
|
||||
notifyUrl: https://api.jamboxsys.com/Cpop-Mall/callback/wxPay/notify/order
|
||||
#退款通知地址
|
||||
notifyRefund: https://api.jamboxsys.com/Cpop-Mall/wxPay/callback/notify/refund
|
||||
notifyRefund: https://api.jamboxsys.com/Cpop-Mall/callback/wxPay/notify/refund
|
||||
|
||||
@ -4,7 +4,7 @@ cpop:
|
||||
profile: /root/cpop-union/cpop-mall/upload
|
||||
jwt:
|
||||
#白名单
|
||||
whiteList: /login,/miniLogin,/mini/brand/jamboxBrandIsInMall/*,/wxPay/callback/notify/**,/profile/**,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources,/wxOpen/receiveTicket,/wxOpen/*/callback,/wxOpen/bindOpenAccount/*,/wxCp/portal/*
|
||||
whiteList: /login,/miniLogin,/mini/brand/jamboxBrandIsInMall/*,/wxPay/callback/notify/**,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources,/callback/wxPay/notify/**
|
||||
#拦截
|
||||
gateway:
|
||||
rsa-keypair:
|
||||
@ -99,10 +99,6 @@ knife4j:
|
||||
api-rule-resources:
|
||||
- com.cpop.system
|
||||
|
||||
logging:
|
||||
level:
|
||||
com.github.binarywang.wxpay: debug
|
||||
|
||||
#商城相关配置文件
|
||||
mall:
|
||||
cloudBaseUrl: https://test.cpopsz.com/test/ass/
|
||||
@ -117,6 +113,6 @@ wx:
|
||||
# 私钥文件
|
||||
privateCertPath: /root/cpop-union/cpop-mall/script/secretKey/wxPay_cert.pem
|
||||
#支付通知地址
|
||||
notifyUrl: https://test.cpopsz.com/onlineShop/wxPay/callback/notify/order
|
||||
notifyUrl: https://test.cpopsz.com/onlineShop/callback/wxPay/notify/order
|
||||
#退款通知地址
|
||||
notifyRefund: https://test.cpopsz.com/onlineShop/wxPay/callback/notify/refund
|
||||
notifyRefund: https://test.cpopsz.com/onlineShop/callback/wxPay/notify/refund
|
||||
|
||||
@ -31,7 +31,7 @@ spring:
|
||||
max-file-size: 1024MB
|
||||
max-request-size: 300MB
|
||||
profiles:
|
||||
active: dev,mall,core,jambox,system,pay
|
||||
active: dev,core,pay
|
||||
datasource:
|
||||
type: com.zaxxer.hikari.HikariDataSource
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
|
||||
@ -51,11 +51,11 @@ public class CpopWxPayTests {
|
||||
WxPayRefundV3Request.Amount amount = new WxPayRefundV3Request.Amount();
|
||||
//退款金额(单位分)
|
||||
//int refund = order.getTotalAmount().scaleByPowerOfTen(2).intValue();
|
||||
int refund = 1;
|
||||
int refund = 500;
|
||||
amount.setRefund(refund)
|
||||
.setTotal(refund)
|
||||
.setCurrency("CNY");
|
||||
request.setTransactionId("4200002122202401129346519359")
|
||||
request.setTransactionId("4200002130202401237828582894")
|
||||
//.setOutTradeNo("1000000000202401121937112562856")
|
||||
//.setTransactionId(order.getOutOrderNo())
|
||||
//.setOutTradeNo(order.getId())
|
||||
@ -134,8 +134,8 @@ public class CpopWxPayTests {
|
||||
@Test
|
||||
public void getOrderInfo() throws WxPayException {
|
||||
WxPayConfig config = wxPayService.getConfig();
|
||||
config.setSubMchId("1650816616");
|
||||
WxPayOrderQueryResult wxPayOrderQueryResult = wxPayService.queryOrder("01020033210023615210000000008091", null);
|
||||
config.setSubMchId("1661323640");
|
||||
WxPayOrderQueryResult wxPayOrderQueryResult = wxPayService.queryOrder("4200002119202401230387612728", null);
|
||||
System.out.println(wxPayOrderQueryResult);
|
||||
}
|
||||
|
||||
@ -148,7 +148,7 @@ public class CpopWxPayTests {
|
||||
@Test
|
||||
public void getSharingInfo() throws WxPayException {
|
||||
ProfitSharingQueryRequest profitSharingQueryRequest = new ProfitSharingQueryRequest();
|
||||
profitSharingQueryRequest.setOutOrderNo("89825238983995392").setTransactionId("4200002028202312069539269015");
|
||||
profitSharingQueryRequest.setOutOrderNo("107321591016267776").setTransactionId("4200002119202401230387612728");
|
||||
profitSharingQueryRequest.setSubMchId("1661807764");
|
||||
ProfitSharingQueryResult result = wxPayService.getProfitSharingService().profitSharingQuery(profitSharingQueryRequest);
|
||||
System.out.println(result.getResultCode());
|
||||
|
||||
@ -32,7 +32,7 @@ import static com.cpop.mall.business.entity.table.ProductTableDef.PRODUCT;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "商城轮播图接口")
|
||||
@RequestMapping("/carousel")
|
||||
@RequestMapping("/backstage/carousel")
|
||||
public class BackstageCarouselController {
|
||||
|
||||
@Autowired
|
||||
|
||||
@ -0,0 +1,53 @@
|
||||
package com.cpop.mall.business.controller.callback;
|
||||
|
||||
import com.cpop.mall.business.service.OrderRefundService;
|
||||
import com.cpop.mall.business.service.OrderService;
|
||||
import com.github.binarywang.wxpay.bean.notify.WxPayNotifyResponse;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* @author DB
|
||||
* @createTime 2023/10/27 15:57
|
||||
* @description
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/callback/wxPay")
|
||||
public class CallbackWxPayController {
|
||||
|
||||
@Autowired
|
||||
private OrderRefundService orderRefundService;
|
||||
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
|
||||
/**
|
||||
* @descriptions 微信支付订单通知
|
||||
* @author DB
|
||||
* @date 2023/10/27 16:04
|
||||
* @param xmlData 数据
|
||||
* @return: java.lang.String
|
||||
*/
|
||||
@PostMapping("/notify/order")
|
||||
public String parseOrderNotifyResult(@RequestBody String xmlData){
|
||||
orderService.wxPayNotifyOrder(xmlData);
|
||||
return WxPayNotifyResponse.success("成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* @descriptions 退款回调通知处理
|
||||
* @author DB
|
||||
* @date 2023/10/27 18:21
|
||||
* @param xmlData 数据
|
||||
* @return: java.lang.String
|
||||
*/
|
||||
@PostMapping("/notify/refund")
|
||||
public String parseRefundNotifyResult(@RequestBody String xmlData){
|
||||
orderRefundService.wxPayNotifyRefund(xmlData);
|
||||
return WxPayNotifyResponse.success("成功");
|
||||
}
|
||||
|
||||
}
|
||||
@ -16,6 +16,7 @@ import org.springframework.web.bind.annotation.RestController;
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/wxPay/callback")
|
||||
@Deprecated
|
||||
public class WxPayCallbackController {
|
||||
|
||||
@Autowired
|
||||
|
||||
@ -19,6 +19,7 @@ import com.cpop.jambox.business.entity.BrandExtend;
|
||||
import com.cpop.jambox.business.service.BrandExtendService;
|
||||
import com.cpop.mall.business.bo.*;
|
||||
import com.cpop.mall.business.dto.UserPointDto;
|
||||
import com.cpop.pay.framewok.config.wxPay.WxPayConfiguration;
|
||||
import com.cpop.pay.framewok.core.dto.WxPayGoodsDetailDto;
|
||||
import com.cpop.mall.business.entity.*;
|
||||
import com.cpop.mall.business.mapper.OrderMapper;
|
||||
@ -49,6 +50,7 @@ import com.mybatisflex.core.row.DbChain;
|
||||
import com.mybatisflex.core.row.Row;
|
||||
import com.mybatisflex.core.row.RowKey;
|
||||
import com.mybatisflex.spring.service.impl.ServiceImpl;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.quartz.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
@ -57,6 +59,7 @@ import org.springframework.transaction.annotation.Transactional;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.locks.Lock;
|
||||
import java.util.logging.Logger;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.cpop.core.base.table.table.SysUserTableDef.SYS_USER;
|
||||
@ -78,6 +81,7 @@ import static com.mybatisflex.core.query.QueryMethods.sum;
|
||||
* @since 2023-10-24
|
||||
*/
|
||||
@Service("orderService")
|
||||
@Slf4j
|
||||
public class OrderServiceImpl extends ServiceImpl<OrderMapper, Order> implements OrderService {
|
||||
|
||||
@Autowired
|
||||
@ -300,8 +304,6 @@ public class OrderServiceImpl extends ServiceImpl<OrderMapper, Order> implements
|
||||
//微信支付统一下单
|
||||
WxPayService wxPayService = wxPayHandler.getWxPayService();
|
||||
WxPayUnifiedOrderRequest orderRequest = new WxPayUnifiedOrderRequest();
|
||||
//查询是否是服务商系品牌
|
||||
String brandId = loginUserInfo.getString("brandId");
|
||||
//需要分账
|
||||
if (order.getTotalAmount().scaleByPowerOfTen(2).intValue() >= Math.ceil(1 / OrderSource.MALL.getRate())) {
|
||||
//需要分账
|
||||
@ -311,6 +313,7 @@ public class OrderServiceImpl extends ServiceImpl<OrderMapper, Order> implements
|
||||
if (description.getBytes().length > 127) {
|
||||
description = StringUtils.substringByte(description, 0, 126);
|
||||
}
|
||||
WxPayConfiguration configuration = SpringUtils.getBean(WxPayConfiguration.class);
|
||||
orderRequest.setSpbillCreateIp(IpUtils.getHostIp())
|
||||
.setOpenid(loginUserInfo.getString("openId"))
|
||||
//商品描述
|
||||
|
||||
@ -1,4 +0,0 @@
|
||||
FROM openjdk:8-jdk
|
||||
LABEL authors="Lost"
|
||||
ADD ./target/Cpop-Oam-Web.jar Cpop-Oam-Web.jar
|
||||
ENTRYPOINT ["sh", "-c", "java -jar Cpop-Oam-Web.jar --spring.profiles.active=prod,core,jambox"]
|
||||
5
Cpop-Oam/Cpop-Oam-Web/Oam-DockerD-Dockerfile
Normal file
5
Cpop-Oam/Cpop-Oam-Web/Oam-DockerD-Dockerfile
Normal file
@ -0,0 +1,5 @@
|
||||
FROM openjdk:8-jdk
|
||||
LABEL authors="Lost"
|
||||
RUN mkdir -p /root/Cpop-Oam/
|
||||
ADD ./target/Cpop-Oam-Web.jar /root/Cpop-Oam/Cpop-Oam-Web.jar
|
||||
ENTRYPOINT ["sh", "-c", "java -jar /root/Cpop-Oam/Cpop-Oam-Web.jar --spring.profiles.active=dockerD,core,jambox,pay"]
|
||||
@ -0,0 +1,61 @@
|
||||
[2024-01-22 15:21:23.553] INFO [background-preinit] Version.java:21 - HV000001: Hibernate Validator 6.2.5.Final
|
||||
[2024-01-22 15:21:23.563] INFO [main] StartupInfoLogger.java:55 - Starting CpopDataSyncTests using Java 1.8.0_231 on DESKTOP-PIJFD5O with PID 22368 (started by Lost in E:\Cpop\Cpop-Union\Cpop-Oam\Cpop-Oam-Web)
|
||||
[2024-01-22 15:21:23.564] INFO [main] SpringApplication.java:637 - The following 3 profiles are active: "prod", "core", "pay"
|
||||
[2024-01-22 15:21:24.940] INFO [main] RepositoryConfigurationDelegate.java:262 - Multiple Spring Data modules found, entering strict repository configuration mode
|
||||
[2024-01-22 15:21:24.945] INFO [main] RepositoryConfigurationDelegate.java:132 - Bootstrapping Spring Data Redis repositories in DEFAULT mode.
|
||||
[2024-01-22 15:21:24.967] INFO [main] RepositoryConfigurationDelegate.java:201 - Finished Spring Data repository scanning in 6 ms. Found 0 Redis repository interfaces.
|
||||
[2024-01-22 15:21:25.206] INFO [main] LogAccessor.java:292 - No bean named 'errorChannel' has been explicitly defined. Therefore, a default PublishSubscribeChannel will be created.
|
||||
[2024-01-22 15:21:25.221] INFO [main] LogAccessor.java:292 - No bean named 'integrationHeaderChannelRegistry' has been explicitly defined. Therefore, a default DefaultHeaderChannelRegistry will be created.
|
||||
[2024-01-22 15:21:25.688] INFO [main] PostProcessorRegistrationDelegate.java:376 - Bean 'com.mybatisflex.spring.boot.FlexTransactionAutoConfiguration' of type [com.mybatisflex.spring.boot.FlexTransactionAutoConfiguration] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
|
||||
[2024-01-22 15:21:25.997] INFO [main] PostProcessorRegistrationDelegate.java:376 - Bean 'mybatis-flex-com.mybatisflex.spring.boot.MybatisFlexProperties' of type [com.mybatisflex.spring.boot.MybatisFlexProperties] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
|
||||
[2024-01-22 15:21:26.008] INFO [main] PostProcessorRegistrationDelegate.java:376 - Bean 'com.mybatisflex.spring.boot.MultiDataSourceAutoConfiguration' of type [com.mybatisflex.spring.boot.MultiDataSourceAutoConfiguration] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
|
||||
[2024-01-22 15:21:26.135] INFO [main] PostProcessorRegistrationDelegate.java:376 - Bean 'redisConfig' of type [com.cpop.core.config.RedisConfig$$EnhancerBySpringCGLIB$$979fa58a] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
|
||||
[2024-01-22 15:21:27.184] INFO [main] TomcatWebServer.java:108 - Tomcat initialized with port(s): 0 (http)
|
||||
[2024-01-22 15:21:27.194] INFO [main] DirectJDKLog.java:173 - Initializing ProtocolHandler ["http-nio-auto-1"]
|
||||
[2024-01-22 15:21:27.197] INFO [main] DirectJDKLog.java:173 - Starting service [Tomcat]
|
||||
[2024-01-22 15:21:27.197] INFO [main] DirectJDKLog.java:173 - Starting Servlet engine: [Apache Tomcat/9.0.79]
|
||||
[2024-01-22 15:21:27.417] INFO [main] DirectJDKLog.java:173 - Initializing Spring embedded WebApplicationContext
|
||||
[2024-01-22 15:21:27.417] INFO [main] ServletWebServerApplicationContext.java:292 - Root WebApplicationContext: initialization completed in 3825 ms
|
||||
[2024-01-22 15:21:28.467] INFO [main] HikariDataSource.java:110 - HikariPool-1 - Starting...
|
||||
[2024-01-22 15:21:29.147] INFO [main] HikariDataSource.java:123 - HikariPool-1 - Start completed.
|
||||
[2024-01-22 15:21:32.104] INFO [main] StdSchedulerFactory.java:1220 - Using default implementation for ThreadExecutor
|
||||
[2024-01-22 15:21:32.106] INFO [main] SimpleThreadPool.java:268 - Job execution threads will use class loader of thread: main
|
||||
[2024-01-22 15:21:32.118] INFO [main] SchedulerSignalerImpl.java:61 - Initialized Scheduler Signaller of type: class org.quartz.core.SchedulerSignalerImpl
|
||||
[2024-01-22 15:21:32.119] INFO [main] QuartzScheduler.java:229 - Quartz Scheduler v.2.3.2 created.
|
||||
[2024-01-22 15:21:32.122] INFO [main] JobStoreSupport.java:672 - Using db table-based data access locking (synchronization).
|
||||
[2024-01-22 15:21:32.124] INFO [main] JobStoreCMT.java:145 - JobStoreCMT initialized.
|
||||
[2024-01-22 15:21:32.125] INFO [main] QuartzScheduler.java:294 - Scheduler meta-data: Quartz Scheduler (v2.3.2) 'CpopOamScheduler' with instanceId 'NON_CLUSTERED'
|
||||
Scheduler class: 'org.quartz.core.QuartzScheduler' - running locally.
|
||||
NOT STARTED.
|
||||
Currently in standby mode.
|
||||
Number of jobs executed: 0
|
||||
Using thread pool 'org.quartz.simpl.SimpleThreadPool' - with 1 threads.
|
||||
Using job-store 'org.springframework.scheduling.quartz.LocalDataSourceJobStore' - which supports persistence. and is not clustered.
|
||||
|
||||
[2024-01-22 15:21:32.125] INFO [main] StdSchedulerFactory.java:1374 - Quartz scheduler 'CpopOamScheduler' initialized from an externally provided properties instance.
|
||||
[2024-01-22 15:21:32.126] INFO [main] StdSchedulerFactory.java:1378 - Quartz scheduler version: 2.3.2
|
||||
[2024-01-22 15:21:32.126] INFO [main] QuartzScheduler.java:2293 - JobFactory set to: org.springframework.scheduling.quartz.SpringBeanJobFactory@1d5048d1
|
||||
[2024-01-22 15:21:32.798] INFO [main] InitConfig.java:41 - ===========================项目启动角色初始化===========================
|
||||
[2024-01-22 15:21:34.212] INFO [main] DefaultSecurityFilterChain.java:55 - Will secure any request with [org.springframework.security.web.session.DisableEncodeUrlFilter@4c3d72fd, org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter@259c6ab8, org.springframework.security.web.context.SecurityContextPersistenceFilter@39420d59, org.springframework.security.web.header.HeaderWriterFilter@3340ff7c, com.cpop.core.filter.JwtAuthenticationFilter@1488a861, org.springframework.security.web.authentication.logout.LogoutFilter@5bf1b528, com.cpop.core.filter.RepeatableFilter@22e813fc, com.cpop.core.gateway.sys.SysAuthenticationFilter@605eb072, com.cpop.core.gateway.miniProgram.MiniProgramAuthenticationFilter@1fa9692b, org.springframework.security.web.savedrequest.RequestCacheAwareFilter@5dd227b7, org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter@14ba7f15, org.springframework.security.web.authentication.AnonymousAuthenticationFilter@640a6d4b, org.springframework.security.web.session.SessionManagementFilter@5e198c40, org.springframework.security.web.access.ExceptionTranslationFilter@6cbb6c41, org.springframework.security.web.access.intercept.AuthorizationFilter@7ef7f414]
|
||||
[2024-01-22 15:21:35.868] INFO [main] LogAccessor.java:174 - Adding {logging-channel-adapter:_org.springframework.integration.errorLogger} as a subscriber to the 'errorChannel' channel
|
||||
[2024-01-22 15:21:35.868] INFO [main] LogAccessor.java:174 - Channel 'Cpop-Oam-Prod.errorChannel' has 1 subscriber(s).
|
||||
[2024-01-22 15:21:35.868] INFO [main] LogAccessor.java:292 - started bean '_org.springframework.integration.errorLogger'
|
||||
[2024-01-22 15:21:35.869] INFO [main] DirectJDKLog.java:173 - Starting ProtocolHandler ["http-nio-auto-1"]
|
||||
[2024-01-22 15:21:35.893] INFO [main] TomcatWebServer.java:220 - Tomcat started on port(s): 59855 (http) with context path '/Cpop-Oam'
|
||||
[2024-01-22 15:21:35.895] INFO [main] SchedulerFactoryBean.java:734 - Will start Quartz Scheduler [CpopOamScheduler] in 1 seconds
|
||||
[2024-01-22 15:21:35.912] INFO [main] StartupInfoLogger.java:61 - Started CpopDataSyncTests in 12.809 seconds (JVM running for 14.317)
|
||||
[2024-01-22 15:21:36.907] INFO [Quartz Scheduler [CpopOamScheduler]] SchedulerFactoryBean.java:750 - Starting Quartz Scheduler now, after delay of 1 seconds
|
||||
[2024-01-22 15:21:37.083] INFO [Quartz Scheduler [CpopOamScheduler]] JobStoreSupport.java:866 - Freed 0 triggers from 'acquired' / 'blocked' state.
|
||||
[2024-01-22 15:21:37.154] INFO [Quartz Scheduler [CpopOamScheduler]] JobStoreSupport.java:876 - Recovering 0 jobs that were in-progress at the time of the last shut-down.
|
||||
[2024-01-22 15:21:37.154] INFO [Quartz Scheduler [CpopOamScheduler]] JobStoreSupport.java:889 - Recovery complete.
|
||||
[2024-01-22 15:21:37.188] INFO [Quartz Scheduler [CpopOamScheduler]] JobStoreSupport.java:896 - Removed 0 'complete' triggers.
|
||||
[2024-01-22 15:21:37.224] INFO [Quartz Scheduler [CpopOamScheduler]] JobStoreSupport.java:901 - Removed 0 stale fired job entries.
|
||||
[2024-01-22 15:21:37.294] INFO [Quartz Scheduler [CpopOamScheduler]] QuartzScheduler.java:547 - Scheduler CpopOamScheduler_$_NON_CLUSTERED started.
|
||||
[2024-01-22 15:23:22.877] INFO [SpringApplicationShutdownHook] QuartzScheduler.java:585 - Scheduler CpopOamScheduler_$_NON_CLUSTERED paused.
|
||||
[2024-01-22 15:23:23.203] INFO [SpringApplicationShutdownHook] LogAccessor.java:174 - Removing {logging-channel-adapter:_org.springframework.integration.errorLogger} as a subscriber to the 'errorChannel' channel
|
||||
[2024-01-22 15:23:23.203] INFO [SpringApplicationShutdownHook] LogAccessor.java:174 - Channel 'Cpop-Oam-Prod.errorChannel' has 0 subscriber(s).
|
||||
[2024-01-22 15:23:23.203] INFO [SpringApplicationShutdownHook] LogAccessor.java:292 - stopped bean '_org.springframework.integration.errorLogger'
|
||||
[2024-01-22 15:23:23.209] INFO [SpringApplicationShutdownHook] SchedulerFactoryBean.java:847 - Shutting down Quartz Scheduler
|
||||
[2024-01-22 15:23:23.210] INFO [SpringApplicationShutdownHook] QuartzScheduler.java:666 - Scheduler CpopOamScheduler_$_NON_CLUSTERED shutting down.
|
||||
[2024-01-22 15:23:23.210] INFO [SpringApplicationShutdownHook] QuartzScheduler.java:585 - Scheduler CpopOamScheduler_$_NON_CLUSTERED paused.
|
||||
[2024-01-22 15:23:23.210] INFO [SpringApplicationShutdownHook] QuartzScheduler.java:740 - Scheduler CpopOamScheduler_$_NON_CLUSTERED shutdown complete.
|
||||
@ -4,7 +4,7 @@ cpop:
|
||||
profile: E:/Cpop/uploadPath
|
||||
jwt:
|
||||
#白名单
|
||||
whiteList: /websocket/*,/login,/getCaptcha,/profile/**,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources,/wxCp/*,/wxCp/portal/*/registerCode,/sysCommon/miniSyncBrandAndStore,/easyLearn/callback/*/*,/easyLearn/*,/mini/cardTemplate/*,/website/**
|
||||
whiteList: /websocket/*,/login,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources,/sysCommon/miniSyncBrandAndStore,/easyLearn/callback/*/*,/easyLearn/*,/mini/cardTemplate/*,/website/**,/backstage/wxCp/*,/callback/wxCp/*/registerCode,/callback/easyLearn/**
|
||||
gateway:
|
||||
rsa-keypair:
|
||||
# 公钥文件
|
||||
@ -109,6 +109,6 @@ wx:
|
||||
# 私钥文件
|
||||
privateCertPath: E:/Cpop/Cpop-Union/Cpop-Core/src/main/resources/static/keyPair/wxPay_cert.pem
|
||||
# 先学后付用户签约通知地址
|
||||
learn-now-pay-later-user-sign-plan-notify-url:
|
||||
learn-now-pay-later-user-sign-plan-notify-url: https://frp-oak.top:11899/Cpop-Oam/callback/easyLearn/learnNowPayLaterUserSignPlanNotify
|
||||
# 先学后付用户核销通知地址
|
||||
learn-now-pay-later-service-order-notify-url:
|
||||
learn-now-pay-later-service-order-notify-url: https://frp-oak.top:11899/Cpop-Oam/callback/easyLearn/learnNowPayLaterUserSignPlanNotify
|
||||
114
Cpop-Oam/Cpop-Oam-Web/src/main/resources/application-dockerD.yml
Normal file
114
Cpop-Oam/Cpop-Oam-Web/src/main/resources/application-dockerD.yml
Normal file
@ -0,0 +1,114 @@
|
||||
# 项目相关配置
|
||||
cpop:
|
||||
# 文件路径 示例( Windows配置W:/WorkSpace/java/uploadPath,Linux配置 /home/baseFramework/uploadPath)
|
||||
profile: E:/Cpop/uploadPath
|
||||
jwt:
|
||||
#白名单
|
||||
whiteList: /websocket/*,/login,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources,/sysCommon/miniSyncBrandAndStore,/easyLearn/callback/*/*,/easyLearn/*,/mini/cardTemplate/*,/website/**,/backstage/wxCp/*,/callback/wxCp/*/registerCode,/callback/easyLearn/**
|
||||
gateway:
|
||||
rsa-keypair:
|
||||
# 公钥文件
|
||||
publicKeyFile: /root/Cpop-Oam/keyPair/publicKey
|
||||
# 公钥文件
|
||||
privateKeyFile: /root/Cpop-Oam/keyPair/privateKey
|
||||
|
||||
# DataSource Config
|
||||
spring:
|
||||
application:
|
||||
name: Cpop-Oam-Dev
|
||||
#redis配置
|
||||
redis:
|
||||
#地址
|
||||
host: gz-crs-lv77ii2t.sql.tencentcdb.com
|
||||
#端口
|
||||
port: 27714
|
||||
#数据库
|
||||
database: 1
|
||||
#密码
|
||||
password: Cpop2022@
|
||||
#连接超时
|
||||
timeout: 5000
|
||||
jedis:
|
||||
pool:
|
||||
#
|
||||
min-idle: 0
|
||||
#
|
||||
max-idle: 16
|
||||
#
|
||||
max-active: 16
|
||||
#
|
||||
max-wait: -1ms
|
||||
client-type: jedis
|
||||
data:
|
||||
mongodb:
|
||||
host: localhost
|
||||
port: 27017
|
||||
database: cpop-dev
|
||||
username: Cpop
|
||||
password: Admin@123
|
||||
|
||||
server:
|
||||
port: 9420
|
||||
servlet:
|
||||
context-path: /Cpop-Oam
|
||||
|
||||
#Mybatis-Flex
|
||||
mybatis-flex:
|
||||
configuration:
|
||||
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||||
datasource:
|
||||
oam:
|
||||
url: jdbc:mysql://192.168.3.61:3306/cpop_dev?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: root
|
||||
password: Admin@123
|
||||
jambox:
|
||||
url: jdbc:mysql://sh-cynosdbmysql-grp-fggo83js.sql.tencentcdb.com:20965/jambox_test?useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
|
||||
username: root
|
||||
password: Customer0401
|
||||
|
||||
# springdoc-openapi项目配置
|
||||
knife4j:
|
||||
enable: true
|
||||
openapi:
|
||||
title: PuPu-OAM开发API
|
||||
description: PuPu-OAM开发API
|
||||
email:
|
||||
concat: DB
|
||||
url: https://api.jamboxsys.com
|
||||
version: 1.0.0
|
||||
license: Apache 2.0
|
||||
license-url: https://stackoverflow.com/
|
||||
terms-of-service-url: https://api.jamboxsys.com
|
||||
group:
|
||||
#系统
|
||||
Oam:
|
||||
group-name: Oam
|
||||
api-rule: package
|
||||
api-rule-resources:
|
||||
- com.cpop.oam
|
||||
#系统
|
||||
System:
|
||||
group-name: System
|
||||
api-rule: package
|
||||
api-rule-resources:
|
||||
- com.cpop.system
|
||||
#果酱
|
||||
Jambox:
|
||||
group-name: Jambox
|
||||
api-rule: package
|
||||
api-rule-resources:
|
||||
- com.cpop.jambox
|
||||
|
||||
#微信
|
||||
wx:
|
||||
pay:
|
||||
# p12证书的位置,可以指定绝对路径,也可以指定类路径(以classpath:开头)
|
||||
keyPath: /root/Cpop-Oam/keyPair/wxPay_cert.p12
|
||||
# 私钥证书
|
||||
privateKeyPath: /root/Cpop-Oam/keyPair/wxPay_key.pem
|
||||
# 私钥文件
|
||||
privateCertPath: /root/Cpop-Oam/keyPair/wxPay_cert.pem
|
||||
# 先学后付用户签约通知地址
|
||||
learn-now-pay-later-user-sign-plan-notify-url: https://frp-oak.top:11899/Cpop-Oam/callback/easyLearn/learnNowPayLaterUserSignPlanNotify
|
||||
# 先学后付用户核销通知地址
|
||||
learn-now-pay-later-service-order-notify-url: https://frp-oak.top:11899/Cpop-Oam/callback/easyLearn/learnNowPayLaterUserSignPlanNotify
|
||||
@ -4,7 +4,7 @@ cpop:
|
||||
profile: /root/cpop-union/cpop-oam/upload
|
||||
jwt:
|
||||
#白名单
|
||||
whiteList: /websocket/*,/login,/getCaptcha,/profile/**,/wxOpen/receiveTicket,/wxOpen/*/callback,/wxOpen/bindOpenAccount/*,/wxCp/portal/*,/wxCp/*,/wxCp/portal/*/registerCode,/sysCommon/miniSyncBrandAndStore,/easyLearn/callback/*/*,/easyLearn/*,/mini/cardTemplate/*,/website/**
|
||||
whiteList: /websocket/*,/login,/backstage/wxOpen/**,/sysCommon/miniSyncBrandAndStore,/easyLearn/callback/*/*,/easyLearn/*,/mini/cardTemplate/*,/website/**,/backstage/wxCp/*,/callback/wxCp/*/registerCode,/callback/easyLearn/**
|
||||
#拦截
|
||||
gateway:
|
||||
rsa-keypair:
|
||||
@ -73,4 +73,8 @@ wx:
|
||||
# 私钥证书
|
||||
privateKeyPath: /root/cpop-union/cpop-oam/script/secretKey/wxPay_key.pem
|
||||
# 私钥文件
|
||||
privateCertPath: /root/cpop-union/cpop-oam/script/secretKey/wxPay_cert.pem
|
||||
privateCertPath: /root/cpop-union/cpop-oam/script/secretKey/wxPay_cert.pem
|
||||
# 先学后付用户签约通知地址
|
||||
learn-now-pay-later-user-sign-plan-notify-url: https://oam.jamboxsys.com/Cpop-Oam/callback/easyLearn/learnNowPayLaterUserSignPlanNotify
|
||||
# 先学后付用户核销通知地址
|
||||
learn-now-pay-later-service-order-notify-url: https://oam.jamboxsys.com/Cpop-Oam/callback/easyLearn/userServiceOrderSuccess
|
||||
@ -4,7 +4,7 @@ cpop:
|
||||
profile: /root/cpop-union/cpop-mall/upload
|
||||
jwt:
|
||||
#白名单
|
||||
whiteList: /websocket/*,/login,/getCaptcha,/profile/**,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources,/wxOpen/receiveTicket,/wxOpen/*/callback,/wxOpen/bindOpenAccount/*,/wxCp/portal/*,/wxCp/portal/*/registerCode,/wxCp/*,/sysCommon/miniSyncBrandAndStore,/easyLearn/callback/*/*,/easyLearn/*,/mini/cardTemplate/*,/website/**
|
||||
whiteList: /websocket/*,/login,/doc.html,/webjars/**,/favicon.ico,/v2/api-docs/**,/swagger-resources,/sysCommon/miniSyncBrandAndStore,/easyLearn/callback/*/*,/easyLearn/*,/mini/cardTemplate/*,/website/**,/backstage/wxCp/*,/callback/wxCp/*/registerCode,/callback/easyLearn/**
|
||||
#拦截
|
||||
gateway:
|
||||
rsa-keypair:
|
||||
@ -94,4 +94,8 @@ wx:
|
||||
# 私钥证书
|
||||
privateKeyPath: /root/cpop-union/cpop-oam/script/secretKey/wxPay_key.pem
|
||||
# 私钥文件
|
||||
privateCertPath: /root/cpop-union/cpop-oam/script/secretKey/wxPay_cert.pem
|
||||
privateCertPath: /root/cpop-union/cpop-oam/script/secretKey/wxPay_cert.pem
|
||||
# 先学后付用户签约通知地址
|
||||
learn-now-pay-later-user-sign-plan-notify-url: https://test.cpopsz.com/oam/Cpop-Oam/callback/easyLearn/learnNowPayLaterUserSignPlanNotify
|
||||
# 先学后付用户核销通知地址
|
||||
learn-now-pay-later-service-order-notify-url: https://test.cpopsz.com/oam/Cpop-Oam/callback/easyLearn/userServiceOrderSuccess
|
||||
@ -31,7 +31,7 @@ spring:
|
||||
max-file-size: 1024MB
|
||||
max-request-size: 300MB
|
||||
profiles:
|
||||
active: dev,oam,core,jambox,system,pay
|
||||
active: dev,core,jambox,pay
|
||||
datasource:
|
||||
type: com.zaxxer.hikari.HikariDataSource
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package com.cpop.oam.web;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.cpop.common.utils.StringUtils;
|
||||
import com.cpop.core.utils.SpringUtils;
|
||||
import com.cpop.jambox.business.entity.BrandExtend;
|
||||
@ -36,8 +37,10 @@ import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.cpop.core.base.table.table.SysUserTableDef.SYS_USER;
|
||||
import static com.cpop.jambox.business.entity.table.StoreExtendTableDef.STORE_EXTEND;
|
||||
import static com.cpop.oam.business.entity.table.StaffTableDef.STAFF;
|
||||
import static com.cpop.system.business.entity.table.StoreSignTableDef.STORE_SIGN;
|
||||
import static com.cpop.system.business.entity.table.StoreTableDef.STORE;
|
||||
import static com.mybatisflex.core.query.QueryMethods.count;
|
||||
import static com.mybatisflex.core.query.QueryMethods.max;
|
||||
|
||||
@ -286,4 +289,21 @@ public class CpopDataSyncTests {
|
||||
});
|
||||
SpringUtils.getBean(StoreService.class).updateBatch(stores);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除没有云校区的数据
|
||||
* @author DB
|
||||
* @since 2024/1/23
|
||||
*/
|
||||
@Test
|
||||
public void removeNotHaveCloudStore() {
|
||||
StoreService storeService = SpringUtils.getBean(StoreService.class);
|
||||
List<Store> storeList = storeService.queryChain()
|
||||
.select(STORE.ID)
|
||||
.leftJoin(STORE_EXTEND).on(STORE_EXTEND.STORE_ID.eq(STORE.ID))
|
||||
.where(STORE_EXTEND.STORE_CLOUD_ID.isNull())
|
||||
.list();
|
||||
List<String> collect = storeList.stream().map(Store::getId).collect(Collectors.toList());
|
||||
storeService.removeByIds(collect);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,10 +1,14 @@
|
||||
package com.cpop.oam.web;
|
||||
|
||||
import cn.binarywang.wx.miniapp.api.WxMaQrcodeService;
|
||||
import cn.binarywang.wx.miniapp.api.WxMaService;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.cpop.common.utils.StringUtils;
|
||||
import com.cpop.core.base.enums.OrderSource;
|
||||
import com.cpop.core.base.exception.ServiceException;
|
||||
import com.cpop.core.handler.TencentCosHandler;
|
||||
import com.cpop.core.utils.SpringUtils;
|
||||
import com.cpop.core.utils.file.FileUtils;
|
||||
import com.cpop.jambox.business.entity.EasyLearnOrder;
|
||||
import com.cpop.jambox.business.entity.StoreExtend;
|
||||
import com.cpop.jambox.business.service.EasyLearnOrderService;
|
||||
@ -34,11 +38,14 @@ import com.mybatisflex.core.row.Db;
|
||||
import com.mybatisflex.core.row.DbChain;
|
||||
import com.mybatisflex.core.row.Row;
|
||||
import com.mybatisflex.core.row.RowKey;
|
||||
import com.qcloud.cos.model.UploadResult;
|
||||
import me.chanjar.weixin.common.error.WxErrorException;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
import org.springframework.test.context.ActiveProfiles;
|
||||
import org.springframework.web.client.RestTemplate;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.*;
|
||||
import java.nio.file.Files;
|
||||
@ -303,4 +310,62 @@ public class CpopEasyLearnTest {
|
||||
.update();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建微信太阳码
|
||||
* @author DB
|
||||
* @since 2024/1/23
|
||||
*/
|
||||
@Test
|
||||
public void createMiniQrCode() throws WxErrorException, IOException {
|
||||
// 获取当前执行环境
|
||||
String active = SpringUtils.getActiveProfile();
|
||||
WxMaQrcodeService qrcodeService = SpringUtils.getBean(WxMaService.class).getQrcodeService();
|
||||
File qrCode = qrcodeService.createWxaCodeUnlimit("105525473294344192", "pages/pay/pay", false, StringUtils.equals(active, "prod") ? "release" : "trial", 430,
|
||||
true, null, false);
|
||||
MultipartFile multipartFile = FileUtils.getInstance().getMultipartFile(qrCode);
|
||||
TencentCosHandler tencentCosHandler = SpringUtils.getBean(TencentCosHandler.class);
|
||||
UploadResult uploadResult = tencentCosHandler.cdnUpload(multipartFile);
|
||||
System.out.println("https://" + uploadResult.getBucketName() + tencentCosHandler.getCdnUrl() + uploadResult.getKey());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testtest(){
|
||||
String serviceIntroduction = "排课000\uD83C\uDF3F\uD83C\uDF8B\uD83C\uDF15\uD83C\uDF44\uD83D\uDC1A";
|
||||
String newServiceIntroduction = "";
|
||||
//特殊字符过滤
|
||||
if (StringUtils.isBlank(serviceIntroduction)) {
|
||||
newServiceIntroduction = serviceIntroduction;
|
||||
}
|
||||
StringBuilder buf = null;
|
||||
int len = serviceIntroduction.length();
|
||||
for (int i = 0; i < len; i++) {
|
||||
char codePoint = serviceIntroduction.charAt(i);
|
||||
if (isEmojiCharacter(codePoint)) {
|
||||
if (buf == null) {
|
||||
buf = new StringBuilder(serviceIntroduction.length());
|
||||
}
|
||||
buf.append(codePoint);
|
||||
}
|
||||
}
|
||||
if (buf == null) {
|
||||
newServiceIntroduction = serviceIntroduction;
|
||||
} else {
|
||||
if (buf.length() == len) {
|
||||
buf = null;
|
||||
newServiceIntroduction = serviceIntroduction;
|
||||
} else {
|
||||
newServiceIntroduction = buf.toString();
|
||||
}
|
||||
}
|
||||
System.out.println(newServiceIntroduction);
|
||||
}
|
||||
|
||||
private boolean isEmojiCharacter(char codePoint) {
|
||||
return (codePoint == 0x0) || (codePoint == 0x9) || (codePoint == 0xA)
|
||||
|| (codePoint == 0xD)
|
||||
|| ((codePoint >= 0x20) && (codePoint <= 0xD7FF))
|
||||
|| ((codePoint >= 0xE000) && (codePoint <= 0xFFFD))
|
||||
|| ((codePoint >= 0x10000) && (codePoint <= 0x10FFFF));
|
||||
}
|
||||
}
|
||||
|
||||
@ -31,8 +31,8 @@ import java.util.List;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "品牌管理员表接口")
|
||||
@RequestMapping("/brandManage")
|
||||
public class BrandManagerController {
|
||||
@RequestMapping("/backstage/brandManage")
|
||||
public class BackstageBrandManagerController {
|
||||
@Autowired
|
||||
private BrandManagerService brandManageService;
|
||||
|
||||
@ -36,8 +36,8 @@ import static com.cpop.oam.business.entity.table.StaffTableDef.STAFF;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "市场模块")
|
||||
@RequestMapping("/business")
|
||||
public class BusinessController {
|
||||
@RequestMapping("/backstage/business")
|
||||
public class BackstageBusinessController {
|
||||
|
||||
@Autowired
|
||||
private BusinessService businessService;
|
||||
@ -182,8 +182,8 @@ public class BusinessController {
|
||||
* @return R<Void>
|
||||
*/
|
||||
@ApiOperation("校区签约")
|
||||
@PutMapping("/storeSign")
|
||||
public R<Void> storeSign(@ApiParam(value = "校区id", required = true) @RequestParam(value = "id") String id) {
|
||||
@PutMapping("/storeSign/{id}")
|
||||
public R<Void> storeSign(@ApiParam(value = "校区id", required = true) @PathVariable String id) {
|
||||
businessService.storeSign(id);
|
||||
return R.ok();
|
||||
}
|
||||
@ -20,8 +20,8 @@ import org.springframework.web.bind.annotation.RestController;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "云数据查询接口")
|
||||
@RequestMapping("/cloudData")
|
||||
public class CloudDataController {
|
||||
@RequestMapping("/backstage/cloudData")
|
||||
public class BackstageCloudDataController {
|
||||
|
||||
@Autowired
|
||||
private CloudCustomerStudentHandler cloudCustomerStudentHandler;
|
||||
@ -38,8 +38,8 @@ import static com.cpop.system.business.entity.table.StoreTableDef.STORE;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "数据导入接口")
|
||||
@RequestMapping("/dataImport")
|
||||
public class DataImportController {
|
||||
@RequestMapping("/backstage/dataImport")
|
||||
public class BackstageDataImportController {
|
||||
|
||||
@Autowired
|
||||
private DataImportService dataImportService;
|
||||
@ -24,8 +24,8 @@ import java.util.List;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "系统部门模块")
|
||||
@RequestMapping("/dept")
|
||||
public class DeptController {
|
||||
@RequestMapping("/backstage/dept")
|
||||
public class BackstageDeptController {
|
||||
|
||||
@Autowired
|
||||
private DeptService deptService;
|
||||
@ -28,8 +28,8 @@ import static com.cpop.oam.business.entity.table.StaffTableDef.STAFF;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "值班日历模块")
|
||||
@RequestMapping("/duty")
|
||||
public class DutyController {
|
||||
@RequestMapping("/backstage/duty")
|
||||
public class BackstageDutyController {
|
||||
|
||||
@Autowired
|
||||
private DutyService dutyService;
|
||||
@ -30,8 +30,8 @@ import static com.cpop.oam.business.entity.table.FinanceReimburseTableDef.FINANC
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "财务报销模块")
|
||||
@RequestMapping("/financeReimburse")
|
||||
public class FinanceReimburseController {
|
||||
@RequestMapping("/backstage/financeReimburse")
|
||||
public class BackstageFinanceReimburseController {
|
||||
|
||||
@Autowired
|
||||
private FinanceReimburseService financeReimburseService;
|
||||
@ -26,8 +26,8 @@ import java.util.List;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "商城管理模块")
|
||||
@RequestMapping("/oamMall")
|
||||
public class OamMallController {
|
||||
@RequestMapping("/backstage/oamMall")
|
||||
public class BackstageOamMallController {
|
||||
@Autowired
|
||||
private OamMallService oamMallService;
|
||||
|
||||
@ -36,8 +36,8 @@ import static com.cpop.system.business.entity.table.RoleTableDef.ROLE;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "员工账号管理模块")
|
||||
@RequestMapping("/staff")
|
||||
public class StaffController {
|
||||
@RequestMapping("/backstage/staff")
|
||||
public class BackstageStaffController {
|
||||
|
||||
@Autowired
|
||||
private StaffService staffService;
|
||||
@ -32,8 +32,8 @@ import static com.cpop.jambox.business.entity.table.StorePlugTableDef.STORE_PLUG
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "校区-插件记录表接口")
|
||||
@RequestMapping("/storePlug")
|
||||
public class StorePlugController {
|
||||
@RequestMapping("/backstage/storePlug")
|
||||
public class BackstageStorePlugController {
|
||||
|
||||
@Autowired
|
||||
private StorePlugService storePlugService;
|
||||
@ -20,8 +20,8 @@ import org.springframework.web.bind.annotation.*;
|
||||
*/
|
||||
@Api(tags = "系统配置模块")
|
||||
@RestController
|
||||
@RequestMapping("/sysConfig")
|
||||
public class SysConfigController {
|
||||
@RequestMapping("/backstage/sysConfig")
|
||||
public class BackstageSysConfigController {
|
||||
|
||||
@Autowired
|
||||
private CommonService commonService;
|
||||
@ -33,8 +33,8 @@ import static com.cpop.system.business.entity.table.StoreTableDef.STORE;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "工单模块-需求")
|
||||
@RequestMapping("/taskDemand")
|
||||
public class TaskDemandController {
|
||||
@RequestMapping("/backstage/taskDemand")
|
||||
public class BackstageTaskDemandController {
|
||||
|
||||
@Autowired
|
||||
private TaskDemandService taskDemandService;
|
||||
@ -28,8 +28,8 @@ import java.util.List;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "技术模块-技术")
|
||||
@RequestMapping("/taskTechnology")
|
||||
public class TaskTechnologyController {
|
||||
@RequestMapping("/backstage/taskTechnology")
|
||||
public class BackstageTaskTechnologyController {
|
||||
|
||||
@Autowired
|
||||
private TaskWorkOrderService taskWorkOrderService;
|
||||
@ -34,8 +34,8 @@ import static com.cpop.system.business.entity.table.StoreTableDef.STORE;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "工单模块-工单")
|
||||
@RequestMapping("/taskWorkOrder")
|
||||
public class TaskWorkOrderController {
|
||||
@RequestMapping("/backstage/taskWorkOrder")
|
||||
public class BackstageTaskWorkOrderController {
|
||||
|
||||
@Autowired
|
||||
private TaskWorkOrderService taskWorkOrderService;
|
||||
@ -32,8 +32,8 @@ import static com.cpop.oam.business.entity.table.TechnologyToolTableDef.TECHNOLO
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "技术工具管理")
|
||||
@RequestMapping("/technologyTool")
|
||||
public class TechnologyToolController {
|
||||
@RequestMapping("/backstage/technologyTool")
|
||||
public class BackstageTechnologyToolController {
|
||||
|
||||
@Autowired
|
||||
private TechnologyToolService technologyToolService;
|
||||
@ -24,8 +24,8 @@ import javax.servlet.http.HttpServletRequest;
|
||||
@Slf4j
|
||||
@RestController
|
||||
@Api(tags = "企业微信相关模块")
|
||||
@RequestMapping("/wxCp")
|
||||
public class WxCpController {
|
||||
@RequestMapping("/backstage/wxCp")
|
||||
public class BackstageWxCpController {
|
||||
|
||||
@Autowired
|
||||
private OamWxCpService oamWxCpService;
|
||||
@ -47,8 +47,8 @@ import java.util.List;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "微信开放平台模块")
|
||||
@RequestMapping("/wxOpen")
|
||||
public class WxOpenController {
|
||||
@RequestMapping("/backstage/wxOpen")
|
||||
public class BackstageWxOpenController {
|
||||
|
||||
private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
||||
|
||||
@ -34,8 +34,8 @@ import static com.cpop.system.business.entity.table.BrandTableDef.BRAND;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "微信支付模块")
|
||||
@RequestMapping("/wxPay")
|
||||
public class WxPayController {
|
||||
@RequestMapping("/backstage/wxPay")
|
||||
public class BackstageWxPayController {
|
||||
|
||||
@Autowired
|
||||
private WxPayConfiguration wxPayConfiguration;
|
||||
@ -22,7 +22,8 @@ import org.springframework.web.bind.annotation.RestController;
|
||||
@Api(tags = "云回调controller")
|
||||
@RestController
|
||||
@RequestMapping("/cloudCallback")
|
||||
public class CloudCallbackController {
|
||||
@Deprecated
|
||||
public class CallBackCloudCallbackController {
|
||||
|
||||
/**
|
||||
* 云联合回调
|
||||
@ -0,0 +1,40 @@
|
||||
package com.cpop.oam.business.controller.callback;
|
||||
|
||||
import com.cpop.core.base.R;
|
||||
import com.cpop.oam.business.bo.CloudUnionCallbackBo;
|
||||
import com.cpop.oam.framework.enums.CloudCallbackEnums;
|
||||
import com.cpop.oam.framework.strategy.cloud.CloudCallbackStrategy;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* @author DB
|
||||
* @version 1.0.0
|
||||
* @since 2024-01-16 11:28
|
||||
*/
|
||||
@Api(tags = "云回调controller")
|
||||
@RestController
|
||||
@RequestMapping("/callback/cloud")
|
||||
public class CallbackCloudController {
|
||||
|
||||
/**
|
||||
* 云联合回调
|
||||
* @author DB
|
||||
* @since 2024/1/16
|
||||
* @param callback 回调参数
|
||||
* @return R<Void>
|
||||
*/
|
||||
//@SimpleSignatureCheck
|
||||
@ApiOperation("云联合回调")
|
||||
@PostMapping("/cloudUnionCallback")
|
||||
public R<Void> cloudUnionCallback(@RequestBody @Validated CloudUnionCallbackBo callback) {
|
||||
CloudCallbackStrategy cloudCallbackStrategy = CloudCallbackEnums.valueOf(callback.getCallbackEnum()).getCloudCallbackStrategy();
|
||||
cloudCallbackStrategy.callback(callback);
|
||||
return R.ok();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,107 @@
|
||||
package com.cpop.oam.business.controller.callback;
|
||||
|
||||
import com.cpop.common.utils.JsonUtils;
|
||||
import com.cpop.common.utils.StringUtils;
|
||||
import com.cpop.oam.business.service.OamWxCpService;
|
||||
import com.cpop.oam.framework.config.wxCp.WxCpConfiguration;
|
||||
import io.swagger.annotations.Api;
|
||||
import me.chanjar.weixin.cp.api.WxCpService;
|
||||
import me.chanjar.weixin.cp.bean.message.WxCpXmlMessage;
|
||||
import me.chanjar.weixin.cp.bean.message.WxCpXmlOutMessage;
|
||||
import me.chanjar.weixin.cp.util.crypto.WxCpCryptUtil;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* @author DB
|
||||
* @createTime 2023/10/12 15:17
|
||||
* @description 企业微信认证回调接口
|
||||
*/
|
||||
@Api(tags = "企业微信消息接收controller")
|
||||
@RestController
|
||||
@RequestMapping("/callback/wxCp/{agentId}")
|
||||
public class CallbackWxCpController {
|
||||
|
||||
private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
||||
|
||||
@Autowired
|
||||
private OamWxCpService oamWxCpService;
|
||||
|
||||
@GetMapping(produces = "text/plain;charset=utf-8")
|
||||
public String authGet(@PathVariable
|
||||
Integer agentId, @RequestParam(name = "msg_signature", required = false)
|
||||
String signature, @RequestParam(name = "timestamp", required = false)
|
||||
String timestamp, @RequestParam(name = "nonce", required = false)
|
||||
String nonce, @RequestParam(name = "echostr", required = false)
|
||||
String echostr) {
|
||||
this.logger.info("\n接收到来自微信服务器的认证消息:signature = [{}], timestamp = [{}], nonce = [{}], echostr = [{}]",
|
||||
signature,
|
||||
timestamp,
|
||||
nonce,
|
||||
echostr);
|
||||
if (StringUtils.isAnyBlank(signature, timestamp, nonce, echostr)) {
|
||||
throw new IllegalArgumentException("请求参数非法,请核实!");
|
||||
}
|
||||
final WxCpService wxCpService = WxCpConfiguration.getCpService(agentId);
|
||||
if (wxCpService == null) {
|
||||
throw new IllegalArgumentException(String.format("未找到对应agentId=[%d]的配置,请核实!", agentId));
|
||||
}
|
||||
if (wxCpService.checkSignature(signature, timestamp, nonce, echostr)) {
|
||||
return new WxCpCryptUtil(wxCpService.getWxCpConfigStorage()).decrypt(echostr);
|
||||
}
|
||||
return "非法请求";
|
||||
}
|
||||
|
||||
@PostMapping(produces = "application/xml; charset=UTF-8")
|
||||
public String post(@PathVariable
|
||||
Integer agentId, @RequestBody
|
||||
String requestBody, @RequestParam("msg_signature")
|
||||
String signature, @RequestParam("timestamp")
|
||||
String timestamp, @RequestParam("nonce")
|
||||
String nonce) {
|
||||
this.logger.info("\n接收微信请求:[signature=[{}], timestamp=[{}], nonce=[{}], requestBody=[\n{}\n] ",
|
||||
signature,
|
||||
timestamp,
|
||||
nonce,
|
||||
requestBody);
|
||||
final WxCpService wxCpService = WxCpConfiguration.getCpService(agentId);
|
||||
WxCpXmlMessage inMessage = WxCpXmlMessage
|
||||
.fromEncryptedXml(requestBody, wxCpService.getWxCpConfigStorage(), timestamp, nonce, signature);
|
||||
this.logger.debug("\n消息解密后内容为:\n{} ", JsonUtils.toJson(inMessage));
|
||||
WxCpXmlOutMessage outMessage = this.route(agentId, inMessage);
|
||||
if (outMessage == null) {
|
||||
return "";
|
||||
}
|
||||
String out = outMessage.toEncryptedXml(wxCpService.getWxCpConfigStorage());
|
||||
this.logger.debug("\n组装回复信息:{}", out);
|
||||
return out;
|
||||
}
|
||||
|
||||
private WxCpXmlOutMessage route(Integer agentId, WxCpXmlMessage message) {
|
||||
try {
|
||||
return WxCpConfiguration.getRouters().get(agentId).route(message);
|
||||
} catch (Exception e) {
|
||||
this.logger.error(e.getMessage(), e);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 企微的o2认证可查询用户敏感信息
|
||||
* @author DB
|
||||
* @since 2023/11/17 14:42
|
||||
* @param agentId 企业微信服务应用id
|
||||
* @param code 授权码
|
||||
* @param state 信息 注册
|
||||
*/
|
||||
@GetMapping(produces = "text/plain;charset=utf-8", value = "/registerCode")
|
||||
public void registerCode(@PathVariable
|
||||
Integer agentId, @RequestParam("code")
|
||||
String code, @RequestParam("state")
|
||||
String state) {
|
||||
oamWxCpService.registerCode(agentId, code);
|
||||
}
|
||||
|
||||
}
|
||||
@ -22,6 +22,7 @@ import org.springframework.web.bind.annotation.*;
|
||||
@Api(tags = "企业微信消息接收controller")
|
||||
@RestController
|
||||
@RequestMapping("/wxCp/portal/{agentId}")
|
||||
@Deprecated
|
||||
public class WxCpPortalController {
|
||||
|
||||
private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
||||
|
||||
@ -371,15 +371,12 @@ public class BusinessServiceImpl extends ServiceImpl<BusinessMapper, Business> i
|
||||
.select(STORE.ID, STORE.STORE_NAME, STORE.PERSON_CHARGE, STORE.PHONE, STORE.BRAND_ID)
|
||||
.select(BRAND.BRAND_NAME)
|
||||
.select(STORE_LICENSE.LICENSE_PIC_URL)
|
||||
.select(BRAND_EXTEND.BRAND_CLOUD_ID)
|
||||
.select(STORE_EXTEND.STORE_CLOUD_ID)
|
||||
.from(STORE)
|
||||
.leftJoin(BRAND).on(BRAND.ID.eq(STORE.BRAND_ID))
|
||||
.leftJoin(STORE_LICENSE).on(STORE_LICENSE.STORE_ID.eq(STORE.ID))
|
||||
.leftJoin(BRAND_EXTEND).on(BRAND_EXTEND.BRAND_ID.eq(BRAND.ID))
|
||||
.leftJoin(STORE_EXTEND).on(STORE_EXTEND.STORE_ID.eq(STORE.ID))
|
||||
.leftJoin(STORE_SIGN).on(STORE_SIGN.ID.eq(STORE.SIGN_ID))
|
||||
.where(STORE.SIGN_ID.isNull())
|
||||
.and(STORE.IS_TEST.eq(false))
|
||||
.and(STORE.STORE_NAME.like(params)
|
||||
.or(STORE.PERSON_CHARGE.like(params)
|
||||
.or(STORE.PHONE.eq(params))))
|
||||
@ -401,5 +398,9 @@ public class BusinessServiceImpl extends ServiceImpl<BusinessMapper, Business> i
|
||||
storeSign.setSignStaffId(loginUserInfo.getString("id"));
|
||||
StoreSignService storeSignService = SpringUtils.getBean(StoreSignService.class);
|
||||
storeSignService.save(storeSign);
|
||||
SpringUtils.getBean(StoreService.class).updateChain()
|
||||
.set(STORE.SIGN_ID,storeSign.getId())
|
||||
.where(STORE.ID.eq(id))
|
||||
.update();
|
||||
}
|
||||
}
|
||||
|
||||
@ -397,7 +397,7 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task> implements Ta
|
||||
.leftJoin(STAFF)
|
||||
.on(STAFF.ID.eq(TASK.RESPONSIBLE_STAFF_ID))
|
||||
.where(TASK.TASK_TYPE.in(0, 1))
|
||||
.orderBy(TASK.EXPECTED_COMPLETION_DATE.asc()),
|
||||
.orderBy(TASK.TASK_ITEM.asc(), TASK.EXPECTED_COMPLETION_DATE.asc()),
|
||||
PersonTaskPageVo.class);
|
||||
}
|
||||
|
||||
|
||||
@ -14,4 +14,7 @@ wx:
|
||||
sharing-account: 1618884922
|
||||
sharing-account-name: 果酱盒子
|
||||
#服务商appid
|
||||
service-app-id: wx1eb0e5fb7dac3c05
|
||||
service-app-id: wx1eb0e5fb7dac3c05
|
||||
logging:
|
||||
level:
|
||||
com.github.binarywang.wxpay: info
|
||||
@ -1,106 +0,0 @@
|
||||
package com.cpop.system.business.controller;
|
||||
|
||||
import com.mybatisflex.core.paginate.Page;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import com.cpop.system.business.entity.ProfitSharing;
|
||||
import com.cpop.system.business.service.ProfitSharingService;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 系统分账表 控制层。
|
||||
*
|
||||
* @author DB
|
||||
* @since 2023-10-27
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "系统分账表接口")
|
||||
@RequestMapping("/profitSharing")
|
||||
public class ProfitSharingController {
|
||||
|
||||
@Autowired
|
||||
private ProfitSharingService profitSharingService;
|
||||
|
||||
/**
|
||||
* 添加系统分账表。
|
||||
*
|
||||
* @param profitSharing 系统分账表
|
||||
* @return {@code true} 添加成功,{@code false} 添加失败
|
||||
*/
|
||||
@PostMapping("/save")
|
||||
@ApiOperation("保存系统分账表")
|
||||
public boolean save(@RequestBody @ApiParam("系统分账表") ProfitSharing profitSharing) {
|
||||
return profitSharingService.save(profitSharing);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据主键删除系统分账表。
|
||||
*
|
||||
* @param id 主键
|
||||
* @return {@code true} 删除成功,{@code false} 删除失败
|
||||
*/
|
||||
@DeleteMapping("/remove/{id}")
|
||||
@ApiOperation("根据主键系统分账表")
|
||||
public boolean remove(@PathVariable @ApiParam("系统分账表主键") Serializable id) {
|
||||
return profitSharingService.removeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据主键更新系统分账表。
|
||||
*
|
||||
* @param profitSharing 系统分账表
|
||||
* @return {@code true} 更新成功,{@code false} 更新失败
|
||||
*/
|
||||
@PutMapping("/update")
|
||||
@ApiOperation("根据主键更新系统分账表")
|
||||
public boolean update(@RequestBody @ApiParam("系统分账表主键") ProfitSharing profitSharing) {
|
||||
return profitSharingService.updateById(profitSharing);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有系统分账表。
|
||||
*
|
||||
* @return 所有数据
|
||||
*/
|
||||
@GetMapping("/list")
|
||||
@ApiOperation("查询所有系统分账表")
|
||||
public List<ProfitSharing> list() {
|
||||
return profitSharingService.list();
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据系统分账表主键获取详细信息。
|
||||
*
|
||||
* @param id 系统分账表主键
|
||||
* @return 系统分账表详情
|
||||
*/
|
||||
@GetMapping("/getInfo/{id}")
|
||||
@ApiOperation("根据主键获取系统分账表")
|
||||
public ProfitSharing getInfo(@PathVariable @ApiParam("系统分账表主键") Serializable id) {
|
||||
return profitSharingService.getById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询系统分账表。
|
||||
*
|
||||
* @param page 分页对象
|
||||
* @return 分页对象
|
||||
*/
|
||||
@GetMapping("/page")
|
||||
@ApiOperation("分页查询系统分账表")
|
||||
public Page<ProfitSharing> page(@ApiParam("分页信息") Page<ProfitSharing> page) {
|
||||
return profitSharingService.page(page);
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,106 +0,0 @@
|
||||
package com.cpop.system.business.controller;
|
||||
|
||||
import com.mybatisflex.core.paginate.Page;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import com.cpop.system.business.entity.StoreLicense;
|
||||
import com.cpop.system.business.service.StoreLicenseService;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 校区/店铺营业执照 控制层。
|
||||
*
|
||||
* @author DB
|
||||
* @since 2023-12-12
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "校区/店铺营业执照接口")
|
||||
@RequestMapping("/storeLicense")
|
||||
public class StoreLicenseController {
|
||||
|
||||
@Autowired
|
||||
private StoreLicenseService storeLicenseService;
|
||||
|
||||
/**
|
||||
* 添加校区/店铺营业执照。
|
||||
*
|
||||
* @param storeLicense 校区/店铺营业执照
|
||||
* @return {@code true} 添加成功,{@code false} 添加失败
|
||||
*/
|
||||
@PostMapping("/save")
|
||||
@ApiOperation("保存校区/店铺营业执照")
|
||||
public boolean save(@RequestBody @ApiParam("校区/店铺营业执照") StoreLicense storeLicense) {
|
||||
return storeLicenseService.save(storeLicense);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据主键删除校区/店铺营业执照。
|
||||
*
|
||||
* @param id 主键
|
||||
* @return {@code true} 删除成功,{@code false} 删除失败
|
||||
*/
|
||||
@DeleteMapping("/remove/{id}")
|
||||
@ApiOperation("根据主键校区/店铺营业执照")
|
||||
public boolean remove(@PathVariable @ApiParam("校区/店铺营业执照主键") Serializable id) {
|
||||
return storeLicenseService.removeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据主键更新校区/店铺营业执照。
|
||||
*
|
||||
* @param storeLicense 校区/店铺营业执照
|
||||
* @return {@code true} 更新成功,{@code false} 更新失败
|
||||
*/
|
||||
@PutMapping("/update")
|
||||
@ApiOperation("根据主键更新校区/店铺营业执照")
|
||||
public boolean update(@RequestBody @ApiParam("校区/店铺营业执照主键") StoreLicense storeLicense) {
|
||||
return storeLicenseService.updateById(storeLicense);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有校区/店铺营业执照。
|
||||
*
|
||||
* @return 所有数据
|
||||
*/
|
||||
@GetMapping("/list")
|
||||
@ApiOperation("查询所有校区/店铺营业执照")
|
||||
public List<StoreLicense> list() {
|
||||
return storeLicenseService.list();
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据校区/店铺营业执照主键获取详细信息。
|
||||
*
|
||||
* @param id 校区/店铺营业执照主键
|
||||
* @return 校区/店铺营业执照详情
|
||||
*/
|
||||
@GetMapping("/getInfo/{id}")
|
||||
@ApiOperation("根据主键获取校区/店铺营业执照")
|
||||
public StoreLicense getInfo(@PathVariable @ApiParam("校区/店铺营业执照主键") Serializable id) {
|
||||
return storeLicenseService.getById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询校区/店铺营业执照。
|
||||
*
|
||||
* @param page 分页对象
|
||||
* @return 分页对象
|
||||
*/
|
||||
@GetMapping("/page")
|
||||
@ApiOperation("分页查询校区/店铺营业执照")
|
||||
public Page<StoreLicense> page(@ApiParam("分页信息") Page<StoreLicense> page) {
|
||||
return storeLicenseService.page(page);
|
||||
}
|
||||
|
||||
}
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.cpop.common.utils.bean.BeanUtils;
|
||||
import com.cpop.core.base.R;
|
||||
@ -31,8 +31,8 @@ import io.swagger.annotations.ApiParam;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "系统-品牌表接口")
|
||||
@RequestMapping("/brand")
|
||||
public class BrandController {
|
||||
@RequestMapping("/backstage/brand")
|
||||
public class BackstageBrandController {
|
||||
|
||||
@Autowired
|
||||
private BrandService brandService;
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.cpop.common.utils.bean.BeanUtils;
|
||||
import com.cpop.core.base.R;
|
||||
@ -38,8 +38,8 @@ import java.util.List;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "系统-字典数据表接口")
|
||||
@RequestMapping("/dictData")
|
||||
public class DictDataController {
|
||||
@RequestMapping("/backstage/dictData")
|
||||
public class BackstageDictDataController {
|
||||
|
||||
@Autowired
|
||||
private DictDataService dictDataService;
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.cpop.common.utils.bean.BeanUtils;
|
||||
import com.cpop.core.base.R;
|
||||
@ -41,8 +41,8 @@ import static com.cpop.system.business.entity.table.DictTypeTableDef.DICT_TYPE;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "系统管理模块-字典类型接口")
|
||||
@RequestMapping("/dictType")
|
||||
public class DictTypeController {
|
||||
@RequestMapping("/backstage/dictType")
|
||||
public class BackstageDictTypeController {
|
||||
|
||||
@Autowired
|
||||
private DictTypeService dictTypeService;
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.cpop.core.base.R;
|
||||
import com.cpop.system.business.service.LoginService;
|
||||
@ -8,6 +8,7 @@ import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
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.RestController;
|
||||
|
||||
import java.util.List;
|
||||
@ -20,7 +21,8 @@ import java.util.Set;
|
||||
*/
|
||||
@Api(tags = "通用系统登录模块")
|
||||
@RestController
|
||||
public class LoginController {
|
||||
@RequestMapping("/backstage")
|
||||
public class BackstageLoginController {
|
||||
|
||||
@Autowired
|
||||
private LoginService loginService;
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.cpop.core.annontation.OperationLog;
|
||||
import com.cpop.core.base.R;
|
||||
@ -24,8 +24,8 @@ import java.util.List;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "通用系统菜单表接口")
|
||||
@RequestMapping("/menu")
|
||||
public class MenuController {
|
||||
@RequestMapping("/backstage/menu")
|
||||
public class BackstageMenuController {
|
||||
|
||||
@Autowired
|
||||
private MenuService menuService;
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.cpop.core.base.R;
|
||||
import com.cpop.system.business.bo.MenuListBo;
|
||||
@ -27,8 +27,8 @@ import java.util.List;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "系统角色表接口")
|
||||
@RequestMapping("/role")
|
||||
public class RoleController {
|
||||
@RequestMapping("/backstage/role")
|
||||
public class BackstageRoleController {
|
||||
|
||||
@Autowired
|
||||
private RoleService roleService;
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.cpop.core.base.R;
|
||||
import com.cpop.system.business.bo.StoreBo;
|
||||
@ -23,8 +23,8 @@ import io.swagger.annotations.Api;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "系统-店铺/校区表接口")
|
||||
@RequestMapping("/store")
|
||||
public class StoreController {
|
||||
@RequestMapping("/backstage/store")
|
||||
public class BackstageStoreController {
|
||||
|
||||
@Autowired
|
||||
private StoreService storeService;
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.alibaba.excel.EasyExcel;
|
||||
import com.cpop.core.base.R;
|
||||
@ -28,8 +28,8 @@ import java.net.URLEncoder;
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "校区签约续费接口")
|
||||
@RequestMapping("/storeSign")
|
||||
public class StoreSignController {
|
||||
@RequestMapping("/backstage/storeSign")
|
||||
public class BackstageStoreSignController {
|
||||
|
||||
@Autowired
|
||||
private StoreSignService storeSignService;
|
||||
@ -1,4 +1,4 @@
|
||||
package com.cpop.system.business.controller;
|
||||
package com.cpop.system.business.controller.backstage;
|
||||
|
||||
import com.cpop.core.base.R;
|
||||
import com.cpop.core.config.CpopConfig;
|
||||
@ -28,8 +28,8 @@ import org.springframework.web.multipart.MultipartFile;
|
||||
@Slf4j
|
||||
@Api(tags = "通用接口")
|
||||
@RestController
|
||||
@RequestMapping("/sysCommon")
|
||||
public class SysCommonController {
|
||||
@RequestMapping("/backstage/sysCommon")
|
||||
public class BackstageSysCommonController {
|
||||
|
||||
@Autowired
|
||||
private ServerConfig serverConfig;
|
||||
@ -0,0 +1,51 @@
|
||||
package com.cpop.system.business.controller.mini;
|
||||
|
||||
import com.cpop.core.base.R;
|
||||
import com.cpop.core.config.CpopConfig;
|
||||
import com.cpop.core.config.ServerConfig;
|
||||
import com.cpop.core.handler.TencentCosHandler;
|
||||
import com.cpop.core.utils.file.FileUploadUtils;
|
||||
import com.cpop.core.utils.file.FileUtils;
|
||||
import com.cpop.system.business.bo.SyncBrandAndStoreBo;
|
||||
import com.cpop.system.business.service.StoreService;
|
||||
import com.cpop.system.business.vo.SysFileVo;
|
||||
import com.qcloud.cos.model.UploadResult;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
/**
|
||||
* @author DB
|
||||
* @createTime 2023/09/13 15:10
|
||||
* @description 通用接口
|
||||
*/
|
||||
@Slf4j
|
||||
@Api(tags = "通用接口")
|
||||
@RestController
|
||||
@RequestMapping("/mini/sysCommon")
|
||||
public class MiniSysCommonController {
|
||||
|
||||
@Autowired
|
||||
private StoreService storeService;
|
||||
|
||||
/**
|
||||
* 小程序同步品牌和校区
|
||||
* @author DB
|
||||
* @since 2023/12/21
|
||||
* @param bo 请求参数
|
||||
* @return R<SysFileVo>
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation("小程序同步品牌和校区")
|
||||
@PostMapping("/syncBrandAndStore")
|
||||
public R<Void> miniSyncBrandAndStore(@RequestBody SyncBrandAndStoreBo bo) {
|
||||
storeService.miniSyncBrandAndStore(bo);
|
||||
return R.ok();
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user