import { Module } from '@nestjs/common';
import { TypeOrmModule } from '@nestjs/typeorm';
import { AuthModule } from '../auth/auth.module';
import { OrderItem } from '../orders/entities/order-item.entity';
import { ApiCallLog } from './entities/api-call-log.entity';
import { CatalogSyncJob } from './entities/catalog-sync-job.entity';
import { Category } from './entities/category.entity';
import { Course } from './entities/course.entity';
import { ThirdPartyAdminController } from './third-party-admin.controller';
import { ThirdPartyAdminService } from './third-party-admin.service';
import { ThirdPartyCatalogService } from './third-party-catalog.service';
import { ThirdPartyCatalogSyncTask } from './third-party-catalog-sync.task';
import { ThirdPartyClientService } from './third-party-client.service';

@Module({
  imports: [
    AuthModule,
    TypeOrmModule.forFeature([
      ApiCallLog,
      CatalogSyncJob,
      Category,
      Course,
      OrderItem,
    ]),
  ],
  controllers: [ThirdPartyAdminController],
  providers: [
    ThirdPartyAdminService,
    ThirdPartyCatalogService,
    ThirdPartyCatalogSyncTask,
    ThirdPartyClientService,
  ],
  exports: [ThirdPartyCatalogService, ThirdPartyClientService],
})
export class ThirdPartyModule {}
