mirror of
https://github.com/HamzaSha1/zod-backend.git
synced 2025-11-26 16:44:54 +00:00
feat: add cron job for allowance and implement cron lock
This commit is contained in:
@ -2,6 +2,7 @@ import { MiddlewareConsumer, Module } from '@nestjs/common';
|
||||
import { ConfigModule, ConfigService } from '@nestjs/config';
|
||||
import { APP_FILTER, APP_PIPE } from '@nestjs/core';
|
||||
import { EventEmitterModule } from '@nestjs/event-emitter';
|
||||
import { ScheduleModule } from '@nestjs/schedule';
|
||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
||||
import { I18nMiddleware, I18nModule } from 'nestjs-i18n';
|
||||
import { LoggerModule } from 'nestjs-pino';
|
||||
@ -17,6 +18,7 @@ import { AllExceptionsFilter, buildI18nValidationExceptionFilter } from './core/
|
||||
import { buildConfigOptions, buildLoggerOptions, buildTypeormOptions } from './core/module-options';
|
||||
import { buildI18nOptions } from './core/module-options/i18n-options';
|
||||
import { buildValidationPipe } from './core/pipes';
|
||||
import { CronModule } from './cron/cron.module';
|
||||
import { CustomerModule } from './customer/customer.module';
|
||||
import { migrations } from './db';
|
||||
import { DocumentModule } from './document/document.module';
|
||||
@ -56,6 +58,7 @@ import { UserModule } from './user/user.module';
|
||||
I18nModule.forRoot(buildI18nOptions()),
|
||||
CacheModule,
|
||||
EventEmitterModule.forRoot(),
|
||||
ScheduleModule.forRoot(),
|
||||
// App modules
|
||||
AuthModule,
|
||||
CustomerModule,
|
||||
@ -75,6 +78,8 @@ import { UserModule } from './user/user.module';
|
||||
HealthModule,
|
||||
|
||||
UserModule,
|
||||
|
||||
CronModule,
|
||||
],
|
||||
providers: [
|
||||
// Global Pipes
|
||||
|
||||
Reference in New Issue
Block a user