fix: count by group
This commit is contained in:
parent
03707b7bd8
commit
3fb15f8344
1 changed files with 2 additions and 2 deletions
|
|
@ -81,8 +81,8 @@ function globalAllow(roles?: string[]) {
|
|||
export class ServiceController extends Controller {
|
||||
@Get("stats")
|
||||
@Security("keycloak")
|
||||
async getServiceStats() {
|
||||
return await prisma.service.count();
|
||||
async getServiceStats(@Query() productGroupId?: string) {
|
||||
return await prisma.service.count({ where: { productGroupId } });
|
||||
}
|
||||
|
||||
@Get()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue