Merge dev to main #1
@@ -14,28 +14,24 @@ export class DashboardController {
|
||||
@Get('kpis')
|
||||
@Roles('manager')
|
||||
async getKpis(@CurrentUser() user: CurrentUserPayload) {
|
||||
const data = await this.dashboardService.getKpis(user.tenantId);
|
||||
return { data };
|
||||
return this.dashboardService.getKpis(user.tenantId);
|
||||
}
|
||||
|
||||
@Get('revenue-chart')
|
||||
@Roles('manager')
|
||||
async getRevenueChart(@CurrentUser() user: CurrentUserPayload) {
|
||||
const data = await this.dashboardService.getRevenueChart(user.tenantId);
|
||||
return { data };
|
||||
return this.dashboardService.getRevenueChart(user.tenantId);
|
||||
}
|
||||
|
||||
@Get('activity')
|
||||
@Roles('manager')
|
||||
async getActivity(@CurrentUser() user: CurrentUserPayload) {
|
||||
const data = await this.dashboardService.getRecentActivity(user.tenantId);
|
||||
return { data };
|
||||
return this.dashboardService.getRecentActivity(user.tenantId);
|
||||
}
|
||||
|
||||
@Get('financial-summary')
|
||||
@Roles('manager')
|
||||
async getFinancialSummary(@CurrentUser() user: CurrentUserPayload) {
|
||||
const data = await this.dashboardService.getFinancialSummary(user.tenantId);
|
||||
return { data };
|
||||
return this.dashboardService.getFinancialSummary(user.tenantId);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user