会员列表返回优惠券数量

This commit is contained in:
张松
2025-03-17 13:43:30 +08:00
parent 42c2a90ec6
commit b2042e4721
6 changed files with 54 additions and 32 deletions

View File

@@ -1,10 +1,7 @@
package com.czg.controller.admin;
import cn.hutool.core.util.StrUtil;
import com.czg.account.dto.shopuser.ShopUserAddDTO;
import com.czg.account.dto.shopuser.ShopUserEditDTO;
import com.czg.account.dto.shopuser.ShopUserMoneyEditDTO;
import com.czg.account.dto.shopuser.ShopUserSummaryDTO;
import com.czg.account.dto.shopuser.*;
import com.czg.account.entity.ShopUser;
import com.czg.account.entity.ShopUserFlow;
import com.czg.account.service.ShopUserFlowService;
@@ -86,7 +83,7 @@ public class ShopUserController {
@SaStaffCheckPermission("yun_xu_guan_li_hui_yuan_xin_xi")
@SaAdminCheckPermission(value = "shopUser:list", name = "店铺用户列表")
@GetMapping
public CzgResult<Page<ShopUser>> list(String key, Integer isVip) {
public CzgResult<Page<ShopUserDTO>> list(String key, Integer isVip) {
return CzgResult.success(shopUserService.getPage(key, isVip));
}
@@ -103,7 +100,7 @@ public class ShopUserController {
if (id == null && userId == null) {
return CzgResult.failure("id和userId不能重复为空");
}
return CzgResult.success(shopUserService.getOne(new QueryWrapper().eq(ShopUser::getShopId, StpKit.USER.getShopId()).eq(ShopUser::getId, id).eq(ShopUser::getUserId, userId)));
return CzgResult.success(shopUserService.getDetail(id, userId));
}
/**