mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-19 22:30:31 +00:00
29 lines
844 B
TypeScript
29 lines
844 B
TypeScript
import {
|
|
ApiTags,
|
|
ApiOperation,
|
|
ApiResponse,
|
|
getSchemaPath,
|
|
ApiExtraModels,
|
|
} from '@nestjs/swagger';
|
|
import { Controller, Get } from '@nestjs/common';
|
|
import { DashboardService } from './Dashboard.service';
|
|
import { GetDashboardBootMetaResponseDto } from './dtos/GetDashboardBootMetaResponse.dto';
|
|
|
|
@ApiTags('Dashboard')
|
|
@Controller('dashboard')
|
|
@ApiExtraModels(GetDashboardBootMetaResponseDto)
|
|
export class DashboardController {
|
|
constructor(private readonly dashboardService: DashboardService) {}
|
|
|
|
@ApiOperation({ summary: 'Get dashboard boot metadata' })
|
|
@ApiResponse({
|
|
status: 200,
|
|
description: 'The dashboard details have been successfully retrieved.',
|
|
schema: { $ref: getSchemaPath(GetDashboardBootMetaResponseDto) },
|
|
})
|
|
@Get('boot')
|
|
getBootMeta() {
|
|
return this.dashboardService.getBootMeta();
|
|
}
|
|
}
|