From bfa327354627edf3ca3e1f0f22ceed506faef119 Mon Sep 17 00:00:00 2001 From: Rubin Bhandari Date: Wed, 18 Oct 2023 14:20:35 +0545 Subject: [PATCH] fix: issues with configs --- src/app.module.ts | 31 ++------------- src/common/constant/string.constants.ts | 9 +++-- src/generated/i18n-generated.ts | 49 ++++++++++++++++++++++++ src/lib/i18n/i18n.module.ts | 14 ++----- src/lib/pino/pino.module.ts | 8 ++-- src/lib/sentry.module.ts | 5 ++- src/main.ts | 10 ++--- src/modules/category/category.service.ts | 7 ++-- src/modules/shared/shared.module.ts | 30 +++++++++++++-- temp/BaseEntity.js.json | 2 +- temp/Category.js.json | 2 +- temp/Comment.js.json | 2 +- temp/Conversation.js.json | 2 +- temp/Message.js.json | 2 +- temp/NewsLetter.js.json | 2 +- temp/OtpLog.js.json | 2 +- temp/PointRedemptionLog.js.json | 1 + temp/Post.js.json | 2 +- temp/Protocol.js.json | 2 +- temp/Referral.js.json | 1 + temp/RefreshToken.js.json | 2 +- temp/Social.js.json | 2 +- temp/Subscriber.js.json | 2 +- temp/Tag.js.json | 2 +- temp/User.js.json | 2 +- tsconfig.build.json | 3 +- tsconfig.json | 1 + 27 files changed, 124 insertions(+), 73 deletions(-) create mode 100644 src/generated/i18n-generated.ts create mode 100644 temp/PointRedemptionLog.js.json create mode 100644 temp/Referral.js.json diff --git a/src/app.module.ts b/src/app.module.ts index 02e550e0..ebb92193 100644 --- a/src/app.module.ts +++ b/src/app.module.ts @@ -1,40 +1,17 @@ +import { SWAGGER_API_ENDPOINT } from "@common/constant"; +import { ClearCacheMiddleware, RealIpMiddleware } from "@common/middlewares"; import { applyRawBodyOnlyTo } from "@golevelup/nestjs-webhooks"; +import { SharedModule } from "@modules/shared/shared.module"; import type { MiddlewareConsumer, NestModule } from "@nestjs/common"; import { Module, RequestMethod } from "@nestjs/common"; -import { APP_GUARD, APP_INTERCEPTOR } from "@nestjs/core"; -import { SentryInterceptor } from "@ntegral/nestjs-sentry"; -import { CustomThrottlerGuard } from "@common/guards"; -import { ClearCacheInterceptor, HttpCacheInterceptor } from "@common/interceptors"; -import { ClearCacheMiddleware, RealIpMiddleware } from "@common/middlewares"; -import { NestCacheModule } from "@lib/cache"; -import { SharedModule } from "@modules/shared/shared.module"; import { AppController } from "app.controller"; -import { SWAGGER_API_ENDPOINT } from "@common/constant"; const stripeWebhookPath = "stripe/webhook"; const excludedPaths = [stripeWebhookPath, SWAGGER_API_ENDPOINT]; @Module({ + imports: [SharedModule], controllers: [AppController], - imports: [SharedModule, NestCacheModule], - providers: [ - { - provide: APP_INTERCEPTOR, - useClass: SentryInterceptor, - }, - { - provide: APP_GUARD, - useClass: CustomThrottlerGuard, - }, - { - provide: APP_INTERCEPTOR, - useClass: HttpCacheInterceptor, - }, - { - provide: APP_INTERCEPTOR, - useClass: ClearCacheInterceptor, - }, - ], }) export class AppModule implements NestModule { configure(consumer: MiddlewareConsumer) { diff --git a/src/common/constant/string.constants.ts b/src/common/constant/string.constants.ts index 6f2ea648..270b4ff9 100644 --- a/src/common/constant/string.constants.ts +++ b/src/common/constant/string.constants.ts @@ -1,5 +1,4 @@ import { capitalize } from "helper-fns"; -import { readPackageSync } from "read-pkg"; export const REQUEST_ID_TOKEN_HEADER = "x-request-id"; export const VERSION_VALIDATION_MESSAGE = "Version must start with \"v\" followed by a number."; @@ -10,8 +9,12 @@ export const THROTTLE_LIMIT_RESPONSE = "Too many requests, please try again late export const MULTER_IMAGE_FILTER = "Only image files are allowed!."; export const API_UNAUTHORISED_RESPONSE = "No auth token in request."; -// swagger constants -const packageJson = readPackageSync(); +// swagger constants, TODO: dfix this too +const packageJson = { + name: "nestjs-boilerplate", + version: "1.0.0", + description: "NestJS Boilerplate", +}; export const APP_NAME = packageJson.name; export const SWAGGER_API_CURRENT_VERSION = packageJson.version; diff --git a/src/generated/i18n-generated.ts b/src/generated/i18n-generated.ts new file mode 100644 index 00000000..4b501095 --- /dev/null +++ b/src/generated/i18n-generated.ts @@ -0,0 +1,49 @@ +/* DO NOT EDIT, file generated by nestjs-i18n */ + +import { Path } from "nestjs-i18n"; +export type I18nTranslations = { + "exception": { + "itemExists": string; + "itemDoesNotExist": string; + "unauthorized": string; + "internalError": string; + "otpRequired": string; + "usernameRequired": string; + "followerFollowingSame": string; + "invalidOTP": string; + "inactiveUser": string; + "invalidCredentials": string; + "invalidTwoFaCode": string; + "forbidden": string; + "userInactive": string; + "notFound": string; + "itemExpired": string; + "emailLooksGood": string; + "unsupportedFileType": string; + "incorrectOldPassword": string; + "badRequest": string; + "invalidRefreshToken": string; + "deleteDefaultError": string; + "tooManyTries": string; + "refreshToken": string; + "token": string; + "tooManyRequests": string; + "invalidCursor": string; + "cursorInvalidDate": string; + "cursorInvalidNumber": string; + "apiUnauthorizedResponse": string; + "tooManyRequest": string; + }; + "validation": { + "isNotEmpty": string; + "maxLength": string; + "minLength": string; + "max": string; + "min": string; + "isPassword": string; + "isIn": string; + "isEnum": string; + "isDataType": string; + }; +}; +export type I18nPath = Path; diff --git a/src/lib/i18n/i18n.module.ts b/src/lib/i18n/i18n.module.ts index 32fef7fd..f301233c 100644 --- a/src/lib/i18n/i18n.module.ts +++ b/src/lib/i18n/i18n.module.ts @@ -1,15 +1,15 @@ import path from "node:path"; import { Module } from "@nestjs/common"; -import { AcceptLanguageResolver, CookieResolver, HeaderResolver, I18nModule, QueryResolver } from "nestjs-i18n"; import { ConfigModule, ConfigService } from "@nestjs/config"; +import { AcceptLanguageResolver, HeaderResolver, I18nModule, QueryResolver } from "nestjs-i18n"; @Module({ imports: [ I18nModule.forRootAsync({ + imports: [ConfigModule], + inject: [ConfigService], useFactory: (configService: ConfigService) => ({ - imports: [ConfigModule], - inject: [ConfigService], fallbackLanguage: "en", fallbacks: { "np-*": "np", @@ -26,12 +26,6 @@ import { ConfigModule, ConfigService } from "@nestjs/config"; includeSubfolders: true, }, typesOutputPath: configService.get("app.env", { infer: true }).startsWith("prod") ? undefined : path.join(`${process.cwd()}/src/generated/i18n-generated.ts`), - resolvers: [ - new HeaderResolver(["x-custom-lang"]), - AcceptLanguageResolver, - new CookieResolver(), - { use: QueryResolver, options: ["lang", "locale"] }, - ], }), resolvers: [ { use: QueryResolver, options: ["lang"] }, @@ -42,4 +36,4 @@ import { ConfigModule, ConfigService } from "@nestjs/config"; ], exports: [I18nModule], }) -export class NestI18nModule {} +export class NestI18nModule { } diff --git a/src/lib/pino/pino.module.ts b/src/lib/pino/pino.module.ts index 4fd08f42..14e65b30 100644 --- a/src/lib/pino/pino.module.ts +++ b/src/lib/pino/pino.module.ts @@ -14,9 +14,9 @@ const basePinoOptions = { @Module({ imports: [ LoggerModule.forRootAsync({ - useFactory: (configService: ConfigService) => ({ - imports: [ConfigModule], - inject: [ConfigService], + imports: [ConfigModule], + inject: [ConfigService], + useFactory: (_configService: ConfigService) => ({ pinoHttp: { timestamp: () => `,"timestamp":"${new Date(Date.now()).toISOString()}"`, name: "ultimate-nest", @@ -34,7 +34,7 @@ const basePinoOptions = { paths: redactFields, censor: "**GDPR COMPLIANT**", }, - transport: configService.get("app.env", { infer: true }).startsWith("prod") + transport: true ? { targets: [ { diff --git a/src/lib/sentry.module.ts b/src/lib/sentry.module.ts index 514c6ea8..e96acb1c 100644 --- a/src/lib/sentry.module.ts +++ b/src/lib/sentry.module.ts @@ -1,7 +1,8 @@ -import { Module } from "@nestjs/common"; +import { Global, Module } from "@nestjs/common"; import { ConfigModule, ConfigService } from "@nestjs/config"; import { SentryModule } from "@ntegral/nestjs-sentry"; +@Global() @Module({ imports: [ SentryModule.forRootAsync({ @@ -9,7 +10,7 @@ import { SentryModule } from "@ntegral/nestjs-sentry"; inject: [ConfigService], useFactory: async (configService: ConfigService) => ({ dsn: configService.get("sentry.sentryDsn", { infer: true }), - environment: configService.get("sentry.sentryDsn", { infer: true }), + environment: configService.get("sentry.environment", { infer: true }), debug: true, tracesSampleRate: 1, }), diff --git a/src/main.ts b/src/main.ts index 7abddc26..2c9acca1 100644 --- a/src/main.ts +++ b/src/main.ts @@ -1,21 +1,20 @@ import "@total-typescript/ts-reset"; -import bodyParser from "body-parser"; -import chalk from "chalk"; +import { AppUtils, HelperService } from "@common/helpers"; import { Logger, ValidationPipe } from "@nestjs/common"; import { ConfigService } from "@nestjs/config"; import { NestFactory } from "@nestjs/core"; import type { NestExpressApplication } from "@nestjs/platform-express"; import { ExpressAdapter } from "@nestjs/platform-express"; +import bodyParser from "body-parser"; +import chalk from "chalk"; import { useContainer } from "class-validator"; import compression from "compression"; import helmet from "helmet"; import { I18nValidationExceptionFilter } from "nestjs-i18n"; import { LoggerErrorInterceptor } from "nestjs-pino"; -import { createLogger } from "@lib/pino/app.logger"; -import { AppUtils, HelperService } from "@common/helpers"; -import { SocketIOAdapter } from "./socket-io.adapter"; import { AppModule } from "./app.module"; +import { SocketIOAdapter } from "./socket-io.adapter"; declare const module: { hot: { accept: () => void; dispose: (argument: () => Promise) => void } }; @@ -23,7 +22,6 @@ const logger = new Logger("Bootstrap"); async function bootstrap() { const app = await NestFactory.create(AppModule, new ExpressAdapter(), { - logger: await createLogger(), snapshot: true, }); diff --git a/src/modules/category/category.service.ts b/src/modules/category/category.service.ts index 28476a7e..d05ab5fc 100644 --- a/src/modules/category/category.service.ts +++ b/src/modules/category/category.service.ts @@ -3,15 +3,16 @@ import { BaseRepository } from "@common/database"; import type { OffsetPaginationDto } from "@common/dtos"; import { Category } from "@entities"; import { BaseService } from "@lib/crud/crud.service"; +import { InjectRepository } from "@mikro-orm/nestjs"; @Injectable() export class CategoryService extends BaseService { protected readonly queryName = "c"; // the name of the query used in the pagination protected readonly searchField = "name"; // the field to search for when searching for tags constructor( - // @ts-expect-error: Unused import error - // eslint-disable-next-line ts/no-unsafe-call - @InjectRepository(Category) private categoryRepository: BaseRepository, + // @ts-expect-error: Unused import error + // eslint-disable-next-line ts/no-unsafe-call + @InjectRepository(Category) private categoryRepository: BaseRepository, ) { super(categoryRepository); } diff --git a/src/modules/shared/shared.module.ts b/src/modules/shared/shared.module.ts index 1050589d..e7c72483 100644 --- a/src/modules/shared/shared.module.ts +++ b/src/modules/shared/shared.module.ts @@ -1,6 +1,7 @@ -import { Module } from "@nestjs/common"; -import { ScheduleModule } from "@nestjs/schedule"; import { IsUniqueConstraint } from "@common/decorators/validation"; +import { CustomThrottlerGuard } from "@common/guards"; +import { ClearCacheInterceptor, HttpCacheInterceptor } from "@common/interceptors"; +import { NestCacheModule } from "@lib/cache"; import { NestConfigModule } from "@lib/config/config.module"; import { NestCaslModule, @@ -25,6 +26,9 @@ import { ProfileModule } from "@modules/profile/profile.module"; import { TagsModule } from "@modules/tags/tags.module"; import { TwoFactorModule } from "@modules/twofa/twofa.module"; import { UserModule } from "@modules/user/user.module"; +import { Module } from "@nestjs/common"; +import { APP_GUARD, APP_INTERCEPTOR } from "@nestjs/core"; +import { ScheduleModule } from "@nestjs/schedule"; @Module({ imports: [ @@ -44,14 +48,34 @@ import { UserModule } from "@modules/user/user.module"; NestPinoModule, NestI18nModule, NestCloudinaryModule, + NestCacheModule, NestSentryModule, NestCaslModule, NestThrottlerModule, NestHttpModule, NestServeStaticModule, + NestSentryModule, NestJwtModule, ScheduleModule.forRoot(), ], - providers: [IsUniqueConstraint], + providers: [ + IsUniqueConstraint, + // { + // provide: APP_INTERCEPTOR, // TODO: fix sentry + // useClass: SentryInterceptor, + // }, + { + provide: APP_GUARD, + useClass: CustomThrottlerGuard, + }, + { + provide: APP_INTERCEPTOR, + useClass: HttpCacheInterceptor, + }, + { + provide: APP_INTERCEPTOR, + useClass: ClearCacheInterceptor, + }, + ], }) export class SharedModule {} diff --git a/temp/BaseEntity.js.json b/temp/BaseEntity.js.json index e0a46f41..7d7c3c78 100644 --- a/temp/BaseEntity.js.json +++ b/temp/BaseEntity.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"id":{"name":"id","reference":"scalar","primary":true,"hidden":true,"index":true,"type":"number","array":false},"idx":{"name":"idx","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"isActive":{"name":"isActive","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"isDeleted":{"name":"isDeleted","reference":"scalar","hidden":true,"getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"deletedAt":{"name":"deletedAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true},"createdAt":{"name":"createdAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true},"updatedAt":{"name":"updatedAt","reference":"scalar","hidden":true,"getter":false,"setter":false,"type":"Date","array":false,"optional":true}},"props":[{"name":"id","reference":"scalar","primary":true,"hidden":true,"index":true,"type":"number","array":false},{"name":"idx","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"isActive","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"isDeleted","reference":"scalar","hidden":true,"getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"deletedAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true},{"name":"createdAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true},{"name":"updatedAt","reference":"scalar","hidden":true,"getter":false,"setter":false,"type":"Date","array":false,"optional":true}],"primaryKeys":["id"],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"BaseEntity","path":"./dist/common/database/base.entity.js","abstract":true,"constructorParams":[],"toJsonParams":[],"useCache":true,"compositePK":false,"simplePK":true,"relations":[]},"origin":"./dist/common/database/base.entity.js","hash":"0a512305f18ebe86f440150896ef51f0","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"id":{"name":"id","reference":"scalar","primary":true,"hidden":true,"index":true,"type":"number","array":false},"idx":{"name":"idx","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"isActive":{"name":"isActive","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"isDeleted":{"name":"isDeleted","reference":"scalar","hidden":true,"getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"deletedAt":{"name":"deletedAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true},"createdAt":{"name":"createdAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true},"updatedAt":{"name":"updatedAt","reference":"scalar","hidden":true,"getter":false,"setter":false,"type":"Date","array":false,"optional":true}},"props":[{"name":"id","reference":"scalar","primary":true,"hidden":true,"index":true,"type":"number","array":false},{"name":"idx","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"isActive","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"isDeleted","reference":"scalar","hidden":true,"getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"deletedAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true},{"name":"createdAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true},{"name":"updatedAt","reference":"scalar","hidden":true,"getter":false,"setter":false,"type":"Date","array":false,"optional":true}],"primaryKeys":["id"],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"BaseEntity","path":"./dist/common/database/base.entity.js","abstract":true,"constructorParams":[],"toJsonParams":[],"useCache":true,"compositePK":false,"simplePK":true,"relations":[]},"origin":"./dist/common/database/base.entity.js","hash":"a2153d72199ccfeab857a9c5b5d94af8","version":"5.8.9"} diff --git a/temp/Category.js.json b/temp/Category.js.json index fbe691bf..84749ed0 100644 --- a/temp/Category.js.json +++ b/temp/Category.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"name":{"name":"name","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},"description":{"name":"description","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"posts":{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}},"props":[{"name":"name","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"description","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Category","path":"./dist/entities/category.entity.js","name":"Category","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}],"collection":"category"},"origin":"./dist/entities/category.entity.js","hash":"fc4f3683c61704e000098ea26e174c85","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"name":{"name":"name","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},"description":{"name":"description","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"posts":{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}},"props":[{"name":"name","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"description","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Category","path":"./dist/entities/category.entity.js","name":"Category","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}],"collection":"category"},"origin":"./dist/entities/category.entity.js","hash":"8e2ec5a16c5fbab38c730eb820e536a7","version":"5.8.9"} diff --git a/temp/Comment.js.json b/temp/Comment.js.json index df2c812b..3cf305df 100644 --- a/temp/Comment.js.json +++ b/temp/Comment.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"body":{"name":"body","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"post":{"name":"post","reference":"m:1","cascade":["persist"],"eager":false,"type":"Post","owner":true,"array":false},"author":{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false}},"props":[{"name":"body","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"post","reference":"m:1","cascade":["persist"],"eager":false,"type":"Post","owner":true,"array":false},{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Comment","path":"./dist/entities/comment.entity.js","name":"Comment","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"post","reference":"m:1","cascade":["persist"],"eager":false,"type":"Post","owner":true,"array":false},{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false}],"collection":"comment"},"origin":"./dist/entities/comment.entity.js","hash":"68720b550ef47caff5316fb0b69a1ab8","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"body":{"name":"body","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"post":{"name":"post","reference":"m:1","cascade":["persist"],"eager":false,"type":"Post","owner":true,"array":false,"wrappedReference":true},"author":{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true}},"props":[{"name":"body","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"post","reference":"m:1","cascade":["persist"],"eager":false,"type":"Post","owner":true,"array":false,"wrappedReference":true},{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Comment","path":"./dist/entities/comment.entity.js","name":"Comment","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"post","reference":"m:1","cascade":["persist"],"eager":false,"type":"Post","owner":true,"array":false,"wrappedReference":true},{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true}],"collection":"comment"},"origin":"./dist/entities/comment.entity.js","hash":"4303f3bf213b272cff524f35508c15de","version":"5.8.9"} diff --git a/temp/Conversation.js.json b/temp/Conversation.js.json index 3a6ff45b..6124673c 100644 --- a/temp/Conversation.js.json +++ b/temp/Conversation.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"chatName":{"name":"chatName","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},"users":{"name":"users","reference":"m:n","cascade":["persist"],"index":true,"type":"User","fixedOrder":false,"array":false},"messages":{"name":"messages","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"nullable":true,"type":"Message","array":false}},"props":[{"name":"chatName","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"users","reference":"m:n","cascade":["persist"],"index":true,"type":"User","fixedOrder":false,"array":false},{"name":"messages","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"nullable":true,"type":"Message","array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Conversation","path":"./dist/entities/conversation.entity.js","name":"Conversation","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"users","reference":"m:n","cascade":["persist"],"index":true,"type":"User","fixedOrder":false,"array":false},{"name":"messages","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"nullable":true,"type":"Message","array":false}],"collection":"conversation"},"origin":"./dist/entities/conversation.entity.js","hash":"c7ed2280f935143d35c9daebb1ca7250","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"chatName":{"name":"chatName","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},"users":{"name":"users","reference":"m:n","cascade":["persist"],"index":true,"type":"User","fixedOrder":false,"array":false},"messages":{"name":"messages","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"nullable":true,"type":"Message","array":false}},"props":[{"name":"chatName","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"users","reference":"m:n","cascade":["persist"],"index":true,"type":"User","fixedOrder":false,"array":false},{"name":"messages","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"nullable":true,"type":"Message","array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Conversation","path":"./dist/entities/conversation.entity.js","name":"Conversation","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"users","reference":"m:n","cascade":["persist"],"index":true,"type":"User","fixedOrder":false,"array":false},{"name":"messages","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"nullable":true,"type":"Message","array":false}],"collection":"conversation"},"origin":"./dist/entities/conversation.entity.js","hash":"fbaeba4f8c23a43c247c1f449079ee0e","version":"5.8.9"} diff --git a/temp/Message.js.json b/temp/Message.js.json index fa0928ee..bac6e875 100644 --- a/temp/Message.js.json +++ b/temp/Message.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"body":{"name":"body","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"sender":{"name":"sender","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false},"conversation":{"name":"conversation","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"Conversation","owner":true,"array":false},"isRead":{"name":"isRead","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"readAt":{"name":"readAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true}},"props":[{"name":"body","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"sender","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false},{"name":"conversation","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"Conversation","owner":true,"array":false},{"name":"isRead","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"readAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Message","path":"./dist/entities/message.entity.js","name":"Message","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"sender","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false},{"name":"conversation","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"Conversation","owner":true,"array":false}],"collection":"message"},"origin":"./dist/entities/message.entity.js","hash":"963a25eef622ea82d6b15e3427e2c968","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"body":{"name":"body","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"sender":{"name":"sender","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},"conversation":{"name":"conversation","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"Conversation","owner":true,"array":false,"wrappedReference":true},"isRead":{"name":"isRead","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"readAt":{"name":"readAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true}},"props":[{"name":"body","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"sender","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},{"name":"conversation","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"Conversation","owner":true,"array":false,"wrappedReference":true},{"name":"isRead","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"readAt","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Message","path":"./dist/entities/message.entity.js","name":"Message","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"sender","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},{"name":"conversation","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"Conversation","owner":true,"array":false,"wrappedReference":true}],"collection":"message"},"origin":"./dist/entities/message.entity.js","hash":"6e1c88a23e8c766f3212819de7267b3f","version":"5.8.9"} diff --git a/temp/NewsLetter.js.json b/temp/NewsLetter.js.json index ac6d0bc0..68ef7c37 100644 --- a/temp/NewsLetter.js.json +++ b/temp/NewsLetter.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"name":{"name":"name","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},"content":{"name":"content","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"sentAt":{"name":"sentAt","reference":"scalar","type":"date","nullable":true,"getter":false,"setter":false,"array":false,"optional":true}},"props":[{"name":"name","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"content","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"sentAt","reference":"scalar","type":"date","nullable":true,"getter":false,"setter":false,"array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"NewsLetter","path":"./dist/entities/news-letter.entity.js","name":"NewsLetter","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[],"collection":"news_letter"},"origin":"./dist/entities/news-letter.entity.js","hash":"302f649f5d9512bcda018ad533cd65e8","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"name":{"name":"name","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},"content":{"name":"content","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"sentAt":{"name":"sentAt","reference":"scalar","type":"date","nullable":true,"getter":false,"setter":false,"array":false,"optional":true}},"props":[{"name":"name","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"content","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"sentAt","reference":"scalar","type":"date","nullable":true,"getter":false,"setter":false,"array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"NewsLetter","path":"./dist/entities/news-letter.entity.js","name":"NewsLetter","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[],"collection":"news_letter"},"origin":"./dist/entities/news-letter.entity.js","hash":"9d93c5a88c04e98b10cd8df1ddc0ef54","version":"5.8.9"} diff --git a/temp/OtpLog.js.json b/temp/OtpLog.js.json index ec457a0f..48af6347 100644 --- a/temp/OtpLog.js.json +++ b/temp/OtpLog.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"expiresIn":{"name":"expiresIn","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false},"otpCode":{"name":"otpCode","reference":"scalar","length":20,"index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"user":{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false},"isUsed":{"name":"isUsed","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true}},"props":[{"name":"expiresIn","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false},{"name":"otpCode","reference":"scalar","length":20,"index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false},{"name":"isUsed","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"OtpLog","path":"./dist/entities/otp-log.entity.js","name":"OtpLog","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false}],"collection":"otp_log"},"origin":"./dist/entities/otp-log.entity.js","hash":"11fc28a3ce56ef992e476e365c6d8dc4","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"expiresIn":{"name":"expiresIn","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false},"otpCode":{"name":"otpCode","reference":"scalar","length":20,"index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"user":{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},"isUsed":{"name":"isUsed","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true}},"props":[{"name":"expiresIn","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false},{"name":"otpCode","reference":"scalar","length":20,"index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},{"name":"isUsed","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"OtpLog","path":"./dist/entities/otp-log.entity.js","name":"OtpLog","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true}],"collection":"otp_log"},"origin":"./dist/entities/otp-log.entity.js","hash":"304cc8b9f9121721130bc28bf8c6c3a7","version":"5.8.9"} diff --git a/temp/PointRedemptionLog.js.json b/temp/PointRedemptionLog.js.json new file mode 100644 index 00000000..b57ce0c3 --- /dev/null +++ b/temp/PointRedemptionLog.js.json @@ -0,0 +1 @@ +{"data":{"propertyOrder":{},"properties":{"points":{"name":"points","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},"amount":{"name":"amount","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["numeric(9,2)"],"array":false},"user":{"name":"user","reference":"m:1","cascade":["persist"],"type":"User","owner":true,"array":false,"wrappedReference":true}},"props":[{"name":"points","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},{"name":"amount","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["numeric(9,2)"],"array":false},{"name":"user","reference":"m:1","cascade":["persist"],"type":"User","owner":true,"array":false,"wrappedReference":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"PointRedemptionLog","path":"./dist/entities/points-redemption-log.entity.js","name":"PointRedemptionLog","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"user","reference":"m:1","cascade":["persist"],"type":"User","owner":true,"array":false,"wrappedReference":true}],"collection":"point_redemption_log"},"origin":"./dist/entities/points-redemption-log.entity.js","hash":"edbec5c2950365c9f7174e109aa50244","version":"5.8.9"} diff --git a/temp/Post.js.json b/temp/Post.js.json index 30a34a10..b55188b8 100644 --- a/temp/Post.js.json +++ b/temp/Post.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"slug":{"name":"slug","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"title":{"name":"title","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},"description":{"name":"description","reference":"scalar","type":"text","getter":false,"setter":false,"array":false},"content":{"name":"content","reference":"scalar","type":"text","getter":false,"setter":false,"array":false},"readingTime":{"name":"readingTime","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},"readCount":{"name":"readCount","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},"favoritesCount":{"name":"favoritesCount","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},"author":{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false},"comments":{"name":"comments","reference":"1:m","cascade":["persist"],"eager":false,"orphanRemoval":true,"nullable":true,"type":"Comment","array":false},"tags":{"name":"tags","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Tag","fixedOrder":false,"array":false},"categories":{"name":"categories","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Category","fixedOrder":false,"array":false},"state":{"name":"state","reference":"scalar","enum":true,"items":["DRAFT","PUBLISHED"],"type":"any","array":false,"optional":true}},"props":[{"name":"slug","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"title","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"description","reference":"scalar","type":"text","getter":false,"setter":false,"array":false},{"name":"content","reference":"scalar","type":"text","getter":false,"setter":false,"array":false},{"name":"readingTime","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},{"name":"readCount","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},{"name":"favoritesCount","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false},{"name":"comments","reference":"1:m","cascade":["persist"],"eager":false,"orphanRemoval":true,"nullable":true,"type":"Comment","array":false},{"name":"tags","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Tag","fixedOrder":false,"array":false},{"name":"categories","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Category","fixedOrder":false,"array":false},{"name":"state","reference":"scalar","enum":true,"items":["DRAFT","PUBLISHED"],"type":"any","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{"beforeUpdate":["generateSlug"],"beforeCreate":["generateSlug"],"beforeUpsert":["generateSlug"]},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Post","path":"./dist/entities/post.entity.js","name":"Post","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false},{"name":"comments","reference":"1:m","cascade":["persist"],"eager":false,"orphanRemoval":true,"nullable":true,"type":"Comment","array":false},{"name":"tags","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Tag","fixedOrder":false,"array":false},{"name":"categories","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Category","fixedOrder":false,"array":false}],"collection":"post"},"origin":"./dist/entities/post.entity.js","hash":"1bcdff0468d26c0786e94e3dec2c64c6","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"slug":{"name":"slug","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"title":{"name":"title","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},"description":{"name":"description","reference":"scalar","type":"text","getter":false,"setter":false,"array":false},"content":{"name":"content","reference":"scalar","type":"text","getter":false,"setter":false,"array":false},"readingTime":{"name":"readingTime","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},"readCount":{"name":"readCount","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},"favoritesCount":{"name":"favoritesCount","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},"author":{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},"comments":{"name":"comments","reference":"1:m","cascade":["persist"],"eager":false,"orphanRemoval":true,"nullable":true,"type":"Comment","array":false},"tags":{"name":"tags","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Tag","fixedOrder":false,"array":false},"categories":{"name":"categories","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Category","fixedOrder":false,"array":false},"state":{"name":"state","reference":"scalar","enum":true,"items":["DRAFT","PUBLISHED"],"type":"any","array":false,"optional":true}},"props":[{"name":"slug","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"title","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"description","reference":"scalar","type":"text","getter":false,"setter":false,"array":false},{"name":"content","reference":"scalar","type":"text","getter":false,"setter":false,"array":false},{"name":"readingTime","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},{"name":"readCount","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},{"name":"favoritesCount","reference":"scalar","getter":false,"setter":false,"type":"number","array":false,"optional":true},{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},{"name":"comments","reference":"1:m","cascade":["persist"],"eager":false,"orphanRemoval":true,"nullable":true,"type":"Comment","array":false},{"name":"tags","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Tag","fixedOrder":false,"array":false},{"name":"categories","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Category","fixedOrder":false,"array":false},{"name":"state","reference":"scalar","enum":true,"items":["DRAFT","PUBLISHED"],"type":"any","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{"beforeUpdate":["generateSlug"],"beforeCreate":["generateSlug"],"beforeUpsert":["generateSlug"]},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Post","path":"./dist/entities/post.entity.js","name":"Post","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"author","reference":"m:1","cascade":["persist"],"eager":false,"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},{"name":"comments","reference":"1:m","cascade":["persist"],"eager":false,"orphanRemoval":true,"nullable":true,"type":"Comment","array":false},{"name":"tags","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Tag","fixedOrder":false,"array":false},{"name":"categories","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"posts","type":"Category","fixedOrder":false,"array":false}],"collection":"post"},"origin":"./dist/entities/post.entity.js","hash":"0ba2c240fcef6258540b12211c78c38b","version":"5.8.9"} diff --git a/temp/Protocol.js.json b/temp/Protocol.js.json index 82bc5d31..2c699edf 100644 --- a/temp/Protocol.js.json +++ b/temp/Protocol.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"loginAttemptnumbererval":{"name":"loginAttemptnumbererval","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},"loginnumberervalUnit":{"name":"loginnumberervalUnit","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"loginMaxRetry":{"name":"loginMaxRetry","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},"otpExpiryInMinutes":{"name":"otpExpiryInMinutes","reference":"scalar","getter":false,"setter":false,"type":"number","array":false}},"props":[{"name":"loginAttemptnumbererval","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},{"name":"loginnumberervalUnit","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"loginMaxRetry","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},{"name":"otpExpiryInMinutes","reference":"scalar","getter":false,"setter":false,"type":"number","array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Protocol","path":"./dist/entities/protocol.entity.js","name":"Protocol","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[],"collection":"protocol"},"origin":"./dist/entities/protocol.entity.js","hash":"58d109b83db185186471e3501e58f4b6","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"loginAttemptnumbererval":{"name":"loginAttemptnumbererval","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},"loginnumberervalUnit":{"name":"loginnumberervalUnit","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"loginMaxRetry":{"name":"loginMaxRetry","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},"otpExpiryInMinutes":{"name":"otpExpiryInMinutes","reference":"scalar","getter":false,"setter":false,"type":"number","array":false}},"props":[{"name":"loginAttemptnumbererval","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},{"name":"loginnumberervalUnit","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"loginMaxRetry","reference":"scalar","getter":false,"setter":false,"type":"number","array":false},{"name":"otpExpiryInMinutes","reference":"scalar","getter":false,"setter":false,"type":"number","array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Protocol","path":"./dist/entities/protocol.entity.js","name":"Protocol","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[],"collection":"protocol"},"origin":"./dist/entities/protocol.entity.js","hash":"c93d605364e6aee23e702f403317ae2e","version":"5.8.9"} diff --git a/temp/Referral.js.json b/temp/Referral.js.json new file mode 100644 index 00000000..849e154b --- /dev/null +++ b/temp/Referral.js.json @@ -0,0 +1 @@ +{"data":{"propertyOrder":{},"properties":{"referrer":{"name":"referrer","reference":"m:1","cascade":["persist"],"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},"mobileNumber":{"name":"mobileNumber","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},"status":{"name":"status","reference":"scalar","enum":true,"items":["PENDING","COMPLETED"],"type":"ReferralStatus","array":false}},"props":[{"name":"referrer","reference":"m:1","cascade":["persist"],"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true},{"name":"mobileNumber","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"status","reference":"scalar","enum":true,"items":["PENDING","COMPLETED"],"type":"ReferralStatus","array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[{"properties":"status"}],"uniques":[],"concurrencyCheckKeys":{},"className":"Referral","path":"./dist/entities/referral.entity.js","name":"Referral","abstract":false,"constructorParams":[],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"referrer","reference":"m:1","cascade":["persist"],"index":true,"type":"User","owner":true,"array":false,"wrappedReference":true}],"collection":"referral"},"origin":"./dist/entities/referral.entity.js","hash":"137e3fcb5ad5b1ae3d4330374c658190","version":"5.8.9"} diff --git a/temp/RefreshToken.js.json b/temp/RefreshToken.js.json index 3f0b9c92..a962dde9 100644 --- a/temp/RefreshToken.js.json +++ b/temp/RefreshToken.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"expiresIn":{"name":"expiresIn","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false},"user":{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"type":"User","owner":true,"array":false},"isRevoked":{"name":"isRevoked","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true}},"props":[{"name":"expiresIn","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false},{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"type":"User","owner":true,"array":false},{"name":"isRevoked","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"RefreshToken","path":"./dist/entities/refresh-token.entity.js","name":"RefreshToken","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"type":"User","owner":true,"array":false}],"collection":"refresh_token"},"origin":"./dist/entities/refresh-token.entity.js","hash":"f396f80ab8fed7d3635745f9b340cc25","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"expiresIn":{"name":"expiresIn","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false},"user":{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"type":"User","owner":true,"array":false,"wrappedReference":true},"isRevoked":{"name":"isRevoked","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true}},"props":[{"name":"expiresIn","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false},{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"type":"User","owner":true,"array":false,"wrappedReference":true},{"name":"isRevoked","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"RefreshToken","path":"./dist/entities/refresh-token.entity.js","name":"RefreshToken","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"user","reference":"m:1","cascade":["persist"],"eager":false,"type":"User","owner":true,"array":false,"wrappedReference":true}],"collection":"refresh_token"},"origin":"./dist/entities/refresh-token.entity.js","hash":"6d63d3ac57a060dd8f52f8086cb11d71","version":"5.8.9"} diff --git a/temp/Social.js.json b/temp/Social.js.json index 11e59717..e2708c92 100644 --- a/temp/Social.js.json +++ b/temp/Social.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"twitter":{"name":"twitter","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},"facebook":{"name":"facebook","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},"linkedin":{"name":"linkedin","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true}},"props":[{"name":"twitter","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"facebook","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"linkedin","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Social","path":"./dist/entities/user.entity.js","name":"Social","embeddable":true,"abstract":false,"constructorParams":[],"toJsonParams":[],"useCache":true,"relations":[],"collection":"social"},"origin":"./dist/entities/user.entity.js","hash":"a6c08be1f8338e182a288a2f2a653d82","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"twitter":{"name":"twitter","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},"facebook":{"name":"facebook","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},"linkedin":{"name":"linkedin","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true}},"props":[{"name":"twitter","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"facebook","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"linkedin","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Social","path":"./dist/entities/user.entity.js","name":"Social","embeddable":true,"abstract":false,"constructorParams":[],"toJsonParams":[],"useCache":true,"relations":[],"collection":"social"},"origin":"./dist/entities/user.entity.js","hash":"26b91a657e2c8663fb9efafcb5989dd2","version":"5.8.9"} diff --git a/temp/Subscriber.js.json b/temp/Subscriber.js.json index fef23060..dbe6441d 100644 --- a/temp/Subscriber.js.json +++ b/temp/Subscriber.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"email":{"name":"email","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false}},"props":[{"name":"email","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Subscriber","path":"./dist/entities/subscribers.entity.js","name":"Subscriber","abstract":false,"constructorParams":[],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[],"collection":"subscriber"},"origin":"./dist/entities/subscribers.entity.js","hash":"e5e39399d25968164f1f24674615db83","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"email":{"name":"email","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false}},"props":[{"name":"email","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false}],"primaryKeys":[],"filters":{},"hooks":{},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Subscriber","path":"./dist/entities/subscribers.entity.js","name":"Subscriber","abstract":false,"constructorParams":[],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[],"collection":"subscriber"},"origin":"./dist/entities/subscribers.entity.js","hash":"63c82df81dbc704e4c6e0ab76f97ff5f","version":"5.8.9"} diff --git a/temp/Tag.js.json b/temp/Tag.js.json index 85dea14c..d9345d3c 100644 --- a/temp/Tag.js.json +++ b/temp/Tag.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"title":{"name":"title","reference":"scalar","length":50,"index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},"description":{"name":"description","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"slug":{"name":"slug","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"posts":{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}},"props":[{"name":"title","reference":"scalar","length":50,"index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"description","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"slug","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}],"primaryKeys":[],"filters":{},"hooks":{"beforeUpdate":["generateSlug"],"beforeUpsert":["generateSlug"],"beforeCreate":["generateSlug"]},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"Tag","path":"./dist/entities/tag.entity.js","name":"Tag","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}],"collection":"tag"},"origin":"./dist/entities/tag.entity.js","hash":"11672de06200cacbe30a320e4549da16","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"title":{"name":"title","reference":"scalar","length":50,"index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},"description":{"name":"description","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"slug":{"name":"slug","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"posts":{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}},"props":[{"name":"title","reference":"scalar","length":50,"index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"description","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"slug","reference":"scalar","index":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}],"primaryKeys":[],"filters":{},"hooks":{"beforeUpdate":["generateSlug"],"beforeUpsert":["generateSlug"],"beforeCreate":["generateSlug"]},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"Tag","path":"./dist/entities/tag.entity.js","name":"Tag","abstract":false,"constructorParams":["partial"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"posts","reference":"m:n","cascade":["persist"],"type":"Post","fixedOrder":false,"array":false}],"collection":"tag"},"origin":"./dist/entities/tag.entity.js","hash":"6961738313a3b90b98acd6f0bb0fd30d","version":"5.8.9"} diff --git a/temp/User.js.json b/temp/User.js.json index c21dbfc1..cfa7763b 100644 --- a/temp/User.js.json +++ b/temp/User.js.json @@ -1 +1 @@ -{"data":{"propertyOrder":{},"properties":{"firstName":{"name":"firstName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"middleName":{"name":"middleName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},"lastName":{"name":"lastName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"username":{"name":"username","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},"email":{"name":"email","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},"bio":{"name":"bio","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"avatar":{"name":"avatar","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"password":{"name":"password","reference":"scalar","hidden":true,"lazy":true,"getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"twoFactorSecret":{"name":"twoFactorSecret","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},"isTwoFactorEnabled":{"name":"isTwoFactorEnabled","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"roles":{"name":"roles","reference":"scalar","enum":false,"items":["ADMIN","AUTHOR"],"array":true,"type":"Roles[]","customType":"customType","optional":true},"mobileNumber":{"name":"mobileNumber","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"isVerified":{"name":"isVerified","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"posts":{"name":"posts","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"eager":false,"nullable":true,"type":"Post","array":false},"conversations":{"name":"conversations","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"users","type":"Conversation","fixedOrder":false,"array":false},"favorites":{"name":"favorites","reference":"m:n","cascade":["persist"],"hidden":true,"type":"Post","fixedOrder":false,"owner":true,"array":false},"social":{"name":"social","type":"Social","reference":"embedded","object":true,"nullable":true,"prefix":true,"array":false,"optional":true},"followers":{"name":"followers","reference":"m:n","cascade":["persist"],"owner":true,"pivotTable":"user_to_follower","hidden":true,"type":"User","fixedOrder":false,"joinColumns":["follower"],"inverseJoinColumns":["following"],"array":false},"followed":{"name":"followed","reference":"m:n","cascade":["persist"],"type":"User","fixedOrder":false,"array":false},"lastLogin":{"name":"lastLogin","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true}},"props":[{"name":"firstName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"middleName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"lastName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"username","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"email","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"bio","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"avatar","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"password","reference":"scalar","hidden":true,"lazy":true,"getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"twoFactorSecret","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"isTwoFactorEnabled","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"roles","reference":"scalar","enum":false,"items":["ADMIN","AUTHOR"],"array":true,"type":"Roles[]","customType":"customType","optional":true},{"name":"mobileNumber","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"isVerified","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"posts","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"eager":false,"nullable":true,"type":"Post","array":false},{"name":"conversations","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"users","type":"Conversation","fixedOrder":false,"array":false},{"name":"favorites","reference":"m:n","cascade":["persist"],"hidden":true,"type":"Post","fixedOrder":false,"owner":true,"array":false},{"name":"social","type":"Social","reference":"embedded","object":true,"nullable":true,"prefix":true,"array":false,"optional":true},{"name":"followers","reference":"m:n","cascade":["persist"],"owner":true,"pivotTable":"user_to_follower","hidden":true,"type":"User","fixedOrder":false,"joinColumns":["follower"],"inverseJoinColumns":["following"],"array":false},{"name":"followed","reference":"m:n","cascade":["persist"],"type":"User","fixedOrder":false,"array":false},{"name":"lastLogin","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{"beforeUpsert":["hashPassword"],"beforeUpdate":["hashPassword"],"beforeCreate":["hashPassword"]},"indexes":[],"uniques":[],"checks":[],"concurrencyCheckKeys":{},"className":"User","path":"./dist/entities/user.entity.js","name":"User","abstract":false,"constructorParams":["data"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"posts","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"eager":false,"nullable":true,"type":"Post","array":false},{"name":"conversations","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"users","type":"Conversation","fixedOrder":false,"array":false},{"name":"favorites","reference":"m:n","cascade":["persist"],"hidden":true,"type":"Post","fixedOrder":false,"owner":true,"array":false},{"name":"followers","reference":"m:n","cascade":["persist"],"owner":true,"pivotTable":"user_to_follower","hidden":true,"type":"User","fixedOrder":false,"joinColumns":["follower"],"inverseJoinColumns":["following"],"array":false},{"name":"followed","reference":"m:n","cascade":["persist"],"type":"User","fixedOrder":false,"array":false}],"collection":"user"},"origin":"./dist/entities/user.entity.js","hash":"a6c08be1f8338e182a288a2f2a653d82","version":"5.7.12"} +{"data":{"propertyOrder":{},"properties":{"firstName":{"name":"firstName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"middleName":{"name":"middleName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},"lastName":{"name":"lastName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},"username":{"name":"username","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},"email":{"name":"email","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},"bio":{"name":"bio","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"avatar":{"name":"avatar","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"password":{"name":"password","reference":"scalar","hidden":true,"lazy":true,"getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},"twoFactorSecret":{"name":"twoFactorSecret","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},"isTwoFactorEnabled":{"name":"isTwoFactorEnabled","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"roles":{"name":"roles","reference":"scalar","enum":false,"items":["ADMIN","AUTHOR"],"array":true,"type":"Roles[]","customType":"customType","optional":true},"mobileNumber":{"name":"mobileNumber","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},"isVerified":{"name":"isVerified","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},"posts":{"name":"posts","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"eager":false,"nullable":true,"type":"Post","array":false},"conversations":{"name":"conversations","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"users","type":"Conversation","fixedOrder":false,"array":false},"favorites":{"name":"favorites","reference":"m:n","cascade":["persist"],"hidden":true,"type":"Post","fixedOrder":false,"owner":true,"array":false},"social":{"name":"social","type":"Social","reference":"embedded","object":true,"nullable":true,"prefix":true,"array":false,"optional":true},"followers":{"name":"followers","reference":"m:n","cascade":["persist"],"owner":true,"pivotTable":"user_to_follower","hidden":true,"type":"User","fixedOrder":false,"joinColumns":["follower"],"inverseJoinColumns":["following"],"array":false},"followed":{"name":"followed","reference":"m:n","cascade":["persist"],"type":"User","fixedOrder":false,"array":false},"lastLogin":{"name":"lastLogin","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true}},"props":[{"name":"firstName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"middleName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"lastName","reference":"scalar","getter":false,"setter":false,"type":"string","array":false},{"name":"username","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"email","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false},{"name":"bio","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"avatar","reference":"scalar","getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"password","reference":"scalar","hidden":true,"lazy":true,"getter":false,"setter":false,"type":"string","columnTypes":["text"],"array":false},{"name":"twoFactorSecret","reference":"scalar","getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"isTwoFactorEnabled","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"roles","reference":"scalar","enum":false,"items":["ADMIN","AUTHOR"],"array":true,"type":"Roles[]","customType":"customType","optional":true},{"name":"mobileNumber","reference":"scalar","index":true,"unique":true,"getter":false,"setter":false,"type":"string","array":false,"optional":true},{"name":"isVerified","reference":"scalar","getter":false,"setter":false,"type":"boolean","array":false,"optional":true},{"name":"posts","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"eager":false,"nullable":true,"type":"Post","array":false},{"name":"conversations","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"users","type":"Conversation","fixedOrder":false,"array":false},{"name":"favorites","reference":"m:n","cascade":["persist"],"hidden":true,"type":"Post","fixedOrder":false,"owner":true,"array":false},{"name":"social","type":"Social","reference":"embedded","object":true,"nullable":true,"prefix":true,"array":false,"optional":true},{"name":"followers","reference":"m:n","cascade":["persist"],"owner":true,"pivotTable":"user_to_follower","hidden":true,"type":"User","fixedOrder":false,"joinColumns":["follower"],"inverseJoinColumns":["following"],"array":false},{"name":"followed","reference":"m:n","cascade":["persist"],"type":"User","fixedOrder":false,"array":false},{"name":"lastLogin","reference":"scalar","getter":false,"setter":false,"type":"Date","array":false,"optional":true}],"primaryKeys":[],"filters":{},"hooks":{"beforeUpsert":["hashPassword"],"beforeUpdate":["hashPassword"],"beforeCreate":["hashPassword"]},"indexes":[],"uniques":[],"concurrencyCheckKeys":{},"className":"User","path":"./dist/entities/user.entity.js","name":"User","abstract":false,"constructorParams":["data"],"toJsonParams":[],"extends":"BaseEntity","useCache":true,"relations":[{"name":"posts","reference":"1:m","cascade":["persist"],"orphanRemoval":true,"eager":false,"nullable":true,"type":"Post","array":false},{"name":"conversations","reference":"m:n","cascade":["persist"],"owner":true,"inversedBy":"users","type":"Conversation","fixedOrder":false,"array":false},{"name":"favorites","reference":"m:n","cascade":["persist"],"hidden":true,"type":"Post","fixedOrder":false,"owner":true,"array":false},{"name":"followers","reference":"m:n","cascade":["persist"],"owner":true,"pivotTable":"user_to_follower","hidden":true,"type":"User","fixedOrder":false,"joinColumns":["follower"],"inverseJoinColumns":["following"],"array":false},{"name":"followed","reference":"m:n","cascade":["persist"],"type":"User","fixedOrder":false,"array":false}],"collection":"user"},"origin":"./dist/entities/user.entity.js","hash":"26b91a657e2c8663fb9efafcb5989dd2","version":"5.8.9"} diff --git a/tsconfig.build.json b/tsconfig.build.json index 2946703a..f0e6f32b 100755 --- a/tsconfig.build.json +++ b/tsconfig.build.json @@ -7,6 +7,7 @@ "**/*spec.ts", "./src/common/database/factories/*", "./src/common/database/seeders/*", - "./src/_mocks_/*" + "./src/_mocks_/*", + "eslint.config.js" ] } diff --git a/tsconfig.json b/tsconfig.json index 5a928f28..e5aeae75 100755 --- a/tsconfig.json +++ b/tsconfig.json @@ -22,6 +22,7 @@ "./generated" ] }, + "declaration": true, "outDir": "dist" }, "include": [