mirror of
https://github.com/HamzaSha1/zod-backend.git
synced 2025-11-26 16:44:54 +00:00
34 lines
1.2 KiB
TypeScript
34 lines
1.2 KiB
TypeScript
import { forwardRef, Module } from '@nestjs/common';
|
|
import { TypeOrmModule } from '@nestjs/typeorm';
|
|
import { NeoLeapModule } from '~/common/modules/neoleap/neoleap.module';
|
|
import { CustomerModule } from '~/customer/customer.module';
|
|
import { CardsController } from './controllers';
|
|
import { Card } from './entities';
|
|
import { Account } from './entities/account.entity';
|
|
import { Transaction } from './entities/transaction.entity';
|
|
import { CardRepository } from './repositories';
|
|
import { AccountRepository } from './repositories/account.repository';
|
|
import { TransactionRepository } from './repositories/transaction.repository';
|
|
import { CardService } from './services';
|
|
import { AccountService } from './services/account.service';
|
|
import { TransactionService } from './services/transaction.service';
|
|
|
|
@Module({
|
|
imports: [
|
|
TypeOrmModule.forFeature([Card, Account, Transaction]),
|
|
forwardRef(() => NeoLeapModule),
|
|
forwardRef(() => CustomerModule), // <-- add forwardRef here
|
|
],
|
|
providers: [
|
|
CardService,
|
|
CardRepository,
|
|
TransactionService,
|
|
TransactionRepository,
|
|
AccountService,
|
|
AccountRepository,
|
|
],
|
|
exports: [CardService, TransactionService],
|
|
controllers: [CardsController],
|
|
})
|
|
export class CardModule {}
|