fix: add notiftype
This commit is contained in:
@@ -491,22 +491,20 @@ export class UsersService {
|
||||
|
||||
async findOneCustomer(userId: string) {
|
||||
const customer = await this.userRepository.findOne({
|
||||
where: {
|
||||
id: userId,
|
||||
roles: {
|
||||
name: RoleEnum.USER,
|
||||
},
|
||||
},
|
||||
relations: {
|
||||
legalUser: true,
|
||||
realUser: true,
|
||||
},
|
||||
where: { id: userId, roles: { name: RoleEnum.USER } },
|
||||
relations: { legalUser: true, realUser: true },
|
||||
});
|
||||
|
||||
return { customer };
|
||||
}
|
||||
/************************************************************ */
|
||||
|
||||
async getUsersByGroup(groupId: string) {
|
||||
const users = await this.userRepository.find({ where: { groups: { id: groupId } }, relations: { tickets: true } });
|
||||
return { users };
|
||||
}
|
||||
/************************************************************ */
|
||||
|
||||
async getAdmins(queryDto: SearchAdminQueryDto) {
|
||||
const { limit, skip } = PaginationUtils(queryDto);
|
||||
const queryBuilder = this.userRepository.createQueryBuilder("user");
|
||||
|
||||
Reference in New Issue
Block a user