From 8974da651e28bf5265ecfd7694f443db3588d169 Mon Sep 17 00:00:00 2001 From: Gbuntu Date: Thu, 9 Nov 2023 10:52:35 +0330 Subject: [PATCH] more automation for new children --- nest-cli.json | 7 ++++--- src/features/children/children.controller.ts | 5 +++-- src/{ => features/children}/resources/names.xlsx | Bin 3 files changed, 7 insertions(+), 5 deletions(-) rename src/{ => features/children}/resources/names.xlsx (100%) diff --git a/nest-cli.json b/nest-cli.json index 2229a44c1..d9e26c586 100644 --- a/nest-cli.json +++ b/nest-cli.json @@ -4,8 +4,9 @@ "sourceRoot": "src", "compilerOptions": { "assets": [ - "features/campaign/templates/**/*" - ], - "watchAssets": true + "features/campaign/templates/**/*", + "features/children/**/*" + ], + "watchAssets": true } } \ No newline at end of file diff --git a/src/features/children/children.controller.ts b/src/features/children/children.controller.ts index f1852a160..ad09dcf31 100644 --- a/src/features/children/children.controller.ts +++ b/src/features/children/children.controller.ts @@ -649,9 +649,10 @@ export class ChildrenController { ) { throw new ForbiddenException(403, 'You Are not the Super admin'); } - return await this.downloadService.excelStream('src/resources/names.xlsx'); + return await this.downloadService.excelStream( + 'src/features/children/resources/names.xlsx', + ); } - @UseInterceptors(ChildrenInterceptor) @Post(`flask/all`) @ApiOperation({ description: 'Get all flask children from db' }) diff --git a/src/resources/names.xlsx b/src/features/children/resources/names.xlsx similarity index 100% rename from src/resources/names.xlsx rename to src/features/children/resources/names.xlsx