import { Module } from '@nestjs/common';
import { ConfigModule, ConfigService } from '@nestjs/config';
import { JwtModule } from '@nestjs/jwt';
import { PermissionResolverService } from '../../common/access-control/permission-resolver.service';
import { DatabaseService, jwtConfig } from '../../config';
import { JwtStrategy } from '../owner/strategies/jwt.strategy';
import { EmployementTypesController } from './employement_types.controller';
import { EmployementTypesService } from './employement_types.service';

@Module({
  imports: [
    JwtModule.registerAsync({
      imports: [ConfigModule],
      inject: [ConfigService],
      useFactory: jwtConfig,
    }),
  ],
  controllers: [EmployementTypesController],
  providers: [
    EmployementTypesService,
    DatabaseService,
    JwtStrategy,
    PermissionResolverService,
  ],
})
export class EmployementTypesModule {}
