pie chart for food added
This commit is contained in:
@@ -14,7 +14,7 @@ import { UpdateOrderStatusDto } from '../dto/update-order-status.dto';
|
||||
@ApiBearerAuth()
|
||||
@Controller()
|
||||
export class OrdersController {
|
||||
constructor(private readonly ordersService: OrdersService) {}
|
||||
constructor(private readonly ordersService: OrdersService) { }
|
||||
|
||||
@UseGuards(AuthGuard)
|
||||
@Post('public/checkout')
|
||||
@@ -98,8 +98,16 @@ export class OrdersController {
|
||||
|
||||
@UseGuards(AdminAuthGuard)
|
||||
@ApiOperation({ summary: 'Get Stats for report page' })
|
||||
@Get('admin/orders/stats')
|
||||
findStats( @RestId() restId: string) {
|
||||
@Get('admin/orders/stats')
|
||||
findStats(@RestId() restId: string) {
|
||||
return this.ordersService.getStats(restId);
|
||||
}
|
||||
|
||||
@UseGuards(AdminAuthGuard)
|
||||
@ApiOperation({ summary: 'Get food sales pie chart data for last month' })
|
||||
@ApiHeader(API_HEADER_SLUG)
|
||||
@Get('admin/orders/food-sales-pie-chart')
|
||||
getFoodSalesPieChart(@RestId() restId: string) {
|
||||
return this.ordersService.getFoodSalesPieChart(restId);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user