会员管理充值订单数据权限

pull/2/head
perry 2023-05-27 12:21:55 +08:00
parent c5a16c07f9
commit 2d5c8236c7
3 changed files with 9 additions and 0 deletions

View File

@ -5,6 +5,7 @@ import cn.hutool.core.collection.CollUtil;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.tenant.core.aop.TenantIgnore;
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
import cn.iocoder.yudao.module.member.controller.admin.user.dto.AdminUserQueryDTO;
import cn.iocoder.yudao.module.member.controller.admin.user.vo.AdminUserInfoRespVO;
import cn.iocoder.yudao.module.member.controller.admin.user.vo.MemberUpdateStatusReqVO;
@ -101,6 +102,9 @@ public class AdminUserController {
@PreAuthorize("@ss.hasPermission('member:user:query')")
@TenantIgnore
public CommonResult<PageResult<AdminUserInfoRespVO>> findPageList(@RequestBody AdminUserQueryDTO queryDTO) {
if(!TenantContextHolder.ID_SYSTEM.equals(TenantContextHolder.getRequiredTenantId())){
queryDTO.setTenantId(TenantContextHolder.getRequiredTenantId());
}
// 获得用户分页列表
PageResult<MemberUserDO> pageResult = userService.findPageList(queryDTO);
if (CollUtil.isEmpty(pageResult.getList())) {

View File

@ -12,6 +12,10 @@ public class AdminUserQueryDTO extends PageParam {
private String mobile;
@Schema(description = "用户昵称", example = "芋艿")
private String nickname;
@Schema(description = "租户id")
private Long tenantId;
/**
*
* <p>

View File

@ -30,6 +30,7 @@ public interface MemberUserMapper extends BaseMapperX<MemberUserDO> {
.likeIfPresent(MemberUserDO::getMobile, reqVO.getMobile())
.likeIfPresent(MemberUserDO::getNickname,reqVO.getNickname())
.eqIfPresent(MemberUserDO::getStatus,reqVO.getStatus())
.eqIfPresent(MemberUserDO::getTenantId,reqVO.getTenantId())
.orderByDesc(MemberUserDO::getId));
}
}