Nestjs, Transactions, Dependency Injection, Repository Pattern, Repository Design Pattern.
'./transaction.interceptor'; export class BaseRepository { constructor(private dataSource: DataSource, private request: Request) {} protected getRepository<T>(entityCls: new () => T): Repository<T> { const entityManager: EntityManager = this.request[ENTITY_MANAGER_KEY] ?? this.dataSource.manager;