feat: implement partner licenses module with pagination and filtering capabilities

This commit is contained in:
2026-04-26 09:54:48 +03:30
parent b72e6c7194
commit 34793295c9
24 changed files with 459 additions and 76 deletions
@@ -46,14 +46,14 @@ export class AdminConsumersService {
}
async findAll() {
const [consumers, count] = await this.prisma.$transaction([
const [consumers, total] = await this.prisma.$transaction([
this.prisma.consumer.findMany({
select: this.defaultSelect,
}),
this.prisma.consumer.count(),
])
return ResponseMapper.paginate(consumers.map(mapConsumerWithLicenseUtil), { count })
return ResponseMapper.paginate(consumers.map(mapConsumerWithLicenseUtil), { total })
}
async findOne(id: string) {