diff --git a/dictation_server/src/app.module.ts b/dictation_server/src/app.module.ts index 36e33c8..b2b6929 100644 --- a/dictation_server/src/app.module.ts +++ b/dictation_server/src/app.module.ts @@ -28,7 +28,6 @@ import { FilesService } from './features/files/files.service'; import { TasksService } from './features/tasks/tasks.service'; import { TasksController } from './features/tasks/tasks.controller'; import { TasksModule } from './features/tasks/tasks.module'; -import { LicensesModule } from './features/licenses/licenses.module'; @Module({ imports: [ @@ -66,7 +65,6 @@ import { LicensesModule } from './features/licenses/licenses.module'; }), NotificationModule, NotificationhubModule, - LicensesModule, ], controllers: [ HealthController, diff --git a/dictation_server/src/features/licenses/licenses.controller.spec.ts b/dictation_server/src/features/licenses/licenses.controller.spec.ts deleted file mode 100644 index 520fa20..0000000 --- a/dictation_server/src/features/licenses/licenses.controller.spec.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Test, TestingModule } from '@nestjs/testing'; -import { LicensesController } from './licenses.controller'; - -describe('LicensesController', () => { - let controller: LicensesController; - - beforeEach(async () => { - const module: TestingModule = await Test.createTestingModule({ - controllers: [LicensesController], - }).compile(); - - controller = module.get(LicensesController); - }); - - it('should be defined', () => { - expect(controller).toBeDefined(); - }); -}); diff --git a/dictation_server/src/features/licenses/licenses.controller.ts b/dictation_server/src/features/licenses/licenses.controller.ts deleted file mode 100644 index 05f5084..0000000 --- a/dictation_server/src/features/licenses/licenses.controller.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { Body, Controller, HttpStatus, Post, Req } from '@nestjs/common'; -import { - ApiResponse, - ApiTags, - ApiOperation, - ApiBearerAuth, -} from '@nestjs/swagger'; -import { ErrorResponse } from '../../common/error/types/types'; -import { LicensesService } from './licenses.service'; -import { CreateOrdersResponse, CreateOrdersRequest } from './types/types'; -import { Request } from 'express'; - -@ApiTags('licenses') -@Controller('licenses') -export class LicensesController { - constructor(private readonly licensesService: LicensesService) {} - - @ApiResponse({ - status: HttpStatus.OK, - type: CreateOrdersResponse, - description: '成功時のレスポンス', - }) - @ApiResponse({ - status: HttpStatus.BAD_REQUEST, - description: '同一PONumberの注文がすでに存在する場合など', - type: ErrorResponse, - }) - @ApiResponse({ - status: HttpStatus.UNAUTHORIZED, - description: '認証エラー', - type: ErrorResponse, - }) - @ApiResponse({ - status: HttpStatus.INTERNAL_SERVER_ERROR, - description: '想定外のサーバーエラー', - type: ErrorResponse, - }) - @ApiOperation({ operationId: 'signup' }) - @ApiBearerAuth() - @Post('/orders') - async createOrders( - @Req() req: Request, - @Body() body: CreateOrdersRequest, - ): Promise { - console.log(req.header('Authorization')); - console.log(body); - return {}; - } -} diff --git a/dictation_server/src/features/licenses/licenses.module.ts b/dictation_server/src/features/licenses/licenses.module.ts deleted file mode 100644 index a223cf9..0000000 --- a/dictation_server/src/features/licenses/licenses.module.ts +++ /dev/null @@ -1,9 +0,0 @@ -import { Module } from '@nestjs/common'; -import { LicensesController } from './licenses.controller'; -import { LicensesService } from './licenses.service'; - -@Module({ - controllers: [LicensesController], - providers: [LicensesService], -}) -export class LicensesModule {} diff --git a/dictation_server/src/features/licenses/licenses.service.spec.ts b/dictation_server/src/features/licenses/licenses.service.spec.ts deleted file mode 100644 index 7288d3d..0000000 --- a/dictation_server/src/features/licenses/licenses.service.spec.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Test, TestingModule } from '@nestjs/testing'; -import { LicensesService } from './licenses.service'; - -describe('LicensesService', () => { - let service: LicensesService; - - beforeEach(async () => { - const module: TestingModule = await Test.createTestingModule({ - providers: [LicensesService], - }).compile(); - - service = module.get(LicensesService); - }); - - it('should be defined', () => { - expect(service).toBeDefined(); - }); -}); diff --git a/dictation_server/src/features/licenses/licenses.service.ts b/dictation_server/src/features/licenses/licenses.service.ts deleted file mode 100644 index 4677a8f..0000000 --- a/dictation_server/src/features/licenses/licenses.service.ts +++ /dev/null @@ -1,4 +0,0 @@ -import { Injectable } from '@nestjs/common'; - -@Injectable() -export class LicensesService {} diff --git a/dictation_server/src/features/licenses/types/types.ts b/dictation_server/src/features/licenses/types/types.ts deleted file mode 100644 index c34f0d1..0000000 --- a/dictation_server/src/features/licenses/types/types.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { ApiProperty } from '@nestjs/swagger'; - -export class CreateOrdersRequest { - @ApiProperty() - poNumber: string; - - @ApiProperty() - orderCount: number; -} - -export class CreateOrdersResponse {}