import { Logger, Module } from '@nestjs/common'; import { TypeOrmModule } from '@nestjs/typeorm'; import { StaffsService } from './staffs.service'; import { StaffsController } from './staffs.controller'; import { Staff } from './entities/staff.entity'; @Module({ imports: [TypeOrmModule.forFeature([Staff])], controllers: [StaffsController], providers: [Logger, StaffsService], // If you want to use the repository outside of the module // which imports TypeOrmModule.forFeature, you'll need to re-export the providers generated by it. // exports: [TypeOrmModule], }) export class StaffsModule {}