31 lines
1.3 KiB
TypeScript
31 lines
1.3 KiB
TypeScript
import { Module } from '@nestjs/common'
|
|
import { MongooseModule } from '@nestjs/mongoose'
|
|
import { AdminController } from './admin.controller'
|
|
import { User, UserSchema } from '../user/user.schema'
|
|
import { UserModule } from '../user/user.module'
|
|
import { Interview, InterviewSchema } from '../interview/interview.schema'
|
|
import { PaymentOrder, PaymentOrderSchema } from '../payment/payment-order.schema'
|
|
import { WechatPayService } from '../payment/wechat-pay.service'
|
|
import { AdminGuard } from '../../common/guards/admin.guard'
|
|
import { SiteConfig, SiteConfigSchema } from '../schemas/site-config.schema'
|
|
import { ShareRecord, ShareRecordSchema, ShareVisit, ShareVisitSchema } from '../share/share.schema'
|
|
import { Resume, ResumeSchema } from '../resume/resume.schema'
|
|
|
|
@Module({
|
|
imports: [
|
|
MongooseModule.forFeature([
|
|
{ name: User.name, schema: UserSchema },
|
|
{ name: Interview.name, schema: InterviewSchema },
|
|
{ name: PaymentOrder.name, schema: PaymentOrderSchema },
|
|
{ name: SiteConfig.name, schema: SiteConfigSchema },
|
|
{ name: ShareRecord.name, schema: ShareRecordSchema },
|
|
{ name: ShareVisit.name, schema: ShareVisitSchema },
|
|
{ name: Resume.name, schema: ResumeSchema },
|
|
]),
|
|
UserModule,
|
|
],
|
|
controllers: [AdminController],
|
|
providers: [WechatPayService, AdminGuard],
|
|
})
|
|
export class AdminModule {}
|