How to use the @nestjs/typeorm.InjectConnection function in @nestjs/typeorm

To help you get started, we’ve selected a few @nestjs/typeorm examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github vendure-ecommerce / vendure / server / src / service / services / channel.service.ts View on Github external
    constructor(@InjectConnection() private connection: Connection, private configService: ConfigService) {}
github vendure-ecommerce / vendure / server / src / service / helpers / connection.decorator.ts View on Github external
export function ActiveConnection() {
    const cm = getConnectionManager();
    return InjectConnection(getConfig().dbConnectionOptions.name);
}
github mpcast / mpcast-server / packages / core / src / service / services / user.service.ts View on Github external
constructor(
    @InjectConnection() private readonly connection: Connection,
  ) {
  }
github vendure-ecommerce / vendure / server / src / service / services / product-option-group.service.ts View on Github external
constructor(
        @InjectConnection() private connection: Connection,
        private translatableSaver: TranslatableSaver,
    ) {}
github vendure-ecommerce / vendure / packages / email-plugin / src / plugin.ts View on Github external
constructor(
        private eventBus: EventBus,
        @InjectConnection() private connection: Connection,
        private moduleRef: ModuleRef,
    ) {}
github ZhiXiao-Lin / nestify / server / src / common / services / import.service.ts View on Github external
constructor(
		@InjectConnection() private readonly connection: Connection,
		private readonly categoryService: CategoryService,
		private readonly serviceCategoryService: ServiceCategoryService
	) { }
github vendure-ecommerce / vendure / packages / elasticsearch-plugin / src / indexer.controller.ts View on Github external
constructor(
        @InjectConnection() private connection: Connection,
        @Inject(ELASTIC_SEARCH_OPTIONS) private options: Required,
        @Inject(ELASTIC_SEARCH_CLIENT) private client: Client,
        private productVariantService: ProductVariantService,
        private jobService: JobService,
    ) {}
github vendure-ecommerce / vendure / packages / core / src / service / services / auth.service.ts View on Github external
constructor(
        @InjectConnection() private connection: Connection,
        private passwordCipher: PasswordCiper,
        private configService: ConfigService,
        private orderService: OrderService,
        private eventBus: EventBus,
    ) {
        this.sessionDurationInMs = ms(this.configService.authOptions.sessionDuration as string);
    }