26 lines
858 B
TypeScript
26 lines
858 B
TypeScript
import { Module } from '@nestjs/common'
|
|
|
|
import { PrismaModule } from '@/infra/prisma/prisma.module'
|
|
|
|
import { CreateTheaterUsecase } from '../applications/commands/create-theater.usecase'
|
|
import { GetTheaterUsecase } from '../applications/queries/get-theater.usecase'
|
|
import { ListTheaterUsecase } from '../applications/queries/list-theater.usecase'
|
|
import { TheaterRepositoryPort } from '../domain/ports/theater.repository.port'
|
|
import { TheaterGrpcController } from '../interfaces/grpc/theater.grpc.controller'
|
|
|
|
import { TheaterPrismaRepository } from './prisma/theater.prisma.repository'
|
|
|
|
@Module({
|
|
controllers: [TheaterGrpcController],
|
|
providers: [
|
|
{
|
|
provide: TheaterRepositoryPort,
|
|
useClass: TheaterPrismaRepository
|
|
},
|
|
ListTheaterUsecase,
|
|
GetTheaterUsecase,
|
|
CreateTheaterUsecase
|
|
]
|
|
})
|
|
export class TheaterModule {}
|