import { Controller, Get, Param } from '@nestjs/common'; import { ApiTags, ApiOperation, ApiResponse, ApiParam } from '@nestjs/swagger'; import { ThemesService } from './themes.service'; @Controller('themes') @ApiTags('themes') export class ThemesController { constructor(private readonly themesService: ThemesService) {} @Get() @ApiOperation({ summary: 'Get all cross-cutting themes overview' }) @ApiResponse({ status: 200, description: 'Returns overview of all 6 themes' }) getAllThemes() { return this.themesService.getAllThemes(); } @Get(':name') @ApiOperation({ summary: 'Get detailed information about a specific theme' }) @ApiParam({ name: 'name', description: 'Theme name', enum: [ 'legal-defense', 'media-misrepresentation', 'satanic-panic-history', 'academic-recognition', 'persecution-mechanics', 'reform-movements', ], }) @ApiResponse({ status: 200, description: 'Returns detailed theme information' }) @ApiResponse({ status: 404, description: 'Theme not found' }) getTheme(@Param('name') name: string) { return this.themesService.getTheme(name); } }