import { Module } from '@nestjs/common';
import { MongooseModule } from '@nestjs/mongoose';
import { NotificationsModule } from '../notifications/notifications.module';
import { SupportTicket, SupportTicketSchema } from './schemas/support-ticket.schema';
import {
  SupportTicketMessage,
  SupportTicketMessageSchema,
} from './schemas/support-ticket-message.schema';
import { SupportController } from './support.controller';
import { SupportRepository } from './support.repository';
import { SupportService } from './support.service';

@Module({
  imports: [
    NotificationsModule,
    MongooseModule.forFeature([
      { name: SupportTicket.name, schema: SupportTicketSchema },
      { name: SupportTicketMessage.name, schema: SupportTicketMessageSchema },
    ]),
  ],
  controllers: [SupportController],
  providers: [SupportService, SupportRepository],
  exports: [SupportService, SupportRepository],
})
export class SupportModule {}
