@lyxa.ai/types 1.0.381-alpha.0 → 1.0.390
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/README.md +1 -1
- package/package.json +1 -1
- package/utilities/enum.d.ts +42 -16
- package/utilities/enum.js +49 -20
- package/utilities/enum.js.map +1 -1
- package/utilities/validation/common-validation.d.ts +25 -1
- package/utilities/validation/common-validation.js +7 -2
- package/utilities/validation/common-validation.js.map +1 -1
- package/utilities/validation/global-validation.d.ts +14 -0
- package/utilities/validation/global-validation.js +57 -6
- package/utilities/validation/global-validation.js.map +1 -1
package/README.md
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lyxa.ai/types",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.390",
|
|
4
4
|
"description": "Lyxa type definitions and validation schemas for both frontend and backend",
|
|
5
5
|
"author": "elie <42282499+Internalizable@users.noreply.github.com>",
|
|
6
6
|
"license": "MIT",
|
package/utilities/enum.d.ts
CHANGED
|
@@ -391,6 +391,12 @@ export declare enum MarketingStatus {
|
|
|
391
391
|
EXPIRED = "expired",
|
|
392
392
|
DELETED = "deleted"
|
|
393
393
|
}
|
|
394
|
+
export declare enum PunchMarketingStatus {
|
|
395
|
+
ACTIVE = "active",
|
|
396
|
+
COMPLETED = "completed",
|
|
397
|
+
COUPON_USED = "coupon_used",
|
|
398
|
+
EXPIRED = "expired"
|
|
399
|
+
}
|
|
394
400
|
export declare enum AdminRole {
|
|
395
401
|
SUPER_ADMIN = "super_admin",
|
|
396
402
|
GENERAL_MANAGER = "general_manager",
|
|
@@ -595,17 +601,6 @@ export declare enum OrderCanceledBy {
|
|
|
595
601
|
SHOP = "shop",
|
|
596
602
|
ADMIN = "admin"
|
|
597
603
|
}
|
|
598
|
-
export declare enum LateOrderReason {
|
|
599
|
-
SHOP_PREPARATION_OVERDUE = "shop_preparation_overdue",
|
|
600
|
-
PICKUP_OVERDUE = "pickup_overdue",
|
|
601
|
-
DELIVERY_OVERDUE = "delivery_overdue"
|
|
602
|
-
}
|
|
603
|
-
export declare enum UrgentOrderReason {
|
|
604
|
-
SHOP_INACTION = "shop_inaction",
|
|
605
|
-
RIDER_INACTION = "rider_inaction",
|
|
606
|
-
HIGH_VALUE_FIRST_ORDER = "high_value_first_order",
|
|
607
|
-
ADJUSTED_ORDER_REQUEST_IGNORED = "adjusted_order_request_ignored"
|
|
608
|
-
}
|
|
609
604
|
export declare enum ReplacementReason {
|
|
610
605
|
MISSING = "missing_item",
|
|
611
606
|
WRONG = "wrong_item",
|
|
@@ -641,10 +636,6 @@ export declare enum ChatroomType {
|
|
|
641
636
|
TICKET = "ticket",
|
|
642
637
|
DIRECT = "direct"
|
|
643
638
|
}
|
|
644
|
-
export declare enum SocketEventType {
|
|
645
|
-
MESSAGE_RECEIVED = "message.received",
|
|
646
|
-
TICKET_NOTIFICATION = "ticket.notification"
|
|
647
|
-
}
|
|
648
639
|
export declare enum ServiceCartStatus {
|
|
649
640
|
ACTIVE = "active",
|
|
650
641
|
LOCKED = "locked",
|
|
@@ -718,13 +709,21 @@ export declare enum PromotionType {
|
|
|
718
709
|
export declare enum FlagType {
|
|
719
710
|
NORMAL = "normal",
|
|
720
711
|
LATE = "late",
|
|
712
|
+
URGENT = "urgent",
|
|
721
713
|
REPLACEMENT = "replacement",
|
|
722
714
|
REFUNDED = "refunded"
|
|
723
715
|
}
|
|
724
716
|
export declare enum FlagReasonType {
|
|
725
717
|
MISSING = "missing_item",
|
|
726
718
|
WRONG = "wrong_item",
|
|
727
|
-
OTHER = "other"
|
|
719
|
+
OTHER = "other",
|
|
720
|
+
SHOP_PREPARATION_OVERDUE = "shop_preparation_overdue",
|
|
721
|
+
PICKUP_OVERDUE = "pickup_overdue",
|
|
722
|
+
DELIVERY_OVERDUE = "delivery_overdue",
|
|
723
|
+
SHOP_INACTION = "shop_inaction",
|
|
724
|
+
RIDER_INACTION = "rider_inaction",
|
|
725
|
+
HIGH_VALUE_FIRST_ORDER = "high_value_first_order",
|
|
726
|
+
ADJUSTED_ORDER_REQUEST_IGNORED = "adjusted_order_request_ignored"
|
|
728
727
|
}
|
|
729
728
|
export declare enum AdjustmentReason {
|
|
730
729
|
USER_REQUEST = "user_request",
|
|
@@ -746,3 +745,30 @@ export declare enum OtpMethodType {
|
|
|
746
745
|
SMS = "sms",
|
|
747
746
|
WHATSAPP = "whatsapp"
|
|
748
747
|
}
|
|
748
|
+
export declare enum SocketServiceQueue {
|
|
749
|
+
CHAT = "socket.chat.emit",
|
|
750
|
+
NOTIFICATION = "socket.notification.emit",
|
|
751
|
+
ORDER = "socket.order.emit"
|
|
752
|
+
}
|
|
753
|
+
export declare enum SocketEventType {
|
|
754
|
+
CHATROOM_MESSAGE_SEND = "CHATROOM_MESSAGE_SEND"
|
|
755
|
+
}
|
|
756
|
+
export declare enum DeviceType {
|
|
757
|
+
MOBILE = "mobile",
|
|
758
|
+
WEB = "web"
|
|
759
|
+
}
|
|
760
|
+
export declare enum ActionType {
|
|
761
|
+
ADD = "add",
|
|
762
|
+
REMOVE = "remove"
|
|
763
|
+
}
|
|
764
|
+
export declare enum ServiceType {
|
|
765
|
+
CLEANING = "cleaning",
|
|
766
|
+
FURNITURE_CLEANING = "furniture_cleaning",
|
|
767
|
+
HOME_CLEANING = "home_cleaning",
|
|
768
|
+
DEEP_CLEANING = "deep_cleaning",
|
|
769
|
+
LAUNDRY = "laundry",
|
|
770
|
+
REGULAR_WASH = "regular_wash",
|
|
771
|
+
DRY_CLEANING = "dry_cleaning",
|
|
772
|
+
IRONING = "ironing",
|
|
773
|
+
SALOON = "saloon"
|
|
774
|
+
}
|
package/utilities/enum.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ServiceMarketingType = exports.MarketingType = exports.FavouriteType = exports.CouponExpirationReason = exports.CouponType = exports.BobType = exports.BobChannelType = exports.BobModel = exports.BobSettlementStatus = exports.BobSettlementType = exports.BobAccountType = exports.ZoneStatus = exports.FaqAccountType = exports.CounterType = exports.BannerUserType = exports.BannerLinkType = exports.BannerClickType = exports.VendorRole = exports.ShopRole = exports.OnlineStatus = exports.ShopOnlineStatus = exports.ChargeType = exports.ClickType = exports.NotificationAccountType = exports.DishCategory = exports.ProductDietaryType = exports.PriceOption = exports.ProductType = exports.CoreAuthIdentityType = exports.UserAppSectionItemType = exports.UserAppSectionType = exports.AdminLogsUpdatedFieldsType = exports.UpdatedField = exports.GeoLocationType = exports.RatingAccountType = exports.SubscriptionStatus = exports.SubscriptionPackage = exports.PaidCurrency = exports.PaymentStatus = exports.PaymentMethod = exports.ValueType = exports.HolidayWorkStatus = exports.WorkStatus = exports.WeekDay = exports.GlobalItemType = exports.AdjustmentStatus = exports.ItemType = exports.Status = exports.AccountType = exports.AgentLiveStatus = void 0;
|
|
4
|
-
exports.
|
|
5
|
-
exports.OtpMethodType = exports.ReviewType = exports.FoodNutritionType = exports.AdjustmentReason = exports.FlagReasonType = exports.FlagType = exports.PromotionType = exports.ServiceOrderCanceledBy = exports.TRPCErrorEnum = exports.ShopFilterSortByEnum = exports.ProfessionalScheduleType = exports.ServiceOrderRecurrencePattern = exports.ProfessionalRecurrencePattern =
|
|
4
|
+
exports.ServiceOrderPriority = exports.ProfessionalStatus = exports.Service = exports.ServiceCartStatus = exports.ChatroomType = exports.UserRef = exports.TicketStatus = exports.TicketType = exports.RewardedToTypeEnum = exports.ReplacementType = exports.ReplacementReason = exports.OrderCanceledBy = exports.LogUser = exports.PayoutStatus = exports.PayoutType = exports.AddRemoveCreditAccountType = exports.SettingsReasonStatus = exports.CancellationReasonTypeEnum = exports.SupportReasonTypeEnum = exports.PlusSettingsPackageType = exports.AddRemoveCreditSettlementType = exports.SettlementType = exports.MediaType = exports.WorkingHourSettingsType = exports.ZoneGeometryType = exports.RiderAssignmentStatus = exports.CourierServiceType = exports.TripLegStatus = exports.DeliveryStatus = exports.CourierOrderPaymentFrom = exports.ShopCourierOrderStatus = exports.ServiceOrderStatus = exports.CourierOrderStatus = exports.RegularOrderStatus = exports.OrderType = exports.Language = exports.OrderSize = exports.RiderBagSize = exports.RiderType = exports.ShiftType = exports.CreatedBy = exports.LiveStatus = exports.AreebaCardStatus = exports.CardUserType = exports.CardType = exports.PaymentPreference = exports.CartStatus = exports.AdminRole = exports.PunchMarketingStatus = exports.MarketingStatus = void 0;
|
|
5
|
+
exports.ServiceType = exports.ActionType = exports.DeviceType = exports.SocketEventType = exports.SocketServiceQueue = exports.OtpMethodType = exports.ReviewType = exports.FoodNutritionType = exports.AdjustmentReason = exports.FlagReasonType = exports.FlagType = exports.PromotionType = exports.ServiceOrderCanceledBy = exports.TRPCErrorEnum = exports.ShopFilterSortByEnum = exports.ProfessionalScheduleType = exports.ServiceOrderRecurrencePattern = exports.ProfessionalRecurrencePattern = void 0;
|
|
6
6
|
var AgentLiveStatus;
|
|
7
7
|
(function (AgentLiveStatus) {
|
|
8
8
|
AgentLiveStatus["ONLINE"] = "online";
|
|
@@ -447,6 +447,13 @@ var MarketingStatus;
|
|
|
447
447
|
MarketingStatus["EXPIRED"] = "expired";
|
|
448
448
|
MarketingStatus["DELETED"] = "deleted";
|
|
449
449
|
})(MarketingStatus || (exports.MarketingStatus = MarketingStatus = {}));
|
|
450
|
+
var PunchMarketingStatus;
|
|
451
|
+
(function (PunchMarketingStatus) {
|
|
452
|
+
PunchMarketingStatus["ACTIVE"] = "active";
|
|
453
|
+
PunchMarketingStatus["COMPLETED"] = "completed";
|
|
454
|
+
PunchMarketingStatus["COUPON_USED"] = "coupon_used";
|
|
455
|
+
PunchMarketingStatus["EXPIRED"] = "expired";
|
|
456
|
+
})(PunchMarketingStatus || (exports.PunchMarketingStatus = PunchMarketingStatus = {}));
|
|
450
457
|
var AdminRole;
|
|
451
458
|
(function (AdminRole) {
|
|
452
459
|
AdminRole["SUPER_ADMIN"] = "super_admin";
|
|
@@ -688,19 +695,6 @@ var OrderCanceledBy;
|
|
|
688
695
|
OrderCanceledBy["SHOP"] = "shop";
|
|
689
696
|
OrderCanceledBy["ADMIN"] = "admin";
|
|
690
697
|
})(OrderCanceledBy || (exports.OrderCanceledBy = OrderCanceledBy = {}));
|
|
691
|
-
var LateOrderReason;
|
|
692
|
-
(function (LateOrderReason) {
|
|
693
|
-
LateOrderReason["SHOP_PREPARATION_OVERDUE"] = "shop_preparation_overdue";
|
|
694
|
-
LateOrderReason["PICKUP_OVERDUE"] = "pickup_overdue";
|
|
695
|
-
LateOrderReason["DELIVERY_OVERDUE"] = "delivery_overdue";
|
|
696
|
-
})(LateOrderReason || (exports.LateOrderReason = LateOrderReason = {}));
|
|
697
|
-
var UrgentOrderReason;
|
|
698
|
-
(function (UrgentOrderReason) {
|
|
699
|
-
UrgentOrderReason["SHOP_INACTION"] = "shop_inaction";
|
|
700
|
-
UrgentOrderReason["RIDER_INACTION"] = "rider_inaction";
|
|
701
|
-
UrgentOrderReason["HIGH_VALUE_FIRST_ORDER"] = "high_value_first_order";
|
|
702
|
-
UrgentOrderReason["ADJUSTED_ORDER_REQUEST_IGNORED"] = "adjusted_order_request_ignored";
|
|
703
|
-
})(UrgentOrderReason || (exports.UrgentOrderReason = UrgentOrderReason = {}));
|
|
704
698
|
var ReplacementReason;
|
|
705
699
|
(function (ReplacementReason) {
|
|
706
700
|
ReplacementReason["MISSING"] = "missing_item";
|
|
@@ -743,11 +737,6 @@ var ChatroomType;
|
|
|
743
737
|
ChatroomType["TICKET"] = "ticket";
|
|
744
738
|
ChatroomType["DIRECT"] = "direct";
|
|
745
739
|
})(ChatroomType || (exports.ChatroomType = ChatroomType = {}));
|
|
746
|
-
var SocketEventType;
|
|
747
|
-
(function (SocketEventType) {
|
|
748
|
-
SocketEventType["MESSAGE_RECEIVED"] = "message.received";
|
|
749
|
-
SocketEventType["TICKET_NOTIFICATION"] = "ticket.notification";
|
|
750
|
-
})(SocketEventType || (exports.SocketEventType = SocketEventType = {}));
|
|
751
740
|
var ServiceCartStatus;
|
|
752
741
|
(function (ServiceCartStatus) {
|
|
753
742
|
ServiceCartStatus["ACTIVE"] = "active";
|
|
@@ -833,6 +822,7 @@ var FlagType;
|
|
|
833
822
|
(function (FlagType) {
|
|
834
823
|
FlagType["NORMAL"] = "normal";
|
|
835
824
|
FlagType["LATE"] = "late";
|
|
825
|
+
FlagType["URGENT"] = "urgent";
|
|
836
826
|
FlagType["REPLACEMENT"] = "replacement";
|
|
837
827
|
FlagType["REFUNDED"] = "refunded";
|
|
838
828
|
})(FlagType || (exports.FlagType = FlagType = {}));
|
|
@@ -841,6 +831,13 @@ var FlagReasonType;
|
|
|
841
831
|
FlagReasonType["MISSING"] = "missing_item";
|
|
842
832
|
FlagReasonType["WRONG"] = "wrong_item";
|
|
843
833
|
FlagReasonType["OTHER"] = "other";
|
|
834
|
+
FlagReasonType["SHOP_PREPARATION_OVERDUE"] = "shop_preparation_overdue";
|
|
835
|
+
FlagReasonType["PICKUP_OVERDUE"] = "pickup_overdue";
|
|
836
|
+
FlagReasonType["DELIVERY_OVERDUE"] = "delivery_overdue";
|
|
837
|
+
FlagReasonType["SHOP_INACTION"] = "shop_inaction";
|
|
838
|
+
FlagReasonType["RIDER_INACTION"] = "rider_inaction";
|
|
839
|
+
FlagReasonType["HIGH_VALUE_FIRST_ORDER"] = "high_value_first_order";
|
|
840
|
+
FlagReasonType["ADJUSTED_ORDER_REQUEST_IGNORED"] = "adjusted_order_request_ignored";
|
|
844
841
|
})(FlagReasonType || (exports.FlagReasonType = FlagReasonType = {}));
|
|
845
842
|
var AdjustmentReason;
|
|
846
843
|
(function (AdjustmentReason) {
|
|
@@ -866,4 +863,36 @@ var OtpMethodType;
|
|
|
866
863
|
OtpMethodType["SMS"] = "sms";
|
|
867
864
|
OtpMethodType["WHATSAPP"] = "whatsapp";
|
|
868
865
|
})(OtpMethodType || (exports.OtpMethodType = OtpMethodType = {}));
|
|
866
|
+
var SocketServiceQueue;
|
|
867
|
+
(function (SocketServiceQueue) {
|
|
868
|
+
SocketServiceQueue["CHAT"] = "socket.chat.emit";
|
|
869
|
+
SocketServiceQueue["NOTIFICATION"] = "socket.notification.emit";
|
|
870
|
+
SocketServiceQueue["ORDER"] = "socket.order.emit";
|
|
871
|
+
})(SocketServiceQueue || (exports.SocketServiceQueue = SocketServiceQueue = {}));
|
|
872
|
+
var SocketEventType;
|
|
873
|
+
(function (SocketEventType) {
|
|
874
|
+
SocketEventType["CHATROOM_MESSAGE_SEND"] = "CHATROOM_MESSAGE_SEND";
|
|
875
|
+
})(SocketEventType || (exports.SocketEventType = SocketEventType = {}));
|
|
876
|
+
var DeviceType;
|
|
877
|
+
(function (DeviceType) {
|
|
878
|
+
DeviceType["MOBILE"] = "mobile";
|
|
879
|
+
DeviceType["WEB"] = "web";
|
|
880
|
+
})(DeviceType || (exports.DeviceType = DeviceType = {}));
|
|
881
|
+
var ActionType;
|
|
882
|
+
(function (ActionType) {
|
|
883
|
+
ActionType["ADD"] = "add";
|
|
884
|
+
ActionType["REMOVE"] = "remove";
|
|
885
|
+
})(ActionType || (exports.ActionType = ActionType = {}));
|
|
886
|
+
var ServiceType;
|
|
887
|
+
(function (ServiceType) {
|
|
888
|
+
ServiceType["CLEANING"] = "cleaning";
|
|
889
|
+
ServiceType["FURNITURE_CLEANING"] = "furniture_cleaning";
|
|
890
|
+
ServiceType["HOME_CLEANING"] = "home_cleaning";
|
|
891
|
+
ServiceType["DEEP_CLEANING"] = "deep_cleaning";
|
|
892
|
+
ServiceType["LAUNDRY"] = "laundry";
|
|
893
|
+
ServiceType["REGULAR_WASH"] = "regular_wash";
|
|
894
|
+
ServiceType["DRY_CLEANING"] = "dry_cleaning";
|
|
895
|
+
ServiceType["IRONING"] = "ironing";
|
|
896
|
+
ServiceType["SALOON"] = "saloon";
|
|
897
|
+
})(ServiceType || (exports.ServiceType = ServiceType = {}));
|
|
869
898
|
//# sourceMappingURL=enum.js.map
|
package/utilities/enum.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C,EAHW,gBAAgB,gCAAhB,gBAAgB,QAG3B;AAED,IAAY,iBAMX;AAND,WAAY,iBAAiB;IAC5B,wCAAmB,CAAA;IACnB,gCAAW,CAAA;IACX,gCAAW,CAAA;IACX,oCAAe,CAAA;IACf,sCAAiB,CAAA;AAClB,CAAC,EANW,iBAAiB,iCAAjB,iBAAiB,QAM5B;AAED,IAAY,UAIX;AAJD,WAAY,UAAU;IACrB,2BAAa,CAAA;IACb,6BAAe,CAAA;IACf,2CAA6B,CAAA;AAC9B,CAAC,EAJW,UAAU,0BAAV,UAAU,QAIrB;AAED,IAAY,aAGX;AAHD,WAAY,aAAa;IACxB,4BAAW,CAAA;IACX,sCAAqB,CAAA;AACtB,CAAC,EAHW,aAAa,6BAAb,aAAa,QAGxB","sourcesContent":["export enum AgentLiveStatus {\n\tONLINE = 'online',\n\tOFFLINE = 'offline',\n}\nexport enum AccountType {\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n\tCOMPANY = 'company',\n\tVENDOR = 'vendor',\n\tPROFESSIONAL = 'professional',\n}\n\nexport enum Status {\n\tACTIVE = 'active',\n\tINACTIVE = 'inactive',\n}\n\nexport enum ItemType {\n\tFOOD = 'food',\n\tGROCERY = 'grocery',\n\tPHARMACY = 'pharmacy',\n\tCOFFEE = 'coffee',\n\tFLOWER = 'flower',\n\tPET = 'pet',\n\tHEALTHY_CORNER = 'healthy_corner',\n}\n\nexport enum AdjustmentStatus {\n\tNONE = 'none',\n\tPENDING = 'pending',\n\tAPPROVED = 'approved',\n}\n\nexport enum GlobalItemType {\n\tGROCERY = ItemType.GROCERY,\n}\n\nexport enum WeekDay {\n\tSunday = 0,\n\tMonday = 1,\n\tTuesday = 2,\n\tWednesday = 3,\n\tThursday = 4,\n\tFriday = 5,\n\tSaturday = 6,\n}\n\nexport enum WorkStatus {\n\tOPEN = 'open',\n\tCLOSED = 'closed',\n\tFULL_DAY = 'full_day',\n}\n\nexport enum HolidayWorkStatus {\n\tCLOSED = WorkStatus.CLOSED,\n\tFULL_DAY = WorkStatus.FULL_DAY,\n}\n\nexport enum ValueType {\n\tPERCENTAGE = 'percentage',\n\tFIXED = 'fixed',\n}\n\nexport enum PaymentMethod {\n\tCASH = 'cash',\n\tONLINE = 'online',\n}\n\nexport enum PaymentStatus {\n\tPAID = 'paid',\n\tPENDING = 'pending',\n\tFAILED = 'failed',\n\tREFUNDED = 'refunded',\n\tPARTIALLY_REFUNDED = 'partially_refunded',\n}\n\nexport enum PaidCurrency {\n\tBASE = 'base',\n\tSECONDARY = 'secondary',\n\tMIXED = 'mixed',\n}\n\nexport enum SubscriptionPackage {\n\tMONTHLY = 'monthly',\n\tYEARLY = 'yearly',\n}\n\nexport enum SubscriptionStatus {\n\tONGOING = 'ongoing',\n\tEXPIRED = 'expired',\n}\n\nexport enum RatingAccountType {\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum GeoLocationType {\n\tPOINT = 'Point',\n}\n\nexport enum UpdatedField {\n\tMAX_TOTAL_EST_ITEMS_PRICE = 'max_total_est_items_price',\n\tMAX_DISTANCE = 'max_distance',\n\tDAILY_WORKING_HOURS = 'daily_working_hours',\n\tBOB_CASH_SETTLEMENT_LIMIT = 'bob_cash_settlement_limit',\n\tTIPS = 'tips',\n\tEQUIPMENTS = 'equipments',\n\tMONTHLY_SHOP_TARGET = 'monthly_shop_target',\n\tMONTHLY_REWARD_PRIZE = 'monthly_reward_prize',\n\tBASE_CURRENCY = 'base_currency',\n\tSECONDARY_CURRENCY = 'secondary_currency',\n\tIS_DUAL_CURRENCY_ENABLED = 'is_dual_currency_enabled',\n\tEXCHANGE_RATE = 'exchange_rate',\n\tISSUANCE_DAY = 'issuance_day',\n\tOVER_DUE_PERIODS = 'over_due_periods',\n\tPAY_LIMIT_FOR_USER = 'pay_limit_for_user',\n\tVAT_PERCENTAGE = 'vat_percentage',\n\tRIDER_SEARCH_RANGES = 'rider_search_ranges',\n\tNEAR_BY_SHOP_DISTANCE = 'near_by_shop_distance',\n\tNEAR_BY_SHOP_DISTANCE_IN_HOME_SCREEN = 'near_by_shop_distance_in_home_screen',\n\tUNITS = 'units',\n\tCURRENCY_SETTING = 'currency_setting',\n\tPAYMENT_METHODS = 'payment_methods',\n\tIS_GROUND_ORDER_ENABLED = 'is_ground_order_enabled',\n\tCUSTOMER_SUPPORT_PHONE_NUMBER = 'customer_support_phone_number',\n}\n\nexport enum AdminLogsUpdatedFieldsType {\n\tCHARGE_SETTINGS = 'charge_settings',\n\tSERVICE_FEE_SETTINGS = 'service_fee_settings',\n\tPAYOUT_SETTINGS = 'payout_settings',\n\tCOURIER_SETTINGS = 'courier_settings',\n\tRIDER_SETTINGS = 'rider_settings',\n\tBUSINESS_DEVELOPMENT_EXECUTIVE = 'business_development_executive',\n\tPAY_LIMIT_FOR_USER = 'pay_limit_for_user',\n\tVAT_PERCENTAGE = 'vat_percentage',\n\tRIDER_SEARCH_RANGES = 'rider_search_ranges',\n\tRIDER_BATCHES = 'rider_batches',\n\tNEARBY_SHOP_DISTANCE = 'nearby_shop_distance',\n\tNEAR_BY_SHOP_DISTANCE_IN_HOME_SCREEN = 'nearby_shop_distance_in_home_screen',\n\tUNITS = 'units',\n\tCURRENCY_SETTING = 'currency_setting',\n\tPAYMENT_METHODS = 'payment_methods',\n\tIS_GROUPED_ORDER_ENABLED = 'is_grouped_order_enabled',\n\tCUSTOMER_SUPPORT = 'customer_support',\n\tCUSTOMER_SUPPORT_BATCHES = 'customer_support_batches',\n\tWORK_HOUR_SETTINGS = 'work_hour_settings',\n\tPLUS_SETTING = 'plus_setting',\n\tDELIVERY_CHARGES = 'delivery_charges',\n\tSETTINGS_DELETED = 'settings_deleted',\n\n\tSHOP_ACTIVATED = 'shop_activated',\n\tSHOP_DEACTIVATED = 'shop_deactivated',\n\tSHOP_DELETED = 'shop_deleted',\n\n\tSHOW_SHOP_IN_USER_APP = 'show_shop_in_user_app',\n\tHIDE_SHOP_IN_USER_APP = 'hide_shop_in_user_app',\n\n\tPARENT_ACTIVATED = 'parent_activated',\n\tPARENT_DEACTIVATED = 'parent_deactivated',\n\tPARENT_DELETED = 'parent_deleted',\n\n\tRIDER_CREATED = 'rider_created',\n\tRIDER_UPDATED = 'rider_updated',\n\tRIDER_ACTIVATED = 'rider_activated',\n\tRIDER_DEACTIVATED = 'rider_deactivated',\n\tRIDER_DELETED = 'rider_deleted',\n\n\tACTIVATED_MARKETING_PROMOTIONS = 'activated_marketing_promotions',\n\tCONTINUED_MARKETING_PROMOTIONS = 'continued_marketing_promotions',\n\tEDITED_MARKETING_PROMOTIONS = 'edited_marketing_promotions',\n\tPAUSED_MARKETING_PROMOTIONS = 'paused_marketing_promotions',\n\tDELETED_MARKETING_PROMOTIONS = 'deleted_marketing_promotions',\n\n\tACTIVATED_ZONE = 'activated_zone',\n\tDEACTIVATED_ZONE = 'deactivated_zone',\n\n\tCREATED_MARKETING_SETTINGS = 'created_marketing_settings',\n\tCHANGE_IN_MARKETING_SETTINGS = 'change_in_marketing_settings',\n\tDELETED_MARKETING_SETTINGS = 'deleted_marketing_settings',\n\n\tCHANGE_IN_PRIVACY_POLICY = 'change_in_privacy_policy',\n\tCHANGE_IN_USER_TERMS_AND_CONDITIONS = 'change_in_user_terms_and_conditions',\n\tCHANGE_IN_SHOP_TERMS_AND_CONDITIONS = 'change_in_shop_terms_and_conditions',\n\tCHANGE_IN_RIDER_TERMS_AND_CONDITIONS = 'change_in_rider_terms_and_conditions',\n\tCHANGE_IN_LYXA_PLUS_TERMS_AND_CONDITIONS = 'lyxa_plux_terms_and_conditions',\n\n\tCHANGE_IN_SUPPORT_REASON = 'change_in_support_reason',\n\tDELETE_SUPPORT_REASON = 'delete_support_reason',\n\tCHANGE_IN_CANCELLATION_REASON = 'change_in_cancellation_reason',\n\tDELETE_CANCELLATION_REASON = 'delete_cancellation_reason',\n\n\tCHANGE_IN_SETTINGS_OPENING_HOURS = 'change_in_settings_opening_hours',\n\n\tCHANGE_IN_DEFAULT_CHAT_MESSAGE = 'change_in_default_chat_messages',\n\tDELETE_DEFAULT_CHAT_MESSAGE = 'delete_default_chat_message',\n\n\tCHANGE_IN_LYXA_PLUS_CONFIGURATION = 'change_in_lyxa_plux_configuration',\n\n\tCHANGE_IN_BANNER_DISPLAY = 'change_in_banner_display',\n\tCHANGE_IN_TAG_DISPLAY = 'change_in_tag_display',\n\tCHANGE_IN_LIST_CONTAINER_DISPLAY = 'change_in_list_container_display',\n\tCHANGE_IN_FILTER_CONTAINER_DISPLAY = 'change_in_filter_container_display',\n\tCHANGE_IN_USER_APP_SECTIONS_DISPLAY = 'change_in_user_app_sections_display',\n\tCHANGE_IN_FEATURED_SHOP_DISPLAY = 'change_in_featured_shop_display',\n\n\tDELETE_BANNER_DISPLAY = 'delete_banner_display',\n\tDELETE_TAG_DISPLAY = 'delete_tag_display',\n\tDELETE_LIST_CONTAINER_DISPLAY = 'delete_list_container_display',\n\tDELETE_FILTER_CONTAINER_DISPLAY = 'delete_filter_container_display',\n\tDELETE_USER_APP_SECTION_DISPLAY = 'delete_user_app_section_display',\n\tDELETE_FEATURED_SHOP_DISPLAY = 'delete_featured_shop_display',\n}\n\nexport enum UserAppSectionType {\n\tSHOW_ALL = 'show_all',\n\tSTORE_PUNCHES = 'store_punches',\n\tAUTHENTIC_BEIRUT = 'authentic_beirut',\n\tCRAZY_OFFER_SHOPS = 'crazy_offer_shops',\n\n\tNEAR_ME = 'near_me',\n\tNEARBY_FOOD = 'nearby_food',\n\tNEARBY_GROCERY = 'nearby_grocery',\n\tNEARBY_PET = 'nearby_pet',\n\tNEARBY_FLOWER = 'nearby_flower',\n\tNEARBY_COFFEE = 'nearby_coffee',\n\n\tOFFERS = 'offers',\n\tOFFERS_FOOD = 'offers_food',\n\tOFFERS_GROCERY = 'offers_grocery',\n\tOFFERS_PET = 'offers_pet',\n\tOFFERS_FLOWER = 'offers_flower',\n\tOFFERS_COFFEE = 'offers_coffee',\n\n\tFREE_DELIVERY = 'free_delivery',\n\tFREE_DELIVERY_FOOD = 'free_delivery_food',\n\tFREE_DELIVERY_GROCERY = 'free_delivery_grocery',\n\tFREE_DELIVERY_PET = 'free_delivery_pet',\n\tFREE_DELIVERY_FLOWER = 'free_delivery_flower',\n\tFREE_DELIVERY_COFFEE = 'free_delivery_coffee',\n\n\tORDER_AGAIN = 'order_again',\n\tORDER_AGAIN_FOOD = 'order_again_food',\n\tORDER_AGAIN_GROCERY = 'order_again_grocery',\n\tORDER_AGAIN_PET = 'order_again_pet',\n\tORDER_AGAIN_FLOWER = 'order_again_flower',\n\tORDER_AGAIN_COFFEE = 'order_again_coffee',\n\n\tTOP_PICKS = 'top_picks',\n\tTOP_PICKS_FOOD = 'top_picks_food',\n\tTOP_PICKS_GROCERY = 'top_picks_grocery',\n\tTOP_PICKS_PET = 'top_picks_pet',\n\tTOP_PICKS_FLOWER = 'top_picks_flower',\n\tTOP_PICKS_COFFEE = 'top_picks_coffee',\n}\n\nexport enum UserAppSectionItemType {\n\tHOME = 'home',\n\tFOOD = 'food',\n\tGROCERY = 'grocery',\n\tCOFFEE = 'coffee',\n\tPET = 'pet',\n\tFLOWER = 'flower',\n}\n\nexport enum CoreAuthIdentityType {\n\tEMAIL = 'email',\n\tPHONE = 'phone',\n\tGOOGLE = 'google',\n\tAPPLE = 'apple',\n}\n\nexport enum ProductType {\n\tMEAT = 'meat',\n\tCHICKEN = 'chicken',\n\tFISH = 'fish',\n\tVEGETARIAN = 'vegetarian',\n\tOTHER = 'other',\n}\n\nexport enum PriceOption {\n\tSINGLE_PRICE = 'single_price',\n\tPRICE_PER_UNIT = 'price_per_unit',\n\tPRICE_PER_PORTION = 'price_per_portion',\n}\n\nexport enum ProductDietaryType {\n\tGLUTEN_FREE = 'gluten_free',\n\tLOW_CAL = 'low_cal',\n\tVEGETARIAN = 'vegetarian',\n\tVEGAN = 'vegan',\n\tKETO = 'keto',\n\tLACTOSE_FREE = 'lactose_free',\n\tHIGH_PROTEIN = 'high_protein',\n}\n\nexport enum DishCategory {\n\tBREAKFAST = 'breakfast',\n\tLUNCH = 'lunch',\n\tDINNER = 'dinner',\n\tSNACKS = 'snacks',\n}\n\nexport enum NotificationAccountType {\n\tUSER = 'user',\n\tPARENT = 'parent',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n\tADMIN = 'admin',\n\tCUSTOMER_SERVICE = 'customer_service',\n}\n\nexport enum ClickType {\n\tCLICKABLE_URL = 'clickable_url',\n\tCLICKABLE_ORDER = 'clickable_order',\n\tCLICKABLE_SHOP = 'clickable_shop',\n\tCLICKABLE_PRODUCT = 'clickable_product',\n\tCLICKABLE_LIST_CONTAINER = 'clickable_list_container',\n\tCLICKABLE_PAYOUT = 'clickable_payout',\n\tCLICKABLE_BOB_FINANCE = 'clickable_bob_finance',\n\tCLICKABLE_REQUEST_AREA = 'clickable_request_area',\n}\n\nexport enum ChargeType {\n\tCUSTOM = 'custom',\n}\n\nexport enum ShopOnlineStatus {\n\tONLINE = 'online',\n\tOFFLINE = 'offline',\n\tBUSY = 'busy',\n}\n\nexport enum OnlineStatus {\n\tONLINE = 'online',\n\tOFFLINE = 'offline',\n}\n\nexport enum ShopRole {\n\tPARENT = 'parent',\n\tPARENT_MANAGER = 'parent_manager',\n\tPARENT_ORDER_MANAGER = 'parent_order_manager',\n\tSHOP = 'shop',\n\tSHOP_MANAGER = 'shop_manager',\n\tSHOP_ORDER_MANAGER = 'shop_order_manager',\n}\n\nexport enum VendorRole {\n\tPARENT = 'parent',\n\tPARENT_MANAGER = 'parent_manager',\n\tPARENT_ORDER_MANAGER = 'parent_order_manager',\n\tVENDOR = 'vendor',\n\tVENDOR_MANAGER = 'vendor_manager',\n\tVENDOR_ORDER_MANAGER = 'vendor_order_manager',\n}\n\nexport enum BannerClickType {\n\tLINK = 'link',\n\tSHOP = 'shop',\n\tPRODUCT = 'product',\n\tLIST_CONTAINER = 'list_container',\n}\n\nexport enum BannerLinkType {\n\tURL = 'url',\n\tAPP_ROUTE = 'app-route',\n}\n\nexport enum BannerUserType {\n\tALL = 'all',\n\tPLUS = 'plus',\n\tNORMAL = 'normal',\n}\n\nexport enum CounterType {\n\tORDER = 'order',\n\tCRM_NUMBER = 'crm_number',\n\tshop = 'shop',\n\tPAYOUT = 'payout',\n\tTICKET = 'ticket',\n}\n\nexport enum FaqAccountType {\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum ZoneStatus {\n\tACTIVE = 'active',\n\tINACTIVE = 'inactive',\n\tBUSY = 'busy',\n}\n\nexport enum BobAccountType {\n\tRIDER = 'rider',\n\tSHOP = 'shop',\n}\n\nexport enum BobSettlementType {\n\tSETTLE_CASH = 'settle_cash',\n\t// SETTLE_PAYOUT = 'settle_Payout',\n}\n\nexport enum BobSettlementStatus {\n\tNOT_PAID = 'not_paid',\n\tPAID = 'paid',\n\tREVOKED = 'revoked',\n}\n\nexport enum BobModel {\n\tC2B = 'C2B',\n\t// B2C = 'B2C',\n}\n\nexport enum BobChannelType {\n\tCO = 'CO',\n\t// API = 'API',\n}\n\nexport enum BobType {\n\tINWARD = 'inward',\n\t// OUTWARD = 'outward',\n}\n\nexport enum CouponType {\n\tGLOBAL = 'global',\n\tINDIVIDUAL_STORE = 'individual_store',\n\tINDIVIDUAL_USER = 'individual_user',\n\tCUSTOM_COUPON = 'custom_coupon',\n\tREFERRAL_CODE = 'referral_code',\n\tREFERRAL_REWARD = 'referral_reward',\n}\n\nexport enum CouponExpirationReason {\n\tDURATION = 'duration',\n\tSPEND_LIMIT = 'spendLimit',\n\tTOTAL_ORDER_LIMIT = 'totalOrderLimit',\n}\n\nexport enum FavouriteType {\n\tPRODUCT = 'product',\n\tSHOP = 'shop',\n}\n\nexport enum MarketingType {\n\tDISCOUNT = 'discount',\n\tBUY1GET1 = 'buy1get1',\n\tFREE_DELIVERY = 'free_delivery',\n\tFEATURED = 'featured',\n\tPUNCH_MARKETING = 'punch_marketing',\n}\n\nexport enum ServiceMarketingType {\n\tDISCOUNT = 'discount',\n}\n\nexport enum MarketingStatus {\n\tACTIVE = 'active',\n\tPAUSED = 'paused',\n\tEXPIRED = 'expired',\n\tDELETED = 'deleted',\n}\n\nexport enum AdminRole {\n\tSUPER_ADMIN = 'super_admin',\n\tGENERAL_MANAGER = 'general_manager',\n\tORDER_MANAGEMENT_MANAGER = 'order_management_lead',\n\tORDER_MANAGEMENT_AGENT = 'order_management_agent',\n\tACCOUNT_MANAGER = 'account_manager',\n\tBUSINESS_DEVELOPMENT_EXECUTIVE = 'business_development_executive',\n\tACCOUNTING = 'accounting',\n\tMARKETING_MANAGER = 'marketing_manager',\n}\n\nexport enum CartStatus {\n\tACTIVE = 'active',\n\tLOCKED = 'locked',\n\tSUBMITTED = 'submitted',\n}\n\nexport enum PaymentPreference {\n\tPAY_FOR_EVERYONE = 'pay_for_everyone',\n\tPAY_FOR_THEMSELVES = 'pay_for_themselves',\n}\n\nexport enum CardType {\n\tSTRIPE = 'stripe',\n\tAREEEBA = 'areeba',\n}\n\nexport enum CardUserType {\n\tPARENT = 'parent',\n\tADMIN = 'admin',\n\tUSER = 'user',\n}\n\nexport enum AreebaCardStatus {\n\tPENDING = 'pending',\n\tACTIVE = 'active',\n}\n\nexport enum LiveStatus {\n\tONLINE = 'online',\n\tOFFLINE = 'offline',\n}\n\nexport enum CreatedBy {\n\tADMIN = 'admin',\n\tRIDER = 'rider',\n\tSHOP = 'shop',\n}\n\nexport enum ShiftType {\n\tDAY = 'day',\n\tNIGHT = 'night',\n}\n\nexport enum RiderType {\n\tSHOP_RIDER = 'shop_rider',\n\tLYXA_RIDER = 'lyxa_rider',\n}\n\nexport enum RiderBagSize {\n\tREGULAR = 'regular',\n\tLARGE = 'large',\n}\n\nexport enum OrderSize {\n\tSMALL = 'small',\n\tMEDIUM = 'medium',\n\tLARGE = 'large',\n}\n\nexport enum Language {\n\tEN = 'en',\n\tAR = 'ar',\n}\n\nexport enum OrderType {\n\tREGULAR = 'regular',\n\tCOURIER = 'courier',\n\tSHOP_COURIER = 'shop_courier',\n}\n\nexport enum RegularOrderStatus {\n\tSCHEDULED = 'schedule',\n\tPLACED = 'placed',\n\tACCEPTED_BY_RIDER = 'accepted_by_rider',\n\tPREPARING = 'preparing',\n\tREADY_FOR_PICKUP = 'ready_for_pickup',\n\tRIDER_ARRIVED_AT_STORE = 'rider_arrived_at_store',\n\tON_THE_WAY = 'on_the_way',\n\tREPLACEMENT_DROP_AND_PICKUP = 'replacement_drop_and_pickup',\n\tDELIVERED = 'delivered',\n\tCANCELLED = 'cancelled',\n}\n\nexport enum CourierOrderStatus {\n\tSCHEDULED = 'schedule',\n\tPLACED = 'placed',\n\tACCEPTED_BY_RIDER = 'accepted_by_rider',\n\tON_THE_WAY = 'on_the_way',\n\tDELIVERED = 'delivered',\n\tCANCELLED = 'cancelled',\n}\n\nexport enum ServiceOrderStatus {\n\tPENDING = 'pending',\n\tCONFIRMED = 'confirmed',\n\tIN_PROGRESS = 'in_progress',\n\tCOMPLETED = 'completed',\n\tCANCELLED = 'cancelled',\n\tOVERDUE = 'overdue',\n}\n\nexport enum ShopCourierOrderStatus {\n\tPLACED = 'placed',\n\tACCEPTED_BY_RIDER = 'accepted_by_rider',\n\tON_THE_WAY = 'on_the_way',\n\tDELIVERED = 'delivered',\n\tCANCELLED = 'cancelled',\n}\n\nexport enum CourierOrderPaymentFrom {\n\tSENDER = 'sender',\n\tRECEIVER = 'receiver',\n}\n\nexport enum DeliveryStatus {\n\tPENDING = 'pending',\n\tACCEPTED_BY_RIDER = 'accepted_by_rider',\n\tREADY_FOR_PICKUP = 'ready_to_pickup',\n\tON_THE_WAY = 'on_the_way',\n\tDELIVERED = 'delivered',\n\tCANCELLED = 'cancelled',\n}\n\nexport enum TripLegStatus {\n\tPENDING = 'pending',\n\tONGOING = 'ongoing',\n\tCOMPLETE = 'complete',\n}\n\nexport enum CourierServiceType {\n\tDELIVERY_ONLY = 'delivery_only',\n\tPURCHASE_AND_DELIVER = 'purchase_and_deliver',\n}\n\nexport enum RiderAssignmentStatus {\n\tREQUESTED = 'requested',\n\tASSIGNED = 'assigned',\n\tREJECTED = 'rejected',\n\tCANCELED = 'canceled',\n\tUNASSIGNED = 'unassigned', // for unassigning rider from order by admin\n}\n\nexport enum ZoneGeometryType {\n\tPOLYGON = 'Polygon',\n}\n\nexport enum WorkingHourSettingsType {\n\tGLOBAL = 'Global',\n\tSHOP = 'Shop',\n}\n\nexport enum MediaType {\n\tIMAGE = 'image',\n}\n\nexport enum SettlementType {\n\tADD_CREDIT = 'add_credit',\n\tREMOVE_CREDIT = 'remove_credit',\n\tRIDER_SETTLE_CASH = 'rider_settle_cash',\n\tSETTLE_VAT = 'settle_vat',\n\tSETTLE_FEATURED_AMOUNT = 'settle_featured_amount',\n\tSETTLE_SUBSCRIPTION_AMOUNT = 'settle_subscription_amount',\n\tSETTLE_PAYOUT = 'settle_payout',\n\tORDER_REFUND = 'order_refund',\n\tTOP_UP = 'top_up',\n\tWALLET_TOP_UP = 'wallet_top_up',\n}\n\nexport enum AddRemoveCreditSettlementType {\n\tADD_CREDIT = 'add_credit',\n\tREMOVE_CREDIT = 'remove_credit',\n}\n\nexport enum PlusSettingsPackageType {\n\tMONTHLY = 'monthly',\n\tYEARLY = 'yearly',\n\tWEEKLY = 'weekly',\n}\n\nexport enum SupportReasonTypeEnum {\n\tORDER = 'order',\n\tACCOUNT = 'account',\n\tSHOP = 'shop',\n\tFAQ = 'faq',\n}\n\nexport enum CancellationReasonTypeEnum {\n\tUSER = 'user',\n\tCOURIER = 'courier',\n\tSHOP = 'shop',\n\tRESOLVE_CHAT = 'resolve_chat',\n\tLYXA_PLUS_SUBSCRIPTION = 'lyxa_plus_subscription',\n}\n\nexport enum SettingsReasonStatus {\n\tACTIVE = 'active',\n\tINACTIVE = 'inactive',\n\tDELETE = 'delete',\n}\n\nexport enum AddRemoveCreditAccountType {\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum PayoutType {\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum PayoutStatus {\n\tPAID = 'paid',\n\tUNPAID = 'unpaid',\n\tREVOKED = 'revoked',\n}\n\nexport enum LogUser {\n\tALL = 'all',\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum OrderCanceledBy {\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tADMIN = 'admin',\n}\n\nexport enum LateOrderReason {\n\tSHOP_PREPARATION_OVERDUE = 'shop_preparation_overdue',\n\tPICKUP_OVERDUE = 'pickup_overdue',\n\tDELIVERY_OVERDUE = 'delivery_overdue',\n}\n\nexport enum UrgentOrderReason {\n\tSHOP_INACTION = 'shop_inaction',\n\tRIDER_INACTION = 'rider_inaction',\n\tHIGH_VALUE_FIRST_ORDER = 'high_value_first_order',\n\tADJUSTED_ORDER_REQUEST_IGNORED = 'adjusted_order_request_ignored',\n}\n\nexport enum ReplacementReason {\n\tMISSING = 'missing_item',\n\tWRONG = 'wrong_item',\n\tOTHER = 'other',\n}\n\nexport enum ReplacementType {\n\tSHOP_CUSTOMER = 'shop_customer',\n\tSHOP_CUSTOMER_SHOP = 'shop_customer_shop',\n}\n\nexport enum RewardedToTypeEnum {\n\tBUSINESS_DEVELOPMENT_EXECUTIVE = 'business_development_executive',\n\tRIDER = 'rider',\n}\n\nexport enum TicketType {\n\tORDER = 'order',\n\tACCOUNT = 'account',\n\tSHOP = 'shop',\n}\n\nexport enum TicketStatus {\n\tPENDING = 'pending',\n\tRESOLVED = 'resolved',\n\tONGOING = 'ongoing',\n}\n\nexport enum UserRef {\n\tUSER = 'User',\n\tADMIN = 'Admin',\n\tSHOP = 'Shop',\n\tRIDER = 'Rider',\n\tVENDOR = 'Vendor',\n\tPROFESSIONAL = 'Professional',\n}\n\nexport enum ChatroomType {\n\tTICKET = 'ticket',\n\tDIRECT = 'direct',\n}\n\nexport enum SocketEventType {\n\tMESSAGE_RECEIVED = 'message.received',\n\tTICKET_NOTIFICATION = 'ticket.notification',\n}\n\nexport enum ServiceCartStatus {\n\tACTIVE = 'active',\n\tLOCKED = 'locked',\n\tSUBMITTED = 'submitted',\n}\n\nexport enum Service {\n\tCLEANING = 'cleaning',\n\tLAUNDRY = 'laundry',\n\tPEST_CONTROL = 'pest_control',\n\tSALON = 'salon',\n}\n\nexport enum ProfessionalStatus {\n\tAVAILABLE = 'available',\n\tBUSY = 'busy',\n\tFULLY_BOOKED = 'fully_booked',\n}\n\nexport enum ServiceOrderPriority {\n\tNORMAL = 'normal',\n\tURGENT = 'urgent',\n\tFLAGGED = 'flagged',\n}\n\nexport enum ProfessionalRecurrencePattern {\n\tDAILY = 'daily',\n\tWEEKLY = 'weekly',\n\tMONTHLY = 'monthly',\n}\n\nexport enum ServiceOrderRecurrencePattern {\n\tONETIME = 'onetime',\n\tWEEKLY = 'weekly',\n\tMONTHLY = 'monthly',\n}\n\nexport enum ProfessionalScheduleType {\n\tBLOCK = 'block',\n\tORDER = 'order',\n}\n\nexport enum ShopFilterSortByEnum {\n\tPRICE_LOW_TO_HIGH = 'price_low_to_high',\n\tPRICE_HIGH_TO_LOW = 'price_high_to_low',\n\tDELIVERY_TIME = 'delivery_time',\n\tRATING = 'rating',\n}\n\nexport enum TRPCErrorEnum {\n\tPARSE_ERROR = 'PARSE_ERROR',\n\tBAD_REQUEST = 'BAD_REQUEST',\n\tINTERNAL_SERVER_ERROR = 'INTERNAL_SERVER_ERROR',\n\tUNAUTHORIZED = 'UNAUTHORIZED',\n\tFORBIDDEN = 'FORBIDDEN',\n\tNOT_FOUND = 'NOT_FOUND',\n\tMETHOD_NOT_SUPPORTED = 'METHOD_NOT_SUPPORTED',\n\tTIMEOUT = 'TIMEOUT',\n\tCONFLICT = 'CONFLICT',\n\tNOT_IMPLEMENTED = 'NOT_IMPLEMENTED',\n\tPRECONDITION_FAILED = 'PRECONDITION_FAILED',\n\tPAYLOAD_TOO_LARGE = 'PAYLOAD_TOO_LARGE',\n\tUNPROCESSABLE_CONTENT = 'UNPROCESSABLE_CONTENT',\n\tTOO_MANY_REQUESTS = 'TOO_MANY_REQUESTS',\n\tCLIENT_CLOSED_REQUEST = 'CLIENT_CLOSED_REQUEST',\n\tBAD_GATEWAY = 'BAD_GATEWAY',\n\tGATEWAY_TIMEOUT = 'GATEWAY_TIMEOUT',\n\tSERVICE_UNAVAILABLE = 'SERVICE_UNAVAILABLE',\n}\n\nexport enum ServiceOrderCanceledBy {\n\tUSER = 'user',\n\tSHOP = 'vendor',\n\tADMIN = 'admin',\n}\n\nexport enum PromotionType {\n\tPACKAGE = 'package',\n\tSLOT = 'slot',\n}\n\nexport enum FlagType {\n\tNORMAL = 'normal',\n\tLATE = 'late',\n\tREPLACEMENT = 'replacement',\n\tREFUNDED = 'refunded',\n}\n\nexport enum FlagReasonType {\n\tMISSING = 'missing_item',\n\tWRONG = 'wrong_item',\n\tOTHER = 'other',\n}\n\nexport enum AdjustmentReason {\n\tUSER_REQUEST = 'user_request',\n\tUNAVAILABLE_ITEM = 'unavailable_item',\n}\n\nexport enum FoodNutritionType {\n\tPROTEIN = 'protein',\n\tFAT = 'fat',\n\tCAL = 'cal',\n\tCARBS = 'carbs',\n\tFIBERS = 'fibers',\n}\n\nexport enum ReviewType {\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n\tPROFESSIONAL = 'professional',\n}\n\nexport enum OtpMethodType {\n\tSMS = 'sms',\n\tWHATSAPP = 'whatsapp',\n}\n"]}
|
|
1
|
+
{"version":3,"file":"enum.js","sourceRoot":"/","sources":["utilities/enum.ts"],"names":[],"mappings":";;;;;AAAA,IAAY,eAGX;AAHD,WAAY,eAAe;IAC1B,oCAAiB,CAAA;IACjB,sCAAmB,CAAA;AACpB,CAAC,EAHW,eAAe,+BAAf,eAAe,QAG1B;AAED,IAAY,WAOX;AAPD,WAAY,WAAW;IACtB,4BAAa,CAAA;IACb,4BAAa,CAAA;IACb,8BAAe,CAAA;IACf,kCAAmB,CAAA;IACnB,gCAAiB,CAAA;IACjB,4CAA6B,CAAA;AAC9B,CAAC,EAPW,WAAW,2B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AAkB;IAC7B,+CAAyB,CAAA;IACzB,+DAAyC,CAAA;IACzC,iDAA2B,CAAA;AAC5B,CAAC,EAJW,kBAAkB,kCAAlB,kBAAkB,QAI7B;AAED,IAAY,eAEX;AAFD,WAAY,eAAe;IAC1B,kEAA+C,CAAA;AAChD,CAAC,EAFW,eAAe,+BAAf,eAAe,QAE1B;AAED,IAAY,UAGX;AAHD,WAAY,UAAU;IACrB,+BAAiB,CAAA;IACjB,yBAAW,CAAA;AACZ,CAAC,EAHW,UAAU,0BAAV,UAAU,QAGrB;AAED,IAAY,UAGX;AAHD,WAAY,UAAU;IACrB,yBAAW,CAAA;IACX,+BAAiB,CAAA;AAClB,CAAC,EAHW,UAAU,0BAAV,UAAU,QAGrB;AAED,IAAY,WAUX;AAVD,WAAY,WAAW;IACtB,oCAAqB,CAAA;IACrB,wDAAyC,CAAA;IACzC,8CAA+B,CAAA;IAC/B,8CAA+B,CAAA;IAC/B,kCAAmB,CAAA;IACnB,4CAA6B,CAAA;IAC7B,4CAA6B,CAAA;IAC7B,kCAAmB,CAAA;IACnB,gCAAiB,CAAA;AAClB,CAAC,EAVW,WAAW,2BAAX,WAAW,QAUtB","sourcesContent":["export enum AgentLiveStatus {\n\tONLINE = 'online',\n\tOFFLINE = 'offline',\n}\n\nexport enum AccountType {\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n\tCOMPANY = 'company',\n\tVENDOR = 'vendor',\n\tPROFESSIONAL = 'professional',\n}\n\nexport enum Status {\n\tACTIVE = 'active',\n\tINACTIVE = 'inactive',\n}\n\nexport enum ItemType {\n\tFOOD = 'food',\n\tGROCERY = 'grocery',\n\tPHARMACY = 'pharmacy',\n\tCOFFEE = 'coffee',\n\tFLOWER = 'flower',\n\tPET = 'pet',\n\tHEALTHY_CORNER = 'healthy_corner',\n}\n\nexport enum AdjustmentStatus {\n\tNONE = 'none',\n\tPENDING = 'pending',\n\tAPPROVED = 'approved',\n}\n\nexport enum GlobalItemType {\n\tGROCERY = ItemType.GROCERY,\n}\n\nexport enum WeekDay {\n\tSunday = 0,\n\tMonday = 1,\n\tTuesday = 2,\n\tWednesday = 3,\n\tThursday = 4,\n\tFriday = 5,\n\tSaturday = 6,\n}\n\nexport enum WorkStatus {\n\tOPEN = 'open',\n\tCLOSED = 'closed',\n\tFULL_DAY = 'full_day',\n}\n\nexport enum HolidayWorkStatus {\n\tCLOSED = WorkStatus.CLOSED,\n\tFULL_DAY = WorkStatus.FULL_DAY,\n}\n\nexport enum ValueType {\n\tPERCENTAGE = 'percentage',\n\tFIXED = 'fixed',\n}\n\nexport enum PaymentMethod {\n\tCASH = 'cash',\n\tONLINE = 'online',\n}\n\nexport enum PaymentStatus {\n\tPAID = 'paid',\n\tPENDING = 'pending',\n\tFAILED = 'failed',\n\tREFUNDED = 'refunded',\n\tPARTIALLY_REFUNDED = 'partially_refunded',\n}\n\nexport enum PaidCurrency {\n\tBASE = 'base',\n\tSECONDARY = 'secondary',\n\tMIXED = 'mixed',\n}\n\nexport enum SubscriptionPackage {\n\tMONTHLY = 'monthly',\n\tYEARLY = 'yearly',\n}\n\nexport enum SubscriptionStatus {\n\tONGOING = 'ongoing',\n\tEXPIRED = 'expired',\n}\n\nexport enum RatingAccountType {\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum GeoLocationType {\n\tPOINT = 'Point',\n}\n\nexport enum UpdatedField {\n\tMAX_TOTAL_EST_ITEMS_PRICE = 'max_total_est_items_price',\n\tMAX_DISTANCE = 'max_distance',\n\tDAILY_WORKING_HOURS = 'daily_working_hours',\n\tBOB_CASH_SETTLEMENT_LIMIT = 'bob_cash_settlement_limit',\n\tTIPS = 'tips',\n\tEQUIPMENTS = 'equipments',\n\tMONTHLY_SHOP_TARGET = 'monthly_shop_target',\n\tMONTHLY_REWARD_PRIZE = 'monthly_reward_prize',\n\tBASE_CURRENCY = 'base_currency',\n\tSECONDARY_CURRENCY = 'secondary_currency',\n\tIS_DUAL_CURRENCY_ENABLED = 'is_dual_currency_enabled',\n\tEXCHANGE_RATE = 'exchange_rate',\n\tISSUANCE_DAY = 'issuance_day',\n\tOVER_DUE_PERIODS = 'over_due_periods',\n\tPAY_LIMIT_FOR_USER = 'pay_limit_for_user',\n\tVAT_PERCENTAGE = 'vat_percentage',\n\tRIDER_SEARCH_RANGES = 'rider_search_ranges',\n\tNEAR_BY_SHOP_DISTANCE = 'near_by_shop_distance',\n\tNEAR_BY_SHOP_DISTANCE_IN_HOME_SCREEN = 'near_by_shop_distance_in_home_screen',\n\tUNITS = 'units',\n\tCURRENCY_SETTING = 'currency_setting',\n\tPAYMENT_METHODS = 'payment_methods',\n\tIS_GROUND_ORDER_ENABLED = 'is_ground_order_enabled',\n\tCUSTOMER_SUPPORT_PHONE_NUMBER = 'customer_support_phone_number',\n}\n\nexport enum AdminLogsUpdatedFieldsType {\n\tCHARGE_SETTINGS = 'charge_settings',\n\tSERVICE_FEE_SETTINGS = 'service_fee_settings',\n\tPAYOUT_SETTINGS = 'payout_settings',\n\tCOURIER_SETTINGS = 'courier_settings',\n\tRIDER_SETTINGS = 'rider_settings',\n\tBUSINESS_DEVELOPMENT_EXECUTIVE = 'business_development_executive',\n\tPAY_LIMIT_FOR_USER = 'pay_limit_for_user',\n\tVAT_PERCENTAGE = 'vat_percentage',\n\tRIDER_SEARCH_RANGES = 'rider_search_ranges',\n\tRIDER_BATCHES = 'rider_batches',\n\tNEARBY_SHOP_DISTANCE = 'nearby_shop_distance',\n\tNEAR_BY_SHOP_DISTANCE_IN_HOME_SCREEN = 'nearby_shop_distance_in_home_screen',\n\tUNITS = 'units',\n\tCURRENCY_SETTING = 'currency_setting',\n\tPAYMENT_METHODS = 'payment_methods',\n\tIS_GROUPED_ORDER_ENABLED = 'is_grouped_order_enabled',\n\tCUSTOMER_SUPPORT = 'customer_support',\n\tCUSTOMER_SUPPORT_BATCHES = 'customer_support_batches',\n\tWORK_HOUR_SETTINGS = 'work_hour_settings',\n\tPLUS_SETTING = 'plus_setting',\n\tDELIVERY_CHARGES = 'delivery_charges',\n\tSETTINGS_DELETED = 'settings_deleted',\n\n\tSHOP_ACTIVATED = 'shop_activated',\n\tSHOP_DEACTIVATED = 'shop_deactivated',\n\tSHOP_DELETED = 'shop_deleted',\n\n\tSHOW_SHOP_IN_USER_APP = 'show_shop_in_user_app',\n\tHIDE_SHOP_IN_USER_APP = 'hide_shop_in_user_app',\n\n\tPARENT_ACTIVATED = 'parent_activated',\n\tPARENT_DEACTIVATED = 'parent_deactivated',\n\tPARENT_DELETED = 'parent_deleted',\n\n\tRIDER_CREATED = 'rider_created',\n\tRIDER_UPDATED = 'rider_updated',\n\tRIDER_ACTIVATED = 'rider_activated',\n\tRIDER_DEACTIVATED = 'rider_deactivated',\n\tRIDER_DELETED = 'rider_deleted',\n\n\tACTIVATED_MARKETING_PROMOTIONS = 'activated_marketing_promotions',\n\tCONTINUED_MARKETING_PROMOTIONS = 'continued_marketing_promotions',\n\tEDITED_MARKETING_PROMOTIONS = 'edited_marketing_promotions',\n\tPAUSED_MARKETING_PROMOTIONS = 'paused_marketing_promotions',\n\tDELETED_MARKETING_PROMOTIONS = 'deleted_marketing_promotions',\n\n\tACTIVATED_ZONE = 'activated_zone',\n\tDEACTIVATED_ZONE = 'deactivated_zone',\n\n\tCREATED_MARKETING_SETTINGS = 'created_marketing_settings',\n\tCHANGE_IN_MARKETING_SETTINGS = 'change_in_marketing_settings',\n\tDELETED_MARKETING_SETTINGS = 'deleted_marketing_settings',\n\n\tCHANGE_IN_PRIVACY_POLICY = 'change_in_privacy_policy',\n\tCHANGE_IN_USER_TERMS_AND_CONDITIONS = 'change_in_user_terms_and_conditions',\n\tCHANGE_IN_SHOP_TERMS_AND_CONDITIONS = 'change_in_shop_terms_and_conditions',\n\tCHANGE_IN_RIDER_TERMS_AND_CONDITIONS = 'change_in_rider_terms_and_conditions',\n\tCHANGE_IN_LYXA_PLUS_TERMS_AND_CONDITIONS = 'lyxa_plux_terms_and_conditions',\n\n\tCHANGE_IN_SUPPORT_REASON = 'change_in_support_reason',\n\tDELETE_SUPPORT_REASON = 'delete_support_reason',\n\tCHANGE_IN_CANCELLATION_REASON = 'change_in_cancellation_reason',\n\tDELETE_CANCELLATION_REASON = 'delete_cancellation_reason',\n\n\tCHANGE_IN_SETTINGS_OPENING_HOURS = 'change_in_settings_opening_hours',\n\n\tCHANGE_IN_DEFAULT_CHAT_MESSAGE = 'change_in_default_chat_messages',\n\tDELETE_DEFAULT_CHAT_MESSAGE = 'delete_default_chat_message',\n\n\tCHANGE_IN_LYXA_PLUS_CONFIGURATION = 'change_in_lyxa_plux_configuration',\n\n\tCHANGE_IN_BANNER_DISPLAY = 'change_in_banner_display',\n\tCHANGE_IN_TAG_DISPLAY = 'change_in_tag_display',\n\tCHANGE_IN_LIST_CONTAINER_DISPLAY = 'change_in_list_container_display',\n\tCHANGE_IN_FILTER_CONTAINER_DISPLAY = 'change_in_filter_container_display',\n\tCHANGE_IN_USER_APP_SECTIONS_DISPLAY = 'change_in_user_app_sections_display',\n\tCHANGE_IN_FEATURED_SHOP_DISPLAY = 'change_in_featured_shop_display',\n\n\tDELETE_BANNER_DISPLAY = 'delete_banner_display',\n\tDELETE_TAG_DISPLAY = 'delete_tag_display',\n\tDELETE_LIST_CONTAINER_DISPLAY = 'delete_list_container_display',\n\tDELETE_FILTER_CONTAINER_DISPLAY = 'delete_filter_container_display',\n\tDELETE_USER_APP_SECTION_DISPLAY = 'delete_user_app_section_display',\n\tDELETE_FEATURED_SHOP_DISPLAY = 'delete_featured_shop_display',\n}\n\nexport enum UserAppSectionType {\n\tSHOW_ALL = 'show_all',\n\tSTORE_PUNCHES = 'store_punches',\n\tAUTHENTIC_BEIRUT = 'authentic_beirut',\n\tCRAZY_OFFER_SHOPS = 'crazy_offer_shops',\n\n\tNEAR_ME = 'near_me',\n\tNEARBY_FOOD = 'nearby_food',\n\tNEARBY_GROCERY = 'nearby_grocery',\n\tNEARBY_PET = 'nearby_pet',\n\tNEARBY_FLOWER = 'nearby_flower',\n\tNEARBY_COFFEE = 'nearby_coffee',\n\n\tOFFERS = 'offers',\n\tOFFERS_FOOD = 'offers_food',\n\tOFFERS_GROCERY = 'offers_grocery',\n\tOFFERS_PET = 'offers_pet',\n\tOFFERS_FLOWER = 'offers_flower',\n\tOFFERS_COFFEE = 'offers_coffee',\n\n\tFREE_DELIVERY = 'free_delivery',\n\tFREE_DELIVERY_FOOD = 'free_delivery_food',\n\tFREE_DELIVERY_GROCERY = 'free_delivery_grocery',\n\tFREE_DELIVERY_PET = 'free_delivery_pet',\n\tFREE_DELIVERY_FLOWER = 'free_delivery_flower',\n\tFREE_DELIVERY_COFFEE = 'free_delivery_coffee',\n\n\tORDER_AGAIN = 'order_again',\n\tORDER_AGAIN_FOOD = 'order_again_food',\n\tORDER_AGAIN_GROCERY = 'order_again_grocery',\n\tORDER_AGAIN_PET = 'order_again_pet',\n\tORDER_AGAIN_FLOWER = 'order_again_flower',\n\tORDER_AGAIN_COFFEE = 'order_again_coffee',\n\n\tTOP_PICKS = 'top_picks',\n\tTOP_PICKS_FOOD = 'top_picks_food',\n\tTOP_PICKS_GROCERY = 'top_picks_grocery',\n\tTOP_PICKS_PET = 'top_picks_pet',\n\tTOP_PICKS_FLOWER = 'top_picks_flower',\n\tTOP_PICKS_COFFEE = 'top_picks_coffee',\n}\n\nexport enum UserAppSectionItemType {\n\tHOME = 'home',\n\tFOOD = 'food',\n\tGROCERY = 'grocery',\n\tCOFFEE = 'coffee',\n\tPET = 'pet',\n\tFLOWER = 'flower',\n}\n\nexport enum CoreAuthIdentityType {\n\tEMAIL = 'email',\n\tPHONE = 'phone',\n\tGOOGLE = 'google',\n\tAPPLE = 'apple',\n}\n\nexport enum ProductType {\n\tMEAT = 'meat',\n\tCHICKEN = 'chicken',\n\tFISH = 'fish',\n\tVEGETARIAN = 'vegetarian',\n\tOTHER = 'other',\n}\n\nexport enum PriceOption {\n\tSINGLE_PRICE = 'single_price',\n\tPRICE_PER_UNIT = 'price_per_unit',\n\tPRICE_PER_PORTION = 'price_per_portion',\n}\n\nexport enum ProductDietaryType {\n\tGLUTEN_FREE = 'gluten_free',\n\tLOW_CAL = 'low_cal',\n\tVEGETARIAN = 'vegetarian',\n\tVEGAN = 'vegan',\n\tKETO = 'keto',\n\tLACTOSE_FREE = 'lactose_free',\n\tHIGH_PROTEIN = 'high_protein',\n}\n\nexport enum DishCategory {\n\tBREAKFAST = 'breakfast',\n\tLUNCH = 'lunch',\n\tDINNER = 'dinner',\n\tSNACKS = 'snacks',\n}\n\nexport enum NotificationAccountType {\n\tUSER = 'user',\n\tPARENT = 'parent',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n\tADMIN = 'admin',\n\tCUSTOMER_SERVICE = 'customer_service',\n}\n\nexport enum ClickType {\n\tCLICKABLE_URL = 'clickable_url',\n\tCLICKABLE_ORDER = 'clickable_order',\n\tCLICKABLE_SHOP = 'clickable_shop',\n\tCLICKABLE_PRODUCT = 'clickable_product',\n\tCLICKABLE_LIST_CONTAINER = 'clickable_list_container',\n\tCLICKABLE_PAYOUT = 'clickable_payout',\n\tCLICKABLE_BOB_FINANCE = 'clickable_bob_finance',\n\tCLICKABLE_REQUEST_AREA = 'clickable_request_area',\n}\n\nexport enum ChargeType {\n\tCUSTOM = 'custom',\n}\n\nexport enum ShopOnlineStatus {\n\tONLINE = 'online',\n\tOFFLINE = 'offline',\n\tBUSY = 'busy',\n}\n\nexport enum OnlineStatus {\n\tONLINE = 'online',\n\tOFFLINE = 'offline',\n}\n\nexport enum ShopRole {\n\tPARENT = 'parent',\n\tPARENT_MANAGER = 'parent_manager',\n\tPARENT_ORDER_MANAGER = 'parent_order_manager',\n\tSHOP = 'shop',\n\tSHOP_MANAGER = 'shop_manager',\n\tSHOP_ORDER_MANAGER = 'shop_order_manager',\n}\n\nexport enum VendorRole {\n\tPARENT = 'parent',\n\tPARENT_MANAGER = 'parent_manager',\n\tPARENT_ORDER_MANAGER = 'parent_order_manager',\n\tVENDOR = 'vendor',\n\tVENDOR_MANAGER = 'vendor_manager',\n\tVENDOR_ORDER_MANAGER = 'vendor_order_manager',\n}\n\nexport enum BannerClickType {\n\tLINK = 'link',\n\tSHOP = 'shop',\n\tPRODUCT = 'product',\n\tLIST_CONTAINER = 'list_container',\n}\n\nexport enum BannerLinkType {\n\tURL = 'url',\n\tAPP_ROUTE = 'app-route',\n}\n\nexport enum BannerUserType {\n\tALL = 'all',\n\tPLUS = 'plus',\n\tNORMAL = 'normal',\n}\n\nexport enum CounterType {\n\tORDER = 'order',\n\tCRM_NUMBER = 'crm_number',\n\tshop = 'shop',\n\tPAYOUT = 'payout',\n\tTICKET = 'ticket',\n}\n\nexport enum FaqAccountType {\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum ZoneStatus {\n\tACTIVE = 'active',\n\tINACTIVE = 'inactive',\n\tBUSY = 'busy',\n}\n\nexport enum BobAccountType {\n\tRIDER = 'rider',\n\tSHOP = 'shop',\n}\n\nexport enum BobSettlementType {\n\tSETTLE_CASH = 'settle_cash',\n\t// SETTLE_PAYOUT = 'settle_Payout',\n}\n\nexport enum BobSettlementStatus {\n\tNOT_PAID = 'not_paid',\n\tPAID = 'paid',\n\tREVOKED = 'revoked',\n}\n\nexport enum BobModel {\n\tC2B = 'C2B',\n\t// B2C = 'B2C',\n}\n\nexport enum BobChannelType {\n\tCO = 'CO',\n\t// API = 'API',\n}\n\nexport enum BobType {\n\tINWARD = 'inward',\n\t// OUTWARD = 'outward',\n}\n\nexport enum CouponType {\n\tGLOBAL = 'global',\n\tINDIVIDUAL_STORE = 'individual_store',\n\tINDIVIDUAL_USER = 'individual_user',\n\tCUSTOM_COUPON = 'custom_coupon',\n\tREFERRAL_CODE = 'referral_code',\n\tREFERRAL_REWARD = 'referral_reward',\n}\n\nexport enum CouponExpirationReason {\n\tDURATION = 'duration',\n\tSPEND_LIMIT = 'spendLimit',\n\tTOTAL_ORDER_LIMIT = 'totalOrderLimit',\n}\n\nexport enum FavouriteType {\n\tPRODUCT = 'product',\n\tSHOP = 'shop',\n}\n\nexport enum MarketingType {\n\tDISCOUNT = 'discount',\n\tBUY1GET1 = 'buy1get1',\n\tFREE_DELIVERY = 'free_delivery',\n\tFEATURED = 'featured',\n\tPUNCH_MARKETING = 'punch_marketing',\n}\n\nexport enum ServiceMarketingType {\n\tDISCOUNT = 'discount',\n}\n\nexport enum MarketingStatus {\n\tACTIVE = 'active',\n\tPAUSED = 'paused',\n\tEXPIRED = 'expired',\n\tDELETED = 'deleted',\n}\n\nexport enum PunchMarketingStatus {\n\tACTIVE = 'active',\n\tCOMPLETED = 'completed',\n\tCOUPON_USED = 'coupon_used',\n\tEXPIRED = 'expired',\n}\n\nexport enum AdminRole {\n\tSUPER_ADMIN = 'super_admin',\n\tGENERAL_MANAGER = 'general_manager',\n\tORDER_MANAGEMENT_MANAGER = 'order_management_lead',\n\tORDER_MANAGEMENT_AGENT = 'order_management_agent',\n\tACCOUNT_MANAGER = 'account_manager',\n\tBUSINESS_DEVELOPMENT_EXECUTIVE = 'business_development_executive',\n\tACCOUNTING = 'accounting',\n\tMARKETING_MANAGER = 'marketing_manager',\n}\n\nexport enum CartStatus {\n\tACTIVE = 'active',\n\tLOCKED = 'locked',\n\tSUBMITTED = 'submitted',\n}\n\nexport enum PaymentPreference {\n\tPAY_FOR_EVERYONE = 'pay_for_everyone',\n\tPAY_FOR_THEMSELVES = 'pay_for_themselves',\n}\n\nexport enum CardType {\n\tSTRIPE = 'stripe',\n\tAREEEBA = 'areeba',\n}\n\nexport enum CardUserType {\n\tPARENT = 'parent',\n\tADMIN = 'admin',\n\tUSER = 'user',\n}\n\nexport enum AreebaCardStatus {\n\tPENDING = 'pending',\n\tACTIVE = 'active',\n}\n\nexport enum LiveStatus {\n\tONLINE = 'online',\n\tOFFLINE = 'offline',\n}\n\nexport enum CreatedBy {\n\tADMIN = 'admin',\n\tRIDER = 'rider',\n\tSHOP = 'shop',\n}\n\nexport enum ShiftType {\n\tDAY = 'day',\n\tNIGHT = 'night',\n}\n\nexport enum RiderType {\n\tSHOP_RIDER = 'shop_rider',\n\tLYXA_RIDER = 'lyxa_rider',\n}\n\nexport enum RiderBagSize {\n\tREGULAR = 'regular',\n\tLARGE = 'large',\n}\n\nexport enum OrderSize {\n\tSMALL = 'small',\n\tMEDIUM = 'medium',\n\tLARGE = 'large',\n}\n\nexport enum Language {\n\tEN = 'en',\n\tAR = 'ar',\n}\n\nexport enum OrderType {\n\tREGULAR = 'regular',\n\tCOURIER = 'courier',\n\tSHOP_COURIER = 'shop_courier',\n}\n\nexport enum RegularOrderStatus {\n\tSCHEDULED = 'schedule',\n\tPLACED = 'placed',\n\tACCEPTED_BY_RIDER = 'accepted_by_rider',\n\tPREPARING = 'preparing',\n\tREADY_FOR_PICKUP = 'ready_for_pickup',\n\tRIDER_ARRIVED_AT_STORE = 'rider_arrived_at_store',\n\tON_THE_WAY = 'on_the_way',\n\tREPLACEMENT_DROP_AND_PICKUP = 'replacement_drop_and_pickup',\n\tDELIVERED = 'delivered',\n\tCANCELLED = 'cancelled',\n}\n\nexport enum CourierOrderStatus {\n\tSCHEDULED = 'schedule',\n\tPLACED = 'placed',\n\tACCEPTED_BY_RIDER = 'accepted_by_rider',\n\tON_THE_WAY = 'on_the_way',\n\tDELIVERED = 'delivered',\n\tCANCELLED = 'cancelled',\n}\n\nexport enum ServiceOrderStatus {\n\tPENDING = 'pending',\n\tCONFIRMED = 'confirmed',\n\tIN_PROGRESS = 'in_progress',\n\tCOMPLETED = 'completed',\n\tCANCELLED = 'cancelled',\n\tOVERDUE = 'overdue',\n}\n\nexport enum ShopCourierOrderStatus {\n\tPLACED = 'placed',\n\tACCEPTED_BY_RIDER = 'accepted_by_rider',\n\tON_THE_WAY = 'on_the_way',\n\tDELIVERED = 'delivered',\n\tCANCELLED = 'cancelled',\n}\n\nexport enum CourierOrderPaymentFrom {\n\tSENDER = 'sender',\n\tRECEIVER = 'receiver',\n}\n\nexport enum DeliveryStatus {\n\tPENDING = 'pending',\n\tACCEPTED_BY_RIDER = 'accepted_by_rider',\n\tREADY_FOR_PICKUP = 'ready_to_pickup',\n\tON_THE_WAY = 'on_the_way',\n\tDELIVERED = 'delivered',\n\tCANCELLED = 'cancelled',\n}\n\nexport enum TripLegStatus {\n\tPENDING = 'pending',\n\tONGOING = 'ongoing',\n\tCOMPLETE = 'complete',\n}\n\nexport enum CourierServiceType {\n\tDELIVERY_ONLY = 'delivery_only',\n\tPURCHASE_AND_DELIVER = 'purchase_and_deliver',\n}\n\nexport enum RiderAssignmentStatus {\n\tREQUESTED = 'requested',\n\tASSIGNED = 'assigned',\n\tREJECTED = 'rejected',\n\tCANCELED = 'canceled',\n\tUNASSIGNED = 'unassigned', // for unassigning rider from order by admin\n}\n\nexport enum ZoneGeometryType {\n\tPOLYGON = 'Polygon',\n}\n\nexport enum WorkingHourSettingsType {\n\tGLOBAL = 'Global',\n\tSHOP = 'Shop',\n}\n\nexport enum MediaType {\n\tIMAGE = 'image',\n}\n\nexport enum SettlementType {\n\tADD_CREDIT = 'add_credit',\n\tREMOVE_CREDIT = 'remove_credit',\n\tRIDER_SETTLE_CASH = 'rider_settle_cash',\n\tSETTLE_VAT = 'settle_vat',\n\tSETTLE_FEATURED_AMOUNT = 'settle_featured_amount',\n\tSETTLE_SUBSCRIPTION_AMOUNT = 'settle_subscription_amount',\n\tSETTLE_PAYOUT = 'settle_payout',\n\tORDER_REFUND = 'order_refund',\n\tTOP_UP = 'top_up',\n\tWALLET_TOP_UP = 'wallet_top_up',\n}\n\nexport enum AddRemoveCreditSettlementType {\n\tADD_CREDIT = 'add_credit',\n\tREMOVE_CREDIT = 'remove_credit',\n}\n\nexport enum PlusSettingsPackageType {\n\tMONTHLY = 'monthly',\n\tYEARLY = 'yearly',\n\tWEEKLY = 'weekly',\n}\n\nexport enum SupportReasonTypeEnum {\n\tORDER = 'order',\n\tACCOUNT = 'account',\n\tSHOP = 'shop',\n\tFAQ = 'faq',\n}\n\nexport enum CancellationReasonTypeEnum {\n\tUSER = 'user',\n\tCOURIER = 'courier',\n\tSHOP = 'shop',\n\tRESOLVE_CHAT = 'resolve_chat',\n\tLYXA_PLUS_SUBSCRIPTION = 'lyxa_plus_subscription',\n}\n\nexport enum SettingsReasonStatus {\n\tACTIVE = 'active',\n\tINACTIVE = 'inactive',\n\tDELETE = 'delete',\n}\n\nexport enum AddRemoveCreditAccountType {\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum PayoutType {\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum PayoutStatus {\n\tPAID = 'paid',\n\tUNPAID = 'unpaid',\n\tREVOKED = 'revoked',\n}\n\nexport enum LogUser {\n\tALL = 'all',\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n}\n\nexport enum OrderCanceledBy {\n\tUSER = 'user',\n\tSHOP = 'shop',\n\tADMIN = 'admin',\n}\n\nexport enum ReplacementReason {\n\tMISSING = 'missing_item',\n\tWRONG = 'wrong_item',\n\tOTHER = 'other',\n}\n\nexport enum ReplacementType {\n\tSHOP_CUSTOMER = 'shop_customer',\n\tSHOP_CUSTOMER_SHOP = 'shop_customer_shop',\n}\n\nexport enum RewardedToTypeEnum {\n\tBUSINESS_DEVELOPMENT_EXECUTIVE = 'business_development_executive',\n\tRIDER = 'rider',\n}\n\nexport enum TicketType {\n\tORDER = 'order',\n\tACCOUNT = 'account',\n\tSHOP = 'shop',\n}\n\nexport enum TicketStatus {\n\tPENDING = 'pending',\n\tRESOLVED = 'resolved',\n\tONGOING = 'ongoing',\n}\n\nexport enum UserRef {\n\tUSER = 'User',\n\tADMIN = 'Admin',\n\tSHOP = 'Shop',\n\tRIDER = 'Rider',\n\tVENDOR = 'Vendor',\n\tPROFESSIONAL = 'Professional',\n}\n\nexport enum ChatroomType {\n\tTICKET = 'ticket',\n\tDIRECT = 'direct',\n}\n\nexport enum ServiceCartStatus {\n\tACTIVE = 'active',\n\tLOCKED = 'locked',\n\tSUBMITTED = 'submitted',\n}\n\nexport enum Service {\n\tCLEANING = 'cleaning',\n\tLAUNDRY = 'laundry',\n\tPEST_CONTROL = 'pest_control',\n\tSALON = 'salon',\n}\n\nexport enum ProfessionalStatus {\n\tAVAILABLE = 'available',\n\tBUSY = 'busy',\n\tFULLY_BOOKED = 'fully_booked',\n}\n\nexport enum ServiceOrderPriority {\n\tNORMAL = 'normal',\n\tURGENT = 'urgent',\n\tFLAGGED = 'flagged',\n}\n\nexport enum ProfessionalRecurrencePattern {\n\tDAILY = 'daily',\n\tWEEKLY = 'weekly',\n\tMONTHLY = 'monthly',\n}\n\nexport enum ServiceOrderRecurrencePattern {\n\tONETIME = 'onetime',\n\tWEEKLY = 'weekly',\n\tMONTHLY = 'monthly',\n}\n\nexport enum ProfessionalScheduleType {\n\tBLOCK = 'block',\n\tORDER = 'order',\n}\n\nexport enum ShopFilterSortByEnum {\n\tPRICE_LOW_TO_HIGH = 'price_low_to_high',\n\tPRICE_HIGH_TO_LOW = 'price_high_to_low',\n\tDELIVERY_TIME = 'delivery_time',\n\tRATING = 'rating',\n}\n\nexport enum TRPCErrorEnum {\n\tPARSE_ERROR = 'PARSE_ERROR',\n\tBAD_REQUEST = 'BAD_REQUEST',\n\tINTERNAL_SERVER_ERROR = 'INTERNAL_SERVER_ERROR',\n\tUNAUTHORIZED = 'UNAUTHORIZED',\n\tFORBIDDEN = 'FORBIDDEN',\n\tNOT_FOUND = 'NOT_FOUND',\n\tMETHOD_NOT_SUPPORTED = 'METHOD_NOT_SUPPORTED',\n\tTIMEOUT = 'TIMEOUT',\n\tCONFLICT = 'CONFLICT',\n\tNOT_IMPLEMENTED = 'NOT_IMPLEMENTED',\n\tPRECONDITION_FAILED = 'PRECONDITION_FAILED',\n\tPAYLOAD_TOO_LARGE = 'PAYLOAD_TOO_LARGE',\n\tUNPROCESSABLE_CONTENT = 'UNPROCESSABLE_CONTENT',\n\tTOO_MANY_REQUESTS = 'TOO_MANY_REQUESTS',\n\tCLIENT_CLOSED_REQUEST = 'CLIENT_CLOSED_REQUEST',\n\tBAD_GATEWAY = 'BAD_GATEWAY',\n\tGATEWAY_TIMEOUT = 'GATEWAY_TIMEOUT',\n\tSERVICE_UNAVAILABLE = 'SERVICE_UNAVAILABLE',\n}\n\nexport enum ServiceOrderCanceledBy {\n\tUSER = 'user',\n\tSHOP = 'vendor',\n\tADMIN = 'admin',\n}\n\nexport enum PromotionType {\n\tPACKAGE = 'package',\n\tSLOT = 'slot',\n}\n\nexport enum FlagType {\n\tNORMAL = 'normal',\n\tLATE = 'late',\n\tURGENT = 'urgent',\n\tREPLACEMENT = 'replacement',\n\tREFUNDED = 'refunded',\n}\n\nexport enum FlagReasonType {\n\tMISSING = 'missing_item',\n\tWRONG = 'wrong_item',\n\tOTHER = 'other',\n\n\t// Late Order Reasons\n\tSHOP_PREPARATION_OVERDUE = 'shop_preparation_overdue',\n\tPICKUP_OVERDUE = 'pickup_overdue',\n\tDELIVERY_OVERDUE = 'delivery_overdue',\n\n\t// Urgent Order Reasons\n\tSHOP_INACTION = 'shop_inaction',\n\tRIDER_INACTION = 'rider_inaction',\n\tHIGH_VALUE_FIRST_ORDER = 'high_value_first_order',\n\tADJUSTED_ORDER_REQUEST_IGNORED = 'adjusted_order_request_ignored',\n}\n\nexport enum AdjustmentReason {\n\tUSER_REQUEST = 'user_request',\n\tUNAVAILABLE_ITEM = 'unavailable_item',\n}\n\nexport enum FoodNutritionType {\n\tPROTEIN = 'protein',\n\tFAT = 'fat',\n\tCAL = 'cal',\n\tCARBS = 'carbs',\n\tFIBERS = 'fibers',\n}\n\nexport enum ReviewType {\n\tSHOP = 'shop',\n\tRIDER = 'rider',\n\tPROFESSIONAL = 'professional',\n}\n\nexport enum OtpMethodType {\n\tSMS = 'sms',\n\tWHATSAPP = 'whatsapp',\n}\n\nexport enum SocketServiceQueue {\n\tCHAT = 'socket.chat.emit',\n\tNOTIFICATION = 'socket.notification.emit',\n\tORDER = 'socket.order.emit',\n}\n\nexport enum SocketEventType {\n\tCHATROOM_MESSAGE_SEND = 'CHATROOM_MESSAGE_SEND',\n}\n\nexport enum DeviceType {\n\tMOBILE = 'mobile',\n\tWEB = 'web',\n}\n\nexport enum ActionType {\n\tADD = 'add',\n\tREMOVE = 'remove',\n}\n\nexport enum ServiceType {\n\tCLEANING = 'cleaning',\n\tFURNITURE_CLEANING = 'furniture_cleaning',\n\tHOME_CLEANING = 'home_cleaning',\n\tDEEP_CLEANING = 'deep_cleaning',\n\tLAUNDRY = 'laundry',\n\tREGULAR_WASH = 'regular_wash',\n\tDRY_CLEANING = 'dry_cleaning',\n\tIRONING = 'ironing',\n\tSALOON = 'saloon',\n}\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { DTO } from './global-validation';
|
|
3
|
-
import { GeoLocationType, HolidayWorkStatus, WeekDay, WorkStatus } from '../enum';
|
|
3
|
+
import { ActionType, GeoLocationType, HolidayWorkStatus, WeekDay, WorkStatus } from '../enum';
|
|
4
4
|
import { mongoose } from '@typegoose/typegoose';
|
|
5
5
|
export declare const FilterSchema: z.ZodOptional<z.ZodObject<{
|
|
6
6
|
size: z.ZodDefault<z.ZodOptional<z.ZodNumber>>;
|
|
@@ -698,10 +698,13 @@ export declare const GetOneQuerySchema: z.ZodObject<{
|
|
|
698
698
|
export type GetOneQueryDTO = DTO<typeof GetOneQuerySchema>;
|
|
699
699
|
declare const ShareableLinkSchema: z.ZodObject<{
|
|
700
700
|
link: z.ZodString;
|
|
701
|
+
message: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
701
702
|
}, "strip", z.ZodTypeAny, {
|
|
702
703
|
link: string;
|
|
704
|
+
message: string;
|
|
703
705
|
}, {
|
|
704
706
|
link: string;
|
|
707
|
+
message: string;
|
|
705
708
|
}>;
|
|
706
709
|
export declare const ShareableLinkResponseSchema: z.ZodObject<{
|
|
707
710
|
success: z.ZodBoolean;
|
|
@@ -725,12 +728,15 @@ export declare const ShareableLinkResponseSchema: z.ZodObject<{
|
|
|
725
728
|
}>>;
|
|
726
729
|
documents: z.ZodArray<z.ZodType<{
|
|
727
730
|
link: string;
|
|
731
|
+
message: string;
|
|
728
732
|
}, z.ZodTypeDef, {
|
|
729
733
|
link: string;
|
|
734
|
+
message: string;
|
|
730
735
|
}>, "many">;
|
|
731
736
|
}, "strip", z.ZodTypeAny, {
|
|
732
737
|
documents: {
|
|
733
738
|
link: string;
|
|
739
|
+
message: string;
|
|
734
740
|
}[];
|
|
735
741
|
metadata?: {
|
|
736
742
|
size: number;
|
|
@@ -741,6 +747,7 @@ export declare const ShareableLinkResponseSchema: z.ZodObject<{
|
|
|
741
747
|
}, {
|
|
742
748
|
documents: {
|
|
743
749
|
link: string;
|
|
750
|
+
message: string;
|
|
744
751
|
}[];
|
|
745
752
|
metadata?: {
|
|
746
753
|
size: number;
|
|
@@ -750,17 +757,21 @@ export declare const ShareableLinkResponseSchema: z.ZodObject<{
|
|
|
750
757
|
} | undefined;
|
|
751
758
|
}>, z.ZodType<{
|
|
752
759
|
link: string;
|
|
760
|
+
message: string;
|
|
753
761
|
}, z.ZodTypeDef, {
|
|
754
762
|
link: string;
|
|
763
|
+
message: string;
|
|
755
764
|
}>]>>;
|
|
756
765
|
}, "strip", z.ZodTypeAny, {
|
|
757
766
|
message: string;
|
|
758
767
|
success: boolean;
|
|
759
768
|
data?: {
|
|
760
769
|
link: string;
|
|
770
|
+
message: string;
|
|
761
771
|
} | {
|
|
762
772
|
documents: {
|
|
763
773
|
link: string;
|
|
774
|
+
message: string;
|
|
764
775
|
}[];
|
|
765
776
|
metadata?: {
|
|
766
777
|
size: number;
|
|
@@ -774,9 +785,11 @@ export declare const ShareableLinkResponseSchema: z.ZodObject<{
|
|
|
774
785
|
success: boolean;
|
|
775
786
|
data?: {
|
|
776
787
|
link: string;
|
|
788
|
+
message: string;
|
|
777
789
|
} | {
|
|
778
790
|
documents: {
|
|
779
791
|
link: string;
|
|
792
|
+
message: string;
|
|
780
793
|
}[];
|
|
781
794
|
metadata?: {
|
|
782
795
|
size: number;
|
|
@@ -787,4 +800,15 @@ export declare const ShareableLinkResponseSchema: z.ZodObject<{
|
|
|
787
800
|
} | undefined;
|
|
788
801
|
}>;
|
|
789
802
|
export type ShareableLinkDTO = DTO<typeof ShareableLinkSchema>;
|
|
803
|
+
export declare const UpdateFcmTokenInputSchema: z.ZodObject<{
|
|
804
|
+
fcmToken: z.ZodString | z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
805
|
+
action: z.ZodNativeEnum<typeof ActionType>;
|
|
806
|
+
}, "strip", z.ZodTypeAny, {
|
|
807
|
+
fcmToken: string;
|
|
808
|
+
action: ActionType;
|
|
809
|
+
}, {
|
|
810
|
+
fcmToken: string;
|
|
811
|
+
action: ActionType;
|
|
812
|
+
}>;
|
|
813
|
+
export type UpdateFcmTokenInputDTO = DTO<typeof UpdateFcmTokenInputSchema>;
|
|
790
814
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ShareableLinkResponseSchema = exports.GetOneQuerySchema = exports.GetByIdInputSchema = exports.IdSchema = exports.DeleteSchema = exports.UpdateSortingOrderSchema = exports.TokenSchema = exports.createResponseSchema = exports.createPaginatedSchema = exports.LoginSchema = exports.WorkHourSettingSchema = exports.HolidayHourSchema = exports.NormalHourSchema = exports.DurationSchema = exports.CourierAddressSchema = exports.RegularOrderAddressSchema = exports.UserAddressSchema = exports.AddressSchema = exports.StringSchema = exports.FilterSchema = void 0;
|
|
3
|
+
exports.UpdateFcmTokenInputSchema = exports.ShareableLinkResponseSchema = exports.GetOneQuerySchema = exports.GetByIdInputSchema = exports.IdSchema = exports.DeleteSchema = exports.UpdateSortingOrderSchema = exports.TokenSchema = exports.createResponseSchema = exports.createPaginatedSchema = exports.LoginSchema = exports.WorkHourSettingSchema = exports.HolidayHourSchema = exports.NormalHourSchema = exports.DurationSchema = exports.CourierAddressSchema = exports.RegularOrderAddressSchema = exports.UserAddressSchema = exports.AddressSchema = exports.StringSchema = exports.FilterSchema = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
const global_validation_1 = require("./global-validation");
|
|
6
6
|
const enum_1 = require("../enum");
|
|
@@ -153,7 +153,12 @@ exports.GetOneQuerySchema = zod_1.z.object({
|
|
|
153
153
|
populate: zod_1.z.union([populateSchema, zod_1.z.array(populateSchema)]).optional(),
|
|
154
154
|
});
|
|
155
155
|
const ShareableLinkSchema = zod_1.z.object({
|
|
156
|
-
link: global_validation_1.ZodValidation.url(),
|
|
156
|
+
link: global_validation_1.ZodValidation.url('Link'),
|
|
157
|
+
message: global_validation_1.ZodValidation.string('Message'),
|
|
157
158
|
});
|
|
158
159
|
exports.ShareableLinkResponseSchema = (0, exports.createResponseSchema)(ShareableLinkSchema);
|
|
160
|
+
exports.UpdateFcmTokenInputSchema = zod_1.z.object({
|
|
161
|
+
fcmToken: global_validation_1.ZodValidation.string('Fcm token'),
|
|
162
|
+
action: global_validation_1.ZodValidation.enumType(enum_1.ActionType, 'Action'),
|
|
163
|
+
});
|
|
159
164
|
//# sourceMappingURL=common-validation.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"common-validation.js","sourceRoot":"/","sources":["utilities/validation/common-validation.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,2DAAyD;AACzD,kCAAkF;AAMlF,MAAM,gBAAgB,GAAmC,OAAC,CAAC,IAAI,CAAC,GAAG,EAAE,CACpE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,KAAK,CAAC,CAAC,OAAC,CAAC,GAAG,EAAE,EAAE,oBAAoB,CAAC,CAAC,CAAC,CAClD,CAAC;AAKF,MAAM,oBAAoB,GAAG,OAAC,CAAC,MAAM,CAAC;IACrC,GAAG,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,QAAQ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KAAK,CAAC,CAAC,OAAC,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,OAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE;IAC9E,QAAQ,EAAE,OAAC,CAAC,KAAK,CAAC,CAAC,cAAc,EAAE,OAAC,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE;CACvE,CAAC,CAAC;AAIH,MAAM,mBAAmB,GAAG,OAAC,CAAC,MAAM,CAAC;IACpC,IAAI,EAAE,iCAAa,CAAC,GAAG,EAAE;CACzB,CAAC,CAAC;AAEU,QAAA,2BAA2B,GAAG,IAAA,4BAAoB,EAAC,mBAAmB,CAAC,CAAC","sourcesContent":["import { z } from 'zod';\nimport { DTO, ZodValidation } from './global-validation';\nimport { GeoLocationType, HolidayWorkStatus, WeekDay, WorkStatus } from '../enum';\nimport { mongoose } from '@typegoose/typegoose';\n\n/**\n * Define MongoDB query schema (fields + operators) using lazy evaluation to avoid circular dependency\n */\nconst MongoQuerySchema: z.ZodType<Record<string, any>> = z.lazy(() =>\n\tz.record(z.union([z.any(), MongoOperatorsSchema]))\n);\n\n/**\n * Define allowed MongoDB query operators\n */\nconst MongoOperatorsSchema = z.object({\n\t$eq: z.any().optional(),\n\t$ne: z.any().optional(),\n\t$gt: z.any().optional(),\n\t$gte: z.any().optional(),\n\t$lt: z.any().optional(),\n\t$lte: z.any().optional(),\n\t$in: z.array(z.any()).optional(),\n\t$nin: z.array(z.any()).optional(),\n\t$exists: z.boolean().optional(),\n\t$regex: z.string().optional(),\n\t$and: z.array(MongoQuerySchema).optional(),\n\t$or: z.array(MongoQuerySchema).optional(),\n\t$not: MongoQuerySchema.optional(),\n\t$nor: z.array(MongoQuerySchema).optional(),\n});\n\nconst sortSchema = z.record(z.string(), z.union([z.literal(1), z.literal(-1)]));\n\nconst populateSchema: z.ZodType<any> = z.lazy(() =>\n\tz.object({\n\t\tpath: z.string(), // required\n\t\tselect: z.record(z.string(), z.union([z.literal(0), z.literal(1)])).optional(),\n\t\tmatch: z.record(z.string(), z.any()).optional(),\n\t\toptions: z\n\t\t\t.object({\n\t\t\t\tsort: sortSchema.optional(),\n\t\t\t\tlimit: z.number().optional(),\n\t\t\t\tskip: z.number().optional(),\n\t\t\t})\n\t\t\t.optional(),\n\t\tpopulate: z.union([populateSchema, z.array(populateSchema)]).optional(),\n\t})\n);\n\n/**\n * Define the filter schema using MongoQuerySchema\n */\nexport const FilterSchema = z\n\t.object({\n\t\tsize: z\n\t\t\t.number()\n\t\t\t.min(1, { message: 'Size must be greater than 0.' })\n\t\t\t.max(100, { message: 'Size cannot exceed 100.' })\n\t\t\t.optional()\n\t\t\t.default(10),\n\t\tpage: z.number().min(1, { message: 'Page number must be at least 1.' }).optional().default(1),\n\t\tsort: sortSchema.optional(),\n\t\tquery: MongoQuerySchema.optional(),\n\t\tselect: z.record(z.string(), z.union([z.literal(0), z.literal(1)])).optional(),\n\t\tpopulate: z.union([populateSchema, z.array(populateSchema)]).optional(),\n\t\tsearch: z.object({ searchKey: z.string(), searchFields: z.array(z.string()).optional() }).optional(),\n\t})\n\t.optional();\n\n/**\n * Infer TypeScript type from Zod schema\n */\nexport type FilterDTO = z.infer<typeof FilterSchema>;\n\n/**\n * Define String schema\n */\nexport const StringSchema = z.string().min(1, 'String cannot be empty').max(255, 'String is too long');\n\n/**\n * Common address validation schema that can be reused across models.\n * Provides validation for address-related fields.\n *\n * @example\n * ```typescript\n * const userSchema = z.object({\n * name: z.string(),\n * address: AddressSchema\n * });\n * ```\n */\nexport const AddressSchema = z.object({\n\taddress: ZodValidation.string('Address'),\n\tdescription: ZodValidation.string('Description').optional(),\n\tcity: ZodValidation.string('City'),\n\tstate: ZodValidation.string('State').optional(),\n\tcountry: ZodValidation.string('Country'),\n\tlocation: z.object({\n\t\ttype: ZodValidation.enumType(GeoLocationType, 'GeoLocationType').default(GeoLocationType.POINT),\n\t\tcoordinates: z.tuple([\n\t\t\tZodValidation.number('Longitude', { min: -180, max: 180 }),\n\t\t\tZodValidation.number('Latitude', { min: -90, max: 90 }),\n\t\t]),\n\t}),\n\tlatitude: ZodValidation.number('Latitude', { min: -90, max: 90 }),\n\tlongitude: ZodValidation.number('Longitude', { min: -180, max: 180 }),\n\tzone: ZodValidation.objectId('Zone').optional(),\n});\nexport type AddressDTO = DTO<typeof AddressSchema>;\n\n/**\n * Common user address validation schema that can be reused across models.\n * Provides validation for address-related fields.\n *\n * @example\n * ```typescript\n * const userSchema = z.object({\n * name: z.string(),\n * address: UserAddressSchema\n * });\n * ```\n */\nexport const UserAddressSchema = AddressSchema.extend({\n\taddressLabel: ZodValidation.string('Address Label'),\n\tapartment: ZodValidation.string('Apartment'),\n\tbuildingName: ZodValidation.string('Building Name'),\n\tdeliveryOption: ZodValidation.string('Delivery Option').optional(),\n\tinstructions: ZodValidation.string('Instructions').optional(),\n});\nexport type UserAddressDTO = DTO<typeof UserAddressSchema>;\n\n/**\n * Regular order address validation schema.\n * Provides validation for address-related fields.\n *\n */\nexport const RegularOrderAddressSchema = UserAddressSchema.extend({\n\t_id: ZodValidation.objectId('ID of the user address'),\n});\nexport type RegularOrderAddressDTO = DTO<typeof RegularOrderAddressSchema>;\n\n/**\n * Common courier address validation schema that can be reused across models.\n * Provides validation for address-related fields.\n *\n * @example\n * ```typescript\n * const courierAddressSchema = z.object({\n * name: z.string(),\n * address: courierAddressSchema\n * });\n * ```\n */\nexport const CourierAddressSchema = UserAddressSchema.extend({\n\tname: ZodValidation.string('Name'),\n\tphoneNumber: ZodValidation.string('Phone Number'),\n});\nexport type CourierAddressDTO = DTO<typeof CourierAddressSchema>;\n\n/**\n * Common duration validation schema that can be reused across models.\n * Provides validation for duration fields.\n *\n * @example\n * ```typescript\n * const subscriptionSchema = z.object({\n * fee: z.number(),\n * duration: DurationSchema\n * });\n * ```\n */\nexport const DurationSchema = z.object({\n\tstart: ZodValidation.date('Start'),\n\tend: ZodValidation.date('End').optional(),\n});\n\n/**\n * Common Work Hour validation schema that can be reused across models.\n * Provides validation for workHourSetting fields.\n *\n * @example\n * ```typescript\n * const settingSchema = z.object({\n * vat: z.number(),\n * workHourSetting: WorkHourSettingSchema\n * });\n * ```\n */\nconst StartEndTimeSchema = z.object({\n\tstart: ZodValidation.string('Start'),\n\tend: ZodValidation.string('End'),\n});\n\nexport const NormalHourSchema = z.object({\n\tday: ZodValidation.enumType(WeekDay, 'Day'),\n\tstatus: ZodValidation.enumType(WorkStatus, 'Status'),\n\topeningHours: ZodValidation.array(StartEndTimeSchema).default([]),\n});\n\nexport const HolidayHourSchema = z.object({\n\tdate: ZodValidation.date('Date'),\n\tstatus: ZodValidation.enumType(HolidayWorkStatus, 'Status'),\n\tclosingHour: StartEndTimeSchema,\n});\n\nexport const WorkHourSettingSchema = z.object({\n\tnormalHours: ZodValidation.array(NormalHourSchema).default([]),\n\tholidayHours: ZodValidation.array(HolidayHourSchema).default([]),\n});\n\n/**\n * Schema for validating user login credentials.\n * This schema ensures that the provided email and password meet the required validation rules.\n *\n * @example\n * ```typescript\n * const credentials = {\n * email: 'user@example.com',\n * password: 'securePassword123',\n * };\n * ```\n */\nexport const LoginSchema = z.object({\n\temail: ZodValidation.email('Email', {\n\t\trequiredMessage: 'Please enter a valid email address.',\n\t\tinvalidMessage: 'Please enter a valid email address.',\n\t}),\n\tpassword: ZodValidation.string('Password', { requiredMessage: 'Please enter password' }),\n});\nexport type LoginDTO = DTO<typeof LoginSchema>;\n\nconst metadataSchema = z.object({\n\tpage: ZodValidation.number(),\n\tsize: ZodValidation.number(),\n\ttotalElements: ZodValidation.number(),\n\ttotalPages: ZodValidation.number(),\n});\nexport const createPaginatedSchema = <T>(documentSchema: z.ZodSchema<T>) =>\n\tz.object({\n\t\tmetadata: metadataSchema.optional(),\n\t\tdocuments: ZodValidation.array(documentSchema),\n\t});\n\nexport const createResponseSchema = <T>(schema: z.ZodSchema<T>) =>\n\tz.object({\n\t\tsuccess: ZodValidation.boolean(),\n\t\tmessage: ZodValidation.string(),\n\t\tdata: z.union([createPaginatedSchema(schema), schema]).optional(),\n\t});\n\nexport type PaginatedDTO<T> = {\n\tmetadata: DTO<typeof metadataSchema>;\n\tdocuments: T[];\n};\n\nexport type ResponseDTO<T> = {\n\tsuccess: boolean;\n\tmessage: string;\n\tdata?: T;\n};\n\n/**\n * Schema for validating token data, typically used for authentication.\n * This schema ensures that the provided access token and refresh token are valid strings.\n *\n * @example\n * ```typescript\n * const tokens = {\n * accessToken: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...',\n * refreshToken: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...',\n * };\n * ```\n */\nexport const TokenSchema = z.object({\n\taccessToken: ZodValidation.string('AccessToken'),\n\trefreshToken: ZodValidation.string('RefreshToken'),\n});\n\n/**\n * Schema validation for sorting order\n */\nexport const UpdateSortingOrderSchema = z.object({\n\t_id: ZodValidation.objectId('_id'),\n\tnewPosition: ZodValidation.number('New position'),\n});\nexport type UpdateSortingOrderDTO = DTO<typeof UpdateSortingOrderSchema>;\n\n/**\n * Schema validation for delete\n */\nexport const DeleteSchema = z.object({\n\t_id: ZodValidation.objectId('_id'),\n\tsoftDelete: ZodValidation.boolean('Soft Delete').default(true),\n});\nexport type DeleteDTO = DTO<typeof DeleteSchema>;\n\n/**\n * Schema validation for Id\n */\nexport const IdSchema = ZodValidation.objectId();\n\n/**\n * Schema validation get by id\n */\nexport const GetByIdInputSchema = z.object({\n\t_id: ZodValidation.objectId('_id'),\n\tselect: z.record(z.string(), z.union([z.literal(0), z.literal(1)])).optional(),\n\tpopulate: z.union([populateSchema, z.array(populateSchema)]).optional(),\n});\nexport type GetByIdInputDTO = DTO<typeof GetByIdInputSchema>;\n\nexport const GetOneQuerySchema = z.object({\n\tquery: MongoQuerySchema.optional(),\n\tselect: z.record(z.string(), z.union([z.literal(0), z.literal(1)])).optional(),\n\tpopulate: z.union([populateSchema, z.array(populateSchema)]).optional(),\n});\n\nexport type GetOneQueryDTO = DTO<typeof GetOneQuerySchema>;\n\nconst ShareableLinkSchema = z.object({\n\tlink: ZodValidation.url(),\n});\n\nexport const ShareableLinkResponseSchema = createResponseSchema(ShareableLinkSchema);\nexport type ShareableLinkDTO = DTO<typeof ShareableLinkSchema>;\n"]}
|
|
1
|
+
{"version":3,"file":"common-validation.js","sourceRoot":"/","sources":["utilities/validation/common-validation.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,2DAAyD;AACzD,kCAA8F;AAM9F,MAAM,gBAAgB,GAAmC,OAAC,CAAC,IAAI,CAAC,GAAG,EAAE,CACpE,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,KAAK,CAAC,CAAC,OAAC,CAAC,GAAG,EAAE,EAAE,oBAAoB,CAAC,CAAC,CAAC,CAClD,CAAC;AAKF,MAAM,oBAAoB,GAAG,OAAC,CAAC,MAAM,CAAC;IACrC,GAAG,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACvB,GAAG,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACvB,GAAG,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACvB,IAAI,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACxB,GAAG,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACvB,IAAI,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACxB,GAAG,EAAE,OAAC,CAAC,KAAK,CAAC,OAAC,CAAC,GAAG,EAAE,CAAC,CAAC,QAAQ,EAAE;IAChC,IAAI,EAAE,OAAC,CAAC,KAAK,CAAC,OAAC,CAAC,GAAG,EAAE,CAAC,CAAC,QAAQ,EAAE;IACjC,OAAO,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IAC/B,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;I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AC,WAAW,CAAC;IAC3C,MAAM,EAAE,iCAAa,CAAC,QAAQ,CAAC,iBAAU,EAAE,QAAQ,CAAC;CACpD,CAAC,CAAC","sourcesContent":["import { z } from 'zod';\nimport { DTO, ZodValidation } from './global-validation';\nimport { ActionType, GeoLocationType, HolidayWorkStatus, WeekDay, WorkStatus } from '../enum';\nimport { mongoose } from '@typegoose/typegoose';\n\n/**\n * Define MongoDB query schema (fields + operators) using lazy evaluation to avoid circular dependency\n */\nconst MongoQuerySchema: z.ZodType<Record<string, any>> = z.lazy(() =>\n\tz.record(z.union([z.any(), MongoOperatorsSchema]))\n);\n\n/**\n * Define allowed MongoDB query operators\n */\nconst MongoOperatorsSchema = z.object({\n\t$eq: z.any().optional(),\n\t$ne: z.any().optional(),\n\t$gt: z.any().optional(),\n\t$gte: z.any().optional(),\n\t$lt: z.any().optional(),\n\t$lte: z.any().optional(),\n\t$in: z.array(z.any()).optional(),\n\t$nin: z.array(z.any()).optional(),\n\t$exists: z.boolean().optional(),\n\t$regex: z.string().optional(),\n\t$and: z.array(MongoQuerySchema).optional(),\n\t$or: z.array(MongoQuerySchema).optional(),\n\t$not: MongoQuerySchema.optional(),\n\t$nor: z.array(MongoQuerySchema).optional(),\n});\n\nconst sortSchema = z.record(z.string(), z.union([z.literal(1), z.literal(-1)]));\n\nconst populateSchema: z.ZodType<any> = z.lazy(() =>\n\tz.object({\n\t\tpath: z.string(), // required\n\t\tselect: z.record(z.string(), z.union([z.literal(0), z.literal(1)])).optional(),\n\t\tmatch: z.record(z.string(), z.any()).optional(),\n\t\toptions: z\n\t\t\t.object({\n\t\t\t\tsort: sortSchema.optional(),\n\t\t\t\tlimit: z.number().optional(),\n\t\t\t\tskip: z.number().optional(),\n\t\t\t})\n\t\t\t.optional(),\n\t\tpopulate: z.union([populateSchema, z.array(populateSchema)]).optional(),\n\t})\n);\n\n/**\n * Define the filter schema using MongoQuerySchema\n */\nexport const FilterSchema = z\n\t.object({\n\t\tsize: z\n\t\t\t.number()\n\t\t\t.min(1, { message: 'Size must be greater than 0.' })\n\t\t\t.max(100, { message: 'Size cannot exceed 100.' })\n\t\t\t.optional()\n\t\t\t.default(10),\n\t\tpage: z.number().min(1, { message: 'Page number must be at least 1.' }).optional().default(1),\n\t\tsort: sortSchema.optional(),\n\t\tquery: MongoQuerySchema.optional(),\n\t\tselect: z.record(z.string(), z.union([z.literal(0), z.literal(1)])).optional(),\n\t\tpopulate: z.union([populateSchema, z.array(populateSchema)]).optional(),\n\t\tsearch: z.object({ searchKey: z.string(), searchFields: z.array(z.string()).optional() }).optional(),\n\t})\n\t.optional();\n\n/**\n * Infer TypeScript type from Zod schema\n */\nexport type FilterDTO = z.infer<typeof FilterSchema>;\n\n/**\n * Define String schema\n */\nexport const StringSchema = z.string().min(1, 'String cannot be empty').max(255, 'String is too long');\n\n/**\n * Common address validation schema that can be reused across models.\n * Provides validation for address-related fields.\n *\n * @example\n * ```typescript\n * const userSchema = z.object({\n * name: z.string(),\n * address: AddressSchema\n * });\n * ```\n */\nexport const AddressSchema = z.object({\n\taddress: ZodValidation.string('Address'),\n\tdescription: ZodValidation.string('Description').optional(),\n\tcity: ZodValidation.string('City'),\n\tstate: ZodValidation.string('State').optional(),\n\tcountry: ZodValidation.string('Country'),\n\tlocation: z.object({\n\t\ttype: ZodValidation.enumType(GeoLocationType, 'GeoLocationType').default(GeoLocationType.POINT),\n\t\tcoordinates: z.tuple([\n\t\t\tZodValidation.number('Longitude', { min: -180, max: 180 }),\n\t\t\tZodValidation.number('Latitude', { min: -90, max: 90 }),\n\t\t]),\n\t}),\n\tlatitude: ZodValidation.number('Latitude', { min: -90, max: 90 }),\n\tlongitude: ZodValidation.number('Longitude', { min: -180, max: 180 }),\n\tzone: ZodValidation.objectId('Zone').optional(),\n});\nexport type AddressDTO = DTO<typeof AddressSchema>;\n\n/**\n * Common user address validation schema that can be reused across models.\n * Provides validation for address-related fields.\n *\n * @example\n * ```typescript\n * const userSchema = z.object({\n * name: z.string(),\n * address: UserAddressSchema\n * });\n * ```\n */\nexport const UserAddressSchema = AddressSchema.extend({\n\taddressLabel: ZodValidation.string('Address Label'),\n\tapartment: ZodValidation.string('Apartment'),\n\tbuildingName: ZodValidation.string('Building Name'),\n\tdeliveryOption: ZodValidation.string('Delivery Option').optional(),\n\tinstructions: ZodValidation.string('Instructions').optional(),\n});\nexport type UserAddressDTO = DTO<typeof UserAddressSchema>;\n\n/**\n * Regular order address validation schema.\n * Provides validation for address-related fields.\n *\n */\nexport const RegularOrderAddressSchema = UserAddressSchema.extend({\n\t_id: ZodValidation.objectId('ID of the user address'),\n});\nexport type RegularOrderAddressDTO = DTO<typeof RegularOrderAddressSchema>;\n\n/**\n * Common courier address validation schema that can be reused across models.\n * Provides validation for address-related fields.\n *\n * @example\n * ```typescript\n * const courierAddressSchema = z.object({\n * name: z.string(),\n * address: courierAddressSchema\n * });\n * ```\n */\nexport const CourierAddressSchema = UserAddressSchema.extend({\n\tname: ZodValidation.string('Name'),\n\tphoneNumber: ZodValidation.string('Phone Number'),\n});\nexport type CourierAddressDTO = DTO<typeof CourierAddressSchema>;\n\n/**\n * Common duration validation schema that can be reused across models.\n * Provides validation for duration fields.\n *\n * @example\n * ```typescript\n * const subscriptionSchema = z.object({\n * fee: z.number(),\n * duration: DurationSchema\n * });\n * ```\n */\nexport const DurationSchema = z.object({\n\tstart: ZodValidation.date('Start'),\n\tend: ZodValidation.date('End').optional(),\n});\n\n/**\n * Common Work Hour validation schema that can be reused across models.\n * Provides validation for workHourSetting fields.\n *\n * @example\n * ```typescript\n * const settingSchema = z.object({\n * vat: z.number(),\n * workHourSetting: WorkHourSettingSchema\n * });\n * ```\n */\nconst StartEndTimeSchema = z.object({\n\tstart: ZodValidation.string('Start'),\n\tend: ZodValidation.string('End'),\n});\n\nexport const NormalHourSchema = z.object({\n\tday: ZodValidation.enumType(WeekDay, 'Day'),\n\tstatus: ZodValidation.enumType(WorkStatus, 'Status'),\n\topeningHours: ZodValidation.array(StartEndTimeSchema).default([]),\n});\n\nexport const HolidayHourSchema = z.object({\n\tdate: ZodValidation.date('Date'),\n\tstatus: ZodValidation.enumType(HolidayWorkStatus, 'Status'),\n\tclosingHour: StartEndTimeSchema,\n});\n\nexport const WorkHourSettingSchema = z.object({\n\tnormalHours: ZodValidation.array(NormalHourSchema).default([]),\n\tholidayHours: ZodValidation.array(HolidayHourSchema).default([]),\n});\n\n/**\n * Schema for validating user login credentials.\n * This schema ensures that the provided email and password meet the required validation rules.\n *\n * @example\n * ```typescript\n * const credentials = {\n * email: 'user@example.com',\n * password: 'securePassword123',\n * };\n * ```\n */\nexport const LoginSchema = z.object({\n\temail: ZodValidation.email('Email', {\n\t\trequiredMessage: 'Please enter a valid email address.',\n\t\tinvalidMessage: 'Please enter a valid email address.',\n\t}),\n\tpassword: ZodValidation.string('Password', { requiredMessage: 'Please enter password' }),\n});\nexport type LoginDTO = DTO<typeof LoginSchema>;\n\nconst metadataSchema = z.object({\n\tpage: ZodValidation.number(),\n\tsize: ZodValidation.number(),\n\ttotalElements: ZodValidation.number(),\n\ttotalPages: ZodValidation.number(),\n});\nexport const createPaginatedSchema = <T>(documentSchema: z.ZodSchema<T>) =>\n\tz.object({\n\t\tmetadata: metadataSchema.optional(),\n\t\tdocuments: ZodValidation.array(documentSchema),\n\t});\n\nexport const createResponseSchema = <T>(schema: z.ZodSchema<T>) =>\n\tz.object({\n\t\tsuccess: ZodValidation.boolean(),\n\t\tmessage: ZodValidation.string(),\n\t\tdata: z.union([createPaginatedSchema(schema), schema]).optional(),\n\t});\n\nexport type PaginatedDTO<T> = {\n\tmetadata: DTO<typeof metadataSchema>;\n\tdocuments: T[];\n};\n\nexport type ResponseDTO<T> = {\n\tsuccess: boolean;\n\tmessage: string;\n\tdata?: T;\n};\n\n/**\n * Schema for validating token data, typically used for authentication.\n * This schema ensures that the provided access token and refresh token are valid strings.\n *\n * @example\n * ```typescript\n * const tokens = {\n * accessToken: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...',\n * refreshToken: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...',\n * };\n * ```\n */\nexport const TokenSchema = z.object({\n\taccessToken: ZodValidation.string('AccessToken'),\n\trefreshToken: ZodValidation.string('RefreshToken'),\n});\n\n/**\n * Schema validation for sorting order\n */\nexport const UpdateSortingOrderSchema = z.object({\n\t_id: ZodValidation.objectId('_id'),\n\tnewPosition: ZodValidation.number('New position'),\n});\nexport type UpdateSortingOrderDTO = DTO<typeof UpdateSortingOrderSchema>;\n\n/**\n * Schema validation for delete\n */\nexport const DeleteSchema = z.object({\n\t_id: ZodValidation.objectId('_id'),\n\tsoftDelete: ZodValidation.boolean('Soft Delete').default(true),\n});\nexport type DeleteDTO = DTO<typeof DeleteSchema>;\n\n/**\n * Schema validation for Id\n */\nexport const IdSchema = ZodValidation.objectId();\n\n/**\n * Schema validation get by id\n */\nexport const GetByIdInputSchema = z.object({\n\t_id: ZodValidation.objectId('_id'),\n\tselect: z.record(z.string(), z.union([z.literal(0), z.literal(1)])).optional(),\n\tpopulate: z.union([populateSchema, z.array(populateSchema)]).optional(),\n});\nexport type GetByIdInputDTO = DTO<typeof GetByIdInputSchema>;\n\nexport const GetOneQuerySchema = z.object({\n\tquery: MongoQuerySchema.optional(),\n\tselect: z.record(z.string(), z.union([z.literal(0), z.literal(1)])).optional(),\n\tpopulate: z.union([populateSchema, z.array(populateSchema)]).optional(),\n});\n\nexport type GetOneQueryDTO = DTO<typeof GetOneQuerySchema>;\n\nconst ShareableLinkSchema = z.object({\n\tlink: ZodValidation.url('Link'),\n\tmessage: ZodValidation.string('Message'),\n});\n\nexport const ShareableLinkResponseSchema = createResponseSchema(ShareableLinkSchema);\nexport type ShareableLinkDTO = DTO<typeof ShareableLinkSchema>;\n\nexport const UpdateFcmTokenInputSchema = z.object({\n\tfcmToken: ZodValidation.string('Fcm token'),\n\taction: ZodValidation.enumType(ActionType, 'Action'),\n});\nexport type UpdateFcmTokenInputDTO = DTO<typeof UpdateFcmTokenInputSchema>;\n"]}
|
|
@@ -48,6 +48,20 @@ export declare class ZodValidation {
|
|
|
48
48
|
updatedBy: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
49
49
|
deletedBy: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, mongoose.Types.ObjectId, string>, z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>]>>;
|
|
50
50
|
};
|
|
51
|
+
static coerce: {
|
|
52
|
+
number: (field?: string, options?: {
|
|
53
|
+
min?: number;
|
|
54
|
+
max?: number;
|
|
55
|
+
isInt?: boolean;
|
|
56
|
+
isPositive?: boolean;
|
|
57
|
+
isNonpositive?: boolean;
|
|
58
|
+
isNegative?: boolean;
|
|
59
|
+
isNonnegative?: boolean;
|
|
60
|
+
}) => z.ZodNumber;
|
|
61
|
+
date: (field?: string, minDate?: Date, maxDate?: Date) => z.ZodEffects<z.ZodEffects<z.ZodDate, Date, Date>, Date, Date>;
|
|
62
|
+
boolean: (field?: string) => z.ZodBoolean;
|
|
63
|
+
objectId: (field?: string) => z.ZodEffects<z.ZodType<mongoose.Types.ObjectId, z.ZodTypeDef, mongoose.Types.ObjectId>, mongoose.Types.ObjectId, mongoose.Types.ObjectId>;
|
|
64
|
+
};
|
|
51
65
|
}
|
|
52
66
|
export type ExcludeFromUpdate = {
|
|
53
67
|
createdAt?: true;
|
|
@@ -6,7 +6,7 @@ const zod_1 = require("zod");
|
|
|
6
6
|
const typegoose_1 = require("@typegoose/typegoose");
|
|
7
7
|
const libphonenumber_js_1 = require("libphonenumber-js");
|
|
8
8
|
class ZodValidation {
|
|
9
|
-
static objectIdOrStringSchema = zod_1.z.custom(
|
|
9
|
+
static objectIdOrStringSchema = zod_1.z.custom(val => {
|
|
10
10
|
if (typeof val === 'string' && /^[0-9a-fA-F]{24}$/.test(val))
|
|
11
11
|
return true;
|
|
12
12
|
if (typeof val === 'object' && val instanceof typegoose_1.mongoose.Types.ObjectId)
|
|
@@ -109,11 +109,9 @@ class ZodValidation {
|
|
|
109
109
|
message: `Please input a valid phone number`,
|
|
110
110
|
});
|
|
111
111
|
}
|
|
112
|
-
static validPhoneNumber(field =
|
|
113
|
-
return zod_1.z
|
|
114
|
-
.
|
|
115
|
-
.superRefine((phoneWithCountryCode, ctx) => {
|
|
116
|
-
const phoneWithoutCountryCode = phoneWithCountryCode.replace(/^\+\d{1,3}/, "");
|
|
112
|
+
static validPhoneNumber(field = 'Field') {
|
|
113
|
+
return zod_1.z.string({ required_error: `${field} is required` }).superRefine((phoneWithCountryCode, ctx) => {
|
|
114
|
+
const phoneWithoutCountryCode = phoneWithCountryCode.replace(/^\+\d{1,3}/, '');
|
|
117
115
|
if (phoneWithoutCountryCode.length < 4) {
|
|
118
116
|
ctx.addIssue({
|
|
119
117
|
code: zod_1.z.ZodIssueCode.custom,
|
|
@@ -193,6 +191,59 @@ class ZodValidation {
|
|
|
193
191
|
...ZodValidation.timestamps(),
|
|
194
192
|
};
|
|
195
193
|
}
|
|
194
|
+
static coerce = {
|
|
195
|
+
number: (field = 'Field', options) => {
|
|
196
|
+
let schema = zod_1.z.coerce.number({
|
|
197
|
+
required_error: `${field} is required`,
|
|
198
|
+
invalid_type_error: `${field} must be a number`,
|
|
199
|
+
});
|
|
200
|
+
if (options?.min !== undefined) {
|
|
201
|
+
schema = schema.gte(options.min, { message: `${field} must be at least ${options.min}` });
|
|
202
|
+
}
|
|
203
|
+
if (options?.max !== undefined) {
|
|
204
|
+
schema = schema.lte(options.max, { message: `${field} must be at most ${options.max}` });
|
|
205
|
+
}
|
|
206
|
+
if (options?.isInt)
|
|
207
|
+
schema = schema.int({ message: `${field} must be an integer` });
|
|
208
|
+
if (options?.isPositive)
|
|
209
|
+
schema = schema.positive({ message: `${field} must be positive` });
|
|
210
|
+
if (options?.isNonpositive)
|
|
211
|
+
schema = schema.nonpositive({ message: `${field} must be non-positive` });
|
|
212
|
+
if (options?.isNegative)
|
|
213
|
+
schema = schema.negative({ message: `${field} must be negative` });
|
|
214
|
+
if (options?.isNonnegative)
|
|
215
|
+
schema = schema.nonnegative({ message: `${field} must be non-negative` });
|
|
216
|
+
return schema;
|
|
217
|
+
},
|
|
218
|
+
date: (field = 'Field', minDate, maxDate) => {
|
|
219
|
+
return zod_1.z.coerce
|
|
220
|
+
.date({
|
|
221
|
+
required_error: `${field} is required`,
|
|
222
|
+
invalid_type_error: `${field} must be a valid date`,
|
|
223
|
+
})
|
|
224
|
+
.refine(val => minDate === undefined || val >= minDate, {
|
|
225
|
+
message: `${field} must be on or after ${minDate?.toISOString()}`,
|
|
226
|
+
})
|
|
227
|
+
.refine(val => maxDate === undefined || val <= maxDate, {
|
|
228
|
+
message: `${field} must be on or before ${maxDate?.toISOString()}`,
|
|
229
|
+
});
|
|
230
|
+
},
|
|
231
|
+
boolean: (field = 'Field') => {
|
|
232
|
+
return zod_1.z.coerce.boolean({
|
|
233
|
+
required_error: `${field} is required`,
|
|
234
|
+
invalid_type_error: `${field} must be true or false`,
|
|
235
|
+
});
|
|
236
|
+
},
|
|
237
|
+
objectId: (field = 'Field') => zod_1.z
|
|
238
|
+
.custom(val => {
|
|
239
|
+
if (typeof val === 'string' && typegoose_1.mongoose.Types.ObjectId.isValid(val))
|
|
240
|
+
return true;
|
|
241
|
+
if (val instanceof typegoose_1.mongoose.Types.ObjectId)
|
|
242
|
+
return true;
|
|
243
|
+
return false;
|
|
244
|
+
}, { message: `${field} must be a valid ObjectId` })
|
|
245
|
+
.transform(val => (typeof val === 'string' ? new typegoose_1.mongoose.Types.ObjectId(val) : val)),
|
|
246
|
+
};
|
|
196
247
|
}
|
|
197
248
|
exports.ZodValidation = ZodValidation;
|
|
198
249
|
class SchemaBuilder {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"global-validation.js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UAAa,EACb,oBAA6B,IAAI,EACjC,kBAA2B,KAAK;IAEhC,OAAO,IAAI,aAAa,CAAC,UAAU,EAAE,iBAAiB,EAAE,eAAe,CAAC,CAAC;AAC1E,CAAC","sourcesContent":["import { z } from 'zod';\nimport { mongoose } from '@typegoose/typegoose';\nimport { parsePhoneNumberFromString } from 'libphonenumber-js';\n\n/**\n * Enhanced validation utilities for creating robust Zod schemas.\n * This class provides a collection of static methods to create common validation patterns.\n *\n * @example\n * ```typescript\n * const userSchema = z.object({\n * username: ZodValidation.requiredString(\"Username is required\"),\n * email: ZodValidation.email(),\n * role: ZodValidation.enumType(UserRole)\n * });\n * ```\n */\nexport class ZodValidation {\n\t/**\n\t * Creates a union type that accepts both string ObjectId and mongoose ObjectId instance.\n\t * This is useful when dealing with both raw string IDs and Mongoose ObjectId instances.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod union schema that accepts both string and ObjectId\n\t *\n\t * @example\n\t * ```typescript\n\t * const idSchema = ZodValidation.objectIdUnion();\n\t * // Accepts \"507f1f77bcf86cd799439011\" or new mongoose.Types.ObjectId(\"507f1f77bcf86cd799439011\")\n\t * ```\n\t */\n\tstatic objectIdOrStringSchema = z.custom<mongoose.Types.ObjectId | string>(\n\t\t(val) => {\n\t\t\tif (typeof val === 'string' && /^[0-9a-fA-F]{24}$/.test(val)) return true;\n\t\t\tif (typeof val === 'object' && val instanceof mongoose.Types.ObjectId) return true;\n\t\t\treturn false;\n\t\t},\n\t\t{ message: 'Invalid ObjectId' }\n\t);\n\n\tstatic objectId(field: string = 'Field') {\n\t\treturn z.union(\n\t\t\t[\n\t\t\t\tz\n\t\t\t\t\t.string({ required_error: `${field} is required` })\n\t\t\t\t\t.refine(val => mongoose.Types.ObjectId.isValid(val), {\n\t\t\t\t\t\tmessage: `${field} must be a valid ObjectID`,\n\t\t\t\t\t})\n\t\t\t\t\t.transform(val => new mongoose.Types.ObjectId(val)),\n\t\t\t\tz.instanceof(mongoose.Types.ObjectId, {\n\t\t\t\t\tmessage: `${field} must be a valid ObjectID`,\n\t\t\t\t}),\n\t\t\t],\n\t\t\t{ message: `${field} is required` }\n\t\t);\n\t}\n\n\t/**\n\t * Creates an enum validation with custom error message.\n\t * This validates that a value is one of the values defined in the enum.\n\t *\n\t * @template T - Type of the enum\n\t * @param enumObj - The enum object to validate against\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates against the provided enum\n\t *\n\t * @example\n\t * ```typescript\n\t * enum UserRole { ADMIN = \"admin\", USER = \"user\" }\n\t * const roleSchema = ZodValidation.enumType(UserRole, \"Invalid user role\");\n\t * ```\n\t */\n\tstatic enumType<T extends z.EnumLike>(enumObj: T, field: string = 'Field') {\n\t\treturn z.nativeEnum(enumObj, {\n\t\t\tmessage: `${field} must be one of: ${Object.values(enumObj).join(', ')}`,\n\t\t});\n\t}\n\n\t/**\n\t * Creates a required number validation with a minimum length.\n\t * The number is also trimmed to remove leading/trailing whitespace.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @param min - Minimum number (optional)\n\t * @param max - MAximum number (optional)\n\t * @param options - options (optional)\n\t * @returns A Zod schema that validates numbers with minimum length\n\t *\n\t * @example\n\t * ```typescript\n\t * const nameSchema = ZodValidation.Number(\"Price\");\n\t * ```\n\t */\n\tstatic number(\n\t\tfield: string = 'Field',\n\t\toptions?: {\n\t\t\tmin?: number;\n\t\t\tmax?: number;\n\t\t\tisInt?: boolean;\n\t\t\tisPositive?: boolean;\n\t\t\tisNonpositive?: boolean;\n\t\t\tisNegative?: boolean;\n\t\t\tisNonnegative?: boolean;\n\t\t}\n\t) {\n\t\tlet schema = z.number({\n\t\t\trequired_error: `${field} is required`,\n\t\t\tinvalid_type_error: `${field} must be a number`,\n\t\t});\n\n\t\t// Range validation\n\t\tif (options?.min !== undefined) {\n\t\t\tschema = schema.gte(options?.min, {\n\t\t\t\tmessage: `${field} must be at least ${options?.min}`,\n\t\t\t});\n\t\t}\n\t\tif (options?.max !== undefined) {\n\t\t\tschema = schema.lte(options?.max, {\n\t\t\t\tmessage: `${field} must be at most ${options?.max}`,\n\t\t\t});\n\t\t}\n\n\t\t// Option validation\n\t\tif (options?.isInt) {\n\t\t\tschema = schema.int({ message: `${field} must be an integer` });\n\t\t}\n\t\tif (options?.isPositive) {\n\t\t\tschema = schema.positive({ message: `${field} must be positive` });\n\t\t}\n\t\tif (options?.isNonpositive) {\n\t\t\tschema = schema.nonpositive({ message: `${field} must be non-positive` });\n\t\t}\n\t\tif (options?.isNegative) {\n\t\t\tschema = schema.negative({ message: `${field} must be negative` });\n\t\t}\n\t\tif (options?.isNonnegative) {\n\t\t\tschema = schema.nonnegative({ message: `${field} must be non-negative` });\n\t\t}\n\n\t\treturn schema;\n\t}\n\n\t/**\n\t * Creates a required string validation with a minimum length.\n\t * The string is also trimmed to remove leading/trailing whitespace.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @param minLength - Minimum required length (optional)\n\t * @param maxLength - Maximum required length (optional)\n\t * @param regex - Regular expression (optional)\n\t * @returns A Zod schema that validates strings with minimum length\n\t *\n\t * @example\n\t * ```typescript\n\t * const nameSchema = ZodValidation.String(\"Name\");\n\t * ```\n\t */\n\tstatic string(\n\t\tfield: string = 'Field',\n\t\toptions?: {\n\t\t\tminLength?: number;\n\t\t\tmaxLength?: number;\n\t\t\tminMessage?: string;\n\t\t\tmaxMessage?: string;\n\t\t\trequiredMessage?: string;\n\t\t\tregex?: { pattern: RegExp; message: string }; // Add regex option\n\t\t\tisTrimmed?: boolean;\n\t\t}\n\t) {\n\t\tlet schema = z.string({\n\t\t\trequired_error: options?.requiredMessage || `${field} is required`,\n\t\t});\n\n\t\tif (options?.minLength) {\n\t\t\tschema = schema.min(\n\t\t\t\toptions.minLength,\n\t\t\t\toptions.minMessage || `${field} must be at least ${options.minLength} characters`\n\t\t\t);\n\t\t}\n\n\t\tif (options?.maxLength) {\n\t\t\tschema = schema.max(\n\t\t\t\toptions.maxLength,\n\t\t\t\toptions.maxMessage || `${field} shouldn’t exceed ${options.maxLength} characters`\n\t\t\t);\n\t\t}\n\n\t\t// Check for regex pattern and add regex validation\n\t\tif (options?.regex) {\n\t\t\tschema = schema.regex(options.regex.pattern, options.regex.message);\n\t\t}\n\n\t\tif (options?.isTrimmed) {\n\t\t\treturn schema\n\t\t\t\t.transform(val => val?.trim())\n\t\t\t\t.refine(val => val?.length && val?.length > 0, {\n\t\t\t\t\tmessage: options?.requiredMessage || `${field} is required`,\n\t\t\t\t});\n\t\t}\n\n\t\treturn schema;\n\t}\n\n\t/**\n\t * Creates an email validation.\n\t * Validates that the string is a valid email address format.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates email addresses\n\t *\n\t * @example\n\t * ```typescript\n\t * const emailSchema = ZodValidation.email(\"Please enter a valid email\");\n\t * ```\n\t */\n\tstatic email(\n\t\tfield: string = 'Email',\n\t\toptions?: {\n\t\t\trequiredMessage?: string;\n\t\t\tinvalidMessage?: string;\n\t\t}\n\t) {\n\t\tconst schema = z\n\t\t\t.string({\n\t\t\t\trequired_error: options?.requiredMessage || `${field} is required`,\n\t\t\t})\n\t\t\t.email(options?.invalidMessage || `${field} must be a valid email address`);\n\n\t\treturn schema;\n\t}\n\n\t/**\n\t * Creates a URL validation.\n\t * Validates that the string is a valid URL format.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates URLs\n\t *\n\t * @example\n\t * ```typescript\n\t * const websiteSchema = ZodValidation.url(\"Please enter a valid URL\");\n\t * ```\n\t */\n\tstatic url(field: string = 'Field') {\n\t\treturn z.string({ required_error: `${field} is required` }).url(`${field} must be a valid URL`);\n\t}\n\n\t/**\n\t * Creates a phone number validation schema using a regex pattern for global phone numbers.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates phone numbers\n\t *\n\t * @example\n\t * ```typescript\n\t * const phoneSchema = ZodValidation.phoneNumber(\"Phone number\");\n\t * ```\n\t */\n\n\tstatic phoneNumber(field: string = 'Field') {\n\t\treturn z.string({ required_error: `${field} is required` }).refine(\n\t\t\tvalue => {\n\t\t\t\ttry {\n\t\t\t\t\tconst phone = parsePhoneNumberFromString(value);\n\t\t\t\t\treturn phone?.isValid();\n\t\t\t\t} catch {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t},\n\t\t\t{\n\t\t\t\tmessage: `Please input a valid phone number`,\n\t\t\t}\n\t\t);\n\t}\n\n\tstatic validPhoneNumber(field: string = \"Field\") {\n\t\treturn z\n\t\t\t.string({ required_error: `${field} is required` })\n\t\t\t.superRefine((phoneWithCountryCode, ctx) => {\n\t\t\t\tconst phoneWithoutCountryCode = phoneWithCountryCode.replace(/^\\+\\d{1,3}/, \"\");\n\t\t\t\tif (phoneWithoutCountryCode.length < 4) {\n\t\t\t\t\tctx.addIssue({\n\t\t\t\t\t\tcode: z.ZodIssueCode.custom,\n\t\t\t\t\t\tmessage: `${field} must have 4 or more digits`,\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tif (/^\\d{4}$|^\\d{5}$|^\\d{7}$|^\\d{8}$/.test(phoneWithoutCountryCode)) {\n\t\t\t\t\treturn; // ✅ Accept 4,5,7 or 8 digit short numbers\n\t\t\t\t}\n\t\t\t\t// Otherwise, parse as real phone number\n\t\t\t\tconst phone = parsePhoneNumberFromString(phoneWithCountryCode);\n\t\t\t\tif (!phone) {\n\t\t\t\t\tctx.addIssue({\n\t\t\t\t\t\tcode: z.ZodIssueCode.custom,\n\t\t\t\t\t\tmessage: `Invalid phone number format in ${field}`,\n\t\t\t\t\t});\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tif (!phone.isValid()) {\n\t\t\t\t\tctx.addIssue({\n\t\t\t\t\t\tcode: z.ZodIssueCode.custom,\n\t\t\t\t\t\tmessage: `Please input a valid phone number in ${field}`,\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t});\n\t}\n\n\t/**\n\t * Creates a date validation.\n\t * Validates that the input is a JavaScript Date object.\n\t *@param field - The name of the field to be included in the error message\n\t *@param minDate - Minimum required date (optional)\n\t *@param maxDate - Maximum required date (optional)\n\t * @returns A Zod schema that validates Date objects\n\t *\n\t * @example\n\t * ```typescript\n\t * const createdAtSchema = ZodValidation.date();\n\t * ```\n\t */\n\tstatic date(field: string = 'Field', minDate?: Date, maxDate?: Date) {\n\t\treturn z\n\t\t\t.union(\n\t\t\t\t[\n\t\t\t\t\tz\n\t\t\t\t\t\t.string({ required_error: `${field} is required` })\n\t\t\t\t\t\t.refine(val => {\n\t\t\t\t\t\t\tconst date = new Date(val);\n\t\t\t\t\t\t\treturn !isNaN(date.getTime());\n\t\t\t\t\t\t}, `${field} must be a valid date`)\n\t\t\t\t\t\t.transform(val => new Date(val)),\n\t\t\t\t\tz.date({\n\t\t\t\t\t\trequired_error: `${field} is required`,\n\t\t\t\t\t\tinvalid_type_error: `${field} must be a valid date`,\n\t\t\t\t\t}),\n\t\t\t\t],\n\t\t\t\t{ message: `${field} is required` }\n\t\t\t)\n\t\t\t.refine(\n\t\t\t\tval => minDate === undefined || val >= minDate,\n\t\t\t\t`${field} must be on or after ${minDate?.toISOString()}`\n\t\t\t)\n\t\t\t.refine(\n\t\t\t\tval => maxDate === undefined || val <= maxDate,\n\t\t\t\t`${field} must be on or before ${maxDate?.toISOString()}`\n\t\t\t);\n\t}\n\n\t/**\n\t * Creates a boolean validation with an optional default value.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates booleans\n\t *\n\t * @example\n\t * ```typescript\n\t * const isActiveSchema = ZodValidation.boolean(true); // Defaults to true\n\t * ```\n\t */\n\tstatic boolean(field: string = 'Field') {\n\t\treturn z.boolean({\n\t\t\trequired_error: `${field} is required`,\n\t\t\tinvalid_type_error: `${field} must be a boolean`,\n\t\t});\n\t}\n\n\t/**\n\t * Creates an array validation with optional minimum items constraint.\n\t *\n\t * @template T - Type of the schema for array items\n\t * @param schema - The schema for validating array items\n\t * @param field - The name of the field to be included in the error message\n\t * @param minItems - Minimum number of items required (optional)\n\t * @param maxItems - Maximum number of items required (optional)\n\t * @returns A Zod schema that validates arrays\n\t *\n\t * @example\n\t * ```typescript\n\t * const tagsSchema = ZodValidation.array(z.string(), \"At least one tag required\", 1);\n\t * ```\n\t */\n\tstatic array<T extends z.ZodTypeAny>(\n\t\tschema: T,\n\t\tfield: string = 'Array',\n\t\tminItems?: number,\n\t\tmaxItems?: number\n\t) {\n\t\tlet arraySchema = z.array(schema, {\n\t\t\trequired_error: `${field} is required`,\n\t\t});\n\n\t\tif (minItems === 1) {\n\t\t\tarraySchema = arraySchema.min(1, `${field} cannot be empty`);\n\t\t}\n\t\tif (minItems !== undefined && minItems !== 1) {\n\t\t\tarraySchema = arraySchema.min(minItems, `${field} must have at least ${minItems} items`);\n\t\t}\n\t\tif (maxItems !== undefined) {\n\t\t\tarraySchema = arraySchema.max(maxItems, `${field} must have at most ${maxItems} items`);\n\t\t}\n\n\t\treturn arraySchema;\n\t}\n\n\t/**\n\t * Standard timestamp fields for entities.\n\t * Includes createdAt, updatedAt, and deletedAt fields.\n\t *\n\t * @returns An object containing timestamp field schemas\n\t *\n\t * @example\n\t * ```typescript\n\t * const userSchema = z.object({\n\t * name: z.string(),\n\t * ...ZodValidation.timestamps()\n\t * });\n\t * ```\n\t */\n\tstatic timestamps() {\n\t\treturn {\n\t\t\tcreatedAt: z.date().nullable().optional(),\n\t\t\tupdatedAt: z.date().nullable().optional(),\n\t\t\tdeletedAt: z.date().nullable().optional(),\n\t\t};\n\t}\n\n\t/**\n\t * Common fields for tracking model metadata.\n\t * Includes timestamps and user tracking fields (createdBy, updatedBy, deletedBy).\n\t *\n\t * @returns An object containing tracking field schemas\n\t *\n\t * @example\n\t * ```typescript\n\t * const postSchema = z.object({\n\t * title: z.string(),\n\t * content: z.string(),\n\t * ...ZodValidation.trackingFields()\n\t * });\n\t * ```\n\t */\n\tstatic trackingFields() {\n\t\treturn {\n\t\t\tcreatedBy: ZodValidation.objectId().optional(),\n\t\t\tupdatedBy: ZodValidation.objectId().optional(),\n\t\t\tdeletedBy: ZodValidation.objectId().optional(),\n\t\t\t...ZodValidation.timestamps(),\n\t\t};\n\t}\n}\n\n/**\n * Represents the common fields to exclude from update operations.\n * This is used to specify which fields should not be updateable.\n *\n * @example\n * ```typescript\n * const excludeFields: ExcludeFromUpdate = {\n * createdAt: true,\n * createdBy: true,\n * status: true // Prevent status from being updated\n * };\n * ```\n */\nexport type ExcludeFromUpdate = {\n\tcreatedAt?: true;\n\tupdatedAt?: true;\n\tdeletedAt?: true;\n\tcreatedBy?: true;\n\t_id?: true;\n} & Record<string, true>;\n\n/**\n * Schema builder for creating consistent CRUD schemas.\n * Provides utility methods to generate schemas for create, read, update, and delete operations.\n *\n * @template T - Type of the base schema shape\n *\n * @example\n * ```typescript\n * const userBuilder = new SchemaBuilder({\n * name: z.string(),\n * email: z.string().email()\n * });\n *\n * const schemas = userBuilder.getAllSchemas();\n * ```\n */\nexport class SchemaBuilder<T extends z.ZodRawShape> {\n\tprivate baseSchema: z.ZodObject<T>;\n\n\t/**\n\t * Create a new schema builder\n\t *\n\t * @param baseFields - The base fields for the schema\n\t * @param includeTimestamps - Whether to include timestamp fields (default: true)\n\t * @param includeTracking - Whether to include tracking fields (createdBy, etc.) (default: false)\n\t *\n\t * @example\n\t * ```typescript\n\t * const userFields = {\n\t * name: ZodValidation.requiredString(),\n\t * email: ZodValidation.email()\n\t * };\n\t *\n\t * // With timestamps\n\t * const builder1 = new SchemaBuilder(userFields);\n\t *\n\t * // Without timestamps\n\t * const builder2 = new SchemaBuilder(userFields, false);\n\t *\n\t * // With tracking fields\n\t * const builder3 = new SchemaBuilder(userFields, true, true);\n\t * ```\n\t */\n\tconstructor(\n\t\tbaseFields: T,\n\t\tprivate includeTimestamps: boolean = true,\n\t\tprivate includeTracking: boolean = false\n\t) {\n\t\tthis.baseSchema = this.createBaseSchema(baseFields);\n\t}\n\n\t/**\n\t * Creates the base schema with optional timestamps and tracking fields.\n\t */\n\tprivate createBaseSchema(baseFields: T) {\n\t\tconst additionalFields = this.includeTracking\n\t\t\t? ZodValidation.trackingFields()\n\t\t\t: this.includeTimestamps\n\t\t\t\t? ZodValidation.timestamps()\n\t\t\t\t: {};\n\n\t\treturn z.object({\n\t\t\t...baseFields,\n\t\t\t...additionalFields,\n\t\t});\n\t}\n\n\t/**\n\t * Gets the base validation schema without ID.\n\t * Used for creating new entities.\n\t *\n\t * @returns The base schema for creating new entities\n\t *\n\t * @example\n\t * ```typescript\n\t * const createUserSchema = userBuilder.getBaseSchema();\n\t * ```\n\t */\n\tgetBaseSchema() {\n\t\treturn this.baseSchema.strict();\n\t}\n\n\t/**\n\t * Gets the schema for entities with ID.\n\t * Used for representing complete entities with their ID.\n\t *\n\t * @returns The entity schema including ID\n\t *\n\t * @example\n\t * ```typescript\n\t * const userSchema = userBuilder.getEntitySchema();\n\t * ```\n\t */\n\tgetEntitySchema() {\n\t\treturn this.baseSchema\n\t\t\t.extend({\n\t\t\t\t_id: ZodValidation.objectId(),\n\t\t\t})\n\t\t\t.partial()\n\t\t\t.passthrough();\n\t}\n\n\t/**\n\t * Gets the schema for validating an entity ID.\n\t * Used for validating ID parameters in requests.\n\t *\n\t * @returns The ID validation schema\n\t *\n\t * @example\n\t * ```typescript\n\t * const userIdSchema = userBuilder.getIdSchema();\n\t * ```\n\t */\n\tgetIdSchema() {\n\t\treturn ZodValidation.objectId();\n\t}\n\n\t/**\n\t * Gets the schema for updating an entity, excluding specified fields.\n\t * Creates a partial schema where all fields are optional, and removes\n\t * fields that should not be updatable.\n\t *\n\t * @param excludeFields - Fields to exclude from update operations\n\t * @returns The update schema with excluded fields removed\n\t *\n\t * @example\n\t * ```typescript\n\t * // Prevent updating createdAt and status\n\t * const updateUserSchema = userBuilder.getUpdateSchema({\n\t * createdAt: true,\n\t * status: true\n\t * });\n\t * ```\n\t */\n\tgetUpdateSchema(excludeFields: ExcludeFromUpdate = { createdAt: true, updatedAt: true }) {\n\t\tconst entitySchema = this.getEntitySchema();\n\n\t\t// Simple approach - just make everything optional\n\t\tif (Object.keys(excludeFields).length === 0) {\n\t\t\treturn entitySchema;\n\t\t}\n\n\t\t// For the type-safe approach, we need to create a new schema\n\t\t// without the excluded fields and then make it partial\n\n\t\t// Get all fields from the entity schema\n\t\tconst shape = entitySchema._def.shape();\n\n\t\t// Filter out the fields we want to exclude\n\t\tconst filteredShape: z.ZodRawShape = {};\n\t\tfor (const key in shape) {\n\t\t\tif (!excludeFields[key as keyof typeof excludeFields]) {\n\t\t\t\tfilteredShape[key] = shape[key];\n\t\t\t}\n\t\t}\n\n\t\t// Create a new schema with the filtered fields\n\t\treturn z.object(filteredShape).partial().strict();\n\t}\n\n\t/**\n\t * Gets the schema for validating a delete request.\n\t * Used for validating parameters in delete requests, including the entity ID and soft delete flag.\n\t *\n\t * @returns The delete validation schema\n\t *\n\t * @example\n\t * ```typescript\n\t * const deleteSchema = userBuilder.getDeleteSchema();\n\t * ```\n\t */\n\tgetDeleteSchema() {\n\t\treturn z.object({\n\t\t\t_id: ZodValidation.objectId('_id'),\n\t\t\tsoftDelete: ZodValidation.boolean('Soft Delete').default(true),\n\t\t});\n\t}\n\n\t/**\n\t * Creates an update schema by optionally extending the base schema with additional fields\n\t * and optionally omitting specified fields.\n\t *\n\t * @param extendFields - Optional fields to add to the schema (e.g., `_id`, `softDelete`).\n\t * @param omitFields - Optional fields to omit from the base schema (e.g., `name`).\n\t * @returns A new Zod schema for updates.\n\t */\n\tupdateBaseSchema(extendFields?: z.ZodRawShape, omitFields?: string[]) {\n\t\tlet schema: z.ZodObject<any> = this.baseSchema;\n\n\t\tif (omitFields && omitFields.length > 0) {\n\t\t\tschema = schema.omit(omitFields.reduce((acc, key) => ({ ...acc, [key]: true }), {}));\n\t\t}\n\n\t\tif (extendFields) {\n\t\t\tschema = schema.extend({ _id: ZodValidation.objectId().optional(), ...extendFields });\n\t\t}\n\n\t\treturn schema;\n\t}\n\n\t/**\n\t * Gets all common schemas for an entity.\n\t * Returns base, entity, ID, and update schemas in a single object.\n\t *\n\t * @param excludeFromUpdate - Fields to exclude from update operations\n\t * @returns Object containing all schemas\n\t *\n\t * @example\n\t * ```typescript\n\t * const {\n\t * BaseSchema, // For creating\n\t * EntitySchema, // For reading\n\t * IdSchema, // For validating IDs\n\t * UpdateSchema // For updating\n\t * } = userBuilder.getAllSchemas();\n\t * ```\n\t */\n\tgetAllSchemas(excludeFromUpdate?: ExcludeFromUpdate) {\n\t\treturn {\n\t\t\tBaseSchema: this.getBaseSchema(),\n\t\t\tEntitySchema: this.getEntitySchema(),\n\t\t\tIdSchema: this.getIdSchema(),\n\t\t\tUpdateSchema: this.getUpdateSchema(excludeFromUpdate),\n\t\t\tDeleteSchema: this.getDeleteSchema(),\n\t\t};\n\t}\n}\n\n/**\n * Type helper for creating DTO types from creation schemas.\n * Used to derive the type for creating new entities.\n *\n * @template T - The schema type\n *\n * @example\n * ```typescript\n * type CreateUserDTO = DTO<typeof UserValidationSchema>;\n * ```\n */\nexport type DTO<T extends z.ZodType> = z.infer<T>;\n\n/**\n * Creates a schema builder for an entity.\n * Helper function to create a new SchemaBuilder instance.\n *\n * @template T - Type of the base schema shape\n * @param baseFields - Base fields for the entity\n * @param includeTimestamps - Whether to include timestamp fields (default: true)\n * @param includeTracking - Whether to include tracking fields (default: false)\n * @returns A new SchemaBuilder instance\n *\n * @example\n * ```typescript\n * const userFields = {\n * name: ZodValidation.requiredString(),\n * email: ZodValidation.email()\n * };\n *\n * const userSchemaBuilder = createSchemaBuilder(userFields);\n * const userSchemaBuilder = createSchemaBuilder(userFields, true, true); // With tracking\n * ```\n */\nexport type PaginatedResponse<T> = {\n\tmetadata: {\n\t\tpage: number;\n\t\tsize: number;\n\t\ttotalElements: number;\n\t\ttotalPages: number;\n\t};\n\tdocuments: T[];\n};\n\nexport function createSchemaBuilder<T extends z.ZodRawShape>(\n\tbaseFields: T,\n\tincludeTimestamps: boolean = true,\n\tincludeTracking: boolean = false\n) {\n\treturn new SchemaBuilder(baseFields, includeTimestamps, includeTracking);\n}\n"]}
|
|
1
|
+
{"version":3,"file":"global-validation.js","sourceRoot":"/","sources":["utilities/validation/global-validation.ts"],"names":[],"mappings":";;;AAqzBA,kDAMC;AA3zBD,6BAAwB;AACxB,oDAAgD;AAChD,yDAA+D;AAe/D,MAAa,aAAa;IAczB,MAAM,CAAC,sBAAsB,GAAG,OAAC,CAAC,MAAM,CACvC,GAAG,CAAC,EAAE;QACL,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,mBAAmB,CAAC,IAAI,CAAC,GAAG,CAAC;YAAE,OAAO,IAAI,CAAC;QAC1E,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,GAAG,YAAY,oBAAQ,CAAC,KAAK,CAAC,QAAQ;YAAE,OAAO,IAAI,CAAC;QACnF,OAAO,KAAK,CAAC;IACd,CAAC,EACD,EAAE,OAAO,EAAE,kBAAkB,EAAE,CAC/B,CAAC;IAEF,MAAM,CAAC,QAAQ,CAAC,QAAgB,OAAO;QACtC,OAAO,OAAC,CAAC,KAAK,CACb;YACC,OAAC;iBACC,MAAM,CAAC,EAAE,cAAc,EAAE,GAAG,KAAK,cAAc,EAAE,CAAC;iBAClD,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,oBAAQ,CAAC,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE;gBACpD,OAAO,EAAE,GAAG,KAAK,2BAA2B;aAC5C,CAAC;iBACD,SAAS,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,oBAAQ,CAAC,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;YACpD,OAAC,CAAC,UAAU,CAAC,oBAAQ,CAAC,KAAK,CAAC,QAAQ,EAAE;gBACrC,OAAO,EAAE,GAAG,KAAK,2BAA2B;aAC5C,CAAC;SACF,EACD,EAAE,OAAO,EAAE,GAAG,KAAK,cAAc,EAAE,CACnC,CAAC;IACH,CAAC;IAiBD,MAAM,CAAC,QA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AAC;IAmBD,aAAa,CAAC,iBAAqC;QAClD,OAAO;YACN,UAAU,EAAE,IAAI,CAAC,aAAa,EAAE;YAChC,YAAY,EAAE,IAAI,CAAC,eAAe,EAAE;YACpC,QAAQ,EAAE,IAAI,CAAC,WAAW,EAAE;YAC5B,YAAY,EAAE,IAAI,CAAC,eAAe,CAAC,iBAAiB,CAAC;YACrD,YAAY,EAAE,IAAI,CAAC,eAAe,EAAE;SACpC,CAAC;IACH,CAAC;CACD;AAlND,sCAkNC;AA8CD,SAAgB,mBAAmB,CAClC,UAAa,EACb,oBAA6B,IAAI,EACjC,kBAA2B,KAAK;IAEhC,OAAO,IAAI,aAAa,CAAC,UAAU,EAAE,iBAAiB,EAAE,eAAe,CAAC,CAAC;AAC1E,CAAC","sourcesContent":["import { z } from 'zod';\nimport { mongoose } from '@typegoose/typegoose';\nimport { parsePhoneNumberFromString } from 'libphonenumber-js';\n\n/**\n * Enhanced validation utilities for creating robust Zod schemas.\n * This class provides a collection of static methods to create common validation patterns.\n *\n * @example\n * ```typescript\n * const userSchema = z.object({\n * username: ZodValidation.requiredString(\"Username is required\"),\n * email: ZodValidation.email(),\n * role: ZodValidation.enumType(UserRole)\n * });\n * ```\n */\nexport class ZodValidation {\n\t/**\n\t * Creates a union type that accepts both string ObjectId and mongoose ObjectId instance.\n\t * This is useful when dealing with both raw string IDs and Mongoose ObjectId instances.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod union schema that accepts both string and ObjectId\n\t *\n\t * @example\n\t * ```typescript\n\t * const idSchema = ZodValidation.objectIdUnion();\n\t * // Accepts \"507f1f77bcf86cd799439011\" or new mongoose.Types.ObjectId(\"507f1f77bcf86cd799439011\")\n\t * ```\n\t */\n\tstatic objectIdOrStringSchema = z.custom<mongoose.Types.ObjectId | string>(\n\t\tval => {\n\t\t\tif (typeof val === 'string' && /^[0-9a-fA-F]{24}$/.test(val)) return true;\n\t\t\tif (typeof val === 'object' && val instanceof mongoose.Types.ObjectId) return true;\n\t\t\treturn false;\n\t\t},\n\t\t{ message: 'Invalid ObjectId' }\n\t);\n\n\tstatic objectId(field: string = 'Field') {\n\t\treturn z.union(\n\t\t\t[\n\t\t\t\tz\n\t\t\t\t\t.string({ required_error: `${field} is required` })\n\t\t\t\t\t.refine(val => mongoose.Types.ObjectId.isValid(val), {\n\t\t\t\t\t\tmessage: `${field} must be a valid ObjectID`,\n\t\t\t\t\t})\n\t\t\t\t\t.transform(val => new mongoose.Types.ObjectId(val)),\n\t\t\t\tz.instanceof(mongoose.Types.ObjectId, {\n\t\t\t\t\tmessage: `${field} must be a valid ObjectID`,\n\t\t\t\t}),\n\t\t\t],\n\t\t\t{ message: `${field} is required` }\n\t\t);\n\t}\n\n\t/**\n\t * Creates an enum validation with custom error message.\n\t * This validates that a value is one of the values defined in the enum.\n\t *\n\t * @template T - Type of the enum\n\t * @param enumObj - The enum object to validate against\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates against the provided enum\n\t *\n\t * @example\n\t * ```typescript\n\t * enum UserRole { ADMIN = \"admin\", USER = \"user\" }\n\t * const roleSchema = ZodValidation.enumType(UserRole, \"Invalid user role\");\n\t * ```\n\t */\n\tstatic enumType<T extends z.EnumLike>(enumObj: T, field: string = 'Field') {\n\t\treturn z.nativeEnum(enumObj, {\n\t\t\tmessage: `${field} must be one of: ${Object.values(enumObj).join(', ')}`,\n\t\t});\n\t}\n\n\t/**\n\t * Creates a required number validation with a minimum length.\n\t * The number is also trimmed to remove leading/trailing whitespace.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @param min - Minimum number (optional)\n\t * @param max - MAximum number (optional)\n\t * @param options - options (optional)\n\t * @returns A Zod schema that validates numbers with minimum length\n\t *\n\t * @example\n\t * ```typescript\n\t * const nameSchema = ZodValidation.Number(\"Price\");\n\t * ```\n\t */\n\tstatic number(\n\t\tfield: string = 'Field',\n\t\toptions?: {\n\t\t\tmin?: number;\n\t\t\tmax?: number;\n\t\t\tisInt?: boolean;\n\t\t\tisPositive?: boolean;\n\t\t\tisNonpositive?: boolean;\n\t\t\tisNegative?: boolean;\n\t\t\tisNonnegative?: boolean;\n\t\t}\n\t) {\n\t\tlet schema = z.number({\n\t\t\trequired_error: `${field} is required`,\n\t\t\tinvalid_type_error: `${field} must be a number`,\n\t\t});\n\n\t\t// Range validation\n\t\tif (options?.min !== undefined) {\n\t\t\tschema = schema.gte(options?.min, {\n\t\t\t\tmessage: `${field} must be at least ${options?.min}`,\n\t\t\t});\n\t\t}\n\t\tif (options?.max !== undefined) {\n\t\t\tschema = schema.lte(options?.max, {\n\t\t\t\tmessage: `${field} must be at most ${options?.max}`,\n\t\t\t});\n\t\t}\n\n\t\t// Option validation\n\t\tif (options?.isInt) {\n\t\t\tschema = schema.int({ message: `${field} must be an integer` });\n\t\t}\n\t\tif (options?.isPositive) {\n\t\t\tschema = schema.positive({ message: `${field} must be positive` });\n\t\t}\n\t\tif (options?.isNonpositive) {\n\t\t\tschema = schema.nonpositive({ message: `${field} must be non-positive` });\n\t\t}\n\t\tif (options?.isNegative) {\n\t\t\tschema = schema.negative({ message: `${field} must be negative` });\n\t\t}\n\t\tif (options?.isNonnegative) {\n\t\t\tschema = schema.nonnegative({ message: `${field} must be non-negative` });\n\t\t}\n\n\t\treturn schema;\n\t}\n\n\t/**\n\t * Creates a required string validation with a minimum length.\n\t * The string is also trimmed to remove leading/trailing whitespace.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @param minLength - Minimum required length (optional)\n\t * @param maxLength - Maximum required length (optional)\n\t * @param regex - Regular expression (optional)\n\t * @returns A Zod schema that validates strings with minimum length\n\t *\n\t * @example\n\t * ```typescript\n\t * const nameSchema = ZodValidation.String(\"Name\");\n\t * ```\n\t */\n\tstatic string(\n\t\tfield: string = 'Field',\n\t\toptions?: {\n\t\t\tminLength?: number;\n\t\t\tmaxLength?: number;\n\t\t\tminMessage?: string;\n\t\t\tmaxMessage?: string;\n\t\t\trequiredMessage?: string;\n\t\t\tregex?: { pattern: RegExp; message: string }; // Add regex option\n\t\t\tisTrimmed?: boolean;\n\t\t}\n\t) {\n\t\tlet schema = z.string({\n\t\t\trequired_error: options?.requiredMessage || `${field} is required`,\n\t\t});\n\n\t\tif (options?.minLength) {\n\t\t\tschema = schema.min(\n\t\t\t\toptions.minLength,\n\t\t\t\toptions.minMessage || `${field} must be at least ${options.minLength} characters`\n\t\t\t);\n\t\t}\n\n\t\tif (options?.maxLength) {\n\t\t\tschema = schema.max(\n\t\t\t\toptions.maxLength,\n\t\t\t\toptions.maxMessage || `${field} shouldn’t exceed ${options.maxLength} characters`\n\t\t\t);\n\t\t}\n\n\t\t// Check for regex pattern and add regex validation\n\t\tif (options?.regex) {\n\t\t\tschema = schema.regex(options.regex.pattern, options.regex.message);\n\t\t}\n\n\t\tif (options?.isTrimmed) {\n\t\t\treturn schema\n\t\t\t\t.transform(val => val?.trim())\n\t\t\t\t.refine(val => val?.length && val?.length > 0, {\n\t\t\t\t\tmessage: options?.requiredMessage || `${field} is required`,\n\t\t\t\t});\n\t\t}\n\n\t\treturn schema;\n\t}\n\n\t/**\n\t * Creates an email validation.\n\t * Validates that the string is a valid email address format.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates email addresses\n\t *\n\t * @example\n\t * ```typescript\n\t * const emailSchema = ZodValidation.email(\"Please enter a valid email\");\n\t * ```\n\t */\n\tstatic email(\n\t\tfield: string = 'Email',\n\t\toptions?: {\n\t\t\trequiredMessage?: string;\n\t\t\tinvalidMessage?: string;\n\t\t}\n\t) {\n\t\tconst schema = z\n\t\t\t.string({\n\t\t\t\trequired_error: options?.requiredMessage || `${field} is required`,\n\t\t\t})\n\t\t\t.email(options?.invalidMessage || `${field} must be a valid email address`);\n\n\t\treturn schema;\n\t}\n\n\t/**\n\t * Creates a URL validation.\n\t * Validates that the string is a valid URL format.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates URLs\n\t *\n\t * @example\n\t * ```typescript\n\t * const websiteSchema = ZodValidation.url(\"Please enter a valid URL\");\n\t * ```\n\t */\n\tstatic url(field: string = 'Field') {\n\t\treturn z.string({ required_error: `${field} is required` }).url(`${field} must be a valid URL`);\n\t}\n\n\t/**\n\t * Creates a phone number validation schema using a regex pattern for global phone numbers.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates phone numbers\n\t *\n\t * @example\n\t * ```typescript\n\t * const phoneSchema = ZodValidation.phoneNumber(\"Phone number\");\n\t * ```\n\t */\n\n\tstatic phoneNumber(field: string = 'Field') {\n\t\treturn z.string({ required_error: `${field} is required` }).refine(\n\t\t\tvalue => {\n\t\t\t\ttry {\n\t\t\t\t\tconst phone = parsePhoneNumberFromString(value);\n\t\t\t\t\treturn phone?.isValid();\n\t\t\t\t} catch {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t},\n\t\t\t{\n\t\t\t\tmessage: `Please input a valid phone number`,\n\t\t\t}\n\t\t);\n\t}\n\n\tstatic validPhoneNumber(field: string = 'Field') {\n\t\treturn z.string({ required_error: `${field} is required` }).superRefine((phoneWithCountryCode, ctx) => {\n\t\t\tconst phoneWithoutCountryCode = phoneWithCountryCode.replace(/^\\+\\d{1,3}/, '');\n\t\t\tif (phoneWithoutCountryCode.length < 4) {\n\t\t\t\tctx.addIssue({\n\t\t\t\t\tcode: z.ZodIssueCode.custom,\n\t\t\t\t\tmessage: `${field} must have 4 or more digits`,\n\t\t\t\t});\n\t\t\t}\n\t\t\tif (/^\\d{4}$|^\\d{5}$|^\\d{7}$|^\\d{8}$/.test(phoneWithoutCountryCode)) {\n\t\t\t\treturn; // ✅ Accept 4,5,7 or 8 digit short numbers\n\t\t\t}\n\t\t\t// Otherwise, parse as real phone number\n\t\t\tconst phone = parsePhoneNumberFromString(phoneWithCountryCode);\n\t\t\tif (!phone) {\n\t\t\t\tctx.addIssue({\n\t\t\t\t\tcode: z.ZodIssueCode.custom,\n\t\t\t\t\tmessage: `Invalid phone number format in ${field}`,\n\t\t\t\t});\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (!phone.isValid()) {\n\t\t\t\tctx.addIssue({\n\t\t\t\t\tcode: z.ZodIssueCode.custom,\n\t\t\t\t\tmessage: `Please input a valid phone number in ${field}`,\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t}\n\n\t/**\n\t * Creates a date validation.\n\t * Validates that the input is a JavaScript Date object.\n\t *@param field - The name of the field to be included in the error message\n\t *@param minDate - Minimum required date (optional)\n\t *@param maxDate - Maximum required date (optional)\n\t * @returns A Zod schema that validates Date objects\n\t *\n\t * @example\n\t * ```typescript\n\t * const createdAtSchema = ZodValidation.date();\n\t * ```\n\t */\n\tstatic date(field: string = 'Field', minDate?: Date, maxDate?: Date) {\n\t\treturn z\n\t\t\t.union(\n\t\t\t\t[\n\t\t\t\t\tz\n\t\t\t\t\t\t.string({ required_error: `${field} is required` })\n\t\t\t\t\t\t.refine(val => {\n\t\t\t\t\t\t\tconst date = new Date(val);\n\t\t\t\t\t\t\treturn !isNaN(date.getTime());\n\t\t\t\t\t\t}, `${field} must be a valid date`)\n\t\t\t\t\t\t.transform(val => new Date(val)),\n\t\t\t\t\tz.date({\n\t\t\t\t\t\trequired_error: `${field} is required`,\n\t\t\t\t\t\tinvalid_type_error: `${field} must be a valid date`,\n\t\t\t\t\t}),\n\t\t\t\t],\n\t\t\t\t{ message: `${field} is required` }\n\t\t\t)\n\t\t\t.refine(\n\t\t\t\tval => minDate === undefined || val >= minDate,\n\t\t\t\t`${field} must be on or after ${minDate?.toISOString()}`\n\t\t\t)\n\t\t\t.refine(\n\t\t\t\tval => maxDate === undefined || val <= maxDate,\n\t\t\t\t`${field} must be on or before ${maxDate?.toISOString()}`\n\t\t\t);\n\t}\n\n\t/**\n\t * Creates a boolean validation with an optional default value.\n\t *\n\t * @param field - The name of the field to be included in the error message\n\t * @returns A Zod schema that validates booleans\n\t *\n\t * @example\n\t * ```typescript\n\t * const isActiveSchema = ZodValidation.boolean(true); // Defaults to true\n\t * ```\n\t */\n\tstatic boolean(field: string = 'Field') {\n\t\treturn z.boolean({\n\t\t\trequired_error: `${field} is required`,\n\t\t\tinvalid_type_error: `${field} must be a boolean`,\n\t\t});\n\t}\n\n\t/**\n\t * Creates an array validation with optional minimum items constraint.\n\t *\n\t * @template T - Type of the schema for array items\n\t * @param schema - The schema for validating array items\n\t * @param field - The name of the field to be included in the error message\n\t * @param minItems - Minimum number of items required (optional)\n\t * @param maxItems - Maximum number of items required (optional)\n\t * @returns A Zod schema that validates arrays\n\t *\n\t * @example\n\t * ```typescript\n\t * const tagsSchema = ZodValidation.array(z.string(), \"At least one tag required\", 1);\n\t * ```\n\t */\n\tstatic array<T extends z.ZodTypeAny>(\n\t\tschema: T,\n\t\tfield: string = 'Array',\n\t\tminItems?: number,\n\t\tmaxItems?: number\n\t) {\n\t\tlet arraySchema = z.array(schema, {\n\t\t\trequired_error: `${field} is required`,\n\t\t});\n\n\t\tif (minItems === 1) {\n\t\t\tarraySchema = arraySchema.min(1, `${field} cannot be empty`);\n\t\t}\n\t\tif (minItems !== undefined && minItems !== 1) {\n\t\t\tarraySchema = arraySchema.min(minItems, `${field} must have at least ${minItems} items`);\n\t\t}\n\t\tif (maxItems !== undefined) {\n\t\t\tarraySchema = arraySchema.max(maxItems, `${field} must have at most ${maxItems} items`);\n\t\t}\n\n\t\treturn arraySchema;\n\t}\n\n\t/**\n\t * Standard timestamp fields for entities.\n\t * Includes createdAt, updatedAt, and deletedAt fields.\n\t *\n\t * @returns An object containing timestamp field schemas\n\t *\n\t * @example\n\t * ```typescript\n\t * const userSchema = z.object({\n\t * name: z.string(),\n\t * ...ZodValidation.timestamps()\n\t * });\n\t * ```\n\t */\n\tstatic timestamps() {\n\t\treturn {\n\t\t\tcreatedAt: z.date().nullable().optional(),\n\t\t\tupdatedAt: z.date().nullable().optional(),\n\t\t\tdeletedAt: z.date().nullable().optional(),\n\t\t};\n\t}\n\n\t/**\n\t * Common fields for tracking model metadata.\n\t * Includes timestamps and user tracking fields (createdBy, updatedBy, deletedBy).\n\t *\n\t * @returns An object containing tracking field schemas\n\t *\n\t * @example\n\t * ```typescript\n\t * const postSchema = z.object({\n\t * title: z.string(),\n\t * content: z.string(),\n\t * ...ZodValidation.trackingFields()\n\t * });\n\t * ```\n\t */\n\tstatic trackingFields() {\n\t\treturn {\n\t\t\tcreatedBy: ZodValidation.objectId().optional(),\n\t\t\tupdatedBy: ZodValidation.objectId().optional(),\n\t\t\tdeletedBy: ZodValidation.objectId().optional(),\n\t\t\t...ZodValidation.timestamps(),\n\t\t};\n\t}\n\n\t/**\n\t * Namespace for coercion-based Zod validators.\n\t * Provides schemas that automatically convert input types to the expected type.\n\t *\n\t * @example\n\t * ```typescript\n\t * const schema = z.object({\n\t * startDate: ZodValidation.coerce.date(\"Start Date\"),\n\t * age: ZodValidation.coerce.number(\"Age\", { min: 18 }),\n\t * isActive: ZodValidation.coerce.boolean(\"Active\"),\n\t * });\n\t * ```\n\t */\n\tstatic coerce = {\n\t\tnumber: (\n\t\t\tfield: string = 'Field',\n\t\t\toptions?: {\n\t\t\t\tmin?: number;\n\t\t\t\tmax?: number;\n\t\t\t\tisInt?: boolean;\n\t\t\t\tisPositive?: boolean;\n\t\t\t\tisNonpositive?: boolean;\n\t\t\t\tisNegative?: boolean;\n\t\t\t\tisNonnegative?: boolean;\n\t\t\t}\n\t\t) => {\n\t\t\tlet schema = z.coerce.number({\n\t\t\t\trequired_error: `${field} is required`,\n\t\t\t\tinvalid_type_error: `${field} must be a number`,\n\t\t\t});\n\n\t\t\tif (options?.min !== undefined) {\n\t\t\t\tschema = schema.gte(options.min, { message: `${field} must be at least ${options.min}` });\n\t\t\t}\n\t\t\tif (options?.max !== undefined) {\n\t\t\t\tschema = schema.lte(options.max, { message: `${field} must be at most ${options.max}` });\n\t\t\t}\n\t\t\tif (options?.isInt) schema = schema.int({ message: `${field} must be an integer` });\n\t\t\tif (options?.isPositive) schema = schema.positive({ message: `${field} must be positive` });\n\t\t\tif (options?.isNonpositive) schema = schema.nonpositive({ message: `${field} must be non-positive` });\n\t\t\tif (options?.isNegative) schema = schema.negative({ message: `${field} must be negative` });\n\t\t\tif (options?.isNonnegative) schema = schema.nonnegative({ message: `${field} must be non-negative` });\n\n\t\t\treturn schema;\n\t\t},\n\n\t\tdate: (field: string = 'Field', minDate?: Date, maxDate?: Date) => {\n\t\t\treturn z.coerce\n\t\t\t\t.date({\n\t\t\t\t\trequired_error: `${field} is required`,\n\t\t\t\t\tinvalid_type_error: `${field} must be a valid date`,\n\t\t\t\t})\n\t\t\t\t.refine(val => minDate === undefined || val >= minDate, {\n\t\t\t\t\tmessage: `${field} must be on or after ${minDate?.toISOString()}`,\n\t\t\t\t})\n\t\t\t\t.refine(val => maxDate === undefined || val <= maxDate, {\n\t\t\t\t\tmessage: `${field} must be on or before ${maxDate?.toISOString()}`,\n\t\t\t\t});\n\t\t},\n\n\t\tboolean: (field: string = 'Field') => {\n\t\t\treturn z.coerce.boolean({\n\t\t\t\trequired_error: `${field} is required`,\n\t\t\t\tinvalid_type_error: `${field} must be true or false`,\n\t\t\t});\n\t\t},\n\t\tobjectId: (field: string = 'Field') =>\n\t\t\tz\n\t\t\t\t.custom<mongoose.Types.ObjectId>(\n\t\t\t\t\tval => {\n\t\t\t\t\t\tif (typeof val === 'string' && mongoose.Types.ObjectId.isValid(val)) return true;\n\t\t\t\t\t\tif (val instanceof mongoose.Types.ObjectId) return true;\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t},\n\t\t\t\t\t{ message: `${field} must be a valid ObjectId` }\n\t\t\t\t)\n\t\t\t\t.transform(val => (typeof val === 'string' ? new mongoose.Types.ObjectId(val) : val)),\n\t};\n}\n\n/**\n * Represents the common fields to exclude from update operations.\n * This is used to specify which fields should not be updateable.\n *\n * @example\n * ```typescript\n * const excludeFields: ExcludeFromUpdate = {\n * createdAt: true,\n * createdBy: true,\n * status: true // Prevent status from being updated\n * };\n * ```\n */\nexport type ExcludeFromUpdate = {\n\tcreatedAt?: true;\n\tupdatedAt?: true;\n\tdeletedAt?: true;\n\tcreatedBy?: true;\n\t_id?: true;\n} & Record<string, true>;\n\n/**\n * Schema builder for creating consistent CRUD schemas.\n * Provides utility methods to generate schemas for create, read, update, and delete operations.\n *\n * @template T - Type of the base schema shape\n *\n * @example\n * ```typescript\n * const userBuilder = new SchemaBuilder({\n * name: z.string(),\n * email: z.string().email()\n * });\n *\n * const schemas = userBuilder.getAllSchemas();\n * ```\n */\nexport class SchemaBuilder<T extends z.ZodRawShape> {\n\tprivate baseSchema: z.ZodObject<T>;\n\n\t/**\n\t * Create a new schema builder\n\t *\n\t * @param baseFields - The base fields for the schema\n\t * @param includeTimestamps - Whether to include timestamp fields (default: true)\n\t * @param includeTracking - Whether to include tracking fields (createdBy, etc.) (default: false)\n\t *\n\t * @example\n\t * ```typescript\n\t * const userFields = {\n\t * name: ZodValidation.requiredString(),\n\t * email: ZodValidation.email()\n\t * };\n\t *\n\t * // With timestamps\n\t * const builder1 = new SchemaBuilder(userFields);\n\t *\n\t * // Without timestamps\n\t * const builder2 = new SchemaBuilder(userFields, false);\n\t *\n\t * // With tracking fields\n\t * const builder3 = new SchemaBuilder(userFields, true, true);\n\t * ```\n\t */\n\tconstructor(\n\t\tbaseFields: T,\n\t\tprivate includeTimestamps: boolean = true,\n\t\tprivate includeTracking: boolean = false\n\t) {\n\t\tthis.baseSchema = this.createBaseSchema(baseFields);\n\t}\n\n\t/**\n\t * Creates the base schema with optional timestamps and tracking fields.\n\t */\n\tprivate createBaseSchema(baseFields: T) {\n\t\tconst additionalFields = this.includeTracking\n\t\t\t? ZodValidation.trackingFields()\n\t\t\t: this.includeTimestamps\n\t\t\t\t? ZodValidation.timestamps()\n\t\t\t\t: {};\n\n\t\treturn z.object({\n\t\t\t...baseFields,\n\t\t\t...additionalFields,\n\t\t});\n\t}\n\n\t/**\n\t * Gets the base validation schema without ID.\n\t * Used for creating new entities.\n\t *\n\t * @returns The base schema for creating new entities\n\t *\n\t * @example\n\t * ```typescript\n\t * const createUserSchema = userBuilder.getBaseSchema();\n\t * ```\n\t */\n\tgetBaseSchema() {\n\t\treturn this.baseSchema.strict();\n\t}\n\n\t/**\n\t * Gets the schema for entities with ID.\n\t * Used for representing complete entities with their ID.\n\t *\n\t * @returns The entity schema including ID\n\t *\n\t * @example\n\t * ```typescript\n\t * const userSchema = userBuilder.getEntitySchema();\n\t * ```\n\t */\n\tgetEntitySchema() {\n\t\treturn this.baseSchema\n\t\t\t.extend({\n\t\t\t\t_id: ZodValidation.objectId(),\n\t\t\t})\n\t\t\t.partial()\n\t\t\t.passthrough();\n\t}\n\n\t/**\n\t * Gets the schema for validating an entity ID.\n\t * Used for validating ID parameters in requests.\n\t *\n\t * @returns The ID validation schema\n\t *\n\t * @example\n\t * ```typescript\n\t * const userIdSchema = userBuilder.getIdSchema();\n\t * ```\n\t */\n\tgetIdSchema() {\n\t\treturn ZodValidation.objectId();\n\t}\n\n\t/**\n\t * Gets the schema for updating an entity, excluding specified fields.\n\t * Creates a partial schema where all fields are optional, and removes\n\t * fields that should not be updatable.\n\t *\n\t * @param excludeFields - Fields to exclude from update operations\n\t * @returns The update schema with excluded fields removed\n\t *\n\t * @example\n\t * ```typescript\n\t * // Prevent updating createdAt and status\n\t * const updateUserSchema = userBuilder.getUpdateSchema({\n\t * createdAt: true,\n\t * status: true\n\t * });\n\t * ```\n\t */\n\tgetUpdateSchema(excludeFields: ExcludeFromUpdate = { createdAt: true, updatedAt: true }) {\n\t\tconst entitySchema = this.getEntitySchema();\n\n\t\t// Simple approach - just make everything optional\n\t\tif (Object.keys(excludeFields).length === 0) {\n\t\t\treturn entitySchema;\n\t\t}\n\n\t\t// For the type-safe approach, we need to create a new schema\n\t\t// without the excluded fields and then make it partial\n\n\t\t// Get all fields from the entity schema\n\t\tconst shape = entitySchema._def.shape();\n\n\t\t// Filter out the fields we want to exclude\n\t\tconst filteredShape: z.ZodRawShape = {};\n\t\tfor (const key in shape) {\n\t\t\tif (!excludeFields[key as keyof typeof excludeFields]) {\n\t\t\t\tfilteredShape[key] = shape[key];\n\t\t\t}\n\t\t}\n\n\t\t// Create a new schema with the filtered fields\n\t\treturn z.object(filteredShape).partial().strict();\n\t}\n\n\t/**\n\t * Gets the schema for validating a delete request.\n\t * Used for validating parameters in delete requests, including the entity ID and soft delete flag.\n\t *\n\t * @returns The delete validation schema\n\t *\n\t * @example\n\t * ```typescript\n\t * const deleteSchema = userBuilder.getDeleteSchema();\n\t * ```\n\t */\n\tgetDeleteSchema() {\n\t\treturn z.object({\n\t\t\t_id: ZodValidation.objectId('_id'),\n\t\t\tsoftDelete: ZodValidation.boolean('Soft Delete').default(true),\n\t\t});\n\t}\n\n\t/**\n\t * Creates an update schema by optionally extending the base schema with additional fields\n\t * and optionally omitting specified fields.\n\t *\n\t * @param extendFields - Optional fields to add to the schema (e.g., `_id`, `softDelete`).\n\t * @param omitFields - Optional fields to omit from the base schema (e.g., `name`).\n\t * @returns A new Zod schema for updates.\n\t */\n\tupdateBaseSchema(extendFields?: z.ZodRawShape, omitFields?: string[]) {\n\t\tlet schema: z.ZodObject<any> = this.baseSchema;\n\n\t\tif (omitFields && omitFields.length > 0) {\n\t\t\tschema = schema.omit(omitFields.reduce((acc, key) => ({ ...acc, [key]: true }), {}));\n\t\t}\n\n\t\tif (extendFields) {\n\t\t\tschema = schema.extend({ _id: ZodValidation.objectId().optional(), ...extendFields });\n\t\t}\n\n\t\treturn schema;\n\t}\n\n\t/**\n\t * Gets all common schemas for an entity.\n\t * Returns base, entity, ID, and update schemas in a single object.\n\t *\n\t * @param excludeFromUpdate - Fields to exclude from update operations\n\t * @returns Object containing all schemas\n\t *\n\t * @example\n\t * ```typescript\n\t * const {\n\t * BaseSchema, // For creating\n\t * EntitySchema, // For reading\n\t * IdSchema, // For validating IDs\n\t * UpdateSchema // For updating\n\t * } = userBuilder.getAllSchemas();\n\t * ```\n\t */\n\tgetAllSchemas(excludeFromUpdate?: ExcludeFromUpdate) {\n\t\treturn {\n\t\t\tBaseSchema: this.getBaseSchema(),\n\t\t\tEntitySchema: this.getEntitySchema(),\n\t\t\tIdSchema: this.getIdSchema(),\n\t\t\tUpdateSchema: this.getUpdateSchema(excludeFromUpdate),\n\t\t\tDeleteSchema: this.getDeleteSchema(),\n\t\t};\n\t}\n}\n\n/**\n * Type helper for creating DTO types from creation schemas.\n * Used to derive the type for creating new entities.\n *\n * @template T - The schema type\n *\n * @example\n * ```typescript\n * type CreateUserDTO = DTO<typeof UserValidationSchema>;\n * ```\n */\nexport type DTO<T extends z.ZodType> = z.infer<T>;\n\n/**\n * Creates a schema builder for an entity.\n * Helper function to create a new SchemaBuilder instance.\n *\n * @template T - Type of the base schema shape\n * @param baseFields - Base fields for the entity\n * @param includeTimestamps - Whether to include timestamp fields (default: true)\n * @param includeTracking - Whether to include tracking fields (default: false)\n * @returns A new SchemaBuilder instance\n *\n * @example\n * ```typescript\n * const userFields = {\n * name: ZodValidation.requiredString(),\n * email: ZodValidation.email()\n * };\n *\n * const userSchemaBuilder = createSchemaBuilder(userFields);\n * const userSchemaBuilder = createSchemaBuilder(userFields, true, true); // With tracking\n * ```\n */\nexport type PaginatedResponse<T> = {\n\tmetadata: {\n\t\tpage: number;\n\t\tsize: number;\n\t\ttotalElements: number;\n\t\ttotalPages: number;\n\t};\n\tdocuments: T[];\n};\n\nexport function createSchemaBuilder<T extends z.ZodRawShape>(\n\tbaseFields: T,\n\tincludeTimestamps: boolean = true,\n\tincludeTracking: boolean = false\n) {\n\treturn new SchemaBuilder(baseFields, includeTimestamps, includeTracking);\n}\n"]}
|