diff --git a/src/controllers/product/group-controller.ts b/src/controllers/product/group-controller.ts index e5b3ef1..cea4f52 100644 --- a/src/controllers/product/group-controller.ts +++ b/src/controllers/product/group-controller.ts @@ -37,7 +37,7 @@ type ProductGroupUpdate = { @Tags("Product Group") @Security("keycloak") export class ProductGroup extends Controller { - @Get() + @Get("stats") async getProductGroupStats() { return await prisma.productGroup.count(); } diff --git a/src/controllers/product/type-controller.ts b/src/controllers/product/type-controller.ts index 87611d7..e1c5bb8 100644 --- a/src/controllers/product/type-controller.ts +++ b/src/controllers/product/type-controller.ts @@ -37,7 +37,7 @@ type ProductTypeUpdate = { @Tags("Product Type") @Security("keycloak") export class ProductType extends Controller { - @Get() + @Get("stats") async getProductTypeStats() { return await prisma.productType.count(); } diff --git a/src/controllers/service/service-controller.ts b/src/controllers/service/service-controller.ts index a2a5ca8..d8a9583 100644 --- a/src/controllers/service/service-controller.ts +++ b/src/controllers/service/service-controller.ts @@ -46,7 +46,7 @@ function imageLocation(id: string) { @Tags("Service") @Security("keycloak") export class ServiceController extends Controller { - @Get() + @Get("stats") async getServiceStats() { return await prisma.service.count(); }