import { Module, forwardRef } from '@nestjs/common'
import { CommissionService } from './commission.service'
import { CommissionController } from './commission.controller'
import { TypeOrmModule } from '@nestjs/typeorm'
import { CommissionConfig } from './entities/commission-config.entity'
import { CommissionRecord } from './entities/commission-record.entity'
import { Users } from '../users/entities/users.entity'
import { UserBalanceModule } from '../user-balance/user-balance.module'
import { MembershipModule } from '../membership/membership.module'

@Module({
    imports: [
        TypeOrmModule.forFeature([CommissionRecord, CommissionConfig, Users]),
        UserBalanceModule,
        forwardRef(() => MembershipModule)
    ],
    providers: [CommissionService],
    controllers: [CommissionController],
    exports: [CommissionService]
})
export class CommissionModule {}
