import { Module } from '@nestjs/common'
import { MongooseModule } from '@nestjs/mongoose'
import {
  MatterDeadline, MatterDeadlineSchema,
  ObligationRule, ObligationRuleSchema,
  Matter, MatterSchema,
  ClientFolder, ClientFolderSchema,
} from '../common/schemas'
import { MatterDeadlinesService } from './matter-deadlines.service'
import { MatterDeadlinesController } from './matter-deadlines.controller'

@Module({
  imports: [
    MongooseModule.forFeature([
      { name: MatterDeadline.name, schema: MatterDeadlineSchema },
      { name: ObligationRule.name, schema: ObligationRuleSchema },
      { name: Matter.name,         schema: MatterSchema },
      { name: ClientFolder.name,   schema: ClientFolderSchema },
    ]),
  ],
  controllers: [MatterDeadlinesController],
  providers:   [MatterDeadlinesService],
  exports:     [MatterDeadlinesService],
})
export class MatterDeadlinesModule {}
