@lyxa.ai/core 1.0.66 → 1.0.67-debug.2
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/mongo/models/app-screen-setting.model.d.ts +9 -0
- package/dist/libraries/mongo/models/app-screen-setting.model.js +72 -0
- package/dist/libraries/mongo/models/app-screen-setting.model.js.map +1 -0
- package/dist/libraries/mongo/models/embedded/cash-settlement.model.d.ts +8 -0
- package/dist/libraries/mongo/models/embedded/cash-settlement.model.js +47 -0
- package/dist/libraries/mongo/models/embedded/cash-settlement.model.js.map +1 -0
- package/dist/libraries/mongo/models/embedded/courier-order-finance.model.d.ts +7 -0
- package/dist/libraries/mongo/models/embedded/courier-order-finance.model.js +30 -0
- package/dist/libraries/mongo/models/embedded/courier-order-finance.model.js.map +1 -0
- package/dist/libraries/mongo/models/embedded/order-finance.model.d.ts +11 -0
- package/dist/libraries/mongo/models/embedded/order-finance.model.js +46 -0
- package/dist/libraries/mongo/models/embedded/order-finance.model.js.map +1 -0
- package/dist/libraries/mongo/models/embedded/order-pricing.model.d.ts +10 -8
- package/dist/libraries/mongo/models/embedded/order-pricing.model.js +30 -27
- package/dist/libraries/mongo/models/embedded/order-pricing.model.js.map +1 -1
- package/dist/libraries/mongo/models/embedded/regular-order-finance.model.d.ts +18 -0
- package/dist/libraries/mongo/models/embedded/regular-order-finance.model.js +77 -0
- package/dist/libraries/mongo/models/embedded/regular-order-finance.model.js.map +1 -0
- package/dist/libraries/mongo/models/embedded/rider-assignment-model.d.ts +8 -0
- package/dist/libraries/mongo/models/embedded/rider-assignment-model.js +44 -0
- package/dist/libraries/mongo/models/embedded/rider-assignment-model.js.map +1 -0
- package/dist/libraries/mongo/models/embedded/trip-leg.mode.d.ts +25 -0
- package/dist/libraries/mongo/models/embedded/trip-leg.mode.js +121 -0
- package/dist/libraries/mongo/models/embedded/trip-leg.mode.js.map +1 -0
- package/dist/libraries/mongo/models/index.d.ts +2 -9
- package/dist/libraries/mongo/models/index.js +3 -10
- package/dist/libraries/mongo/models/index.js.map +1 -1
- package/dist/libraries/mongo/models/order-delivery.model.d.ts +5 -30
- package/dist/libraries/mongo/models/order-delivery.model.js +15 -136
- package/dist/libraries/mongo/models/order-delivery.model.js.map +1 -1
- package/dist/libraries/mongo/models/order-finance.model.d.ts +2 -0
- package/dist/libraries/mongo/models/order-finance.model.js +6 -0
- package/dist/libraries/mongo/models/order-finance.model.js.map +1 -1
- package/dist/libraries/mongo/models/order-payment.model.d.ts +17 -0
- package/dist/libraries/mongo/models/order-payment.model.js +84 -0
- package/dist/libraries/mongo/models/order-payment.model.js.map +1 -0
- package/dist/libraries/mongo/models/order.model.d.ts +3 -0
- package/dist/libraries/mongo/models/order.model.js +11 -1
- package/dist/libraries/mongo/models/order.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/courier-order.model.d.ts +2 -0
- package/dist/libraries/mongo/models/providers/courier-order.model.js +6 -0
- package/dist/libraries/mongo/models/providers/courier-order.model.js.map +1 -1
- package/dist/libraries/mongo/models/providers/regular-order.model.d.ts +2 -0
- package/dist/libraries/mongo/models/providers/regular-order.model.js +6 -0
- package/dist/libraries/mongo/models/providers/regular-order.model.js.map +1 -1
- package/dist/libraries/mongo/models/rider.model.js +1 -1
- package/dist/libraries/mongo/models/rider.model.js.map +1 -1
- package/dist/libraries/mongo/models/shop.model.js.map +1 -1
- package/dist/libraries/mongo/models/zone.model.d.ts +2 -0
- package/dist/libraries/mongo/models/zone.model.js +10 -0
- package/dist/libraries/mongo/models/zone.model.js.map +1 -1
- package/dist/utilities/validation/common-validation.d.ts +146 -146
- package/dist/utilities/validation/global-validation.d.ts +2 -6
- package/dist/utilities/validation/global-validation.js +1 -19
- package/dist/utilities/validation/global-validation.js.map +1 -1
- package/package.json +1 -1
|
@@ -150,11 +150,11 @@ export declare const FilterSchema: z.ZodOptional<z.ZodObject<{
|
|
|
150
150
|
export type FilterDTO = z.infer<typeof FilterSchema>;
|
|
151
151
|
export declare const StringSchema: z.ZodString;
|
|
152
152
|
export declare const AddressSchema: z.ZodObject<{
|
|
153
|
-
address: z.ZodString
|
|
154
|
-
description: z.ZodOptional<z.ZodString
|
|
155
|
-
city: z.ZodString
|
|
156
|
-
state: z.ZodString
|
|
157
|
-
country: z.ZodString
|
|
153
|
+
address: z.ZodString;
|
|
154
|
+
description: z.ZodOptional<z.ZodString>;
|
|
155
|
+
city: z.ZodString;
|
|
156
|
+
state: z.ZodString;
|
|
157
|
+
country: z.ZodString;
|
|
158
158
|
location: z.ZodObject<{
|
|
159
159
|
type: z.ZodDefault<z.ZodNativeEnum<typeof GeoLocationType>>;
|
|
160
160
|
coordinates: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
@@ -173,34 +173,34 @@ export declare const AddressSchema: z.ZodObject<{
|
|
|
173
173
|
type: GeoLocationType;
|
|
174
174
|
coordinates: [number, number];
|
|
175
175
|
};
|
|
176
|
+
state: string;
|
|
177
|
+
address: string;
|
|
178
|
+
country: string;
|
|
179
|
+
city: string;
|
|
176
180
|
latitude: number;
|
|
177
181
|
longitude: number;
|
|
178
|
-
|
|
179
|
-
address?: string | null | undefined;
|
|
180
|
-
country?: string | null | undefined;
|
|
181
|
-
description?: string | null | undefined;
|
|
182
|
-
city?: string | null | undefined;
|
|
182
|
+
description?: string | undefined;
|
|
183
183
|
zone?: import("mongoose").Types.ObjectId | undefined;
|
|
184
184
|
}, {
|
|
185
185
|
location: {
|
|
186
186
|
coordinates: [number, number];
|
|
187
187
|
type?: GeoLocationType | undefined;
|
|
188
188
|
};
|
|
189
|
+
state: string;
|
|
190
|
+
address: string;
|
|
191
|
+
country: string;
|
|
192
|
+
city: string;
|
|
189
193
|
latitude: number;
|
|
190
194
|
longitude: number;
|
|
191
|
-
|
|
192
|
-
address?: string | null | undefined;
|
|
193
|
-
country?: string | null | undefined;
|
|
194
|
-
description?: string | null | undefined;
|
|
195
|
-
city?: string | null | undefined;
|
|
195
|
+
description?: string | undefined;
|
|
196
196
|
zone?: string | import("mongoose").Types.ObjectId | undefined;
|
|
197
197
|
}>;
|
|
198
198
|
export declare const UserAddressSchema: z.ZodObject<{
|
|
199
|
-
address: z.ZodString
|
|
200
|
-
description: z.ZodOptional<z.ZodString
|
|
201
|
-
city: z.ZodString
|
|
202
|
-
state: z.ZodString
|
|
203
|
-
country: z.ZodString
|
|
199
|
+
address: z.ZodString;
|
|
200
|
+
description: z.ZodOptional<z.ZodString>;
|
|
201
|
+
city: z.ZodString;
|
|
202
|
+
state: z.ZodString;
|
|
203
|
+
country: z.ZodString;
|
|
204
204
|
location: z.ZodObject<{
|
|
205
205
|
type: z.ZodDefault<z.ZodNativeEnum<typeof GeoLocationType>>;
|
|
206
206
|
coordinates: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
@@ -215,54 +215,54 @@ export declare const UserAddressSchema: z.ZodObject<{
|
|
|
215
215
|
longitude: z.ZodNumber;
|
|
216
216
|
zone: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, import("mongoose").Types.ObjectId, string>, z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>]>>;
|
|
217
217
|
} & {
|
|
218
|
-
addressLabel: z.ZodString
|
|
219
|
-
apartment: z.ZodString
|
|
220
|
-
buildingName: z.ZodString
|
|
221
|
-
deliveryOption: z.ZodOptional<z.ZodString
|
|
222
|
-
instructions: z.ZodOptional<z.ZodString
|
|
218
|
+
addressLabel: z.ZodString;
|
|
219
|
+
apartment: z.ZodString;
|
|
220
|
+
buildingName: z.ZodString;
|
|
221
|
+
deliveryOption: z.ZodOptional<z.ZodString>;
|
|
222
|
+
instructions: z.ZodOptional<z.ZodString>;
|
|
223
223
|
}, "strip", z.ZodTypeAny, {
|
|
224
224
|
location: {
|
|
225
225
|
type: GeoLocationType;
|
|
226
226
|
coordinates: [number, number];
|
|
227
227
|
};
|
|
228
|
+
state: string;
|
|
229
|
+
address: string;
|
|
230
|
+
country: string;
|
|
231
|
+
city: string;
|
|
228
232
|
latitude: number;
|
|
229
233
|
longitude: number;
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
description?: string |
|
|
234
|
-
city?: string | null | undefined;
|
|
234
|
+
addressLabel: string;
|
|
235
|
+
apartment: string;
|
|
236
|
+
buildingName: string;
|
|
237
|
+
description?: string | undefined;
|
|
235
238
|
zone?: import("mongoose").Types.ObjectId | undefined;
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
buildingName?: string | null | undefined;
|
|
239
|
-
deliveryOption?: string | null | undefined;
|
|
240
|
-
instructions?: string | null | undefined;
|
|
239
|
+
deliveryOption?: string | undefined;
|
|
240
|
+
instructions?: string | undefined;
|
|
241
241
|
}, {
|
|
242
242
|
location: {
|
|
243
243
|
coordinates: [number, number];
|
|
244
244
|
type?: GeoLocationType | undefined;
|
|
245
245
|
};
|
|
246
|
+
state: string;
|
|
247
|
+
address: string;
|
|
248
|
+
country: string;
|
|
249
|
+
city: string;
|
|
246
250
|
latitude: number;
|
|
247
251
|
longitude: number;
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
description?: string |
|
|
252
|
-
city?: string | null | undefined;
|
|
252
|
+
addressLabel: string;
|
|
253
|
+
apartment: string;
|
|
254
|
+
buildingName: string;
|
|
255
|
+
description?: string | undefined;
|
|
253
256
|
zone?: string | import("mongoose").Types.ObjectId | undefined;
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
buildingName?: string | null | undefined;
|
|
257
|
-
deliveryOption?: string | null | undefined;
|
|
258
|
-
instructions?: string | null | undefined;
|
|
257
|
+
deliveryOption?: string | undefined;
|
|
258
|
+
instructions?: string | undefined;
|
|
259
259
|
}>;
|
|
260
260
|
export declare const CourierAddressSchema: z.ZodObject<{
|
|
261
|
-
address: z.ZodString
|
|
262
|
-
description: z.ZodOptional<z.ZodString
|
|
263
|
-
city: z.ZodString
|
|
264
|
-
state: z.ZodString
|
|
265
|
-
country: z.ZodString
|
|
261
|
+
address: z.ZodString;
|
|
262
|
+
description: z.ZodOptional<z.ZodString>;
|
|
263
|
+
city: z.ZodString;
|
|
264
|
+
state: z.ZodString;
|
|
265
|
+
country: z.ZodString;
|
|
266
266
|
location: z.ZodObject<{
|
|
267
267
|
type: z.ZodDefault<z.ZodNativeEnum<typeof GeoLocationType>>;
|
|
268
268
|
coordinates: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
|
|
@@ -277,54 +277,54 @@ export declare const CourierAddressSchema: z.ZodObject<{
|
|
|
277
277
|
longitude: z.ZodNumber;
|
|
278
278
|
zone: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, import("mongoose").Types.ObjectId, string>, z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>]>>;
|
|
279
279
|
} & {
|
|
280
|
-
addressLabel: z.ZodString
|
|
281
|
-
apartment: z.ZodString
|
|
282
|
-
buildingName: z.ZodString
|
|
283
|
-
deliveryOption: z.ZodOptional<z.ZodString
|
|
284
|
-
instructions: z.ZodOptional<z.ZodString
|
|
280
|
+
addressLabel: z.ZodString;
|
|
281
|
+
apartment: z.ZodString;
|
|
282
|
+
buildingName: z.ZodString;
|
|
283
|
+
deliveryOption: z.ZodOptional<z.ZodString>;
|
|
284
|
+
instructions: z.ZodOptional<z.ZodString>;
|
|
285
285
|
} & {
|
|
286
|
-
name: z.ZodString
|
|
287
|
-
phoneNumber: z.ZodString
|
|
286
|
+
name: z.ZodString;
|
|
287
|
+
phoneNumber: z.ZodString;
|
|
288
288
|
}, "strip", z.ZodTypeAny, {
|
|
289
|
+
name: string;
|
|
289
290
|
location: {
|
|
290
291
|
type: GeoLocationType;
|
|
291
292
|
coordinates: [number, number];
|
|
292
293
|
};
|
|
294
|
+
state: string;
|
|
295
|
+
address: string;
|
|
296
|
+
country: string;
|
|
297
|
+
phoneNumber: string;
|
|
298
|
+
city: string;
|
|
293
299
|
latitude: number;
|
|
294
300
|
longitude: number;
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
description?: string | null | undefined;
|
|
300
|
-
phoneNumber?: string | null | undefined;
|
|
301
|
-
city?: string | null | undefined;
|
|
301
|
+
addressLabel: string;
|
|
302
|
+
apartment: string;
|
|
303
|
+
buildingName: string;
|
|
304
|
+
description?: string | undefined;
|
|
302
305
|
zone?: import("mongoose").Types.ObjectId | undefined;
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
buildingName?: string | null | undefined;
|
|
306
|
-
deliveryOption?: string | null | undefined;
|
|
307
|
-
instructions?: string | null | undefined;
|
|
306
|
+
deliveryOption?: string | undefined;
|
|
307
|
+
instructions?: string | undefined;
|
|
308
308
|
}, {
|
|
309
|
+
name: string;
|
|
309
310
|
location: {
|
|
310
311
|
coordinates: [number, number];
|
|
311
312
|
type?: GeoLocationType | undefined;
|
|
312
313
|
};
|
|
314
|
+
state: string;
|
|
315
|
+
address: string;
|
|
316
|
+
country: string;
|
|
317
|
+
phoneNumber: string;
|
|
318
|
+
city: string;
|
|
313
319
|
latitude: number;
|
|
314
320
|
longitude: number;
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
description?: string | null | undefined;
|
|
320
|
-
phoneNumber?: string | null | undefined;
|
|
321
|
-
city?: string | null | undefined;
|
|
321
|
+
addressLabel: string;
|
|
322
|
+
apartment: string;
|
|
323
|
+
buildingName: string;
|
|
324
|
+
description?: string | undefined;
|
|
322
325
|
zone?: string | import("mongoose").Types.ObjectId | undefined;
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
buildingName?: string | null | undefined;
|
|
326
|
-
deliveryOption?: string | null | undefined;
|
|
327
|
-
instructions?: string | null | undefined;
|
|
326
|
+
deliveryOption?: string | undefined;
|
|
327
|
+
instructions?: string | undefined;
|
|
328
328
|
}>;
|
|
329
329
|
export declare const DurationSchema: z.ZodObject<{
|
|
330
330
|
start: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
@@ -340,56 +340,56 @@ export declare const NormalHourSchema: z.ZodObject<{
|
|
|
340
340
|
day: z.ZodNativeEnum<typeof WeekDay>;
|
|
341
341
|
status: z.ZodNativeEnum<typeof WorkStatus>;
|
|
342
342
|
openingHours: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
343
|
-
start: z.ZodString
|
|
344
|
-
end: z.ZodString
|
|
343
|
+
start: z.ZodString;
|
|
344
|
+
end: z.ZodString;
|
|
345
345
|
}, "strip", z.ZodTypeAny, {
|
|
346
|
-
end
|
|
347
|
-
start
|
|
346
|
+
end: string;
|
|
347
|
+
start: string;
|
|
348
348
|
}, {
|
|
349
|
-
end
|
|
350
|
-
start
|
|
349
|
+
end: string;
|
|
350
|
+
start: string;
|
|
351
351
|
}>, "many">>;
|
|
352
352
|
}, "strip", z.ZodTypeAny, {
|
|
353
353
|
status: WorkStatus;
|
|
354
354
|
day: WeekDay;
|
|
355
355
|
openingHours: {
|
|
356
|
-
end
|
|
357
|
-
start
|
|
356
|
+
end: string;
|
|
357
|
+
start: string;
|
|
358
358
|
}[];
|
|
359
359
|
}, {
|
|
360
360
|
status: WorkStatus;
|
|
361
361
|
day: WeekDay;
|
|
362
362
|
openingHours?: {
|
|
363
|
-
end
|
|
364
|
-
start
|
|
363
|
+
end: string;
|
|
364
|
+
start: string;
|
|
365
365
|
}[] | undefined;
|
|
366
366
|
}>;
|
|
367
367
|
export declare const HolidayHourSchema: z.ZodObject<{
|
|
368
368
|
date: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
369
369
|
status: z.ZodNativeEnum<typeof HolidayWorkStatus>;
|
|
370
370
|
closingHour: z.ZodObject<{
|
|
371
|
-
start: z.ZodString
|
|
372
|
-
end: z.ZodString
|
|
371
|
+
start: z.ZodString;
|
|
372
|
+
end: z.ZodString;
|
|
373
373
|
}, "strip", z.ZodTypeAny, {
|
|
374
|
-
end
|
|
375
|
-
start
|
|
374
|
+
end: string;
|
|
375
|
+
start: string;
|
|
376
376
|
}, {
|
|
377
|
-
end
|
|
378
|
-
start
|
|
377
|
+
end: string;
|
|
378
|
+
start: string;
|
|
379
379
|
}>;
|
|
380
380
|
}, "strip", z.ZodTypeAny, {
|
|
381
381
|
status: HolidayWorkStatus;
|
|
382
382
|
date: Date;
|
|
383
383
|
closingHour: {
|
|
384
|
-
end
|
|
385
|
-
start
|
|
384
|
+
end: string;
|
|
385
|
+
start: string;
|
|
386
386
|
};
|
|
387
387
|
}, {
|
|
388
388
|
status: HolidayWorkStatus;
|
|
389
389
|
date: string | Date;
|
|
390
390
|
closingHour: {
|
|
391
|
-
end
|
|
392
|
-
start
|
|
391
|
+
end: string;
|
|
392
|
+
start: string;
|
|
393
393
|
};
|
|
394
394
|
}>;
|
|
395
395
|
export declare const WorkHourSettingSchema: z.ZodObject<{
|
|
@@ -397,56 +397,56 @@ export declare const WorkHourSettingSchema: z.ZodObject<{
|
|
|
397
397
|
day: z.ZodNativeEnum<typeof WeekDay>;
|
|
398
398
|
status: z.ZodNativeEnum<typeof WorkStatus>;
|
|
399
399
|
openingHours: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
400
|
-
start: z.ZodString
|
|
401
|
-
end: z.ZodString
|
|
400
|
+
start: z.ZodString;
|
|
401
|
+
end: z.ZodString;
|
|
402
402
|
}, "strip", z.ZodTypeAny, {
|
|
403
|
-
end
|
|
404
|
-
start
|
|
403
|
+
end: string;
|
|
404
|
+
start: string;
|
|
405
405
|
}, {
|
|
406
|
-
end
|
|
407
|
-
start
|
|
406
|
+
end: string;
|
|
407
|
+
start: string;
|
|
408
408
|
}>, "many">>;
|
|
409
409
|
}, "strip", z.ZodTypeAny, {
|
|
410
410
|
status: WorkStatus;
|
|
411
411
|
day: WeekDay;
|
|
412
412
|
openingHours: {
|
|
413
|
-
end
|
|
414
|
-
start
|
|
413
|
+
end: string;
|
|
414
|
+
start: string;
|
|
415
415
|
}[];
|
|
416
416
|
}, {
|
|
417
417
|
status: WorkStatus;
|
|
418
418
|
day: WeekDay;
|
|
419
419
|
openingHours?: {
|
|
420
|
-
end
|
|
421
|
-
start
|
|
420
|
+
end: string;
|
|
421
|
+
start: string;
|
|
422
422
|
}[] | undefined;
|
|
423
423
|
}>, "many">>;
|
|
424
424
|
holidayHours: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
425
425
|
date: z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
426
426
|
status: z.ZodNativeEnum<typeof HolidayWorkStatus>;
|
|
427
427
|
closingHour: z.ZodObject<{
|
|
428
|
-
start: z.ZodString
|
|
429
|
-
end: z.ZodString
|
|
428
|
+
start: z.ZodString;
|
|
429
|
+
end: z.ZodString;
|
|
430
430
|
}, "strip", z.ZodTypeAny, {
|
|
431
|
-
end
|
|
432
|
-
start
|
|
431
|
+
end: string;
|
|
432
|
+
start: string;
|
|
433
433
|
}, {
|
|
434
|
-
end
|
|
435
|
-
start
|
|
434
|
+
end: string;
|
|
435
|
+
start: string;
|
|
436
436
|
}>;
|
|
437
437
|
}, "strip", z.ZodTypeAny, {
|
|
438
438
|
status: HolidayWorkStatus;
|
|
439
439
|
date: Date;
|
|
440
440
|
closingHour: {
|
|
441
|
-
end
|
|
442
|
-
start
|
|
441
|
+
end: string;
|
|
442
|
+
start: string;
|
|
443
443
|
};
|
|
444
444
|
}, {
|
|
445
445
|
status: HolidayWorkStatus;
|
|
446
446
|
date: string | Date;
|
|
447
447
|
closingHour: {
|
|
448
|
-
end
|
|
449
|
-
start
|
|
448
|
+
end: string;
|
|
449
|
+
start: string;
|
|
450
450
|
};
|
|
451
451
|
}>, "many">>;
|
|
452
452
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -454,16 +454,16 @@ export declare const WorkHourSettingSchema: z.ZodObject<{
|
|
|
454
454
|
status: WorkStatus;
|
|
455
455
|
day: WeekDay;
|
|
456
456
|
openingHours: {
|
|
457
|
-
end
|
|
458
|
-
start
|
|
457
|
+
end: string;
|
|
458
|
+
start: string;
|
|
459
459
|
}[];
|
|
460
460
|
}[];
|
|
461
461
|
holidayHours: {
|
|
462
462
|
status: HolidayWorkStatus;
|
|
463
463
|
date: Date;
|
|
464
464
|
closingHour: {
|
|
465
|
-
end
|
|
466
|
-
start
|
|
465
|
+
end: string;
|
|
466
|
+
start: string;
|
|
467
467
|
};
|
|
468
468
|
}[];
|
|
469
469
|
}, {
|
|
@@ -471,28 +471,28 @@ export declare const WorkHourSettingSchema: z.ZodObject<{
|
|
|
471
471
|
status: WorkStatus;
|
|
472
472
|
day: WeekDay;
|
|
473
473
|
openingHours?: {
|
|
474
|
-
end
|
|
475
|
-
start
|
|
474
|
+
end: string;
|
|
475
|
+
start: string;
|
|
476
476
|
}[] | undefined;
|
|
477
477
|
}[] | undefined;
|
|
478
478
|
holidayHours?: {
|
|
479
479
|
status: HolidayWorkStatus;
|
|
480
480
|
date: string | Date;
|
|
481
481
|
closingHour: {
|
|
482
|
-
end
|
|
483
|
-
start
|
|
482
|
+
end: string;
|
|
483
|
+
start: string;
|
|
484
484
|
};
|
|
485
485
|
}[] | undefined;
|
|
486
486
|
}>;
|
|
487
487
|
export declare const LoginSchema: z.ZodObject<{
|
|
488
|
-
email: z.ZodString
|
|
489
|
-
password: z.ZodString
|
|
488
|
+
email: z.ZodString;
|
|
489
|
+
password: z.ZodString;
|
|
490
490
|
}, "strip", z.ZodTypeAny, {
|
|
491
|
-
email
|
|
492
|
-
password
|
|
491
|
+
email: string;
|
|
492
|
+
password: string;
|
|
493
493
|
}, {
|
|
494
|
-
email
|
|
495
|
-
password
|
|
494
|
+
email: string;
|
|
495
|
+
password: string;
|
|
496
496
|
}>;
|
|
497
497
|
export type LoginDTO = DTO<typeof LoginSchema>;
|
|
498
498
|
export declare const createPaginatedSchema: <T>(documentSchema: z.ZodSchema<T>) => z.ZodObject<{
|
|
@@ -532,7 +532,7 @@ export declare const createPaginatedSchema: <T>(documentSchema: z.ZodSchema<T>)
|
|
|
532
532
|
}>;
|
|
533
533
|
export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodObject<{
|
|
534
534
|
success: z.ZodBoolean;
|
|
535
|
-
message: z.ZodString
|
|
535
|
+
message: z.ZodString;
|
|
536
536
|
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
537
537
|
metadata: z.ZodOptional<z.ZodObject<{
|
|
538
538
|
page: z.ZodNumber;
|
|
@@ -570,7 +570,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
570
570
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
571
571
|
}, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
|
|
572
572
|
success: z.ZodBoolean;
|
|
573
|
-
message: z.ZodString
|
|
573
|
+
message: z.ZodString;
|
|
574
574
|
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
575
575
|
metadata: z.ZodOptional<z.ZodObject<{
|
|
576
576
|
page: z.ZodNumber;
|
|
@@ -608,7 +608,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
608
608
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
609
609
|
}>, any> extends infer T_1 ? { [k in keyof T_1]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
|
|
610
610
|
success: z.ZodBoolean;
|
|
611
|
-
message: z.ZodString
|
|
611
|
+
message: z.ZodString;
|
|
612
612
|
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
613
613
|
metadata: z.ZodOptional<z.ZodObject<{
|
|
614
614
|
page: z.ZodNumber;
|
|
@@ -646,7 +646,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
646
646
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
647
647
|
}>, any>[k]; } : never, z.baseObjectInputType<{
|
|
648
648
|
success: z.ZodBoolean;
|
|
649
|
-
message: z.ZodString
|
|
649
|
+
message: z.ZodString;
|
|
650
650
|
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
651
651
|
metadata: z.ZodOptional<z.ZodObject<{
|
|
652
652
|
page: z.ZodNumber;
|
|
@@ -684,7 +684,7 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
684
684
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
685
685
|
}> extends infer T_2 ? { [k_1 in keyof T_2]: z.baseObjectInputType<{
|
|
686
686
|
success: z.ZodBoolean;
|
|
687
|
-
message: z.ZodString
|
|
687
|
+
message: z.ZodString;
|
|
688
688
|
data: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
|
|
689
689
|
metadata: z.ZodOptional<z.ZodObject<{
|
|
690
690
|
page: z.ZodNumber;
|
|
@@ -722,14 +722,14 @@ export declare const createResponseSchema: <T>(schema: z.ZodSchema<T>) => z.ZodO
|
|
|
722
722
|
}>, z.ZodType<T, z.ZodTypeDef, T>]>>;
|
|
723
723
|
}>[k_1]; } : never>;
|
|
724
724
|
export declare const TokenSchema: z.ZodObject<{
|
|
725
|
-
accessToken: z.ZodString
|
|
726
|
-
refreshToken: z.ZodString
|
|
725
|
+
accessToken: z.ZodString;
|
|
726
|
+
refreshToken: z.ZodString;
|
|
727
727
|
}, "strip", z.ZodTypeAny, {
|
|
728
|
-
refreshToken
|
|
729
|
-
accessToken
|
|
728
|
+
refreshToken: string;
|
|
729
|
+
accessToken: string;
|
|
730
730
|
}, {
|
|
731
|
-
refreshToken
|
|
732
|
-
accessToken
|
|
731
|
+
refreshToken: string;
|
|
732
|
+
accessToken: string;
|
|
733
733
|
}>;
|
|
734
734
|
export declare const UpdateSortingOrderSchema: z.ZodObject<{
|
|
735
735
|
_id: z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, import("mongoose").Types.ObjectId, string>, z.ZodType<import("mongoose").Types.ObjectId, z.ZodTypeDef, import("mongoose").Types.ObjectId>]>;
|
|
@@ -15,8 +15,6 @@ export declare class ZodValidation {
|
|
|
15
15
|
static string(field?: string, options?: {
|
|
16
16
|
minLength?: number;
|
|
17
17
|
maxLength?: number;
|
|
18
|
-
optional?: boolean;
|
|
19
|
-
nullable?: boolean;
|
|
20
18
|
minMessage?: string;
|
|
21
19
|
maxMessage?: string;
|
|
22
20
|
requiredMessage?: string;
|
|
@@ -24,13 +22,11 @@ export declare class ZodValidation {
|
|
|
24
22
|
pattern: RegExp;
|
|
25
23
|
message: string;
|
|
26
24
|
};
|
|
27
|
-
}): z.ZodString
|
|
25
|
+
}): z.ZodString;
|
|
28
26
|
static email(field?: string, options?: {
|
|
29
27
|
requiredMessage?: string;
|
|
30
28
|
invalidMessage?: string;
|
|
31
|
-
|
|
32
|
-
nullable?: boolean;
|
|
33
|
-
}): z.ZodString | z.ZodOptional<z.ZodString> | z.ZodNullable<z.ZodString> | z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
29
|
+
}): z.ZodString;
|
|
34
30
|
static url(field?: string): z.ZodString;
|
|
35
31
|
static phoneNumber(field?: string): z.ZodEffects<z.ZodString, string, string>;
|
|
36
32
|
static date(field?: string, minDate?: Date, maxDate?: Date): z.ZodEffects<z.ZodEffects<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, Date, string>, z.ZodDate]>, Date, string | Date>, Date, string | Date>;
|
|
@@ -69,15 +69,6 @@ class ZodValidation {
|
|
|
69
69
|
if (options?.regex) {
|
|
70
70
|
schema = schema.regex(options.regex.pattern, options.regex.message);
|
|
71
71
|
}
|
|
72
|
-
if (options?.nullable && options?.optional) {
|
|
73
|
-
return schema.nullish();
|
|
74
|
-
}
|
|
75
|
-
if (options?.nullable) {
|
|
76
|
-
return schema.nullable();
|
|
77
|
-
}
|
|
78
|
-
if (options?.optional) {
|
|
79
|
-
return schema.optional();
|
|
80
|
-
}
|
|
81
72
|
return schema;
|
|
82
73
|
}
|
|
83
74
|
static email(field = 'Email', options) {
|
|
@@ -86,15 +77,6 @@ class ZodValidation {
|
|
|
86
77
|
required_error: options?.requiredMessage || `${field} is required`,
|
|
87
78
|
})
|
|
88
79
|
.email(options?.invalidMessage || `${field} must be a valid email address`);
|
|
89
|
-
if (options?.nullable && options?.optional) {
|
|
90
|
-
return schema.nullish();
|
|
91
|
-
}
|
|
92
|
-
if (options?.nullable) {
|
|
93
|
-
return schema.nullable();
|
|
94
|
-
}
|
|
95
|
-
if (options?.optional) {
|
|
96
|
-
return schema.optional();
|
|
97
|
-
}
|
|
98
80
|
return schema;
|
|
99
81
|
}
|
|
100
82
|
static url(field = 'Field') {
|
|
@@ -110,7 +92,7 @@ class ZodValidation {
|
|
|
110
92
|
return false;
|
|
111
93
|
}
|
|
112
94
|
}, {
|
|
113
|
-
message: `
|
|
95
|
+
message: `Please input a valid phone number`,
|
|
114
96
|
});
|
|
115
97
|
}
|
|
116
98
|
static date(field = 'Field', minDate, maxDate) {
|