分享相关代码 注释掉

优惠券 管理端重写 使用的地方 注释
This commit is contained in:
2025-09-11 16:10:38 +08:00
parent 65ba0e18ce
commit 35d257bc56
23 changed files with 1292 additions and 91 deletions

View File

@@ -1,54 +1,54 @@
package com.czg.controller.admin;
import com.czg.account.dto.ShopShareDTO;
import com.czg.account.service.ShopShareService;
import com.czg.account.vo.ShopShareRecordVO;
import com.czg.account.vo.ShopShareVO;
import com.czg.annotation.SaAdminCheckPermission;
import com.czg.resp.CzgResult;
import com.czg.sa.StpKit;
import com.mybatisflex.core.paginate.Page;
import jakarta.annotation.Resource;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
/**
* 小程序分享奖励管理
* @author Administrator
*/
@RestController
@RequestMapping("/admin/shopShare")
public class ShopShareController {
@Resource
private ShopShareService shopShareService;
/**
* 获取分享奖励配置
*/
@SaAdminCheckPermission(value = "shopShare:list", name = "分享好友信息")
@GetMapping
public CzgResult<ShopShareVO> get() {
return CzgResult.success(shopShareService.get(StpKit.USER.getShopId()));
}
/**
* 修改分享奖励配置
*/
@SaAdminCheckPermission(value = "shopShare:add", name = "分享好友信息添加")
@PostMapping
public CzgResult<Boolean> add(@RequestBody @Validated ShopShareDTO shopShareDTO) {
return CzgResult.success(shopShareService.add(StpKit.USER.getShopId(), shopShareDTO));
}
/**
* 分享奖励记录
* @param key 邀请人/被邀请人手机号或昵称
* @param status 0 非新用户 1 未领取 2 已领取 3 已使用 不传递为全部
* @return 分页数据
*/
@SaAdminCheckPermission(value = "shopShare:record", name = "分享邀请记录")
@GetMapping("/record")
public CzgResult<Page<ShopShareRecordVO>> record(String key, Integer status) {
return CzgResult.success(shopShareService.recordPage(StpKit.USER.getShopId(), key, status));
}
}
//package com.czg.controller.admin;
//
//import com.czg.account.dto.ShopShareDTO;
//import com.czg.account.service.ShopShareService;
//import com.czg.account.vo.ShopShareRecordVO;
//import com.czg.account.vo.ShopShareVO;
//import com.czg.annotation.SaAdminCheckPermission;
//import com.czg.resp.CzgResult;
//import com.czg.sa.StpKit;
//import com.mybatisflex.core.paginate.Page;
//import jakarta.annotation.Resource;
//import org.springframework.validation.annotation.Validated;
//import org.springframework.web.bind.annotation.*;
//
///**
// * 小程序分享奖励管理
// * @author Administrator
// */
//@RestController
//@RequestMapping("/admin/shopShare")
//public class ShopShareController {
// @Resource
// private ShopShareService shopShareService;
//
// /**
// * 获取分享奖励配置
// */
// @SaAdminCheckPermission(value = "shopShare:list", name = "分享好友信息")
// @GetMapping
// public CzgResult<ShopShareVO> get() {
// return CzgResult.success(shopShareService.get(StpKit.USER.getShopId()));
// }
//
// /**
// * 修改分享奖励配置
// */
// @SaAdminCheckPermission(value = "shopShare:add", name = "分享好友信息添加")
// @PostMapping
// public CzgResult<Boolean> add(@RequestBody @Validated ShopShareDTO shopShareDTO) {
// return CzgResult.success(shopShareService.add(StpKit.USER.getShopId(), shopShareDTO));
// }
//
// /**
// * 分享奖励记录
// * @param key 邀请人/被邀请人手机号或昵称
// * @param status 0 非新用户 1 未领取 2 已领取 3 已使用 不传递为全部
// * @return 分页数据
// */
// @SaAdminCheckPermission(value = "shopShare:record", name = "分享邀请记录")
// @GetMapping("/record")
// public CzgResult<Page<ShopShareRecordVO>> record(String key, Integer status) {
// return CzgResult.success(shopShareService.recordPage(StpKit.USER.getShopId(), key, status));
// }
//}