@lyxa.ai/core 1.4.68-test-filter-container-model → 1.4.69
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/libraries/logger-kit/logger.service.d.ts +6 -6
- package/dist/libraries/logger-kit/logger.service.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/external-ref.model.d.ts +4 -0
- package/dist/libraries/mongo/models/embedded/external-ref.model.js +32 -0
- package/dist/libraries/mongo/models/embedded/external-ref.model.js.map +1 -0
- package/dist/libraries/mongo/models/filter-container.model.js +1 -1
- package/dist/libraries/mongo/models/filter-container.model.js.map +1 -1
- package/dist/libraries/mongo/models/index.d.ts +5 -0
- package/dist/libraries/mongo/models/index.js +9 -1
- package/dist/libraries/mongo/models/index.js.map +1 -1
- package/dist/libraries/mongo/models/integration-configuration.model.d.ts +5 -0
- package/dist/libraries/mongo/models/integration-configuration.model.js +33 -0
- package/dist/libraries/mongo/models/integration-configuration.model.js.map +1 -0
- package/dist/libraries/mongo/models/log.model.d.ts +2 -2
- package/dist/libraries/mongo/models/log.model.js.map +1 -1
- package/dist/libraries/mongo/models/product.model.d.ts +3 -1
- package/dist/libraries/mongo/models/product.model.js +6 -0
- package/dist/libraries/mongo/models/product.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/service-package.review.model.d.ts +8 -0
- package/dist/libraries/mongo/models/providers/service-package.review.model.js +26 -0
- package/dist/libraries/mongo/models/providers/service-package.review.model.js.map +1 -0
- package/dist/types/README.md +1 -1
- package/dist/types/package.json +1 -1
- package/dist/types/utilities/enum.d.ts +2 -1
- package/dist/types/utilities/enum.js +1 -0
- package/dist/types/utilities/enum.js.map +1 -1
- package/dist/utilities/enum.d.ts +2 -1
- package/dist/utilities/enum.js +1 -0
- package/dist/utilities/enum.js.map +1 -1
- package/package.json +7 -4
|
@@ -35,7 +35,7 @@ export declare class LyxaLoggerKit {
|
|
|
35
35
|
private consoleLog;
|
|
36
36
|
private write;
|
|
37
37
|
info(message: string, options: {
|
|
38
|
-
tag: LogTag;
|
|
38
|
+
tag: LogTag | string;
|
|
39
39
|
data?: Record<string, any>;
|
|
40
40
|
metadata?: LogMetadata;
|
|
41
41
|
request?: Record<string, any>;
|
|
@@ -47,7 +47,7 @@ export declare class LyxaLoggerKit {
|
|
|
47
47
|
__v: number;
|
|
48
48
|
}, "typegooseName"> & import("@typegoose/typegoose/lib/types").IObjectWithTypegooseFunction)>;
|
|
49
49
|
debug(message: string, options: {
|
|
50
|
-
tag: LogTag;
|
|
50
|
+
tag: LogTag | string;
|
|
51
51
|
data?: Record<string, any>;
|
|
52
52
|
metadata?: LogMetadata;
|
|
53
53
|
request?: Record<string, any>;
|
|
@@ -59,7 +59,7 @@ export declare class LyxaLoggerKit {
|
|
|
59
59
|
__v: number;
|
|
60
60
|
}, "typegooseName"> & import("@typegoose/typegoose/lib/types").IObjectWithTypegooseFunction)>;
|
|
61
61
|
warn(message: string, options: {
|
|
62
|
-
tag: LogTag;
|
|
62
|
+
tag: LogTag | string;
|
|
63
63
|
data?: Record<string, any>;
|
|
64
64
|
metadata?: LogMetadata;
|
|
65
65
|
request?: Record<string, any>;
|
|
@@ -71,7 +71,7 @@ export declare class LyxaLoggerKit {
|
|
|
71
71
|
__v: number;
|
|
72
72
|
}, "typegooseName"> & import("@typegoose/typegoose/lib/types").IObjectWithTypegooseFunction)>;
|
|
73
73
|
error(message: string, error: TRPCError | Error | unknown, options: {
|
|
74
|
-
tag: LogTag;
|
|
74
|
+
tag: LogTag | string;
|
|
75
75
|
data?: Record<string, any>;
|
|
76
76
|
metadata?: LogMetadata;
|
|
77
77
|
context?: RequestContext;
|
|
@@ -84,7 +84,7 @@ export declare class LyxaLoggerKit {
|
|
|
84
84
|
__v: number;
|
|
85
85
|
}, "typegooseName"> & import("@typegoose/typegoose/lib/types").IObjectWithTypegooseFunction)>;
|
|
86
86
|
fatal(message: string, error: TRPCError | Error | unknown, options: {
|
|
87
|
-
tag: LogTag;
|
|
87
|
+
tag: LogTag | string;
|
|
88
88
|
data?: Record<string, any>;
|
|
89
89
|
metadata?: LogMetadata;
|
|
90
90
|
context?: RequestContext;
|
|
@@ -99,7 +99,7 @@ export declare class LyxaLoggerKit {
|
|
|
99
99
|
private getHttpLogLevel;
|
|
100
100
|
httpRequest(method: string, url: string, statusCode: HttpStatus, durationMs: number, userId?: string): void;
|
|
101
101
|
child(defaultContext: {
|
|
102
|
-
tag?: LogTag;
|
|
102
|
+
tag?: LogTag | string;
|
|
103
103
|
data?: Record<string, any>;
|
|
104
104
|
metadata?: LogMetadata;
|
|
105
105
|
request?: Record<string, any>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"logger.service.js","sourceRoot":"/","sources":["libraries/logger-kit/logger.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAicA,gDAUC;AA3cD,4CAAoB;AACpB,gDAAwB;AACxB,mCAAiC;AACjC,4CAAsD;AACtD,+CAAoE;AAEpE,uDAAqD;AACrD,wDAAgC;AASnB,QAAA,cAAc,GAAG,IAAI,oCAAiB,EAAgB,CAAC;AAW7D,IAAM,aAAa,GAAnB,MAAM,aAAa;IACR,KAAK,CAAoC;IACzC,MAAM,CAAyB;IAEhD,YAAY,MAAoB;QAC/B,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC;QAC3C,IAAI,CAAC,KAAK,GAAG,IAAA,uBAAc,EAAC,EAAE,OAAO,EAAE,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC,CAAC;QAC9D,IAAI,CAAC,kBAAkB,EAAE,CAAC;IAC3B,CAAC;IAEO,eAAe,CAAC,MAAoB;QAC3C,OAAO;YACN,YAAY,EAAE,MAAM,CAAC,YAAY;YACjC,OAAO,EAAE,MAAM,CAAC,OAAO,IAAI,CAAC;YAC5B,YAAY,EAAE,MAAM,CAAC,YAAY,IAAI,OAAO,CAAC,GAAG,CAAC,kBAAkB,KAAK,MAAM;YAC9E,YA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AC,KAAK,CAAC,OAAO,EAAE,KAAK,EAAE;gBAC1B,GAAG,EAAE,IAAI,CAAC,GAAG,IAAI,cAAc,CAAC,GAAG,IAAI,aAAM,CAAC,YAAY;gBAC1D,IAAI,EAAE,EAAE,GAAG,cAAc,CAAC,IAAI,EAAE,GAAG,IAAI,CAAC,IAAI,EAAE;gBAC9C,QAAQ,EAAE,EAAE,GAAG,cAAc,CAAC,QAAQ,EAAE,GAAG,IAAI,CAAC,QAAQ,EAAE;gBAC1D,OAAO,EAAE,IAAI,CAAC,OAAO,IAAI,cAAc,CAAC,OAAO;gBAC/C,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,cAAc,CAAC,QAAQ;gBAClD,MAAM,EAAE,IAAI,CAAC,MAAM,IAAI,cAAc,CAAC,MAAM;aAC5C,CAAC;SACH,CAAC;IACH,CAAC;CACD,CAAA;AApaY,sCAAa;wBAAb,aAAa;IADzB,IAAA,gBAAO,GAAE;;GACG,aAAa,CAoazB;AAED,SAAgB,kBAAkB,CAAI,KAAmB,EAAE,EAAwB;IAClF,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;QACtC,sBAAc,CAAC,GAAG,CAAC,KAAK,EAAE,KAAK,IAAI,EAAE;YACpC,IAAI,CAAC;gBACJ,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;YACrB,CAAC;YAAC,OAAO,GAAG,EAAE,CAAC;gBACd,MAAM,CAAC,GAAG,CAAC,CAAC;YACb,CAAC;QACF,CAAC,CAAC,CAAC;IACJ,CAAC,CAAC,CAAC;AACJ,CAAC","sourcesContent":["import fs from 'fs';\nimport path from 'path';\nimport { Service } from 'typedi';\nimport { createLogModel, Log } from '../mongo/models';\nimport { HttpStatus, LogLevel, LogTag } from '../../utilities/enum';\nimport { ErrorInfo, LogMetadata, RequestContext } from './types';\nimport { AsyncLocalStorage } from 'node:async_hooks';\nimport mongoose from 'mongoose';\nimport { TRPCError } from '@trpc/server';\n\ninterface RequestStore {\n\trequestId?: string;\n\tuserId?: string;\n\tmetadata?: Record<string, unknown>;\n}\n\nexport const requestContext = new AsyncLocalStorage<RequestStore>();\n\ninterface LoggerConfig {\n\tinstanceType: string;\n\tttlDays?: number;\n\tpersistDebug?: boolean;\n\tlogDirectory?: string;\n\tenvironment?: string;\n}\n\n@Service()\nexport class LyxaLoggerKit {\n\tprivate readonly model: ReturnType<typeof createLogModel>;\n\tprivate readonly config: Required<LoggerConfig>;\n\n\tconstructor(config: LoggerConfig) {\n\t\tthis.config = this.normalizeConfig(config);\n\t\tthis.model = createLogModel({ ttlDays: this.config.ttlDays });\n\t\tthis.ensureLogDirectory();\n\t}\n\n\tprivate normalizeConfig(config: LoggerConfig): Required<LoggerConfig> {\n\t\treturn {\n\t\t\tinstanceType: config.instanceType,\n\t\t\tttlDays: config.ttlDays ?? 7,\n\t\t\tpersistDebug: config.persistDebug ?? process.env.PERSIST_DEBUG_LOGS === 'true',\n\t\t\tlogDirectory: config.logDirectory ?? 'logs',\n\t\t\tenvironment: config.environment ?? process.env.NODE_ENV ?? 'development',\n\t\t};\n\t}\n\n\tprivate ensureLogDirectory(): void {\n\t\tconst logPath = path.join(process.cwd(), this.config.logDirectory);\n\t\tfs.mkdirSync(logPath, { recursive: true });\n\t}\n\n\tprivate getRequestStore(): RequestStore {\n\t\treturn requestContext.getStore() ?? {};\n\t}\n\n\tprivate enrichWithContext(data: Record<string, any> = {}): Record<string, any> {\n\t\tconst store = this.getRequestStore();\n\t\treturn {\n\t\t\t...data,\n\t\t\t...(store.requestId && { requestId: store.requestId }),\n\t\t\t...(store.userId && { userId: store.userId }),\n\t\t};\n\t}\n\n\tprivate shouldPersist(level: LogLevel): boolean {\n\t\t// return level !== LogLevel.DEBUG || this.config.persistDebug;\n\t\treturn true;\n\t}\n\n\tprivate async persistLog(log: Partial<Log>) {\n\t\tconst currentDebug = mongoose.get('debug');\n\t\ttry {\n\t\t\tmongoose.set('debug', false);\n\t\t\treturn await this.model.create({\n\t\t\t\t...log,\n\t\t\t\tmicroService: this.config.instanceType,\n\t\t\t\ttimestamp: new Date(),\n\t\t\t});\n\t\t} catch (err) {\n\t\t\tconsole.error('[Logger] MongoDB persistence failed:', err);\n\t\t} finally {\n\t\t\tmongoose.set('debug', currentDebug);\n\t\t}\n\t}\n\n\tprivate normalizeError(error: TRPCError | Error | unknown): ErrorInfo {\n\t\tif (error instanceof Error) {\n\t\t\treturn {\n\t\t\t\tname: error.name,\n\t\t\t\tmessage: error.message,\n\t\t\t\tstacktrace: error.stack?.split('\\n').map(line => line.trim()),\n\t\t\t\tcode: (error as any).code,\n\t\t\t};\n\t\t}\n\t\tif (typeof error === 'object' && error !== null) {\n\t\t\tconst err = error as any;\n\t\t\treturn {\n\t\t\t\tname: err.name,\n\t\t\t\tmessage: err.message,\n\t\t\t\tstacktrace: err.stack?.split('\\n').map((line: string) => line.trim()) || err.stacktrace,\n\t\t\t\tcode: err.code,\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\tmessage: String(error),\n\t\t};\n\t}\n\n\tprivate buildLogEntry(\n\t\tmessage: string,\n\t\tpayload: {\n\t\t\ttag: LogTag;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\terror?: ErrorInfo;\n\t\t\tcontext?: RequestContext;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\tconst store = this.getRequestStore();\n\n\t\treturn {\n\t\t\ttag: payload.tag,\n\t\t\tmessage,\n\t\t\tdata: this.enrichWithContext(payload.data),\n\t\t\tmetadata: {\n\t\t\t\t...payload.metadata,\n\t\t\t\t...store.metadata,\n\t\t\t},\n\t\t\terror: payload.error,\n\t\t\tcontext: payload.context,\n\t\t\trequestId: store.requestId,\n\t\t\trequest: payload.request,\n\t\t\tresponse: payload.response,\n\t\t\tstatus: payload.status,\n\t\t};\n\t}\n\n\tprivate getColorCode(level: LogLevel): string {\n\t\tswitch (level) {\n\t\t\tcase LogLevel.DEBUG:\n\t\t\t\treturn '\\x1b[96m'; // Cyan\n\t\t\tcase LogLevel.INFO:\n\t\t\t\treturn '\\x1b[32m'; // Green\n\t\t\tcase LogLevel.WARN:\n\t\t\t\treturn '\\x1b[33m'; // Yellow\n\t\t\tcase LogLevel.ERROR:\n\t\t\t\treturn '\\x1b[31m'; // Red\n\t\t\tcase LogLevel.FATAL:\n\t\t\t\treturn '\\x1b[35m'; // Magenta\n\t\t\tdefault:\n\t\t\t\treturn '\\x1b[37m'; // White\n\t\t}\n\t}\n\n\tprivate formatTimestamp(date: Date): string {\n\t\tconst year = date.getFullYear();\n\t\tconst month = String(date.getMonth() + 1).padStart(2, '0');\n\t\tconst day = String(date.getDate()).padStart(2, '0');\n\t\tconst hours = String(date.getHours()).padStart(2, '0');\n\t\tconst minutes = String(date.getMinutes()).padStart(2, '0');\n\t\tconst seconds = String(date.getSeconds()).padStart(2, '0');\n\n\t\treturn `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;\n\t}\n\n\tprivate formatLogMessage(level: LogLevel, message: string, entry: any): string {\n\t\tconst timestamp = this.formatTimestamp(new Date());\n\t\tconst tag = (entry.tag || 'GENERAL').toUpperCase();\n\t\tconst levelUpper = level.toUpperCase();\n\n\t\t// ANSI color codes\n\t\tconst grey = '\\x1b[90m';\n\t\tconst cyan = '\\x1b[36m';\n\t\tconst levelColor = this.getColorCode(level);\n\t\tconst reset = '\\x1b[0m';\n\n\t\t// Pad level to 5 characters for alignment (DEBUG, INFO, WARN, ERROR, FATAL)\n\t\tconst paddedLevel = levelUpper.padEnd(5);\n\n\t\tconst parts = [\n\t\t\t`${grey}[${timestamp}]${reset}`,\n\t\t\t`${levelColor}[${levelUpper}]${reset}`,\n\t\t\t`${cyan}[${tag}]${reset}`,\n\t\t\tmessage,\n\t\t];\n\n\t\treturn parts.join(' ');\n\t}\n\n\tprivate consoleLog(level: LogLevel, formattedMessage: string, entry: any): void {\n\t\tswitch (level) {\n\t\t\tcase LogLevel.DEBUG:\n\t\t\t\tconsole.log(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.log(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase LogLevel.INFO:\n\t\t\t\tconsole.log(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.log(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase LogLevel.WARN:\n\t\t\t\tconsole.warn(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.warn(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase LogLevel.ERROR:\n\t\t\t\tconsole.error(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.error(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase LogLevel.FATAL:\n\t\t\t\tconsole.error(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.error(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\tconsole.log(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.log(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\t}\n\n\tprivate async write(\n\t\tlevel: LogLevel,\n\t\tmessage: string,\n\t\tpayload: {\n\t\t\ttag: LogTag;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\terror?: ErrorInfo;\n\t\t\tcontext?: RequestContext;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t},\n\t\topts: { shouldWrite?: boolean } = {}\n\t) {\n\t\tconst { shouldWrite = true } = opts;\n\t\tconst entry = this.buildLogEntry(message, payload);\n\n\t\t// Console logging with switch case\n\t\tif (shouldWrite) {\n\t\t\tconst formattedMessage = this.formatLogMessage(level, message, entry);\n\t\t\tthis.consoleLog(level, formattedMessage, entry);\n\t\t}\n\n\t\t// Async persistence (fire-and-forget)\n\t\tif (this.shouldPersist(level)) {\n\t\t\treturn this.persistLog({\n\t\t\t\tlevel,\n\t\t\t\ttag: payload.tag,\n\t\t\t\tmessage,\n\t\t\t\tdata: entry.data,\n\t\t\t\tmetadata: entry.metadata ?? {},\n\t\t\t\terror: payload.error,\n\t\t\t\trequestId: entry.requestId,\n\t\t\t\tcontext: payload.context,\n\t\t\t\trequest: payload.request,\n\t\t\t\tresponse: payload.response,\n\t\t\t\tstatus: payload.status,\n\t\t\t}).catch(e => {\n\t\t\t\tconsole.error('Something went wrong', e);\n\t\t\t});\n\t\t}\n\t}\n\n\t/* ---------------------------------- */\n\t/* Public Logging API */\n\t/* ---------------------------------- */\n\n\tinfo(\n\t\tmessage: string,\n\t\toptions: {\n\t\t\ttag: LogTag;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.INFO, message, options);\n\t}\n\n\tdebug(\n\t\tmessage: string,\n\t\toptions: {\n\t\t\ttag: LogTag;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.DEBUG, message, options);\n\t}\n\n\twarn(\n\t\tmessage: string,\n\t\toptions: {\n\t\t\ttag: LogTag;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.WARN, message, options);\n\t}\n\n\terror(\n\t\tmessage: string,\n\t\terror: TRPCError | Error | unknown,\n\t\toptions: {\n\t\t\ttag: LogTag;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\tcontext?: RequestContext;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.ERROR, message, {\n\t\t\t...options,\n\t\t\terror: this.normalizeError(error),\n\t\t});\n\t}\n\n\tfatal(\n\t\tmessage: string,\n\t\terror: TRPCError | Error | unknown,\n\t\toptions: {\n\t\t\ttag: LogTag;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\tcontext?: RequestContext;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.FATAL, message, {\n\t\t\t...options,\n\t\t\terror: this.normalizeError(error),\n\t\t});\n\t}\n\n\t/* ---------------------------------- */\n\t/* HTTP Convenience Methods */\n\t/* ---------------------------------- */\n\n\tprivate getHttpLogLevel(statusCode: number): LogLevel {\n\t\tif (statusCode >= 500) return LogLevel.ERROR;\n\t\tif (statusCode >= 400) return LogLevel.WARN;\n\t\treturn LogLevel.INFO;\n\t}\n\n\thttpRequest(method: string, url: string, statusCode: HttpStatus, durationMs: number, userId?: string): void {\n\t\tthis.write(this.getHttpLogLevel(statusCode), 'HTTP request completed', {\n\t\t\ttag: LogTag.HTTP_REQUEST,\n\t\t\tdata: {\n\t\t\t\tmethod,\n\t\t\t\turl,\n\t\t\t\tdurationMs,\n\t\t\t\t...(userId && { userId }),\n\t\t\t},\n\t\t\tmetadata: {\n\t\t\t\t...(userId && { userId }),\n\t\t\t\tresponseTime: durationMs,\n\t\t\t},\n\t\t\tcontext: { method, url },\n\t\t\tstatus: statusCode,\n\t\t});\n\t}\n\n\tchild(defaultContext: {\n\t\ttag?: LogTag;\n\t\tdata?: Record<string, any>;\n\t\tmetadata?: LogMetadata;\n\t\trequest?: Record<string, any>;\n\t\tresponse?: Record<string, any>;\n\t\tstatus?: HttpStatus;\n\t}): {\n\t\tinfo: (message: string, options?: Partial<typeof defaultContext>) => void;\n\t\tdebug: (message: string, options?: Partial<typeof defaultContext>) => void;\n\t\twarn: (message: string, options?: Partial<typeof defaultContext>) => void;\n\t\terror: (message: string, error: Error | ErrorInfo, options?: Partial<typeof defaultContext>) => void;\n\t} {\n\t\treturn {\n\t\t\tinfo: (message, opts = {}) =>\n\t\t\t\tthis.info(message, {\n\t\t\t\t\ttag: opts.tag ?? defaultContext.tag ?? LogTag.HTTP_REQUEST,\n\t\t\t\t\tdata: { ...defaultContext.data, ...opts.data },\n\t\t\t\t\tmetadata: { ...defaultContext.metadata, ...opts.metadata },\n\t\t\t\t\trequest: opts.request ?? defaultContext.request,\n\t\t\t\t\tresponse: opts.response ?? defaultContext.response,\n\t\t\t\t\tstatus: opts.status ?? defaultContext.status,\n\t\t\t\t}),\n\t\t\tdebug: (message, opts = {}) =>\n\t\t\t\tthis.debug(message, {\n\t\t\t\t\ttag: opts.tag ?? defaultContext.tag ?? LogTag.HTTP_REQUEST,\n\t\t\t\t\tdata: { ...defaultContext.data, ...opts.data },\n\t\t\t\t\tmetadata: { ...defaultContext.metadata, ...opts.metadata },\n\t\t\t\t\trequest: opts.request ?? defaultContext.request,\n\t\t\t\t\tresponse: opts.response ?? defaultContext.response,\n\t\t\t\t\tstatus: opts.status ?? defaultContext.status,\n\t\t\t\t}),\n\t\t\twarn: (message, opts = {}) =>\n\t\t\t\tthis.warn(message, {\n\t\t\t\t\ttag: opts.tag ?? defaultContext.tag ?? LogTag.HTTP_REQUEST,\n\t\t\t\t\tdata: { ...defaultContext.data, ...opts.data },\n\t\t\t\t\tmetadata: { ...defaultContext.metadata, ...opts.metadata },\n\t\t\t\t\trequest: opts.request ?? defaultContext.request,\n\t\t\t\t\tresponse: opts.response ?? defaultContext.response,\n\t\t\t\t\tstatus: opts.status ?? defaultContext.status,\n\t\t\t\t}),\n\t\t\terror: (message, error, opts = {}) =>\n\t\t\t\tthis.error(message, error, {\n\t\t\t\t\ttag: opts.tag ?? defaultContext.tag ?? LogTag.HTTP_REQUEST,\n\t\t\t\t\tdata: { ...defaultContext.data, ...opts.data },\n\t\t\t\t\tmetadata: { ...defaultContext.metadata, ...opts.metadata },\n\t\t\t\t\trequest: opts.request ?? defaultContext.request,\n\t\t\t\t\tresponse: opts.response ?? defaultContext.response,\n\t\t\t\t\tstatus: opts.status ?? defaultContext.status,\n\t\t\t\t}),\n\t\t};\n\t}\n}\n\nexport function withRequestContext<T>(store: RequestStore, fn: () => T | Promise<T>): Promise<T> {\n\treturn new Promise((resolve, reject) => {\n\t\trequestContext.run(store, async () => {\n\t\t\ttry {\n\t\t\t\tresolve(await fn());\n\t\t\t} catch (err) {\n\t\t\t\treject(err);\n\t\t\t}\n\t\t});\n\t});\n}"]}
|
|
1
|
+
{"version":3,"file":"logger.service.js","sourceRoot":"/","sources":["libraries/logger-kit/logger.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAicA,gDAUC;AA3cD,4CAAoB;AACpB,gDAAwB;AACxB,mCAAiC;AACjC,4CAAsD;AACtD,+CAAoE;AAEpE,uDAAqD;AACrD,wDAAgC;AASnB,QAAA,cAAc,GAAG,IAAI,oCAAiB,EAAgB,CAAC;AAW7D,IAAM,aAAa,GAAnB,MAAM,aAAa;IACR,KAAK,CAAoC;IACzC,MAAM,CAAyB;IAEhD,YAAY,MAAoB;QAC/B,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC;QAC3C,IAAI,CAAC,KAAK,GAAG,IAAA,uBAAc,EAAC,EAAE,OAAO,EAAE,I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AAG,CAAC,CAAC;YACb,CAAC;QACF,CAAC,CAAC,CAAC;IACJ,CAAC,CAAC,CAAC;AACJ,CAAC","sourcesContent":["import fs from 'fs';\nimport path from 'path';\nimport { Service } from 'typedi';\nimport { createLogModel, Log } from '../mongo/models';\nimport { HttpStatus, LogLevel, LogTag } from '../../utilities/enum';\nimport { ErrorInfo, LogMetadata, RequestContext } from './types';\nimport { AsyncLocalStorage } from 'node:async_hooks';\nimport mongoose from 'mongoose';\nimport { TRPCError } from '@trpc/server';\n\ninterface RequestStore {\n\trequestId?: string;\n\tuserId?: string;\n\tmetadata?: Record<string, unknown>;\n}\n\nexport const requestContext = new AsyncLocalStorage<RequestStore>();\n\ninterface LoggerConfig {\n\tinstanceType: string;\n\tttlDays?: number;\n\tpersistDebug?: boolean;\n\tlogDirectory?: string;\n\tenvironment?: string;\n}\n\n@Service()\nexport class LyxaLoggerKit {\n\tprivate readonly model: ReturnType<typeof createLogModel>;\n\tprivate readonly config: Required<LoggerConfig>;\n\n\tconstructor(config: LoggerConfig) {\n\t\tthis.config = this.normalizeConfig(config);\n\t\tthis.model = createLogModel({ ttlDays: this.config.ttlDays });\n\t\tthis.ensureLogDirectory();\n\t}\n\n\tprivate normalizeConfig(config: LoggerConfig): Required<LoggerConfig> {\n\t\treturn {\n\t\t\tinstanceType: config.instanceType,\n\t\t\tttlDays: config.ttlDays ?? 7,\n\t\t\tpersistDebug: config.persistDebug ?? process.env.PERSIST_DEBUG_LOGS === 'true',\n\t\t\tlogDirectory: config.logDirectory ?? 'logs',\n\t\t\tenvironment: config.environment ?? process.env.NODE_ENV ?? 'development',\n\t\t};\n\t}\n\n\tprivate ensureLogDirectory(): void {\n\t\tconst logPath = path.join(process.cwd(), this.config.logDirectory);\n\t\tfs.mkdirSync(logPath, { recursive: true });\n\t}\n\n\tprivate getRequestStore(): RequestStore {\n\t\treturn requestContext.getStore() ?? {};\n\t}\n\n\tprivate enrichWithContext(data: Record<string, any> = {}): Record<string, any> {\n\t\tconst store = this.getRequestStore();\n\t\treturn {\n\t\t\t...data,\n\t\t\t...(store.requestId && { requestId: store.requestId }),\n\t\t\t...(store.userId && { userId: store.userId }),\n\t\t};\n\t}\n\n\tprivate shouldPersist(level: LogLevel): boolean {\n\t\t// return level !== LogLevel.DEBUG || this.config.persistDebug;\n\t\treturn true;\n\t}\n\n\tprivate async persistLog(log: Partial<Log>) {\n\t\tconst currentDebug = mongoose.get('debug');\n\t\ttry {\n\t\t\tmongoose.set('debug', false);\n\t\t\treturn await this.model.create({\n\t\t\t\t...log,\n\t\t\t\tmicroService: this.config.instanceType,\n\t\t\t\ttimestamp: new Date(),\n\t\t\t});\n\t\t} catch (err) {\n\t\t\tconsole.error('[Logger] MongoDB persistence failed:', err);\n\t\t} finally {\n\t\t\tmongoose.set('debug', currentDebug);\n\t\t}\n\t}\n\n\tprivate normalizeError(error: TRPCError | Error | unknown): ErrorInfo {\n\t\tif (error instanceof Error) {\n\t\t\treturn {\n\t\t\t\tname: error.name,\n\t\t\t\tmessage: error.message,\n\t\t\t\tstacktrace: error.stack?.split('\\n').map(line => line.trim()),\n\t\t\t\tcode: (error as any).code,\n\t\t\t};\n\t\t}\n\t\tif (typeof error === 'object' && error !== null) {\n\t\t\tconst err = error as any;\n\t\t\treturn {\n\t\t\t\tname: err.name,\n\t\t\t\tmessage: err.message,\n\t\t\t\tstacktrace: err.stack?.split('\\n').map((line: string) => line.trim()) || err.stacktrace,\n\t\t\t\tcode: err.code,\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\tmessage: String(error),\n\t\t};\n\t}\n\n\tprivate buildLogEntry(\n\t\tmessage: string,\n\t\tpayload: {\n\t\t\ttag: LogTag | string;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\terror?: ErrorInfo;\n\t\t\tcontext?: RequestContext;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\tconst store = this.getRequestStore();\n\n\t\treturn {\n\t\t\ttag: payload.tag,\n\t\t\tmessage,\n\t\t\tdata: this.enrichWithContext(payload.data),\n\t\t\tmetadata: {\n\t\t\t\t...payload.metadata,\n\t\t\t\t...store.metadata,\n\t\t\t},\n\t\t\terror: payload.error,\n\t\t\tcontext: payload.context,\n\t\t\trequestId: store.requestId,\n\t\t\trequest: payload.request,\n\t\t\tresponse: payload.response,\n\t\t\tstatus: payload.status,\n\t\t};\n\t}\n\n\tprivate getColorCode(level: LogLevel): string {\n\t\tswitch (level) {\n\t\t\tcase LogLevel.DEBUG:\n\t\t\t\treturn '\\x1b[96m'; // Cyan\n\t\t\tcase LogLevel.INFO:\n\t\t\t\treturn '\\x1b[32m'; // Green\n\t\t\tcase LogLevel.WARN:\n\t\t\t\treturn '\\x1b[33m'; // Yellow\n\t\t\tcase LogLevel.ERROR:\n\t\t\t\treturn '\\x1b[31m'; // Red\n\t\t\tcase LogLevel.FATAL:\n\t\t\t\treturn '\\x1b[35m'; // Magenta\n\t\t\tdefault:\n\t\t\t\treturn '\\x1b[37m'; // White\n\t\t}\n\t}\n\n\tprivate formatTimestamp(date: Date): string {\n\t\tconst year = date.getFullYear();\n\t\tconst month = String(date.getMonth() + 1).padStart(2, '0');\n\t\tconst day = String(date.getDate()).padStart(2, '0');\n\t\tconst hours = String(date.getHours()).padStart(2, '0');\n\t\tconst minutes = String(date.getMinutes()).padStart(2, '0');\n\t\tconst seconds = String(date.getSeconds()).padStart(2, '0');\n\n\t\treturn `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;\n\t}\n\n\tprivate formatLogMessage(level: LogLevel, message: string, entry: any): string {\n\t\tconst timestamp = this.formatTimestamp(new Date());\n\t\tconst tag = (entry.tag || 'GENERAL').toUpperCase();\n\t\tconst levelUpper = level.toUpperCase();\n\n\t\t// ANSI color codes\n\t\tconst grey = '\\x1b[90m';\n\t\tconst cyan = '\\x1b[36m';\n\t\tconst levelColor = this.getColorCode(level);\n\t\tconst reset = '\\x1b[0m';\n\n\t\t// Pad level to 5 characters for alignment (DEBUG, INFO, WARN, ERROR, FATAL)\n\t\tconst paddedLevel = levelUpper.padEnd(5);\n\n\t\tconst parts = [\n\t\t\t`${grey}[${timestamp}]${reset}`,\n\t\t\t`${levelColor}[${levelUpper}]${reset}`,\n\t\t\t`${cyan}[${tag}]${reset}`,\n\t\t\tmessage,\n\t\t];\n\n\t\treturn parts.join(' ');\n\t}\n\n\tprivate consoleLog(level: LogLevel, formattedMessage: string, entry: any): void {\n\t\tswitch (level) {\n\t\t\tcase LogLevel.DEBUG:\n\t\t\t\tconsole.log(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.log(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase LogLevel.INFO:\n\t\t\t\tconsole.log(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.log(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase LogLevel.WARN:\n\t\t\t\tconsole.warn(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.warn(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase LogLevel.ERROR:\n\t\t\t\tconsole.error(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.error(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase LogLevel.FATAL:\n\t\t\t\tconsole.error(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.error(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\tconsole.log(formattedMessage);\n\t\t\t\tif (entry.data && Object.keys(entry.data).length > 0) {\n\t\t\t\t\tconsole.log(entry.data);\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\t}\n\n\tprivate async write(\n\t\tlevel: LogLevel,\n\t\tmessage: string,\n\t\tpayload: {\n\t\t\ttag: LogTag | string;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\terror?: ErrorInfo;\n\t\t\tcontext?: RequestContext;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t},\n\t\topts: { shouldWrite?: boolean } = {}\n\t) {\n\t\tconst { shouldWrite = true } = opts;\n\t\tconst entry = this.buildLogEntry(message, payload);\n\n\t\t// Console logging with switch case\n\t\tif (shouldWrite) {\n\t\t\tconst formattedMessage = this.formatLogMessage(level, message, entry);\n\t\t\tthis.consoleLog(level, formattedMessage, entry);\n\t\t}\n\n\t\t// Async persistence (fire-and-forget)\n\t\tif (this.shouldPersist(level)) {\n\t\t\treturn this.persistLog({\n\t\t\t\tlevel,\n\t\t\t\ttag: payload.tag,\n\t\t\t\tmessage,\n\t\t\t\tdata: entry.data,\n\t\t\t\tmetadata: entry.metadata ?? {},\n\t\t\t\terror: payload.error,\n\t\t\t\trequestId: entry.requestId,\n\t\t\t\tcontext: payload.context,\n\t\t\t\trequest: payload.request,\n\t\t\t\tresponse: payload.response,\n\t\t\t\tstatus: payload.status,\n\t\t\t}).catch(e => {\n\t\t\t\tconsole.error('Something went wrong', e);\n\t\t\t});\n\t\t}\n\t}\n\n\t/* ---------------------------------- */\n\t/* Public Logging API */\n\t/* ---------------------------------- */\n\n\tinfo(\n\t\tmessage: string,\n\t\toptions: {\n\t\t\ttag: LogTag | string;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.INFO, message, options);\n\t}\n\n\tdebug(\n\t\tmessage: string,\n\t\toptions: {\n\t\t\ttag: LogTag | string;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.DEBUG, message, options);\n\t}\n\n\twarn(\n\t\tmessage: string,\n\t\toptions: {\n\t\t\ttag: LogTag | string;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.WARN, message, options);\n\t}\n\n\terror(\n\t\tmessage: string,\n\t\terror: TRPCError | Error | unknown,\n\t\toptions: {\n\t\t\ttag: LogTag | string;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\tcontext?: RequestContext;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.ERROR, message, {\n\t\t\t...options,\n\t\t\terror: this.normalizeError(error),\n\t\t});\n\t}\n\n\tfatal(\n\t\tmessage: string,\n\t\terror: TRPCError | Error | unknown,\n\t\toptions: {\n\t\t\ttag: LogTag | string;\n\t\t\tdata?: Record<string, any>;\n\t\t\tmetadata?: LogMetadata;\n\t\t\tcontext?: RequestContext;\n\t\t\trequest?: Record<string, any>;\n\t\t\tresponse?: Record<string, any>;\n\t\t\tstatus?: HttpStatus;\n\t\t}\n\t) {\n\t\treturn this.write(LogLevel.FATAL, message, {\n\t\t\t...options,\n\t\t\terror: this.normalizeError(error),\n\t\t});\n\t}\n\n\t/* ---------------------------------- */\n\t/* HTTP Convenience Methods */\n\t/* ---------------------------------- */\n\n\tprivate getHttpLogLevel(statusCode: number): LogLevel {\n\t\tif (statusCode >= 500) return LogLevel.ERROR;\n\t\tif (statusCode >= 400) return LogLevel.WARN;\n\t\treturn LogLevel.INFO;\n\t}\n\n\thttpRequest(method: string, url: string, statusCode: HttpStatus, durationMs: number, userId?: string): void {\n\t\tthis.write(this.getHttpLogLevel(statusCode), 'HTTP request completed', {\n\t\t\ttag: LogTag.HTTP_REQUEST,\n\t\t\tdata: {\n\t\t\t\tmethod,\n\t\t\t\turl,\n\t\t\t\tdurationMs,\n\t\t\t\t...(userId && { userId }),\n\t\t\t},\n\t\t\tmetadata: {\n\t\t\t\t...(userId && { userId }),\n\t\t\t\tresponseTime: durationMs,\n\t\t\t},\n\t\t\tcontext: { method, url },\n\t\t\tstatus: statusCode,\n\t\t});\n\t}\n\n\tchild(defaultContext: {\n\t\ttag?: LogTag | string;\n\t\tdata?: Record<string, any>;\n\t\tmetadata?: LogMetadata;\n\t\trequest?: Record<string, any>;\n\t\tresponse?: Record<string, any>;\n\t\tstatus?: HttpStatus;\n\t}): {\n\t\tinfo: (message: string, options?: Partial<typeof defaultContext>) => void;\n\t\tdebug: (message: string, options?: Partial<typeof defaultContext>) => void;\n\t\twarn: (message: string, options?: Partial<typeof defaultContext>) => void;\n\t\terror: (message: string, error: Error | ErrorInfo, options?: Partial<typeof defaultContext>) => void;\n\t} {\n\t\treturn {\n\t\t\tinfo: (message, opts = {}) =>\n\t\t\t\tthis.info(message, {\n\t\t\t\t\ttag: opts.tag ?? defaultContext.tag ?? LogTag.HTTP_REQUEST,\n\t\t\t\t\tdata: { ...defaultContext.data, ...opts.data },\n\t\t\t\t\tmetadata: { ...defaultContext.metadata, ...opts.metadata },\n\t\t\t\t\trequest: opts.request ?? defaultContext.request,\n\t\t\t\t\tresponse: opts.response ?? defaultContext.response,\n\t\t\t\t\tstatus: opts.status ?? defaultContext.status,\n\t\t\t\t}),\n\t\t\tdebug: (message, opts = {}) =>\n\t\t\t\tthis.debug(message, {\n\t\t\t\t\ttag: opts.tag ?? defaultContext.tag ?? LogTag.HTTP_REQUEST,\n\t\t\t\t\tdata: { ...defaultContext.data, ...opts.data },\n\t\t\t\t\tmetadata: { ...defaultContext.metadata, ...opts.metadata },\n\t\t\t\t\trequest: opts.request ?? defaultContext.request,\n\t\t\t\t\tresponse: opts.response ?? defaultContext.response,\n\t\t\t\t\tstatus: opts.status ?? defaultContext.status,\n\t\t\t\t}),\n\t\t\twarn: (message, opts = {}) =>\n\t\t\t\tthis.warn(message, {\n\t\t\t\t\ttag: opts.tag ?? defaultContext.tag ?? LogTag.HTTP_REQUEST,\n\t\t\t\t\tdata: { ...defaultContext.data, ...opts.data },\n\t\t\t\t\tmetadata: { ...defaultContext.metadata, ...opts.metadata },\n\t\t\t\t\trequest: opts.request ?? defaultContext.request,\n\t\t\t\t\tresponse: opts.response ?? defaultContext.response,\n\t\t\t\t\tstatus: opts.status ?? defaultContext.status,\n\t\t\t\t}),\n\t\t\terror: (message, error, opts = {}) =>\n\t\t\t\tthis.error(message, error, {\n\t\t\t\t\ttag: opts.tag ?? defaultContext.tag ?? LogTag.HTTP_REQUEST,\n\t\t\t\t\tdata: { ...defaultContext.data, ...opts.data },\n\t\t\t\t\tmetadata: { ...defaultContext.metadata, ...opts.metadata },\n\t\t\t\t\trequest: opts.request ?? defaultContext.request,\n\t\t\t\t\tresponse: opts.response ?? defaultContext.response,\n\t\t\t\t\tstatus: opts.status ?? defaultContext.status,\n\t\t\t\t}),\n\t\t};\n\t}\n}\n\nexport function withRequestContext<T>(store: RequestStore, fn: () => T | Promise<T>): Promise<T> {\n\treturn new Promise((resolve, reject) => {\n\t\trequestContext.run(store, async () => {\n\t\t\ttry {\n\t\t\t\tresolve(await fn());\n\t\t\t} catch (err) {\n\t\t\t\treject(err);\n\t\t\t}\n\t\t});\n\t});\n}"]}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.ExternalRef = void 0;
|
|
13
|
+
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
|
+
let ExternalRef = class ExternalRef {
|
|
15
|
+
source;
|
|
16
|
+
externalId;
|
|
17
|
+
};
|
|
18
|
+
exports.ExternalRef = ExternalRef;
|
|
19
|
+
__decorate([
|
|
20
|
+
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
21
|
+
__metadata("design:type", String)
|
|
22
|
+
], ExternalRef.prototype, "source", void 0);
|
|
23
|
+
__decorate([
|
|
24
|
+
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
25
|
+
__metadata("design:type", String)
|
|
26
|
+
], ExternalRef.prototype, "externalId", void 0);
|
|
27
|
+
exports.ExternalRef = ExternalRef = __decorate([
|
|
28
|
+
(0, typegoose_1.modelOptions)({
|
|
29
|
+
schemaOptions: { _id: false },
|
|
30
|
+
})
|
|
31
|
+
], ExternalRef);
|
|
32
|
+
//# sourceMappingURL=external-ref.model.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"external-ref.model.js","sourceRoot":"/","sources":["libraries/mongo/models/embedded/external-ref.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA0D;AAKnD,IAAM,WAAW,GAAjB,MAAM,WAAW;IAEhB,MAAM,CAAU;IAGhB,UAAU,CAAU;CAC3B,CAAA;AANY,kCAAW;AAEhB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;2CAChB;AAGhB;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;+CACZ;sBALf,WAAW;IAHvB,IAAA,wBAAY,EAAC;QACb,aAAa,EAAE,EAAE,GAAG,EAAE,KAAK,EAAE;KAC7B,CAAC;GACW,WAAW,CAMvB","sourcesContent":["import { modelOptions, prop } from '@typegoose/typegoose';\n\n@modelOptions({\n\tschemaOptions: { _id: false },\n})\nexport class ExternalRef {\n\t@prop({ required: true, type: String })\n\tpublic source!: string;\n\n\t@prop({ required: true, type: String })\n\tpublic externalId!: string;\n}\n"]}
|
|
@@ -25,7 +25,7 @@ let FilterContainer = class FilterContainer extends defaultClasses_1.TimeStamps
|
|
|
25
25
|
};
|
|
26
26
|
exports.FilterContainer = FilterContainer;
|
|
27
27
|
__decorate([
|
|
28
|
-
(0, typegoose_1.prop)({ required: true, type: String
|
|
28
|
+
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
29
29
|
__metadata("design:type", String)
|
|
30
30
|
], FilterContainer.prototype, "name", void 0);
|
|
31
31
|
__decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filter-container.model.js","sourceRoot":"/","sources":["libraries/mongo/models/filter-container.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAAsE;AACtE,4EAAqE;AACrE,kDAAyE;AACzE,wBAAyC;AAEzC,0EAG0C;AAcnC,IAAM,eAAe,GAArB,MAAM,eAAgB,SAAQ,2BAAU;IAEvC,IAAI,CAAU;IAGd,KAAK,CAAY;IAGjB,QAAQ,CAA0B;IAGlC,MAAM,CAAU;IAGhB,SAAS,CAAW;IAGpB,YAAY,CAAU;CAC7B,CAAA;AAlBY,0CAAe;AAEpB;IAD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C,EAAE,SAAS,EAAE,CAAC,EAAE,CAAC;IACpC,IAAA,eAAG,EAAkB,MAAM,EAAE,KAAK,WAAW,IAAI;QACjD,MAAM,uDAAiC,CAAC,IAAI,CAAC,IAAI,EAAE,uBAAoB,EAAE,EAAE,QAAQ,EAAE,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;QAEtG,IAAI,EAAE,CAAC;IACR,CAAC,CAAC;IACD,IAAA,eAAG,EAAkB,kBAAkB,EAAE,KAAK,WAA8C,IAAI;QAChG,MAAM,yDAAmC,CAAC,IAAI,CAAC,IAAI,EAAE,uBAAoB,EAAE,CAAC,UAAU,CAAC,CAAC,CAAC;QAEzF,IAAI,EAAE,CAAC;IACR,CAAC,CAAC;GACW,eAAe,CAkB3B","sourcesContent":["import { Index, modelOptions, pre, prop } from '@typegoose/typegoose';\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\nimport { Status, UserAppSectionItemType } from '../../../utilities/enum';\nimport { FilterContainerModel } from '.';\nimport { Query } from 'mongoose';\nimport {\n\thandlePreSaveForSortingWithStatus,\n\thandlePreUpdateForSortingWithStatus,\n} from '../utilities/sorting-order.hooks';\n\n@modelOptions({ schemaOptions: { collection: 'filterContainers' } })\n@Index({ itemType: 1, deletedAt: 1 })\n@pre<FilterContainer>('save', async function (next) {\n\tawait handlePreSaveForSortingWithStatus.call(this, FilterContainerModel, { itemType: this.itemType });\n\n\tnext();\n})\n@pre<FilterContainer>('findOneAndUpdate', async function (this: Query<any, FilterContainer>, next) {\n\tawait handlePreUpdateForSortingWithStatus.call(this, FilterContainerModel, ['itemType']);\n\n\tnext();\n})\nexport class FilterContainer extends TimeStamps {\n\t@prop({ required: true, type: String })\n\tpublic name!: string;\n\n\t@prop({ required: true, type: [String] })\n\tpublic deals!: string[]; // e.g., \"5\", \"10\", \"20\", \"30\", \"buy1get1\", \"free_delivery\"\n\n\t@prop({ type: String, enum: UserAppSectionItemType })\n\tpublic itemType?: UserAppSectionItemType;\n\n\t@prop({ type: String, enum: Status, default: Status.ACTIVE })\n\tpublic status?: Status;\n\n\t@prop({ type: Boolean, default: true })\n\tpublic isVisible!: boolean;\n\n\t@prop({ type: Number })\n\tpublic sortingOrder?: number;\n}\n"]}
|
|
@@ -109,6 +109,7 @@ import { PaymentIntent } from './payment-intent.model';
|
|
|
109
109
|
import { AppInstance } from './app-instance.model';
|
|
110
110
|
import { PaymentConfiguration } from './payment-configuration.model';
|
|
111
111
|
import { ServiceFlag } from './service-flag.model';
|
|
112
|
+
import { IntegrationConfiguration } from './integration-configuration.model';
|
|
112
113
|
export declare const ActivityLogModel: ReturnModelType<typeof ActivityLog>;
|
|
113
114
|
export * from './activity-log.model';
|
|
114
115
|
export declare const AdminAccessControlModel: ReturnModelType<typeof AdminAccessControl>;
|
|
@@ -295,6 +296,7 @@ export * from './agent-performance.model';
|
|
|
295
296
|
export declare const ChatroomModel: ReturnModelType<typeof Chatroom>;
|
|
296
297
|
export * from './chat-room.model';
|
|
297
298
|
export * from './embedded/chat-participant.model';
|
|
299
|
+
export * from './embedded/external-ref.model';
|
|
298
300
|
export declare const ServiceModel: ReturnModelType<typeof Service>;
|
|
299
301
|
export * from './service.model';
|
|
300
302
|
export declare const VendorParentModel: ReturnModelType<typeof VendorParent>;
|
|
@@ -332,3 +334,6 @@ export declare const PaymentConfigurationModel: ReturnModelType<typeof PaymentCo
|
|
|
332
334
|
export * from './payment-configuration.model';
|
|
333
335
|
export declare const ServiceFlagModel: ReturnModelType<typeof ServiceFlag>;
|
|
334
336
|
export * from './service-flag.model';
|
|
337
|
+
export declare const IntegrationConfigurationModel: ReturnModelType<typeof IntegrationConfiguration>;
|
|
338
|
+
export * from './integration-configuration.model';
|
|
339
|
+
export declare function createIntegrationDiscriminator<U extends new (...args: any[]) => IntegrationConfiguration>(cls: U, key: string): ReturnModelType<U>;
|
|
@@ -16,7 +16,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
exports.ShopPayoutModel = exports.PayoutModel = exports.ParentModel = exports.ShopCourierOrderModel = exports.CourierOrderModel = exports.RegularOrderModel = exports.OrderModel = exports.NutritionModel = exports.NotificationModel = exports.MealPlanModel = exports.PunchMarketingModel = exports.FreeDeliveryMarketingModel = exports.FeaturedMarketingModel = exports.DiscountMarketingModel = exports.Buy1Get1MarketingModel = exports.MarketingModel = exports.ListContainerModel = exports.LineItemModel = exports.GalleryUploadModel = exports.GalleryModel = exports.FlagModel = exports.FinanceSettlementModel = exports.FilterContainerModel = exports.FeaturedSettingModel = exports.FavouriteModel = exports.DishModel = exports.DealSettingModel = exports.ReferralRewardCouponModel = exports.ReferralCodeCouponModel = exports.IndividualUserCouponModel = exports.IndividualStoreCouponModel = exports.ShopsCategoriesCouponModel = exports.GlobalCouponModel = exports.CustomCouponModel = exports.BaseCouponModel = exports.CouponModel = exports.CounterModel = exports.CategoryModel = exports.CartParticipantModel = exports.CartModel = exports.ServiceControlModel = exports.AppAppearanceModel = exports.BrandModel = exports.BOBFinanceModel = exports.BannerModel = exports.AttributeModel = exports.UserAppSectionSettingModel = exports.AdminModel = exports.AdminAccessControlModel = exports.ActivityLogModel = void 0;
|
|
18
18
|
exports.AppInstanceModel = exports.ZoneExtraTimeModel = exports.LoggerModel = exports.ServicePromotionModel = exports.TicketActionModel = exports.ProfessionalBlockedTimeModel = exports.ServiceBookingModel = exports.ServiceCartModel = exports.ProfessionalModel = exports.ServicePackageModel = exports.ServiceAddonModel = exports.ServiceCategoryModel = exports.VendorAccessControlModel = exports.VendorModel = exports.VendorParentModel = exports.ServiceModel = exports.ChatroomModel = exports.AgentPerformanceModel = exports.MessageModel = exports.TicketModel = exports.RewardModel = exports.CancellationReasonModel = exports.SupportReasonModel = exports.TermsAndConditionsModel = exports.DefaultChatModel = exports.ZoneModel = exports.UserModel = exports.TagModel = exports.SubscriptionModel = exports.ShopModel = exports.ShopMealPlanModel = exports.ShopCategoryModel = exports.ShopAccessControlModel = exports.SettingModel = exports.RiderModel = exports.RiderTrackingModel = exports.RiderTimeoutModel = exports.ServiceBookingReviewModel = exports.RiderReviewModel = exports.ShopReviewModel = exports.ReviewModel = exports.RequestAreaModel = exports.ReferralSettingModel = exports.RatingSettingModel = exports.PunchMarketingHistoryModel = exports.ProductUploadModel = exports.ProductModel = exports.ProductStockTrackerModel = exports.ProductMarketingModel = exports.RiderPayoutModel = void 0;
|
|
19
|
-
exports.ServiceFlagModel = exports.PaymentConfigurationModel = void 0;
|
|
19
|
+
exports.IntegrationConfigurationModel = exports.ServiceFlagModel = exports.PaymentConfigurationModel = void 0;
|
|
20
20
|
exports.getCoreAuthIdentityModel = getCoreAuthIdentityModel;
|
|
21
21
|
exports.getCoreEmailAuthIdentityModel = getCoreEmailAuthIdentityModel;
|
|
22
22
|
exports.getCorePhoneAuthIdentityModel = getCorePhoneAuthIdentityModel;
|
|
@@ -26,6 +26,7 @@ exports.getCoreUserModel = getCoreUserModel;
|
|
|
26
26
|
exports.getCardModel = getCardModel;
|
|
27
27
|
exports.getPaymentIntentModel = getPaymentIntentModel;
|
|
28
28
|
exports.initializeGlobalModels = initializeGlobalModels;
|
|
29
|
+
exports.createIntegrationDiscriminator = createIntegrationDiscriminator;
|
|
29
30
|
const rider_payout_model_1 = require("./providers/rider-payout.model");
|
|
30
31
|
const shop_payout_model_1 = require("./providers/shop-payout.model");
|
|
31
32
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
@@ -140,6 +141,7 @@ const payment_intent_model_1 = require("./payment-intent.model");
|
|
|
140
141
|
const app_instance_model_1 = require("./app-instance.model");
|
|
141
142
|
const payment_configuration_model_1 = require("./payment-configuration.model");
|
|
142
143
|
const service_flag_model_1 = require("./service-flag.model");
|
|
144
|
+
const integration_configuration_model_1 = require("./integration-configuration.model");
|
|
143
145
|
exports.ActivityLogModel = (0, typegoose_1.getModelForClass)(activity_log_model_1.ActivityLog);
|
|
144
146
|
__exportStar(require("./activity-log.model"), exports);
|
|
145
147
|
exports.AdminAccessControlModel = (0, typegoose_1.getModelForClass)(admin_access_control_model_1.AdminAccessControl);
|
|
@@ -381,6 +383,7 @@ __exportStar(require("./agent-performance.model"), exports);
|
|
|
381
383
|
exports.ChatroomModel = (0, typegoose_1.getModelForClass)(chat_room_model_1.Chatroom);
|
|
382
384
|
__exportStar(require("./chat-room.model"), exports);
|
|
383
385
|
__exportStar(require("./embedded/chat-participant.model"), exports);
|
|
386
|
+
__exportStar(require("./embedded/external-ref.model"), exports);
|
|
384
387
|
exports.ServiceModel = (0, typegoose_1.getModelForClass)(service_model_1.Service);
|
|
385
388
|
__exportStar(require("./service.model"), exports);
|
|
386
389
|
exports.VendorParentModel = (0, typegoose_1.getModelForClass)(vendor_parent_model_1.VendorParent);
|
|
@@ -418,4 +421,9 @@ exports.PaymentConfigurationModel = (0, typegoose_1.getModelForClass)(payment_co
|
|
|
418
421
|
__exportStar(require("./payment-configuration.model"), exports);
|
|
419
422
|
exports.ServiceFlagModel = (0, typegoose_1.getModelForClass)(service_flag_model_1.ServiceFlag);
|
|
420
423
|
__exportStar(require("./service-flag.model"), exports);
|
|
424
|
+
exports.IntegrationConfigurationModel = (0, typegoose_1.getModelForClass)(integration_configuration_model_1.IntegrationConfiguration);
|
|
425
|
+
__exportStar(require("./integration-configuration.model"), exports);
|
|
426
|
+
function createIntegrationDiscriminator(cls, key) {
|
|
427
|
+
return (0, typegoose_1.getDiscriminatorModelForClass)(exports.IntegrationConfigurationModel, cls, key);
|
|
428
|
+
}
|
|
421
429
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"/","sources":["libraries/mongo/models/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AAyKA,4DAIC;AAED,sEAIC;AAED,sEAIC;AAED,wEAIC;AAED,sEAIC;AAED,4CAIC;AAED,oCAGC;AAED,sDAIC;AAGD,wDAuCC;AAhQD,uEAA6D;AAC7D,qEAA2D;AAC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AAA,yBAAyB,GACrC,IAAA,4BAAgB,EAAC,kDAAoB,CAAC,CAAC;AACxC,gEAA8C;AAEjC,QAAA,gBAAgB,GAAwC,IAAA,4BAAgB,EAAC,gCAAW,CAAC,CAAC;AACnG,uDAAqC","sourcesContent":["import { RiderPayout } from './providers/rider-payout.model';\nimport { ShopPayout } from './providers/shop-payout.model';\nimport { getDiscriminatorModelForClass, getModelForClass, ReturnModelType } from '@typegoose/typegoose';\nimport { Admin } from './admin.model';\nimport { AdminAccessControl } from './admin-access-control.model';\nimport { ActivityLog } from './activity-log.model';\nimport { UserAppSectionSetting } from './user-app-section-setting.model';\nimport { Attribute } from './attribute.model';\nimport { Banner } from './banner.model';\nimport { BaseCoupon } from './base/base-coupon.model';\nimport { BOBFinance } from './bob-finance.model';\nimport { Brand } from './brand.model';\nimport { Category } from './category.model';\nimport { Counter } from './counter.model';\nimport { Coupon } from './coupon.model';\nimport { DealSetting } from './deal-setting.model';\nimport { Dish } from './dish.model';\nimport { Favourite } from './favourite.model';\nimport { FeaturedSetting } from './featured-setting.model';\nimport { FilterContainer } from './filter-container.model';\nimport { ListContainer } from './list-container.model';\nimport { Marketing } from './marketing.model';\nimport { MealPlan } from './meal-plan.model';\nimport { Nutrition } from './nutrition.model';\nimport { Parent } from './parent.model';\nimport { ProductMarketing } from './product-marketing.model';\nimport { Product } from './product.model';\nimport { PunchMarketingHistory } from './punch-marketing-history.model';\nimport { RatingSetting } from './rating-setting.model';\nimport { ReferralSetting } from './referral-setting.model';\nimport { RequestArea } from './request-area.model';\nimport { Setting } from './setting.model';\nimport { ShopAccessControl } from './shop-access-control.model';\nimport { ShopCategory } from './shop-category.model';\nimport { ShopMealPlan } from './shop-meal-plan.model';\nimport { Shop } from './shop.model';\nimport { Subscription } from './subscription.model';\nimport { Tag } from './tag.model';\nimport { Zone } from './zone.model';\nimport { Buy1Get1Marketing } from './providers/buy1-get1-marketing.model';\nimport {\n\tCoreAuthIdentityType,\n\tCounterType,\n\tCouponType,\n\tMarketingType,\n\tOrderType,\n\tPayoutType,\n\tReviewType,\n} from '../../../utilities/enum';\nimport { ServiceAddon } from './service-addon.model';\nimport { CustomCoupon } from './providers/custom-coupon.model';\nimport { DiscountMarketing } from './providers/discount-marketing.model';\nimport { FeaturedMarketing } from './providers/featured-marketing.model';\nimport { FreeDeliveryMarketing } from './providers/free-delivery-marketing.model';\nimport { GlobalCoupon } from './providers/global-coupon.model';\nimport { IndividualStoreCoupon } from './providers/individual-store-coupon.model';\nimport { IndividualUserCoupon } from './providers/individual-user-coupon.model';\nimport { PunchMarketing } from './providers/punch-marketing.model';\nimport { ReferralCodeCoupon } from './providers/referral-code-coupon.model';\nimport { ReferralRewardCoupon } from './providers/referral-reward-coupon.model';\nimport { Notification } from './notification.model';\nimport { CoreAuthIdentity } from './core-auth-identity.model';\nimport { CoreEmailAuthIdentity } from './providers/core-email-auth-identity.model';\nimport { CorePhoneAuthIdentity } from './providers/core-phone-auth-identity.model';\nimport { CoreGoogleAuthIdentity } from './providers/core-google-auth-identity.model';\nimport { CoreAppleAuthIdentity } from './providers/core-apple-auth-identity.model';\nimport { CoreUser } from './core-user.model';\nimport { RiderTracking } from './rider-tracking.model';\nimport { Rider } from './rider.model';\nimport { RiderTimeout } from './rider-timeout.model';\nimport { User } from './user.model';\nimport { Cart } from './cart.model';\nimport { LineItem } from './line-item.model';\nimport { CartParticipant } from './cart-participant.model';\nimport { Gallery } from './gallery.model';\nimport { Order } from './order.model';\nimport { RegularOrder } from './providers/regular-order.model';\nimport { CourierOrder } from './providers/courier-order.model';\nimport { FinanceSettlement } from './finance-settlement.model';\nimport { DefaultChat } from './default-chat.model';\nimport { TermsAndConditions } from './terms-and-conditions.model';\nimport { SupportReason } from './support-reason.model';\nimport { CancellationReason } from './cancellation-reason.model';\nimport { Payout } from './payout.model';\nimport { Reward } from './reward.model';\nimport { Ticket } from './ticket.model';\nimport { Message } from './message.model';\nimport { AgentPerformance } from './agent-performance.model';\nimport { Chatroom } from './chat-room.model';\nimport { initializeRefreshTokenModel } from '../../auth';\nimport { VendorParent } from './vendor-parent.model';\nimport { Vendor } from './vendor.model';\nimport { VendorAccessControl } from './vendor-access-control.model';\nimport { ServiceCategory } from './service-category.model';\nimport { ServicePackage } from './service-package.model';\nimport { Professional } from './professional.model';\nimport { ServiceBooking } from './service-booking.model';\nimport { Service } from './service.model';\nimport { TicketAction } from './ticket-action.model';\nimport { ServiceCart } from './service-cart.model';\nimport { ShopCourierOrder } from './providers/shop-courier.model';\nimport { ServicePromotion } from './service-promotion.model';\nimport { Flag } from './flag.model';\nimport { Review } from './review.model';\nimport { ShopReview } from './providers/shop-review.model';\nimport { RiderReview } from './providers/rider-review.model';\nimport { ServiceBookingReview } from './providers/service-booking-review.model';\nimport { assignIdsToDocuments } from '../../../utilities/id-generator';\nimport { GalleryUpload } from './gallery-upload.model';\nimport { ProductUpload } from './product-upload.model';\nimport { ShopsCategoriesCoupon } from './providers/shops-categories-coupon.model';\nimport { ProfessionalBlockedTime } from './professional-blocked-time.model';\nimport { ZoneExtraTime } from './zone-extra-time';\nimport { AppAppearance } from './app-appearance.model';\nimport { ServiceControl } from './service-control.model';\nimport { Log } from './log.model';\nimport { Card } from './card.model';\nimport { ProductStockTracker } from './product-stock-tracker.model';\nimport { PaymentIntent } from './payment-intent.model';\nimport { AppInstance } from './app-instance.model';\nimport { PaymentConfiguration } from './payment-configuration.model';\nimport { ServiceFlag } from './service-flag.model';\n\n// Regular models (using standard getModelForClass)\nexport const ActivityLogModel: ReturnModelType<typeof ActivityLog> = getModelForClass(ActivityLog);\nexport * from './activity-log.model';\n\nexport const AdminAccessControlModel: ReturnModelType<typeof AdminAccessControl> =\n\tgetModelForClass(AdminAccessControl);\nexport * from './admin-access-control.model';\n\nexport const AdminModel: ReturnModelType<typeof Admin> = getModelForClass(Admin);\nexport * from './admin.model';\n\nexport const UserAppSectionSettingModel: ReturnModelType<typeof UserAppSectionSetting> =\n\tgetModelForClass(UserAppSectionSetting);\nexport * from './user-app-section-setting.model';\n\nexport const AttributeModel: ReturnModelType<typeof Attribute> = getModelForClass(Attribute);\nexport * from './attribute.model';\n\nexport const BannerModel: ReturnModelType<typeof Banner> = getModelForClass(Banner);\nexport * from './banner.model';\n\nexport const BOBFinanceModel: ReturnModelType<typeof BOBFinance> = getModelForClass(BOBFinance);\nexport * from './bob-finance.model';\n\nexport const BrandModel: ReturnModelType<typeof Brand> = getModelForClass(Brand);\nexport * from './brand.model';\n\nexport const AppAppearanceModel: ReturnModelType<typeof AppAppearance> = getModelForClass(AppAppearance);\nexport * from './app-appearance.model';\n\nexport const ServiceControlModel: ReturnModelType<typeof ServiceControl> = getModelForClass(ServiceControl);\nexport * from './service-control.model';\n\n// Global models - will be set after initGlobalConnection()\nlet actualCoreAuthIdentityModel: ReturnModelType<typeof CoreAuthIdentity> | null = null;\nlet actualCoreUserModel: ReturnModelType<typeof CoreUser> | null = null;\nlet actualCardModel: ReturnModelType<typeof Card> | null = null;\nlet actualPaymentIntentModel: ReturnModelType<typeof PaymentIntent> | null = null;\n\n// Global discriminator models - will be set after initGlobalConnection()\nlet actualCoreEmailAuthIdentityModel: ReturnModelType<typeof CoreEmailAuthIdentity> | null = null;\nlet actualCorePhoneAuthIdentityModel: ReturnModelType<typeof CorePhoneAuthIdentity> | null = null;\nlet actualCoreGoogleAuthIdentityModel: ReturnModelType<typeof CoreGoogleAuthIdentity> | null = null;\nlet actualCoreAppleAuthIdentityModel: ReturnModelType<typeof CoreAppleAuthIdentity> | null = null;\n\n// Export getter functions for global models\nexport function getCoreAuthIdentityModel(): ReturnModelType<typeof CoreAuthIdentity> {\n\tif (!actualCoreAuthIdentityModel)\n\t\tthrow new Error('CoreAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreAuthIdentityModel;\n}\n\nexport function getCoreEmailAuthIdentityModel(): ReturnModelType<typeof CoreEmailAuthIdentity> {\n\tif (!actualCoreEmailAuthIdentityModel)\n\t\tthrow new Error('CoreEmailAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreEmailAuthIdentityModel;\n}\n\nexport function getCorePhoneAuthIdentityModel(): ReturnModelType<typeof CorePhoneAuthIdentity> {\n\tif (!actualCorePhoneAuthIdentityModel)\n\t\tthrow new Error('CorePhoneAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCorePhoneAuthIdentityModel;\n}\n\nexport function getCoreGoogleAuthIdentityModel(): ReturnModelType<typeof CoreGoogleAuthIdentity> {\n\tif (!actualCoreGoogleAuthIdentityModel)\n\t\tthrow new Error('CoreGoogleAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreGoogleAuthIdentityModel;\n}\n\nexport function getCoreAppleAuthIdentityModel(): ReturnModelType<typeof CoreAppleAuthIdentity> {\n\tif (!actualCoreAppleAuthIdentityModel)\n\t\tthrow new Error('CoreAppleAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreAppleAuthIdentityModel;\n}\n\nexport function getCoreUserModel(): ReturnModelType<typeof CoreUser> {\n\tif (!actualCoreUserModel)\n\t\tthrow new Error('CoreUser model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreUserModel;\n}\n\nexport function getCardModel(): ReturnModelType<typeof Card> {\n\tif (!actualCardModel) throw new Error('Card model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCardModel;\n}\n\nexport function getPaymentIntentModel(): ReturnModelType<typeof PaymentIntent> {\n\tif (!actualPaymentIntentModel)\n\t\tthrow new Error('Payment Intent model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualPaymentIntentModel;\n}\n\n// Function to initialize all global models (called from initGlobalConnection)\nexport function initializeGlobalModels(globalConnection: any) {\n\t// Initialize base global models\n\tactualCoreAuthIdentityModel = getModelForClass(CoreAuthIdentity, { existingConnection: globalConnection });\n\tactualCoreUserModel = getModelForClass(CoreUser, { existingConnection: globalConnection });\n\tactualCardModel = getModelForClass(Card, { existingConnection: globalConnection });\n\tactualPaymentIntentModel = getModelForClass(PaymentIntent, { existingConnection: globalConnection });\n\n\t// Initialize discriminator models\n\tactualCoreEmailAuthIdentityModel = getDiscriminatorModelForClass(\n\t\tactualCoreAuthIdentityModel,\n\t\tCoreEmailAuthIdentity,\n\t\tCoreAuthIdentityType.EMAIL,\n\t\t{ existingConnection: globalConnection }\n\t);\n\n\tactualCorePhoneAuthIdentityModel = getDiscriminatorModelForClass(\n\t\tactualCoreAuthIdentityModel,\n\t\tCorePhoneAuthIdentity,\n\t\tCoreAuthIdentityType.PHONE,\n\t\t{ existingConnection: globalConnection }\n\t);\n\n\tactualCoreGoogleAuthIdentityModel = getDiscriminatorModelForClass(\n\t\tactualCoreAuthIdentityModel,\n\t\tCoreGoogleAuthIdentity,\n\t\tCoreAuthIdentityType.GOOGLE,\n\t\t{ existingConnection: globalConnection }\n\t);\n\n\tactualCoreAppleAuthIdentityModel = getDiscriminatorModelForClass(\n\t\tactualCoreAuthIdentityModel,\n\t\tCoreAppleAuthIdentity,\n\t\tCoreAuthIdentityType.APPLE,\n\t\t{ existingConnection: globalConnection }\n\t);\n\n\tinitializeRefreshTokenModel(globalConnection);\n\n\tconsole.log('✅ All global models initialized');\n}\n\nexport const CartModel: ReturnModelType<typeof Cart> = getModelForClass(Cart);\nexport * from './cart.model';\n\nexport const CartParticipantModel: ReturnModelType<typeof CartParticipant> =\n\tgetModelForClass(CartParticipant);\nexport * from './cart-participant.model';\n\nexport const CategoryModel: ReturnModelType<typeof Category> = getModelForClass(Category);\nexport * from './category.model';\n\nexport * from './core-auth-identity.model';\nexport * from './providers/core-apple-auth-identity.model';\nexport * from './providers/core-email-auth-identity.model';\nexport * from './providers/core-google-auth-identity.model';\nexport * from './providers/core-phone-auth-identity.model';\nexport * from './core-user.model';\n\nexport const CounterModel: ReturnModelType<typeof Counter> = getModelForClass(Counter);\nexport * from './counter.model';\n\nexport const CouponModel: ReturnModelType<typeof Coupon> = getModelForClass(Coupon);\nexport const BaseCouponModel: ReturnModelType<typeof BaseCoupon> = getModelForClass(BaseCoupon);\nexport const CustomCouponModel: ReturnModelType<typeof CustomCoupon> = getDiscriminatorModelForClass(\n\tCouponModel,\n\tCustomCoupon,\n\tCouponType.CUSTOM_COUPON\n);\nexport const GlobalCouponModel: ReturnModelType<typeof GlobalCoupon> = getDiscriminatorModelForClass(\n\tCouponModel,\n\tGlobalCoupon,\n\tCouponType.GLOBAL\n);\nexport const ShopsCategoriesCouponModel: ReturnModelType<typeof ShopsCategoriesCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ShopsCategoriesCoupon, CouponType.SHOPS_CATEGORIES);\nexport const IndividualStoreCouponModel: ReturnModelType<typeof IndividualStoreCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, IndividualStoreCoupon, CouponType.INDIVIDUAL_STORE);\nexport const IndividualUserCouponModel: ReturnModelType<typeof IndividualUserCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, IndividualUserCoupon, CouponType.INDIVIDUAL_USER);\nexport const ReferralCodeCouponModel: ReturnModelType<typeof ReferralCodeCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ReferralCodeCoupon, CouponType.REFERRAL_CODE);\nexport const ReferralRewardCouponModel: ReturnModelType<typeof ReferralRewardCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ReferralRewardCoupon, CouponType.REFERRAL_REWARD);\nexport * from './coupon.model';\nexport * from './base/base-coupon.model';\nexport * from './providers/custom-coupon.model';\nexport * from './providers/global-coupon.model';\nexport * from './providers/shops-categories-coupon.model';\nexport * from './providers/individual-store-coupon.model';\nexport * from './providers/individual-user-coupon.model';\nexport * from './providers/referral-code-coupon.model';\nexport * from './providers/referral-reward-coupon.model';\n\nexport const DealSettingModel: ReturnModelType<typeof DealSetting> = getModelForClass(DealSetting);\nexport * from './deal-setting.model';\n\nexport const DishModel: ReturnModelType<typeof Dish> = getModelForClass(Dish);\nexport * from './dish.model';\n\nexport const FavouriteModel: ReturnModelType<typeof Favourite> = getModelForClass(Favourite);\nexport * from './favourite.model';\n\nexport const FeaturedSettingModel: ReturnModelType<typeof FeaturedSetting> =\n\tgetModelForClass(FeaturedSetting);\nexport * from './featured-setting.model';\n\nexport const FilterContainerModel: ReturnModelType<typeof FilterContainer> =\n\tgetModelForClass(FilterContainer);\nexport * from './filter-container.model';\n\nexport const FinanceSettlementModel: ReturnModelType<typeof FinanceSettlement> =\n\tgetModelForClass(FinanceSettlement);\nexport * from './finance-settlement.model';\n\nexport const FlagModel: ReturnModelType<typeof Flag> = getModelForClass(Flag);\nexport * from './flag.model';\n\nexport const GalleryModel: ReturnModelType<typeof Gallery> = getModelForClass(Gallery);\nexport * from './gallery.model';\n\nexport const GalleryUploadModel: ReturnModelType<typeof GalleryUpload> = getModelForClass(GalleryUpload);\nexport * from './gallery-upload.model';\n\nexport const LineItemModel: ReturnModelType<typeof LineItem> = getModelForClass(LineItem);\nexport * from './line-item.model';\n\nexport const ListContainerModel: ReturnModelType<typeof ListContainer> = getModelForClass(ListContainer);\nexport * from './list-container.model';\n\nexport const MarketingModel: ReturnModelType<typeof Marketing> = getModelForClass(Marketing);\nexport const Buy1Get1MarketingModel: ReturnModelType<typeof Buy1Get1Marketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, Buy1Get1Marketing, MarketingType.BUY1GET1);\nexport const DiscountMarketingModel: ReturnModelType<typeof DiscountMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, DiscountMarketing, MarketingType.DISCOUNT);\nexport const FeaturedMarketingModel: ReturnModelType<typeof FeaturedMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, FeaturedMarketing, MarketingType.FEATURED);\nexport const FreeDeliveryMarketingModel: ReturnModelType<typeof FreeDeliveryMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, FreeDeliveryMarketing, MarketingType.FREE_DELIVERY);\nexport const PunchMarketingModel: ReturnModelType<typeof PunchMarketing> = getDiscriminatorModelForClass(\n\tMarketingModel,\n\tPunchMarketing,\n\tMarketingType.PUNCH_MARKETING\n);\nexport * from './marketing.model';\nexport * from './providers/buy1-get1-marketing.model';\nexport * from './providers/discount-marketing.model';\nexport * from './providers/featured-marketing.model';\nexport * from './providers/free-delivery-marketing.model';\nexport * from './providers/punch-marketing.model';\n\nexport const MealPlanModel: ReturnModelType<typeof MealPlan> = getModelForClass(MealPlan);\nexport * from './meal-plan.model';\n\nexport const NotificationModel: ReturnModelType<typeof Notification> = getModelForClass(Notification);\nexport * from './notification.model';\n\nexport const NutritionModel: ReturnModelType<typeof Nutrition> = getModelForClass(Nutrition);\nexport * from './nutrition.model';\n\nexport const OrderModel: ReturnModelType<typeof Order> = getModelForClass(Order);\nexport const RegularOrderModel: ReturnModelType<typeof RegularOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tRegularOrder,\n\tOrderType.REGULAR\n);\nexport const CourierOrderModel: ReturnModelType<typeof CourierOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tCourierOrder,\n\tOrderType.COURIER\n);\n\nexport const ShopCourierOrderModel: ReturnModelType<typeof ShopCourierOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tShopCourierOrder,\n\tOrderType.SHOP_COURIER\n);\n\nexport * from './order.model';\nexport * from './providers/regular-order.model';\nexport * from './providers/courier-order.model';\nexport * from './providers/shop-courier.model';\n\nexport const ParentModel: ReturnModelType<typeof Parent> = getModelForClass(Parent);\nexport * from './parent.model';\n\nexport const PayoutModel: ReturnModelType<typeof Payout> = getModelForClass(Payout);\nexport const ShopPayoutModel: ReturnModelType<typeof ShopPayout> = getDiscriminatorModelForClass(\n\tPayoutModel,\n\tShopPayout,\n\tPayoutType.SHOP\n);\nexport const RiderPayoutModel: ReturnModelType<typeof RiderPayout> = getDiscriminatorModelForClass(\n\tPayoutModel,\n\tRiderPayout,\n\tPayoutType.RIDER\n);\nexport * from './payout.model';\nexport * from './providers/shop-payout.model';\nexport * from './providers/rider-payout.model';\n\nexport const ProductMarketingModel: ReturnModelType<typeof ProductMarketing> =\n\tgetModelForClass(ProductMarketing);\nexport * from './product-marketing.model';\n\nexport const ProductStockTrackerModel: ReturnModelType<typeof ProductStockTracker> =\n\tgetModelForClass(ProductStockTracker);\nexport * from './product-stock-tracker.model';\n\nexport const ProductModel: ReturnModelType<typeof Product> = getModelForClass(Product);\nexport * from './product.model';\nProductModel.schema.pre('insertMany', async function (next, docs: Product[]) {\n\t// Generate all IDs at once (ATOMIC)\n\tawait assignIdsToDocuments(CounterModel, CounterType.ITEM, docs, 'productId');\n\tnext();\n});\n\nexport const ProductUploadModel: ReturnModelType<typeof ProductUpload> = getModelForClass(ProductUpload);\nexport * from './product-upload.model';\n\nexport const PunchMarketingHistoryModel: ReturnModelType<typeof PunchMarketingHistory> =\n\tgetModelForClass(PunchMarketingHistory);\nexport * from './punch-marketing-history.model';\n\nexport const RatingSettingModel: ReturnModelType<typeof RatingSetting> = getModelForClass(RatingSetting);\nexport * from './rating-setting.model';\n\nexport const ReferralSettingModel: ReturnModelType<typeof ReferralSetting> =\n\tgetModelForClass(ReferralSetting);\nexport * from './referral-setting.model';\n\nexport const RequestAreaModel: ReturnModelType<typeof RequestArea> = getModelForClass(RequestArea);\nexport * from './request-area.model';\n\nexport const ReviewModel: ReturnModelType<typeof Review> = getModelForClass(Review);\nexport const ShopReviewModel: ReturnModelType<typeof ShopReview> = getDiscriminatorModelForClass(\n\tReviewModel,\n\tShopReview,\n\tReviewType.SHOP\n);\nexport const RiderReviewModel: ReturnModelType<typeof RiderReview> = getDiscriminatorModelForClass(\n\tReviewModel,\n\tRiderReview,\n\tReviewType.RIDER\n);\nexport const ServiceBookingReviewModel: ReturnModelType<typeof ServiceBookingReview> =\n\tgetDiscriminatorModelForClass(ReviewModel, ServiceBookingReview, ReviewType.SERVICE_BOOKING);\nexport * from './review.model';\nexport * from './providers/shop-review.model';\nexport * from './providers/rider-review.model';\nexport * from './providers/service-booking-review.model';\n\nexport const RiderTimeoutModel: ReturnModelType<typeof RiderTimeout> = getModelForClass(RiderTimeout);\nexport * from './rider-timeout.model';\n\nexport const RiderTrackingModel: ReturnModelType<typeof RiderTracking> = getModelForClass(RiderTracking);\nexport * from './rider-tracking.model';\n\nexport const RiderModel: ReturnModelType<typeof Rider> = getModelForClass(Rider);\nexport * from './rider.model';\n\nexport const SettingModel: ReturnModelType<typeof Setting> = getModelForClass(Setting);\nexport * from './setting.model';\n\nexport const ShopAccessControlModel: ReturnModelType<typeof ShopAccessControl> =\n\tgetModelForClass(ShopAccessControl);\nexport * from './shop-access-control.model';\n\nexport const ShopCategoryModel: ReturnModelType<typeof ShopCategory> = getModelForClass(ShopCategory);\nexport * from './shop-category.model';\n\nexport const ShopMealPlanModel: ReturnModelType<typeof ShopMealPlan> = getModelForClass(ShopMealPlan);\nexport * from './shop-meal-plan.model';\n\nexport const ShopModel: ReturnModelType<typeof Shop> = getModelForClass(Shop);\nexport * from './shop.model';\n\nexport const SubscriptionModel: ReturnModelType<typeof Subscription> = getModelForClass(Subscription);\nexport * from './subscription.model';\n\nexport const TagModel: ReturnModelType<typeof Tag> = getModelForClass(Tag);\nexport * from './tag.model';\n\nexport const UserModel: ReturnModelType<typeof User> = getModelForClass(User);\nexport * from './user.model';\n\nexport const ZoneModel: ReturnModelType<typeof Zone> = getModelForClass(Zone);\nexport * from './zone.model';\n\nexport const DefaultChatModel: ReturnModelType<typeof DefaultChat> = getModelForClass(DefaultChat);\nexport * from './default-chat.model';\n\nexport const TermsAndConditionsModel: ReturnModelType<typeof TermsAndConditions> =\n\tgetModelForClass(TermsAndConditions);\nexport * from './terms-and-conditions.model';\n\nexport const SupportReasonModel: ReturnModelType<typeof SupportReason> = getModelForClass(SupportReason);\nexport * from './support-reason.model';\n\nexport const CancellationReasonModel: ReturnModelType<typeof CancellationReason> =\n\tgetModelForClass(CancellationReason);\nexport * from './cancellation-reason.model';\n\nexport * from './embedded/trip-leg.mode';\nexport * from './embedded/rider-assignment-model';\n\nexport const RewardModel: ReturnModelType<typeof Reward> = getModelForClass(Reward);\nexport * from './reward.model';\n\nexport const TicketModel: ReturnModelType<typeof Ticket> = getModelForClass(Ticket);\nexport * from './ticket.model';\n\nexport const MessageModel: ReturnModelType<typeof Message> = getModelForClass(Message);\nexport * from './message.model';\n\nexport const AgentPerformanceModel: ReturnModelType<typeof AgentPerformance> =\n\tgetModelForClass(AgentPerformance);\nexport * from './agent-performance.model';\n\nexport const ChatroomModel: ReturnModelType<typeof Chatroom> = getModelForClass(Chatroom);\nexport * from './chat-room.model';\n\nexport * from './embedded/chat-participant.model';\n\nexport const ServiceModel: ReturnModelType<typeof Service> = getModelForClass(Service);\nexport * from './service.model';\n\nexport const VendorParentModel: ReturnModelType<typeof VendorParent> = getModelForClass(VendorParent);\nexport * from './vendor-parent.model';\n\nexport const VendorModel: ReturnModelType<typeof Vendor> = getModelForClass(Vendor);\nexport * from './vendor.model';\n\nexport const VendorAccessControlModel: ReturnModelType<typeof VendorAccessControl> =\n\tgetModelForClass(VendorAccessControl);\nexport * from './vendor-access-control.model';\n\nexport const ServiceCategoryModel: ReturnModelType<typeof ServiceCategory> =\n\tgetModelForClass(ServiceCategory);\nexport * from './service-category.model';\n\nexport const ServiceAddonModel: ReturnModelType<typeof ServiceAddon> = getModelForClass(ServiceAddon);\nexport * from './service-addon.model';\n\nexport const ServicePackageModel: ReturnModelType<typeof ServicePackage> = getModelForClass(ServicePackage);\nexport * from './service-package.model';\n\nexport const ProfessionalModel: ReturnModelType<typeof Professional> = getModelForClass(Professional);\nexport * from './professional.model';\n\nexport const ServiceCartModel: ReturnModelType<typeof ServiceCart> = getModelForClass(ServiceCart);\nexport * from './service-cart.model';\n\nexport const ServiceBookingModel: ReturnModelType<typeof ServiceBooking> = getModelForClass(ServiceBooking);\nexport * from './service-booking.model';\n\nexport const ProfessionalBlockedTimeModel: ReturnModelType<typeof ProfessionalBlockedTime> =\n\tgetModelForClass(ProfessionalBlockedTime);\nexport * from './professional-blocked-time.model';\n\nexport const TicketActionModel: ReturnModelType<typeof TicketAction> = getModelForClass(TicketAction);\nexport * from './ticket-action.model';\n\nexport const ServicePromotionModel: ReturnModelType<typeof ServicePromotion> =\n\tgetModelForClass(ServicePromotion);\nexport * from './service-promotion.model';\n\nexport const LoggerModel: ReturnModelType<typeof Log> = getModelForClass(Log);\nexport * from './log.model';\n\nexport const ZoneExtraTimeModel: ReturnModelType<typeof ZoneExtraTime> = getModelForClass(ZoneExtraTime);\nexport * from './zone-extra-time';\n\nexport * from './google-maps-usage.model';\n\nexport const AppInstanceModel: ReturnModelType<typeof AppInstance> = getModelForClass(AppInstance);\nexport * from './app-instance.model';\n\nexport const PaymentConfigurationModel: ReturnModelType<typeof PaymentConfiguration> =\n\tgetModelForClass(PaymentConfiguration);\nexport * from './payment-configuration.model';\n\nexport const ServiceFlagModel: ReturnModelType<typeof ServiceFlag> = getModelForClass(ServiceFlag);\nexport * from './service-flag.model';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"/","sources":["libraries/mongo/models/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;AA0KA,4DAIC;AAED,sEAIC;AAED,sEAIC;AAED,wEAIC;AAED,sEAIC;AAED,4CAIC;AAED,oCAGC;AAED,sDAIC;AAGD,wDAuCC;AA8VD,wEAKC;AApmBD,uEAA6D;AAC7D,qEAA2D;AAC3D,oDAAwG;AACxG,+CAAsC;AACtC,6EAAkE;AAClE,6DAAmD;AACnD,qFAAyE;AACzE,uDAA8C;AAC9C,iDAAwC;AACxC,gEAAsD;AACtD,2DAAiD;AACjD,+CAAsC;AACtC,qDAA4C;AAC5C,mDAA0C;AAC1C,iDAAwC;AACxC,6DAAmD;AACnD,6CAAoC;AACpC,uDAA8C;AAC9C,qEAA2D;AAC3D,qEAA2D;AAC3D,iEAAuD;AACvD,uDAA8C;AAC9C,uDAA6C;AAC7C,uDAA8C;AAC9C,iDAAwC;AACxC,uEAA6D;AAC7D,mDAA0C;AAC1C,mFAAwE;AACxE,iEAAuD;AACvD,qEAA2D;AAC3D,6DAAmD;AACnD,mDAA0C;AAC1C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opPayout } from './providers/shop-payout.model';\nimport { getDiscriminatorModelForClass, getModelForClass, ReturnModelType } from '@typegoose/typegoose';\nimport { Admin } from './admin.model';\nimport { AdminAccessControl } from './admin-access-control.model';\nimport { ActivityLog } from './activity-log.model';\nimport { UserAppSectionSetting } from './user-app-section-setting.model';\nimport { Attribute } from './attribute.model';\nimport { Banner } from './banner.model';\nimport { BaseCoupon } from './base/base-coupon.model';\nimport { BOBFinance } from './bob-finance.model';\nimport { Brand } from './brand.model';\nimport { Category } from './category.model';\nimport { Counter } from './counter.model';\nimport { Coupon } from './coupon.model';\nimport { DealSetting } from './deal-setting.model';\nimport { Dish } from './dish.model';\nimport { Favourite } from './favourite.model';\nimport { FeaturedSetting } from './featured-setting.model';\nimport { FilterContainer } from './filter-container.model';\nimport { ListContainer } from './list-container.model';\nimport { Marketing } from './marketing.model';\nimport { MealPlan } from './meal-plan.model';\nimport { Nutrition } from './nutrition.model';\nimport { Parent } from './parent.model';\nimport { ProductMarketing } from './product-marketing.model';\nimport { Product } from './product.model';\nimport { PunchMarketingHistory } from './punch-marketing-history.model';\nimport { RatingSetting } from './rating-setting.model';\nimport { ReferralSetting } from './referral-setting.model';\nimport { RequestArea } from './request-area.model';\nimport { Setting } from './setting.model';\nimport { ShopAccessControl } from './shop-access-control.model';\nimport { ShopCategory } from './shop-category.model';\nimport { ShopMealPlan } from './shop-meal-plan.model';\nimport { Shop } from './shop.model';\nimport { Subscription } from './subscription.model';\nimport { Tag } from './tag.model';\nimport { Zone } from './zone.model';\nimport { Buy1Get1Marketing } from './providers/buy1-get1-marketing.model';\nimport {\n\tCoreAuthIdentityType,\n\tCounterType,\n\tCouponType,\n\tMarketingType,\n\tOrderType,\n\tPayoutType,\n\tReviewType,\n} from '../../../utilities/enum';\nimport { ServiceAddon } from './service-addon.model';\nimport { CustomCoupon } from './providers/custom-coupon.model';\nimport { DiscountMarketing } from './providers/discount-marketing.model';\nimport { FeaturedMarketing } from './providers/featured-marketing.model';\nimport { FreeDeliveryMarketing } from './providers/free-delivery-marketing.model';\nimport { GlobalCoupon } from './providers/global-coupon.model';\nimport { IndividualStoreCoupon } from './providers/individual-store-coupon.model';\nimport { IndividualUserCoupon } from './providers/individual-user-coupon.model';\nimport { PunchMarketing } from './providers/punch-marketing.model';\nimport { ReferralCodeCoupon } from './providers/referral-code-coupon.model';\nimport { ReferralRewardCoupon } from './providers/referral-reward-coupon.model';\nimport { Notification } from './notification.model';\nimport { CoreAuthIdentity } from './core-auth-identity.model';\nimport { CoreEmailAuthIdentity } from './providers/core-email-auth-identity.model';\nimport { CorePhoneAuthIdentity } from './providers/core-phone-auth-identity.model';\nimport { CoreGoogleAuthIdentity } from './providers/core-google-auth-identity.model';\nimport { CoreAppleAuthIdentity } from './providers/core-apple-auth-identity.model';\nimport { CoreUser } from './core-user.model';\nimport { RiderTracking } from './rider-tracking.model';\nimport { Rider } from './rider.model';\nimport { RiderTimeout } from './rider-timeout.model';\nimport { User } from './user.model';\nimport { Cart } from './cart.model';\nimport { LineItem } from './line-item.model';\nimport { CartParticipant } from './cart-participant.model';\nimport { Gallery } from './gallery.model';\nimport { Order } from './order.model';\nimport { RegularOrder } from './providers/regular-order.model';\nimport { CourierOrder } from './providers/courier-order.model';\nimport { FinanceSettlement } from './finance-settlement.model';\nimport { DefaultChat } from './default-chat.model';\nimport { TermsAndConditions } from './terms-and-conditions.model';\nimport { SupportReason } from './support-reason.model';\nimport { CancellationReason } from './cancellation-reason.model';\nimport { Payout } from './payout.model';\nimport { Reward } from './reward.model';\nimport { Ticket } from './ticket.model';\nimport { Message } from './message.model';\nimport { AgentPerformance } from './agent-performance.model';\nimport { Chatroom } from './chat-room.model';\nimport { initializeRefreshTokenModel } from '../../auth';\nimport { VendorParent } from './vendor-parent.model';\nimport { Vendor } from './vendor.model';\nimport { VendorAccessControl } from './vendor-access-control.model';\nimport { ServiceCategory } from './service-category.model';\nimport { ServicePackage } from './service-package.model';\nimport { Professional } from './professional.model';\nimport { ServiceBooking } from './service-booking.model';\nimport { Service } from './service.model';\nimport { TicketAction } from './ticket-action.model';\nimport { ServiceCart } from './service-cart.model';\nimport { ShopCourierOrder } from './providers/shop-courier.model';\nimport { ServicePromotion } from './service-promotion.model';\nimport { Flag } from './flag.model';\nimport { Review } from './review.model';\nimport { ShopReview } from './providers/shop-review.model';\nimport { RiderReview } from './providers/rider-review.model';\nimport { ServiceBookingReview } from './providers/service-booking-review.model';\nimport { assignIdsToDocuments } from '../../../utilities/id-generator';\nimport { GalleryUpload } from './gallery-upload.model';\nimport { ProductUpload } from './product-upload.model';\nimport { ShopsCategoriesCoupon } from './providers/shops-categories-coupon.model';\nimport { ProfessionalBlockedTime } from './professional-blocked-time.model';\nimport { ZoneExtraTime } from './zone-extra-time';\nimport { AppAppearance } from './app-appearance.model';\nimport { ServiceControl } from './service-control.model';\nimport { Log } from './log.model';\nimport { Card } from './card.model';\nimport { ProductStockTracker } from './product-stock-tracker.model';\nimport { PaymentIntent } from './payment-intent.model';\nimport { AppInstance } from './app-instance.model';\nimport { PaymentConfiguration } from './payment-configuration.model';\nimport { ServiceFlag } from './service-flag.model';\nimport { IntegrationConfiguration } from './integration-configuration.model';\n\n// Regular models (using standard getModelForClass)\nexport const ActivityLogModel: ReturnModelType<typeof ActivityLog> = getModelForClass(ActivityLog);\nexport * from './activity-log.model';\n\nexport const AdminAccessControlModel: ReturnModelType<typeof AdminAccessControl> =\n\tgetModelForClass(AdminAccessControl);\nexport * from './admin-access-control.model';\n\nexport const AdminModel: ReturnModelType<typeof Admin> = getModelForClass(Admin);\nexport * from './admin.model';\n\nexport const UserAppSectionSettingModel: ReturnModelType<typeof UserAppSectionSetting> =\n\tgetModelForClass(UserAppSectionSetting);\nexport * from './user-app-section-setting.model';\n\nexport const AttributeModel: ReturnModelType<typeof Attribute> = getModelForClass(Attribute);\nexport * from './attribute.model';\n\nexport const BannerModel: ReturnModelType<typeof Banner> = getModelForClass(Banner);\nexport * from './banner.model';\n\nexport const BOBFinanceModel: ReturnModelType<typeof BOBFinance> = getModelForClass(BOBFinance);\nexport * from './bob-finance.model';\n\nexport const BrandModel: ReturnModelType<typeof Brand> = getModelForClass(Brand);\nexport * from './brand.model';\n\nexport const AppAppearanceModel: ReturnModelType<typeof AppAppearance> = getModelForClass(AppAppearance);\nexport * from './app-appearance.model';\n\nexport const ServiceControlModel: ReturnModelType<typeof ServiceControl> = getModelForClass(ServiceControl);\nexport * from './service-control.model';\n\n// Global models - will be set after initGlobalConnection()\nlet actualCoreAuthIdentityModel: ReturnModelType<typeof CoreAuthIdentity> | null = null;\nlet actualCoreUserModel: ReturnModelType<typeof CoreUser> | null = null;\nlet actualCardModel: ReturnModelType<typeof Card> | null = null;\nlet actualPaymentIntentModel: ReturnModelType<typeof PaymentIntent> | null = null;\n\n// Global discriminator models - will be set after initGlobalConnection()\nlet actualCoreEmailAuthIdentityModel: ReturnModelType<typeof CoreEmailAuthIdentity> | null = null;\nlet actualCorePhoneAuthIdentityModel: ReturnModelType<typeof CorePhoneAuthIdentity> | null = null;\nlet actualCoreGoogleAuthIdentityModel: ReturnModelType<typeof CoreGoogleAuthIdentity> | null = null;\nlet actualCoreAppleAuthIdentityModel: ReturnModelType<typeof CoreAppleAuthIdentity> | null = null;\n\n// Export getter functions for global models\nexport function getCoreAuthIdentityModel(): ReturnModelType<typeof CoreAuthIdentity> {\n\tif (!actualCoreAuthIdentityModel)\n\t\tthrow new Error('CoreAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreAuthIdentityModel;\n}\n\nexport function getCoreEmailAuthIdentityModel(): ReturnModelType<typeof CoreEmailAuthIdentity> {\n\tif (!actualCoreEmailAuthIdentityModel)\n\t\tthrow new Error('CoreEmailAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreEmailAuthIdentityModel;\n}\n\nexport function getCorePhoneAuthIdentityModel(): ReturnModelType<typeof CorePhoneAuthIdentity> {\n\tif (!actualCorePhoneAuthIdentityModel)\n\t\tthrow new Error('CorePhoneAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCorePhoneAuthIdentityModel;\n}\n\nexport function getCoreGoogleAuthIdentityModel(): ReturnModelType<typeof CoreGoogleAuthIdentity> {\n\tif (!actualCoreGoogleAuthIdentityModel)\n\t\tthrow new Error('CoreGoogleAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreGoogleAuthIdentityModel;\n}\n\nexport function getCoreAppleAuthIdentityModel(): ReturnModelType<typeof CoreAppleAuthIdentity> {\n\tif (!actualCoreAppleAuthIdentityModel)\n\t\tthrow new Error('CoreAppleAuthIdentity model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreAppleAuthIdentityModel;\n}\n\nexport function getCoreUserModel(): ReturnModelType<typeof CoreUser> {\n\tif (!actualCoreUserModel)\n\t\tthrow new Error('CoreUser model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCoreUserModel;\n}\n\nexport function getCardModel(): ReturnModelType<typeof Card> {\n\tif (!actualCardModel) throw new Error('Card model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualCardModel;\n}\n\nexport function getPaymentIntentModel(): ReturnModelType<typeof PaymentIntent> {\n\tif (!actualPaymentIntentModel)\n\t\tthrow new Error('Payment Intent model not initialized yet. Call initGlobalConnection() first.');\n\treturn actualPaymentIntentModel;\n}\n\n// Function to initialize all global models (called from initGlobalConnection)\nexport function initializeGlobalModels(globalConnection: any) {\n\t// Initialize base global models\n\tactualCoreAuthIdentityModel = getModelForClass(CoreAuthIdentity, { existingConnection: globalConnection });\n\tactualCoreUserModel = getModelForClass(CoreUser, { existingConnection: globalConnection });\n\tactualCardModel = getModelForClass(Card, { existingConnection: globalConnection });\n\tactualPaymentIntentModel = getModelForClass(PaymentIntent, { existingConnection: globalConnection });\n\n\t// Initialize discriminator models\n\tactualCoreEmailAuthIdentityModel = getDiscriminatorModelForClass(\n\t\tactualCoreAuthIdentityModel,\n\t\tCoreEmailAuthIdentity,\n\t\tCoreAuthIdentityType.EMAIL,\n\t\t{ existingConnection: globalConnection }\n\t);\n\n\tactualCorePhoneAuthIdentityModel = getDiscriminatorModelForClass(\n\t\tactualCoreAuthIdentityModel,\n\t\tCorePhoneAuthIdentity,\n\t\tCoreAuthIdentityType.PHONE,\n\t\t{ existingConnection: globalConnection }\n\t);\n\n\tactualCoreGoogleAuthIdentityModel = getDiscriminatorModelForClass(\n\t\tactualCoreAuthIdentityModel,\n\t\tCoreGoogleAuthIdentity,\n\t\tCoreAuthIdentityType.GOOGLE,\n\t\t{ existingConnection: globalConnection }\n\t);\n\n\tactualCoreAppleAuthIdentityModel = getDiscriminatorModelForClass(\n\t\tactualCoreAuthIdentityModel,\n\t\tCoreAppleAuthIdentity,\n\t\tCoreAuthIdentityType.APPLE,\n\t\t{ existingConnection: globalConnection }\n\t);\n\n\tinitializeRefreshTokenModel(globalConnection);\n\n\tconsole.log('✅ All global models initialized');\n}\n\nexport const CartModel: ReturnModelType<typeof Cart> = getModelForClass(Cart);\nexport * from './cart.model';\n\nexport const CartParticipantModel: ReturnModelType<typeof CartParticipant> =\n\tgetModelForClass(CartParticipant);\nexport * from './cart-participant.model';\n\nexport const CategoryModel: ReturnModelType<typeof Category> = getModelForClass(Category);\nexport * from './category.model';\n\nexport * from './core-auth-identity.model';\nexport * from './providers/core-apple-auth-identity.model';\nexport * from './providers/core-email-auth-identity.model';\nexport * from './providers/core-google-auth-identity.model';\nexport * from './providers/core-phone-auth-identity.model';\nexport * from './core-user.model';\n\nexport const CounterModel: ReturnModelType<typeof Counter> = getModelForClass(Counter);\nexport * from './counter.model';\n\nexport const CouponModel: ReturnModelType<typeof Coupon> = getModelForClass(Coupon);\nexport const BaseCouponModel: ReturnModelType<typeof BaseCoupon> = getModelForClass(BaseCoupon);\nexport const CustomCouponModel: ReturnModelType<typeof CustomCoupon> = getDiscriminatorModelForClass(\n\tCouponModel,\n\tCustomCoupon,\n\tCouponType.CUSTOM_COUPON\n);\nexport const GlobalCouponModel: ReturnModelType<typeof GlobalCoupon> = getDiscriminatorModelForClass(\n\tCouponModel,\n\tGlobalCoupon,\n\tCouponType.GLOBAL\n);\nexport const ShopsCategoriesCouponModel: ReturnModelType<typeof ShopsCategoriesCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ShopsCategoriesCoupon, CouponType.SHOPS_CATEGORIES);\nexport const IndividualStoreCouponModel: ReturnModelType<typeof IndividualStoreCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, IndividualStoreCoupon, CouponType.INDIVIDUAL_STORE);\nexport const IndividualUserCouponModel: ReturnModelType<typeof IndividualUserCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, IndividualUserCoupon, CouponType.INDIVIDUAL_USER);\nexport const ReferralCodeCouponModel: ReturnModelType<typeof ReferralCodeCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ReferralCodeCoupon, CouponType.REFERRAL_CODE);\nexport const ReferralRewardCouponModel: ReturnModelType<typeof ReferralRewardCoupon> =\n\tgetDiscriminatorModelForClass(CouponModel, ReferralRewardCoupon, CouponType.REFERRAL_REWARD);\nexport * from './coupon.model';\nexport * from './base/base-coupon.model';\nexport * from './providers/custom-coupon.model';\nexport * from './providers/global-coupon.model';\nexport * from './providers/shops-categories-coupon.model';\nexport * from './providers/individual-store-coupon.model';\nexport * from './providers/individual-user-coupon.model';\nexport * from './providers/referral-code-coupon.model';\nexport * from './providers/referral-reward-coupon.model';\n\nexport const DealSettingModel: ReturnModelType<typeof DealSetting> = getModelForClass(DealSetting);\nexport * from './deal-setting.model';\n\nexport const DishModel: ReturnModelType<typeof Dish> = getModelForClass(Dish);\nexport * from './dish.model';\n\nexport const FavouriteModel: ReturnModelType<typeof Favourite> = getModelForClass(Favourite);\nexport * from './favourite.model';\n\nexport const FeaturedSettingModel: ReturnModelType<typeof FeaturedSetting> =\n\tgetModelForClass(FeaturedSetting);\nexport * from './featured-setting.model';\n\nexport const FilterContainerModel: ReturnModelType<typeof FilterContainer> =\n\tgetModelForClass(FilterContainer);\nexport * from './filter-container.model';\n\nexport const FinanceSettlementModel: ReturnModelType<typeof FinanceSettlement> =\n\tgetModelForClass(FinanceSettlement);\nexport * from './finance-settlement.model';\n\nexport const FlagModel: ReturnModelType<typeof Flag> = getModelForClass(Flag);\nexport * from './flag.model';\n\nexport const GalleryModel: ReturnModelType<typeof Gallery> = getModelForClass(Gallery);\nexport * from './gallery.model';\n\nexport const GalleryUploadModel: ReturnModelType<typeof GalleryUpload> = getModelForClass(GalleryUpload);\nexport * from './gallery-upload.model';\n\nexport const LineItemModel: ReturnModelType<typeof LineItem> = getModelForClass(LineItem);\nexport * from './line-item.model';\n\nexport const ListContainerModel: ReturnModelType<typeof ListContainer> = getModelForClass(ListContainer);\nexport * from './list-container.model';\n\nexport const MarketingModel: ReturnModelType<typeof Marketing> = getModelForClass(Marketing);\nexport const Buy1Get1MarketingModel: ReturnModelType<typeof Buy1Get1Marketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, Buy1Get1Marketing, MarketingType.BUY1GET1);\nexport const DiscountMarketingModel: ReturnModelType<typeof DiscountMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, DiscountMarketing, MarketingType.DISCOUNT);\nexport const FeaturedMarketingModel: ReturnModelType<typeof FeaturedMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, FeaturedMarketing, MarketingType.FEATURED);\nexport const FreeDeliveryMarketingModel: ReturnModelType<typeof FreeDeliveryMarketing> =\n\tgetDiscriminatorModelForClass(MarketingModel, FreeDeliveryMarketing, MarketingType.FREE_DELIVERY);\nexport const PunchMarketingModel: ReturnModelType<typeof PunchMarketing> = getDiscriminatorModelForClass(\n\tMarketingModel,\n\tPunchMarketing,\n\tMarketingType.PUNCH_MARKETING\n);\nexport * from './marketing.model';\nexport * from './providers/buy1-get1-marketing.model';\nexport * from './providers/discount-marketing.model';\nexport * from './providers/featured-marketing.model';\nexport * from './providers/free-delivery-marketing.model';\nexport * from './providers/punch-marketing.model';\n\nexport const MealPlanModel: ReturnModelType<typeof MealPlan> = getModelForClass(MealPlan);\nexport * from './meal-plan.model';\n\nexport const NotificationModel: ReturnModelType<typeof Notification> = getModelForClass(Notification);\nexport * from './notification.model';\n\nexport const NutritionModel: ReturnModelType<typeof Nutrition> = getModelForClass(Nutrition);\nexport * from './nutrition.model';\n\nexport const OrderModel: ReturnModelType<typeof Order> = getModelForClass(Order);\nexport const RegularOrderModel: ReturnModelType<typeof RegularOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tRegularOrder,\n\tOrderType.REGULAR\n);\nexport const CourierOrderModel: ReturnModelType<typeof CourierOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tCourierOrder,\n\tOrderType.COURIER\n);\n\nexport const ShopCourierOrderModel: ReturnModelType<typeof ShopCourierOrder> = getDiscriminatorModelForClass(\n\tOrderModel,\n\tShopCourierOrder,\n\tOrderType.SHOP_COURIER\n);\n\nexport * from './order.model';\nexport * from './providers/regular-order.model';\nexport * from './providers/courier-order.model';\nexport * from './providers/shop-courier.model';\n\nexport const ParentModel: ReturnModelType<typeof Parent> = getModelForClass(Parent);\nexport * from './parent.model';\n\nexport const PayoutModel: ReturnModelType<typeof Payout> = getModelForClass(Payout);\nexport const ShopPayoutModel: ReturnModelType<typeof ShopPayout> = getDiscriminatorModelForClass(\n\tPayoutModel,\n\tShopPayout,\n\tPayoutType.SHOP\n);\nexport const RiderPayoutModel: ReturnModelType<typeof RiderPayout> = getDiscriminatorModelForClass(\n\tPayoutModel,\n\tRiderPayout,\n\tPayoutType.RIDER\n);\nexport * from './payout.model';\nexport * from './providers/shop-payout.model';\nexport * from './providers/rider-payout.model';\n\nexport const ProductMarketingModel: ReturnModelType<typeof ProductMarketing> =\n\tgetModelForClass(ProductMarketing);\nexport * from './product-marketing.model';\n\nexport const ProductStockTrackerModel: ReturnModelType<typeof ProductStockTracker> =\n\tgetModelForClass(ProductStockTracker);\nexport * from './product-stock-tracker.model';\n\nexport const ProductModel: ReturnModelType<typeof Product> = getModelForClass(Product);\nexport * from './product.model';\nProductModel.schema.pre('insertMany', async function (next, docs: Product[]) {\n\t// Generate all IDs at once (ATOMIC)\n\tawait assignIdsToDocuments(CounterModel, CounterType.ITEM, docs, 'productId');\n\tnext();\n});\n\nexport const ProductUploadModel: ReturnModelType<typeof ProductUpload> = getModelForClass(ProductUpload);\nexport * from './product-upload.model';\n\nexport const PunchMarketingHistoryModel: ReturnModelType<typeof PunchMarketingHistory> =\n\tgetModelForClass(PunchMarketingHistory);\nexport * from './punch-marketing-history.model';\n\nexport const RatingSettingModel: ReturnModelType<typeof RatingSetting> = getModelForClass(RatingSetting);\nexport * from './rating-setting.model';\n\nexport const ReferralSettingModel: ReturnModelType<typeof ReferralSetting> =\n\tgetModelForClass(ReferralSetting);\nexport * from './referral-setting.model';\n\nexport const RequestAreaModel: ReturnModelType<typeof RequestArea> = getModelForClass(RequestArea);\nexport * from './request-area.model';\n\nexport const ReviewModel: ReturnModelType<typeof Review> = getModelForClass(Review);\nexport const ShopReviewModel: ReturnModelType<typeof ShopReview> = getDiscriminatorModelForClass(\n\tReviewModel,\n\tShopReview,\n\tReviewType.SHOP\n);\nexport const RiderReviewModel: ReturnModelType<typeof RiderReview> = getDiscriminatorModelForClass(\n\tReviewModel,\n\tRiderReview,\n\tReviewType.RIDER\n);\nexport const ServiceBookingReviewModel: ReturnModelType<typeof ServiceBookingReview> =\n\tgetDiscriminatorModelForClass(ReviewModel, ServiceBookingReview, ReviewType.SERVICE_BOOKING);\nexport * from './review.model';\nexport * from './providers/shop-review.model';\nexport * from './providers/rider-review.model';\nexport * from './providers/service-booking-review.model';\n\nexport const RiderTimeoutModel: ReturnModelType<typeof RiderTimeout> = getModelForClass(RiderTimeout);\nexport * from './rider-timeout.model';\n\nexport const RiderTrackingModel: ReturnModelType<typeof RiderTracking> = getModelForClass(RiderTracking);\nexport * from './rider-tracking.model';\n\nexport const RiderModel: ReturnModelType<typeof Rider> = getModelForClass(Rider);\nexport * from './rider.model';\n\nexport const SettingModel: ReturnModelType<typeof Setting> = getModelForClass(Setting);\nexport * from './setting.model';\n\nexport const ShopAccessControlModel: ReturnModelType<typeof ShopAccessControl> =\n\tgetModelForClass(ShopAccessControl);\nexport * from './shop-access-control.model';\n\nexport const ShopCategoryModel: ReturnModelType<typeof ShopCategory> = getModelForClass(ShopCategory);\nexport * from './shop-category.model';\n\nexport const ShopMealPlanModel: ReturnModelType<typeof ShopMealPlan> = getModelForClass(ShopMealPlan);\nexport * from './shop-meal-plan.model';\n\nexport const ShopModel: ReturnModelType<typeof Shop> = getModelForClass(Shop);\nexport * from './shop.model';\n\nexport const SubscriptionModel: ReturnModelType<typeof Subscription> = getModelForClass(Subscription);\nexport * from './subscription.model';\n\nexport const TagModel: ReturnModelType<typeof Tag> = getModelForClass(Tag);\nexport * from './tag.model';\n\nexport const UserModel: ReturnModelType<typeof User> = getModelForClass(User);\nexport * from './user.model';\n\nexport const ZoneModel: ReturnModelType<typeof Zone> = getModelForClass(Zone);\nexport * from './zone.model';\n\nexport const DefaultChatModel: ReturnModelType<typeof DefaultChat> = getModelForClass(DefaultChat);\nexport * from './default-chat.model';\n\nexport const TermsAndConditionsModel: ReturnModelType<typeof TermsAndConditions> =\n\tgetModelForClass(TermsAndConditions);\nexport * from './terms-and-conditions.model';\n\nexport const SupportReasonModel: ReturnModelType<typeof SupportReason> = getModelForClass(SupportReason);\nexport * from './support-reason.model';\n\nexport const CancellationReasonModel: ReturnModelType<typeof CancellationReason> =\n\tgetModelForClass(CancellationReason);\nexport * from './cancellation-reason.model';\n\nexport * from './embedded/trip-leg.mode';\nexport * from './embedded/rider-assignment-model';\n\nexport const RewardModel: ReturnModelType<typeof Reward> = getModelForClass(Reward);\nexport * from './reward.model';\n\nexport const TicketModel: ReturnModelType<typeof Ticket> = getModelForClass(Ticket);\nexport * from './ticket.model';\n\nexport const MessageModel: ReturnModelType<typeof Message> = getModelForClass(Message);\nexport * from './message.model';\n\nexport const AgentPerformanceModel: ReturnModelType<typeof AgentPerformance> =\n\tgetModelForClass(AgentPerformance);\nexport * from './agent-performance.model';\n\nexport const ChatroomModel: ReturnModelType<typeof Chatroom> = getModelForClass(Chatroom);\nexport * from './chat-room.model';\n\nexport * from './embedded/chat-participant.model';\nexport * from './embedded/external-ref.model';\n\nexport const ServiceModel: ReturnModelType<typeof Service> = getModelForClass(Service);\nexport * from './service.model';\n\nexport const VendorParentModel: ReturnModelType<typeof VendorParent> = getModelForClass(VendorParent);\nexport * from './vendor-parent.model';\n\nexport const VendorModel: ReturnModelType<typeof Vendor> = getModelForClass(Vendor);\nexport * from './vendor.model';\n\nexport const VendorAccessControlModel: ReturnModelType<typeof VendorAccessControl> =\n\tgetModelForClass(VendorAccessControl);\nexport * from './vendor-access-control.model';\n\nexport const ServiceCategoryModel: ReturnModelType<typeof ServiceCategory> =\n\tgetModelForClass(ServiceCategory);\nexport * from './service-category.model';\n\nexport const ServiceAddonModel: ReturnModelType<typeof ServiceAddon> = getModelForClass(ServiceAddon);\nexport * from './service-addon.model';\n\nexport const ServicePackageModel: ReturnModelType<typeof ServicePackage> = getModelForClass(ServicePackage);\nexport * from './service-package.model';\n\nexport const ProfessionalModel: ReturnModelType<typeof Professional> = getModelForClass(Professional);\nexport * from './professional.model';\n\nexport const ServiceCartModel: ReturnModelType<typeof ServiceCart> = getModelForClass(ServiceCart);\nexport * from './service-cart.model';\n\nexport const ServiceBookingModel: ReturnModelType<typeof ServiceBooking> = getModelForClass(ServiceBooking);\nexport * from './service-booking.model';\n\nexport const ProfessionalBlockedTimeModel: ReturnModelType<typeof ProfessionalBlockedTime> =\n\tgetModelForClass(ProfessionalBlockedTime);\nexport * from './professional-blocked-time.model';\n\nexport const TicketActionModel: ReturnModelType<typeof TicketAction> = getModelForClass(TicketAction);\nexport * from './ticket-action.model';\n\nexport const ServicePromotionModel: ReturnModelType<typeof ServicePromotion> =\n\tgetModelForClass(ServicePromotion);\nexport * from './service-promotion.model';\n\nexport const LoggerModel: ReturnModelType<typeof Log> = getModelForClass(Log);\nexport * from './log.model';\n\nexport const ZoneExtraTimeModel: ReturnModelType<typeof ZoneExtraTime> = getModelForClass(ZoneExtraTime);\nexport * from './zone-extra-time';\n\nexport * from './google-maps-usage.model';\n\nexport const AppInstanceModel: ReturnModelType<typeof AppInstance> = getModelForClass(AppInstance);\nexport * from './app-instance.model';\n\nexport const PaymentConfigurationModel: ReturnModelType<typeof PaymentConfiguration> =\n\tgetModelForClass(PaymentConfiguration);\nexport * from './payment-configuration.model';\n\nexport const ServiceFlagModel: ReturnModelType<typeof ServiceFlag> = getModelForClass(ServiceFlag);\nexport * from './service-flag.model';\n\nexport const IntegrationConfigurationModel: ReturnModelType<typeof IntegrationConfiguration> =\n\tgetModelForClass(IntegrationConfiguration);\nexport * from './integration-configuration.model';\n\nexport function createIntegrationDiscriminator<U extends new (...args: any[]) => IntegrationConfiguration>(\n\tcls: U,\n\tkey: string\n): ReturnModelType<U> {\n\treturn getDiscriminatorModelForClass(IntegrationConfigurationModel, cls, key);\n}\n"]}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.IntegrationConfiguration = void 0;
|
|
13
|
+
const typegoose_1 = require("@typegoose/typegoose");
|
|
14
|
+
const defaultClasses_1 = require("@typegoose/typegoose/lib/defaultClasses");
|
|
15
|
+
let IntegrationConfiguration = class IntegrationConfiguration extends defaultClasses_1.TimeStamps {
|
|
16
|
+
name;
|
|
17
|
+
active;
|
|
18
|
+
};
|
|
19
|
+
exports.IntegrationConfiguration = IntegrationConfiguration;
|
|
20
|
+
__decorate([
|
|
21
|
+
(0, typegoose_1.prop)({ required: true, type: String }),
|
|
22
|
+
__metadata("design:type", String)
|
|
23
|
+
], IntegrationConfiguration.prototype, "name", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, typegoose_1.prop)({ type: Boolean, default: false }),
|
|
26
|
+
__metadata("design:type", Boolean)
|
|
27
|
+
], IntegrationConfiguration.prototype, "active", void 0);
|
|
28
|
+
exports.IntegrationConfiguration = IntegrationConfiguration = __decorate([
|
|
29
|
+
(0, typegoose_1.modelOptions)({
|
|
30
|
+
schemaOptions: { collection: 'integrationConfigurations', discriminatorKey: 'name' },
|
|
31
|
+
})
|
|
32
|
+
], IntegrationConfiguration);
|
|
33
|
+
//# sourceMappingURL=integration-configuration.model.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"integration-configuration.model.js","sourceRoot":"/","sources":["libraries/mongo/models/integration-configuration.model.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oDAA0D;AAC1D,4EAAqE;AAK9D,IAAM,wBAAwB,GAA9B,MAAM,wBAAyB,SAAQ,2BAAU;IAEhD,IAAI,CAAU;IAGd,MAAM,CAAW;CACxB,CAAA;AANY,4DAAwB;AAE7B;IADN,IAAA,gBAAI,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;sDAClB;AAGd;IADN,IAAA,gBAAI,EAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;;wDAChB;mCALZ,wBAAwB;IAHpC,IAAA,wBAAY,EAAC;QACb,aAAa,EAAE,EAAE,UAAU,EAAE,2BAA2B,EAAE,gBAAgB,EAAE,MAAM,EAAE;KACpF,CAAC;GACW,wBAAwB,CAMpC","sourcesContent":["import { modelOptions, prop } from '@typegoose/typegoose';\nimport { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';\n\n@modelOptions({\n\tschemaOptions: { collection: 'integrationConfigurations', discriminatorKey: 'name' },\n})\nexport class IntegrationConfiguration extends TimeStamps {\n\t@prop({ required: true, type: String })\n\tpublic name!: string;\n\n\t@prop({ type: Boolean, default: false })\n\tpublic active!: boolean;\n}\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ReturnModelType } from '@typegoose/typegoose';
|
|
2
2
|
import { TimeStamps } from '@typegoose/typegoose/lib/defaultClasses';
|
|
3
|
-
import { HttpStatus, LogLevel } from '../../../utilities/enum';
|
|
3
|
+
import { HttpStatus, LogLevel, LogTag } from '../../../utilities/enum';
|
|
4
4
|
import { LogMetadata, RequestContext } from '../../logger-kit';
|
|
5
5
|
export interface LogModelConfig {
|
|
6
6
|
ttlDays?: number;
|
|
@@ -10,7 +10,7 @@ export interface LogModelConfig {
|
|
|
10
10
|
export declare class Log extends TimeStamps {
|
|
11
11
|
level: LogLevel;
|
|
12
12
|
microService: string;
|
|
13
|
-
tag: string;
|
|
13
|
+
tag: LogTag | string;
|
|
14
14
|
subtag?: string;
|
|
15
15
|
requestId?: string;
|
|
16
16
|
data?: Record<string, any>;
|