@restaround/react 1.3.39 → 1.3.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/PublicMenu/OrderDrawer/OrderTable.d.ts +2 -0
- package/dist/components/ScrollToTop/ScrollToTop.d.ts +7 -0
- package/dist/components/ScrollToTop/index.d.ts +1 -0
- package/dist/index.esm.js +1 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/models/index.d.ts +1 -0
- package/dist/models/index.esm.js +1 -1
- package/dist/models/index.esm.js.map +1 -1
- package/dist/models/index.js +1 -1
- package/dist/models/index.js.map +1 -1
- package/dist/models/menu.d.ts +3 -0
- package/dist/models/models/index.d.ts +1 -0
- package/dist/models/models/menu.d.ts +3 -0
- package/dist/models/modules/table/models.d.ts +66 -0
- package/dist/modules/branch/utils.test.d.ts +1 -0
- package/dist/modules/order/constants.d.ts +6 -0
- package/dist/modules/order/hooks.d.ts +10 -1
- package/dist/modules/order/utils.d.ts +5 -1
- package/dist/modules/table/hooks.d.ts +4 -0
- package/dist/modules/table/index.d.ts +2 -0
- package/dist/modules/table/models.d.ts +66 -0
- package/dist/services/translation/locales/az/index.d.ts +6 -0
- package/dist/services/translation/locales/az/order.d.ts +6 -0
- package/dist/services/translation/locales/et/index.d.ts +6 -0
- package/dist/services/translation/locales/et/order.d.ts +6 -0
- package/dist/services/translation/locales/index.d.ts +30 -0
- package/dist/services/translation/locales/nl/index.d.ts +6 -0
- package/dist/services/translation/locales/nl/order.d.ts +6 -0
- package/dist/services/translation/locales/ru/index.d.ts +6 -0
- package/dist/services/translation/locales/ru/order.d.ts +6 -0
- package/dist/services/translation/locales/tr/index.d.ts +6 -0
- package/dist/services/translation/locales/tr/order.d.ts +6 -0
- package/dist/store/order.d.ts +3 -0
- package/dist/styles/ui.css +1 -1
- package/dist/styles/ui.css.map +1 -1
- package/dist/utils/index.esm.js +1 -1
- package/dist/utils/index.esm.js.map +1 -1
- package/dist/utils/index.js +1 -1
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/models/index.d.ts +1 -0
- package/dist/utils/models/menu.d.ts +3 -0
- package/dist/utils/modules/order/constants.d.ts +16 -0
- package/dist/utils/modules/order/utils.d.ts +5 -1
- package/dist/utils/modules/table/models.d.ts +66 -0
- package/package.json +7 -7
package/dist/models/index.d.ts
CHANGED
|
@@ -7,5 +7,6 @@ export * from "../modules/order/models";
|
|
|
7
7
|
export * from "../modules/product/models";
|
|
8
8
|
export * from "../modules/view/models";
|
|
9
9
|
export * from "../modules/subscription/models";
|
|
10
|
+
export * from "../modules/table/models";
|
|
10
11
|
export * from "./category";
|
|
11
12
|
export * from "./menu";
|
package/dist/models/index.esm.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var E,
|
|
1
|
+
var E,A,I,R,N,L,O,D,C,T,_,P,n,S,G,M,i;!function(E){E.SINGLE="SINGLE",E.MULTIPLE="MULTIPLE"}(E||(E={})),function(E){E.MAX_DELIVERY_DISTANCE="maxDeliveryDistance",E.DELIVERY_ORDER_ENABLED="deliveryOrderEnabled",E.PICKUP_ORDER_ENABLED="pickupOrderEnabled",E.DINE_IN_ORDER_ENABLED="dineInOrderEnabled",E.MIN_DELIVERY_AMOUNT="minDeliveryAmount"}(A||(A={})),function(E){E.PHONE="PHONE",E.OTP="OTP",E.EMAIL="EMAIL"}(I||(I={})),function(E){E.HOME="HOME",E.WORK="WORK",E.TRAVEL="TRAVEL"}(R||(R={})),function(E){E.ORDER="feature_order"}(N||(N={})),function(E){E.ALPHA="ALPHA",E.BETA="BETA",E.ALL="ALL"}(L||(L={})),function(E){E.DINE_IN="DINE_IN",E.PICK_UP="PICK_UP",E.DELIVERY="DELIVERY"}(O||(O={})),function(E){E.DRAFT="DRAFT",E.PENDING="PENDING",E.CONFIRMED="CONFIRMED",E.PREPARING="PREPARING",E.READY="READY",E.OUT_FOR_DELIVERY="OUT_FOR_DELIVERY",E.DELIVERED="DELIVERED",E.COMPLETED="COMPLETED",E.CANCELLED="CANCELLED",E.FAILED="FAILED"}(D||(D={})),function(E){E.PENDING="PENDING",E.PREPARING="PREPARING",E.READY="READY",E.SERVED="SERVED"}(C||(C={})),function(E){E.CASH="CASH",E.CARD="CARD",E.WALLET="WALLET",E.TERMINAL="TERMINAL"}(T||(T={})),function(E){E.CART="CART",E.DETAILS="DETAILS",E.COMPLETED="COMPLETED"}(_||(_={})),function(E){E.LIST="list",E.GRID="grid"}(P||(P={})),function(E){E.APPETIZER="appetizer",E.MAIN_COURSE="mainCourse",E.CHEFS_SPECIAL="chefsSpecial",E.LIFETIME="lifeTime"}(n||(n={})),function(E){E.ACTIVE="ACTIVE",E.EXPIRED="EXPIRED",E.CANCELLED="CANCELLED"}(S||(S={})),function(E){E.SQUARE="SQUARE",E.CIRCLE="CIRCLE",E.RECTANGLE="RECTANGLE",E.RECTANGLE_VERTICAL="RECTANGLE_VERTICAL",E.SINGLE_AT_BAR="SINGLE_AT_BAR",E.OTHER="OTHER"}(G||(G={})),function(E){E.VACANT="VACANT",E.RESERVED="RESERVED",E.OCCUPIED="OCCUPIED",E.BLOCKED="BLOCKED",E.NEEDS_CLEANING="NEEDS_CLEANING",E.OUT_OF_SERVICE="OUT_OF_SERVICE",E.PENDING_CONFIRMATION="PENDING_CONFIRMATION",E.NO_SHOW="NO_SHOW"}(M||(M={})),function(E){E.MAIN_HALL="MAIN_HALL",E.PRIVATE_DINING="PRIVATE_DINING",E.VIP_ROOM="VIP_ROOM",E.BANQUET_HALL="BANQUET_HALL",E.BAR_AREA="BAR_AREA",E.LOUNGE="LOUNGE",E.OPEN_KITCHEN="OPEN_KITCHEN",E.BOOTH_SECTION="BOOTH_SECTION",E.MEZZANINE="MEZZANINE",E.WINE_CELLAR="WINE_CELLAR",E.TERRACE="TERRACE",E.PATIO="PATIO",E.GARDEN="GARDEN",E.COURTYARD="COURTYARD",E.ROOFTOP="ROOFTOP",E.BALCONY="BALCONY",E.SIDEWALK="SIDEWALK",E.POOLSIDE="POOLSIDE",E.SMOKING_AREA="SMOKING_AREA",E.NON_SMOKING="NON_SMOKING",E.FAMILY_SECTION="FAMILY_SECTION",E.KIDS_AREA="KIDS_AREA",E.WAITING_AREA="WAITING_AREA",E.DANCE_FLOOR="DANCE_FLOOR"}(i||(i={}));export{A as BusinessSetting,R as CustomerAddressType,I as CustomerAuthStep,N as Feature,L as FeatureSegment,E as MenuAddonSelectType,C as OrderItemStatus,D as OrderStatus,_ as OrderStep,O as OrderType,T as PaymentMethod,n as PlanType,P as ProductView,S as SubscriptionStatus,i as TableLocation,G as TableShape,M as TableStatus};
|
|
2
2
|
//# sourceMappingURL=index.esm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.esm.js","sources":["../../../src/modules/addon/models.ts","../../../src/modules/business/models.ts","../../../src/modules/customer/models.ts","../../../src/modules/feature/models.ts","../../../src/modules/order/models.ts","../../../src/modules/product/models.ts","../../../src/modules/subscription/models.ts"],"sourcesContent":["export enum MenuAddonSelectType {\n\tSINGLE = \"SINGLE\",\n\tMULTIPLE = \"MULTIPLE\",\n}\n\nexport interface MenuAddonTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface MenuAddonOptionTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface MenuAddonOption {\n\tid?: number;\n\tprice: number;\n\ttranslations: MenuAddonOptionTranslation[];\n\tremove?: boolean;\n}\n\nexport interface MenuAddon {\n\tid?: number;\n\tselectType: MenuAddonSelectType;\n\ttranslations: MenuAddonTranslation[];\n\toptions: MenuAddonOption[];\n\tbusinessId?: number;\n}\n","import * as featureModels from \"../feature/models\";\nimport * as subscriptionModels from \"../subscription/models\";\n\nexport interface BusinessLanguage {\n\tid: number;\n\tcode: string;\n\tbusinessId: number;\n}\n\nexport interface BusinessSettings {\n\tdeliveryOrderEnabled: boolean;\n\tpickupOrderEnabled: boolean;\n\tdineInOrderEnabled: boolean;\n\tmaxDeliveryDistance: number;\n\tminDeliveryAmount: number;\n}\n\nexport enum BusinessSetting {\n\tMAX_DELIVERY_DISTANCE = \"maxDeliveryDistance\",\n\tDELIVERY_ORDER_ENABLED = \"deliveryOrderEnabled\",\n\tPICKUP_ORDER_ENABLED = \"pickupOrderEnabled\",\n\tDINE_IN_ORDER_ENABLED = \"dineInOrderEnabled\",\n\tMIN_DELIVERY_AMOUNT = \"minDeliveryAmount\",\n}\n\nexport interface Business {\n\tid: number;\n\tname: string;\n\tusername: string;\n\tavatar64?: string;\n\tavatar128?: string;\n\tavatar256?: string;\n\tcoverPhoto?: string;\n\tinstagram?: string;\n\tfacebook?: string;\n\ttiktok?: string;\n\tcreatedAt?: number;\n\tcurrency: string;\n\tlanguages: BusinessLanguage[];\n\tsubscriptions?: subscriptionModels.Subscription[];\n\tsegment?: featureModels.FeatureSegment;\n\tsettings?: BusinessSettings;\n}\n","export enum CustomerAuthStep {\n\tPHONE = \"PHONE\",\n\tOTP = \"OTP\",\n\tEMAIL = \"EMAIL\",\n}\n\nexport enum CustomerAddressType {\n\tHOME = \"HOME\",\n\tWORK = \"WORK\",\n\tTRAVEL = \"TRAVEL\",\n}\n\nexport interface CustomerAddress {\n\tid?: number;\n\taddressId?: number; // Update address temporary\n\tcountryCode: string;\n\tcityName: string;\n\tstreet: string;\n\thouseNumber: string;\n\tadditionalNumber?: string;\n\tpostCode?: string;\n\tinstructions?: string;\n\tfloor?: number;\n\tlongitude?: number;\n\tlatitude?: number;\n\ttitle?: string;\n\ttype?: CustomerAddressType;\n}\n\nexport interface CustomerAuthForm {\n\tphoneNumber: string;\n\totp: string;\n\temail: string;\n}\n\nexport interface CustomerAuthPhoneForm {\n\tcountryCode: string;\n\tphoneNumber: string;\n}\n\nexport interface AuthResponse {\n\taccessToken: string;\n\trefreshToken: string;\n}\n\nexport interface Customer {\n\tid?: number;\n\temail: string;\n\tphoneNumber: string;\n\tfullName: string;\n\tsmsVerified?: boolean;\n\temailVerified?: boolean;\n\taddress?: CustomerAddress;\n\taddresses?: CustomerAddress[];\n}\n\nexport type CustomerUpdatePayload = Partial<Customer>;\n","export enum Feature {\n\tORDER = \"feature_order\",\n}\nexport enum FeatureSegment {\n\tALPHA = \"ALPHA\",\n\tBETA = \"BETA\",\n\tALL = \"ALL\",\n}\n","import * as customerModels from \"../customer/models\";\n\nexport enum OrderType {\n\tDINE_IN = \"DINE_IN\",\n\tPICK_UP = \"PICK_UP\",\n\tDELIVERY = \"DELIVERY\",\n}\n\nexport enum OrderStatus {\n\tDRAFT = \"DRAFT\",\n\tPENDING = \"PENDING\",\n\tCONFIRMED = \"CONFIRMED\",\n\tPREPARING = \"PREPARING\",\n\tREADY = \"READY\",\n\tOUT_FOR_DELIVERY = \"OUT_FOR_DELIVERY\",\n\tDELIVERED = \"DELIVERED\",\n\tCOMPLETED = \"COMPLETED\",\n\tCANCELLED = \"CANCELLED\",\n\tFAILED = \"FAILED\",\n}\n\nexport enum OrderItemStatus {\n\tPENDING = \"PENDING\",\n\tPREPARING = \"PREPARING\",\n\tREADY = \"READY\",\n\tSERVED = \"SERVED\",\n}\n\nexport enum PaymentMethod {\n\tCASH = \"CASH\",\n\tCARD = \"CARD\",\n\tWALLET = \"WALLET\",\n\tTERMINAL = \"TERMINAL\",\n}\n\nexport interface OrderAddonOption {\n\toptionId: number;\n\tprice: number;\n}\n\nexport interface OrderAddon {\n\tid?: number;\n\taddonId: number;\n\toptions: OrderAddonOption[];\n}\n\nexport interface SelectedAddons {\n\t[key: number]: number | number[];\n}\n\nexport interface OrderItemVariant {\n\tid?: number;\n\tvariantId: number;\n\tprice: number;\n}\n\nexport interface OrderItem {\n\tid?: number;\n\tproductId: number;\n\torderId?: number;\n\tquantity: number;\n\tprice: number;\n\tvariant?: OrderItemVariant;\n\taddons: OrderAddon[];\n\tnote?: string;\n\tstatus?: OrderItemStatus;\n\tvat?: number;\n\tisPaid?: boolean;\n}\n\nexport interface Order {\n\tid?: number;\n\tbusinessId?: number;\n\tbranchId?: number;\n\tworkingDayId?: number;\n\ttableId?: number;\n\temployeeId?: number;\n\torderType: OrderType;\n\ttotalPriceWithTax: number;\n\ttotalPriceWithoutTax: number;\n\ttotalTax: number;\n\titems: OrderItem[];\n\tstatus?: OrderStatus;\n\tvat?: number;\n\tpaymentMethod?: PaymentMethod;\n\tnote?: string;\n\tcreatedAt?: number;\n\tupdatedAt?: number;\n\tcustomer?: customerModels.Customer;\n}\n\nexport interface OrderItems {\n\t[key: string]: OrderItem;\n}\n\nexport enum OrderStep {\n\tCART = \"CART\",\n\tDETAILS = \"DETAILS\",\n\tCOMPLETED = \"COMPLETED\",\n}\n\nexport interface OrderPayload extends Order {\n\tcustomerAddressId: number;\n\tcustomerId: number;\n}\n","import { MenuAddon } from \"../addon/models\";\n\nexport interface ProductTranslation {\n\tid: number;\n\tname: string;\n\tdescription?: string;\n\tlanguage: string;\n\tproductId?: number;\n}\n\nexport interface ProductVariantTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface ProductVariant {\n\tid?: number;\n\tprice: number;\n\ttranslations: ProductVariantTranslation[];\n\tproductId?: number;\n\tremove?: boolean;\n}\n\nexport interface Product {\n\tid: number;\n\tcategoryId: number;\n\tvat?: number;\n\tprice: number;\n\tvolume?: string; // 100qr/250ml/1kq\n\timage160?: string;\n\timage580?: string;\n\timage1024?: string;\n\ttranslations: ProductTranslation[];\n\tvariants: ProductVariant[];\n\taddons: MenuAddon[];\n\tavailable?: boolean;\n\tvisible?: boolean;\n\tposition?: number;\n}\n\nexport enum ProductView {\n\tLIST = \"list\",\n\tGRID = \"grid\",\n}\n\nexport interface DashboardProduct extends Omit<Product, \"addons\"> {\n\taddons: number[];\n}\n","export enum PlanType {\n\tAPPETIZER = \"appetizer\",\n\tMAIN_COURSE = \"mainCourse\",\n\tCHEFS_SPECIAL = \"chefsSpecial\",\n\tLIFETIME = \"lifeTime\",\n}\n\nexport interface PricingPlan {\n\ttitle: string;\n\tprice: {\n\t\tmonthly: number;\n\t\tannually: number;\n\t};\n\tdiscountedPrice?: number;\n\tribbonText?: string;\n}\n\nexport interface PricingPlans {\n\t[key: string]: PricingPlan;\n}\n\nexport type PricingInterval = \"monthly\" | \"annually\";\n\nexport enum SubscriptionStatus {\n\tACTIVE = \"ACTIVE\",\n\tEXPIRED = \"EXPIRED\",\n\tCANCELLED = \"CANCELLED\",\n}\n\nexport type BillingInterval = \"MONTH\" | \"YEAR\";\n\nexport interface Subscription {\n\tid: number;\n\tbillingInterval: BillingInterval;\n\tbillingIntervalCount: number;\n\tstartDate: string;\n\tendDate: string;\n\tinterval: PricingInterval;\n\tstatus: SubscriptionStatus;\n\tbusiness_id?: number;\n\tplanName: string;\n}\n"],"names":["MenuAddonSelectType","BusinessSetting","CustomerAuthStep","CustomerAddressType","Feature","FeatureSegment","OrderType","OrderStatus","OrderItemStatus","PaymentMethod","OrderStep","ProductView","PlanType","SubscriptionStatus"],"mappings":"IAAYA,ECiBAC,ECjBAC,EAMAC,ECNAC,EAGAC,ECDAC,EAMAC,EAaAC,EAOAC,EAmEAC,ECtDAC,ECzCAC,EAuBAC,GNvBZ,SAAYb,GACXA,EAAA,OAAA,SACAA,EAAA,SAAA,UACA,CAHD,CAAYA,IAAAA,EAGX,CAAA,ICcD,SAAYC,GACXA,EAAA,sBAAA,sBACAA,EAAA,uBAAA,uBACAA,EAAA,qBAAA,qBACAA,EAAA,sBAAA,qBACAA,EAAA,oBAAA,mBACA,CAND,CAAYA,IAAAA,EAMX,CAAA,ICvBD,SAAYC,GACXA,EAAA,MAAA,QACAA,EAAA,IAAA,MACAA,EAAA,MAAA,OACA,CAJD,CAAYA,IAAAA,EAIX,CAAA,IAED,SAAYC,GACXA,EAAA,KAAA,OACAA,EAAA,KAAA,OACAA,EAAA,OAAA,QACA,CAJD,CAAYA,IAAAA,EAIX,CAAA,ICVD,SAAYC,GACXA,EAAA,MAAA,eACA,CAFD,CAAYA,IAAAA,EAEX,CAAA,IACD,SAAYC,GACXA,EAAA,MAAA,QACAA,EAAA,KAAA,OACAA,EAAA,IAAA,KACA,CAJD,CAAYA,IAAAA,EAIX,CAAA,ICLD,SAAYC,GACXA,EAAA,QAAA,UACAA,EAAA,QAAA,UACAA,EAAA,SAAA,UACA,CAJD,CAAYA,IAAAA,EAIX,CAAA,IAED,SAAYC,GACXA,EAAA,MAAA,QACAA,EAAA,QAAA,UACAA,EAAA,UAAA,YACAA,EAAA,UAAA,YACAA,EAAA,MAAA,QACAA,EAAA,iBAAA,mBACAA,EAAA,UAAA,YACAA,EAAA,UAAA,YACAA,EAAA,UAAA,YACAA,EAAA,OAAA,QACA,CAXD,CAAYA,IAAAA,EAWX,CAAA,IAED,SAAYC,GACXA,EAAA,QAAA,UACAA,EAAA,UAAA,YACAA,EAAA,MAAA,QACAA,EAAA,OAAA,QACA,CALD,CAAYA,IAAAA,EAKX,CAAA,IAED,SAAYC,GACXA,EAAA,KAAA,OACAA,EAAA,KAAA,OACAA,EAAA,OAAA,SACAA,EAAA,SAAA,UACA,CALD,CAAYA,IAAAA,EAKX,CAAA,IA8DD,SAAYC,GACXA,EAAA,KAAA,OACAA,EAAA,QAAA,UACAA,EAAA,UAAA,WACA,CAJD,CAAYA,IAAAA,EAIX,CAAA,IC1DD,SAAYC,GACXA,EAAA,KAAA,OACAA,EAAA,KAAA,MACA,CAHD,CAAYA,IAAAA,EAGX,CAAA,IC5CD,SAAYC,GACXA,EAAA,UAAA,YACAA,EAAA,YAAA,aACAA,EAAA,cAAA,eACAA,EAAA,SAAA,UACA,CALD,CAAYA,IAAAA,EAKX,CAAA,IAkBD,SAAYC,GACXA,EAAA,OAAA,SACAA,EAAA,QAAA,UACAA,EAAA,UAAA,WACA,CAJD,CAAYA,IAAAA,EAIX,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":["../../../src/modules/addon/models.ts","../../../src/modules/business/models.ts","../../../src/modules/customer/models.ts","../../../src/modules/feature/models.ts","../../../src/modules/order/models.ts","../../../src/modules/product/models.ts","../../../src/modules/subscription/models.ts","../../../src/modules/table/models.ts"],"sourcesContent":["export enum MenuAddonSelectType {\n\tSINGLE = \"SINGLE\",\n\tMULTIPLE = \"MULTIPLE\",\n}\n\nexport interface MenuAddonTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface MenuAddonOptionTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface MenuAddonOption {\n\tid?: number;\n\tprice: number;\n\ttranslations: MenuAddonOptionTranslation[];\n\tremove?: boolean;\n}\n\nexport interface MenuAddon {\n\tid?: number;\n\tselectType: MenuAddonSelectType;\n\ttranslations: MenuAddonTranslation[];\n\toptions: MenuAddonOption[];\n\tbusinessId?: number;\n}\n","import * as featureModels from \"../feature/models\";\nimport * as subscriptionModels from \"../subscription/models\";\n\nexport interface BusinessLanguage {\n\tid: number;\n\tcode: string;\n\tbusinessId: number;\n}\n\nexport interface BusinessSettings {\n\tdeliveryOrderEnabled: boolean;\n\tpickupOrderEnabled: boolean;\n\tdineInOrderEnabled: boolean;\n\tmaxDeliveryDistance: number;\n\tminDeliveryAmount: number;\n}\n\nexport enum BusinessSetting {\n\tMAX_DELIVERY_DISTANCE = \"maxDeliveryDistance\",\n\tDELIVERY_ORDER_ENABLED = \"deliveryOrderEnabled\",\n\tPICKUP_ORDER_ENABLED = \"pickupOrderEnabled\",\n\tDINE_IN_ORDER_ENABLED = \"dineInOrderEnabled\",\n\tMIN_DELIVERY_AMOUNT = \"minDeliveryAmount\",\n}\n\nexport interface Business {\n\tid: number;\n\tname: string;\n\tusername: string;\n\tavatar64?: string;\n\tavatar128?: string;\n\tavatar256?: string;\n\tcoverPhoto?: string;\n\tinstagram?: string;\n\tfacebook?: string;\n\ttiktok?: string;\n\tcreatedAt?: number;\n\tcurrency: string;\n\tlanguages: BusinessLanguage[];\n\tsubscriptions?: subscriptionModels.Subscription[];\n\tsegment?: featureModels.FeatureSegment;\n\tsettings?: BusinessSettings;\n}\n","export enum CustomerAuthStep {\n\tPHONE = \"PHONE\",\n\tOTP = \"OTP\",\n\tEMAIL = \"EMAIL\",\n}\n\nexport enum CustomerAddressType {\n\tHOME = \"HOME\",\n\tWORK = \"WORK\",\n\tTRAVEL = \"TRAVEL\",\n}\n\nexport interface CustomerAddress {\n\tid?: number;\n\taddressId?: number; // Update address temporary\n\tcountryCode: string;\n\tcityName: string;\n\tstreet: string;\n\thouseNumber: string;\n\tadditionalNumber?: string;\n\tpostCode?: string;\n\tinstructions?: string;\n\tfloor?: number;\n\tlongitude?: number;\n\tlatitude?: number;\n\ttitle?: string;\n\ttype?: CustomerAddressType;\n}\n\nexport interface CustomerAuthForm {\n\tphoneNumber: string;\n\totp: string;\n\temail: string;\n}\n\nexport interface CustomerAuthPhoneForm {\n\tcountryCode: string;\n\tphoneNumber: string;\n}\n\nexport interface AuthResponse {\n\taccessToken: string;\n\trefreshToken: string;\n}\n\nexport interface Customer {\n\tid?: number;\n\temail: string;\n\tphoneNumber: string;\n\tfullName: string;\n\tsmsVerified?: boolean;\n\temailVerified?: boolean;\n\taddress?: CustomerAddress;\n\taddresses?: CustomerAddress[];\n}\n\nexport type CustomerUpdatePayload = Partial<Customer>;\n","export enum Feature {\n\tORDER = \"feature_order\",\n}\nexport enum FeatureSegment {\n\tALPHA = \"ALPHA\",\n\tBETA = \"BETA\",\n\tALL = \"ALL\",\n}\n","import * as customerModels from \"../customer/models\";\n\nexport enum OrderType {\n\tDINE_IN = \"DINE_IN\",\n\tPICK_UP = \"PICK_UP\",\n\tDELIVERY = \"DELIVERY\",\n}\n\nexport enum OrderStatus {\n\tDRAFT = \"DRAFT\",\n\tPENDING = \"PENDING\",\n\tCONFIRMED = \"CONFIRMED\",\n\tPREPARING = \"PREPARING\",\n\tREADY = \"READY\",\n\tOUT_FOR_DELIVERY = \"OUT_FOR_DELIVERY\",\n\tDELIVERED = \"DELIVERED\",\n\tCOMPLETED = \"COMPLETED\",\n\tCANCELLED = \"CANCELLED\",\n\tFAILED = \"FAILED\",\n}\n\nexport enum OrderItemStatus {\n\tPENDING = \"PENDING\",\n\tPREPARING = \"PREPARING\",\n\tREADY = \"READY\",\n\tSERVED = \"SERVED\",\n}\n\nexport enum PaymentMethod {\n\tCASH = \"CASH\",\n\tCARD = \"CARD\",\n\tWALLET = \"WALLET\",\n\tTERMINAL = \"TERMINAL\",\n}\n\nexport interface OrderAddonOption {\n\toptionId: number;\n\tprice: number;\n}\n\nexport interface OrderAddon {\n\tid?: number;\n\taddonId: number;\n\toptions: OrderAddonOption[];\n}\n\nexport interface SelectedAddons {\n\t[key: number]: number | number[];\n}\n\nexport interface OrderItemVariant {\n\tid?: number;\n\tvariantId: number;\n\tprice: number;\n}\n\nexport interface OrderItem {\n\tid?: number;\n\tproductId: number;\n\torderId?: number;\n\tquantity: number;\n\tprice: number;\n\tvariant?: OrderItemVariant;\n\taddons: OrderAddon[];\n\tnote?: string;\n\tstatus?: OrderItemStatus;\n\tvat?: number;\n\tisPaid?: boolean;\n}\n\nexport interface Order {\n\tid?: number;\n\tbusinessId?: number;\n\tbranchId?: number;\n\tworkingDayId?: number;\n\ttableId?: number;\n\temployeeId?: number;\n\torderType: OrderType;\n\ttotalPriceWithTax: number;\n\ttotalPriceWithoutTax: number;\n\ttotalTax: number;\n\titems: OrderItem[];\n\tstatus?: OrderStatus;\n\tvat?: number;\n\tpaymentMethod?: PaymentMethod;\n\tnote?: string;\n\tcreatedAt?: number;\n\tupdatedAt?: number;\n\tcustomer?: customerModels.Customer;\n}\n\nexport interface OrderItems {\n\t[key: string]: OrderItem;\n}\n\nexport enum OrderStep {\n\tCART = \"CART\",\n\tDETAILS = \"DETAILS\",\n\tCOMPLETED = \"COMPLETED\",\n}\n\nexport interface OrderPayload extends Order {\n\tcustomerAddressId: number;\n\tcustomerId: number;\n}\n","import { MenuAddon } from \"../addon/models\";\n\nexport interface ProductTranslation {\n\tid: number;\n\tname: string;\n\tdescription?: string;\n\tlanguage: string;\n\tproductId?: number;\n}\n\nexport interface ProductVariantTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface ProductVariant {\n\tid?: number;\n\tprice: number;\n\ttranslations: ProductVariantTranslation[];\n\tproductId?: number;\n\tremove?: boolean;\n}\n\nexport interface Product {\n\tid: number;\n\tcategoryId: number;\n\tvat?: number;\n\tprice: number;\n\tvolume?: string; // 100qr/250ml/1kq\n\timage160?: string;\n\timage580?: string;\n\timage1024?: string;\n\ttranslations: ProductTranslation[];\n\tvariants: ProductVariant[];\n\taddons: MenuAddon[];\n\tavailable?: boolean;\n\tvisible?: boolean;\n\tposition?: number;\n}\n\nexport enum ProductView {\n\tLIST = \"list\",\n\tGRID = \"grid\",\n}\n\nexport interface DashboardProduct extends Omit<Product, \"addons\"> {\n\taddons: number[];\n}\n","export enum PlanType {\n\tAPPETIZER = \"appetizer\",\n\tMAIN_COURSE = \"mainCourse\",\n\tCHEFS_SPECIAL = \"chefsSpecial\",\n\tLIFETIME = \"lifeTime\",\n}\n\nexport interface PricingPlan {\n\ttitle: string;\n\tprice: {\n\t\tmonthly: number;\n\t\tannually: number;\n\t};\n\tdiscountedPrice?: number;\n\tribbonText?: string;\n}\n\nexport interface PricingPlans {\n\t[key: string]: PricingPlan;\n}\n\nexport type PricingInterval = \"monthly\" | \"annually\";\n\nexport enum SubscriptionStatus {\n\tACTIVE = \"ACTIVE\",\n\tEXPIRED = \"EXPIRED\",\n\tCANCELLED = \"CANCELLED\",\n}\n\nexport type BillingInterval = \"MONTH\" | \"YEAR\";\n\nexport interface Subscription {\n\tid: number;\n\tbillingInterval: BillingInterval;\n\tbillingIntervalCount: number;\n\tstartDate: string;\n\tendDate: string;\n\tinterval: PricingInterval;\n\tstatus: SubscriptionStatus;\n\tbusiness_id?: number;\n\tplanName: string;\n}\n","export enum TableShape {\n\tSQUARE = \"SQUARE\",\n\tCIRCLE = \"CIRCLE\",\n\tRECTANGLE = \"RECTANGLE\",\n\tRECTANGLE_VERTICAL = \"RECTANGLE_VERTICAL\",\n\tSINGLE_AT_BAR = \"SINGLE_AT_BAR\",\n\tOTHER = \"OTHER\",\n}\n\nexport enum TableStatus {\n\tVACANT = \"VACANT\", // Free and available\n\tRESERVED = \"RESERVED\", // Booked but not yet seated\n\tOCCUPIED = \"OCCUPIED\", // Currently in use\n\tBLOCKED = \"BLOCKED\", // Temporarily blocked/unavailable\n\tNEEDS_CLEANING = \"NEEDS_CLEANING\", // Dirty, awaiting cleanup\n\tOUT_OF_SERVICE = \"OUT_OF_SERVICE\", // Permanently unavailable repair/maintenance\n\tPENDING_CONFIRMATION = \"PENDING_CONFIRMATION\", // Reservation not yet confirmed\n\tNO_SHOW = \"NO_SHOW\", // Reserved but guest didn’t arrive\n}\n\nexport enum TableLocation {\n\t// Indoor\n\tMAIN_HALL = \"MAIN_HALL\",\n\tPRIVATE_DINING = \"PRIVATE_DINING\",\n\tVIP_ROOM = \"VIP_ROOM\",\n\tBANQUET_HALL = \"BANQUET_HALL\",\n\tBAR_AREA = \"BAR_AREA\",\n\tLOUNGE = \"LOUNGE\",\n\tOPEN_KITCHEN = \"OPEN_KITCHEN\",\n\tBOOTH_SECTION = \"BOOTH_SECTION\",\n\tMEZZANINE = \"MEZZANINE\",\n\tWINE_CELLAR = \"WINE_CELLAR\",\n\n\t// Outdoor\n\tTERRACE = \"TERRACE\",\n\tPATIO = \"PATIO\",\n\tGARDEN = \"GARDEN\",\n\tCOURTYARD = \"COURTYARD\",\n\tROOFTOP = \"ROOFTOP\",\n\tBALCONY = \"BALCONY\",\n\tSIDEWALK = \"SIDEWALK\",\n\tPOOLSIDE = \"POOLSIDE\",\n\n\t// Special Sections\n\tSMOKING_AREA = \"SMOKING_AREA\",\n\tNON_SMOKING = \"NON_SMOKING\",\n\tFAMILY_SECTION = \"FAMILY_SECTION\",\n\tKIDS_AREA = \"KIDS_AREA\",\n\tWAITING_AREA = \"WAITING_AREA\",\n\tDANCE_FLOOR = \"DANCE_FLOOR\",\n}\n\nexport interface Table {\n\tid: number;\n\tbusinessId: number;\n\tbranchId: number;\n\tname: string;\n\tseatCount: number;\n\tshape: TableShape;\n\tlocation: TableLocation;\n\tstatus: TableStatus;\n}\n\nexport interface TableState {\n\ttables: Table[];\n}\n\nexport type TableForm = Omit<Table, \"id\" | \"businessId\" | \"branchId\"> & {\n\tbranchId: string | number;\n};\n\nexport type TableUpdate = Partial<Omit<Table, \"id\" | \"businessId\">>;\n\nexport type TableFilter = Partial<Pick<Table, \"branchId\" | \"shape\" | \"location\" | \"status\">>;\n\nexport type TableFilterParams = { field: keyof TableFilter; value: TableFilter[keyof TableFilter] };\n"],"names":["MenuAddonSelectType","BusinessSetting","CustomerAuthStep","CustomerAddressType","Feature","FeatureSegment","OrderType","OrderStatus","OrderItemStatus","PaymentMethod","OrderStep","ProductView","PlanType","SubscriptionStatus","TableShape","TableStatus","TableLocation"],"mappings":"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"}
|
package/dist/models/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var e,t,
|
|
1
|
+
"use strict";var E,e,t,A,r,I,R,N,O,o,L,s,T,p,D,C;exports.MenuAddonSelectType=void 0,(E=exports.MenuAddonSelectType||(exports.MenuAddonSelectType={})).SINGLE="SINGLE",E.MULTIPLE="MULTIPLE",exports.BusinessSetting=void 0,(e=exports.BusinessSetting||(exports.BusinessSetting={})).MAX_DELIVERY_DISTANCE="maxDeliveryDistance",e.DELIVERY_ORDER_ENABLED="deliveryOrderEnabled",e.PICKUP_ORDER_ENABLED="pickupOrderEnabled",e.DINE_IN_ORDER_ENABLED="dineInOrderEnabled",e.MIN_DELIVERY_AMOUNT="minDeliveryAmount",exports.CustomerAuthStep=void 0,(t=exports.CustomerAuthStep||(exports.CustomerAuthStep={})).PHONE="PHONE",t.OTP="OTP",t.EMAIL="EMAIL",exports.CustomerAddressType=void 0,(A=exports.CustomerAddressType||(exports.CustomerAddressType={})).HOME="HOME",A.WORK="WORK",A.TRAVEL="TRAVEL",exports.Feature=void 0,(exports.Feature||(exports.Feature={})).ORDER="feature_order",exports.FeatureSegment=void 0,(r=exports.FeatureSegment||(exports.FeatureSegment={})).ALPHA="ALPHA",r.BETA="BETA",r.ALL="ALL",exports.OrderType=void 0,(I=exports.OrderType||(exports.OrderType={})).DINE_IN="DINE_IN",I.PICK_UP="PICK_UP",I.DELIVERY="DELIVERY",exports.OrderStatus=void 0,(R=exports.OrderStatus||(exports.OrderStatus={})).DRAFT="DRAFT",R.PENDING="PENDING",R.CONFIRMED="CONFIRMED",R.PREPARING="PREPARING",R.READY="READY",R.OUT_FOR_DELIVERY="OUT_FOR_DELIVERY",R.DELIVERED="DELIVERED",R.COMPLETED="COMPLETED",R.CANCELLED="CANCELLED",R.FAILED="FAILED",exports.OrderItemStatus=void 0,(N=exports.OrderItemStatus||(exports.OrderItemStatus={})).PENDING="PENDING",N.PREPARING="PREPARING",N.READY="READY",N.SERVED="SERVED",exports.PaymentMethod=void 0,(O=exports.PaymentMethod||(exports.PaymentMethod={})).CASH="CASH",O.CARD="CARD",O.WALLET="WALLET",O.TERMINAL="TERMINAL",exports.OrderStep=void 0,(o=exports.OrderStep||(exports.OrderStep={})).CART="CART",o.DETAILS="DETAILS",o.COMPLETED="COMPLETED",exports.ProductView=void 0,(L=exports.ProductView||(exports.ProductView={})).LIST="list",L.GRID="grid",exports.PlanType=void 0,(s=exports.PlanType||(exports.PlanType={})).APPETIZER="appetizer",s.MAIN_COURSE="mainCourse",s.CHEFS_SPECIAL="chefsSpecial",s.LIFETIME="lifeTime",exports.SubscriptionStatus=void 0,(T=exports.SubscriptionStatus||(exports.SubscriptionStatus={})).ACTIVE="ACTIVE",T.EXPIRED="EXPIRED",T.CANCELLED="CANCELLED",exports.TableShape=void 0,(p=exports.TableShape||(exports.TableShape={})).SQUARE="SQUARE",p.CIRCLE="CIRCLE",p.RECTANGLE="RECTANGLE",p.RECTANGLE_VERTICAL="RECTANGLE_VERTICAL",p.SINGLE_AT_BAR="SINGLE_AT_BAR",p.OTHER="OTHER",exports.TableStatus=void 0,(D=exports.TableStatus||(exports.TableStatus={})).VACANT="VACANT",D.RESERVED="RESERVED",D.OCCUPIED="OCCUPIED",D.BLOCKED="BLOCKED",D.NEEDS_CLEANING="NEEDS_CLEANING",D.OUT_OF_SERVICE="OUT_OF_SERVICE",D.PENDING_CONFIRMATION="PENDING_CONFIRMATION",D.NO_SHOW="NO_SHOW",exports.TableLocation=void 0,(C=exports.TableLocation||(exports.TableLocation={})).MAIN_HALL="MAIN_HALL",C.PRIVATE_DINING="PRIVATE_DINING",C.VIP_ROOM="VIP_ROOM",C.BANQUET_HALL="BANQUET_HALL",C.BAR_AREA="BAR_AREA",C.LOUNGE="LOUNGE",C.OPEN_KITCHEN="OPEN_KITCHEN",C.BOOTH_SECTION="BOOTH_SECTION",C.MEZZANINE="MEZZANINE",C.WINE_CELLAR="WINE_CELLAR",C.TERRACE="TERRACE",C.PATIO="PATIO",C.GARDEN="GARDEN",C.COURTYARD="COURTYARD",C.ROOFTOP="ROOFTOP",C.BALCONY="BALCONY",C.SIDEWALK="SIDEWALK",C.POOLSIDE="POOLSIDE",C.SMOKING_AREA="SMOKING_AREA",C.NON_SMOKING="NON_SMOKING",C.FAMILY_SECTION="FAMILY_SECTION",C.KIDS_AREA="KIDS_AREA",C.WAITING_AREA="WAITING_AREA",C.DANCE_FLOOR="DANCE_FLOOR";
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/models/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/modules/addon/models.ts","../../../src/modules/business/models.ts","../../../src/modules/customer/models.ts","../../../src/modules/feature/models.ts","../../../src/modules/order/models.ts","../../../src/modules/product/models.ts","../../../src/modules/subscription/models.ts"],"sourcesContent":["export enum MenuAddonSelectType {\n\tSINGLE = \"SINGLE\",\n\tMULTIPLE = \"MULTIPLE\",\n}\n\nexport interface MenuAddonTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface MenuAddonOptionTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface MenuAddonOption {\n\tid?: number;\n\tprice: number;\n\ttranslations: MenuAddonOptionTranslation[];\n\tremove?: boolean;\n}\n\nexport interface MenuAddon {\n\tid?: number;\n\tselectType: MenuAddonSelectType;\n\ttranslations: MenuAddonTranslation[];\n\toptions: MenuAddonOption[];\n\tbusinessId?: number;\n}\n","import * as featureModels from \"../feature/models\";\nimport * as subscriptionModels from \"../subscription/models\";\n\nexport interface BusinessLanguage {\n\tid: number;\n\tcode: string;\n\tbusinessId: number;\n}\n\nexport interface BusinessSettings {\n\tdeliveryOrderEnabled: boolean;\n\tpickupOrderEnabled: boolean;\n\tdineInOrderEnabled: boolean;\n\tmaxDeliveryDistance: number;\n\tminDeliveryAmount: number;\n}\n\nexport enum BusinessSetting {\n\tMAX_DELIVERY_DISTANCE = \"maxDeliveryDistance\",\n\tDELIVERY_ORDER_ENABLED = \"deliveryOrderEnabled\",\n\tPICKUP_ORDER_ENABLED = \"pickupOrderEnabled\",\n\tDINE_IN_ORDER_ENABLED = \"dineInOrderEnabled\",\n\tMIN_DELIVERY_AMOUNT = \"minDeliveryAmount\",\n}\n\nexport interface Business {\n\tid: number;\n\tname: string;\n\tusername: string;\n\tavatar64?: string;\n\tavatar128?: string;\n\tavatar256?: string;\n\tcoverPhoto?: string;\n\tinstagram?: string;\n\tfacebook?: string;\n\ttiktok?: string;\n\tcreatedAt?: number;\n\tcurrency: string;\n\tlanguages: BusinessLanguage[];\n\tsubscriptions?: subscriptionModels.Subscription[];\n\tsegment?: featureModels.FeatureSegment;\n\tsettings?: BusinessSettings;\n}\n","export enum CustomerAuthStep {\n\tPHONE = \"PHONE\",\n\tOTP = \"OTP\",\n\tEMAIL = \"EMAIL\",\n}\n\nexport enum CustomerAddressType {\n\tHOME = \"HOME\",\n\tWORK = \"WORK\",\n\tTRAVEL = \"TRAVEL\",\n}\n\nexport interface CustomerAddress {\n\tid?: number;\n\taddressId?: number; // Update address temporary\n\tcountryCode: string;\n\tcityName: string;\n\tstreet: string;\n\thouseNumber: string;\n\tadditionalNumber?: string;\n\tpostCode?: string;\n\tinstructions?: string;\n\tfloor?: number;\n\tlongitude?: number;\n\tlatitude?: number;\n\ttitle?: string;\n\ttype?: CustomerAddressType;\n}\n\nexport interface CustomerAuthForm {\n\tphoneNumber: string;\n\totp: string;\n\temail: string;\n}\n\nexport interface CustomerAuthPhoneForm {\n\tcountryCode: string;\n\tphoneNumber: string;\n}\n\nexport interface AuthResponse {\n\taccessToken: string;\n\trefreshToken: string;\n}\n\nexport interface Customer {\n\tid?: number;\n\temail: string;\n\tphoneNumber: string;\n\tfullName: string;\n\tsmsVerified?: boolean;\n\temailVerified?: boolean;\n\taddress?: CustomerAddress;\n\taddresses?: CustomerAddress[];\n}\n\nexport type CustomerUpdatePayload = Partial<Customer>;\n","export enum Feature {\n\tORDER = \"feature_order\",\n}\nexport enum FeatureSegment {\n\tALPHA = \"ALPHA\",\n\tBETA = \"BETA\",\n\tALL = \"ALL\",\n}\n","import * as customerModels from \"../customer/models\";\n\nexport enum OrderType {\n\tDINE_IN = \"DINE_IN\",\n\tPICK_UP = \"PICK_UP\",\n\tDELIVERY = \"DELIVERY\",\n}\n\nexport enum OrderStatus {\n\tDRAFT = \"DRAFT\",\n\tPENDING = \"PENDING\",\n\tCONFIRMED = \"CONFIRMED\",\n\tPREPARING = \"PREPARING\",\n\tREADY = \"READY\",\n\tOUT_FOR_DELIVERY = \"OUT_FOR_DELIVERY\",\n\tDELIVERED = \"DELIVERED\",\n\tCOMPLETED = \"COMPLETED\",\n\tCANCELLED = \"CANCELLED\",\n\tFAILED = \"FAILED\",\n}\n\nexport enum OrderItemStatus {\n\tPENDING = \"PENDING\",\n\tPREPARING = \"PREPARING\",\n\tREADY = \"READY\",\n\tSERVED = \"SERVED\",\n}\n\nexport enum PaymentMethod {\n\tCASH = \"CASH\",\n\tCARD = \"CARD\",\n\tWALLET = \"WALLET\",\n\tTERMINAL = \"TERMINAL\",\n}\n\nexport interface OrderAddonOption {\n\toptionId: number;\n\tprice: number;\n}\n\nexport interface OrderAddon {\n\tid?: number;\n\taddonId: number;\n\toptions: OrderAddonOption[];\n}\n\nexport interface SelectedAddons {\n\t[key: number]: number | number[];\n}\n\nexport interface OrderItemVariant {\n\tid?: number;\n\tvariantId: number;\n\tprice: number;\n}\n\nexport interface OrderItem {\n\tid?: number;\n\tproductId: number;\n\torderId?: number;\n\tquantity: number;\n\tprice: number;\n\tvariant?: OrderItemVariant;\n\taddons: OrderAddon[];\n\tnote?: string;\n\tstatus?: OrderItemStatus;\n\tvat?: number;\n\tisPaid?: boolean;\n}\n\nexport interface Order {\n\tid?: number;\n\tbusinessId?: number;\n\tbranchId?: number;\n\tworkingDayId?: number;\n\ttableId?: number;\n\temployeeId?: number;\n\torderType: OrderType;\n\ttotalPriceWithTax: number;\n\ttotalPriceWithoutTax: number;\n\ttotalTax: number;\n\titems: OrderItem[];\n\tstatus?: OrderStatus;\n\tvat?: number;\n\tpaymentMethod?: PaymentMethod;\n\tnote?: string;\n\tcreatedAt?: number;\n\tupdatedAt?: number;\n\tcustomer?: customerModels.Customer;\n}\n\nexport interface OrderItems {\n\t[key: string]: OrderItem;\n}\n\nexport enum OrderStep {\n\tCART = \"CART\",\n\tDETAILS = \"DETAILS\",\n\tCOMPLETED = \"COMPLETED\",\n}\n\nexport interface OrderPayload extends Order {\n\tcustomerAddressId: number;\n\tcustomerId: number;\n}\n","import { MenuAddon } from \"../addon/models\";\n\nexport interface ProductTranslation {\n\tid: number;\n\tname: string;\n\tdescription?: string;\n\tlanguage: string;\n\tproductId?: number;\n}\n\nexport interface ProductVariantTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface ProductVariant {\n\tid?: number;\n\tprice: number;\n\ttranslations: ProductVariantTranslation[];\n\tproductId?: number;\n\tremove?: boolean;\n}\n\nexport interface Product {\n\tid: number;\n\tcategoryId: number;\n\tvat?: number;\n\tprice: number;\n\tvolume?: string; // 100qr/250ml/1kq\n\timage160?: string;\n\timage580?: string;\n\timage1024?: string;\n\ttranslations: ProductTranslation[];\n\tvariants: ProductVariant[];\n\taddons: MenuAddon[];\n\tavailable?: boolean;\n\tvisible?: boolean;\n\tposition?: number;\n}\n\nexport enum ProductView {\n\tLIST = \"list\",\n\tGRID = \"grid\",\n}\n\nexport interface DashboardProduct extends Omit<Product, \"addons\"> {\n\taddons: number[];\n}\n","export enum PlanType {\n\tAPPETIZER = \"appetizer\",\n\tMAIN_COURSE = \"mainCourse\",\n\tCHEFS_SPECIAL = \"chefsSpecial\",\n\tLIFETIME = \"lifeTime\",\n}\n\nexport interface PricingPlan {\n\ttitle: string;\n\tprice: {\n\t\tmonthly: number;\n\t\tannually: number;\n\t};\n\tdiscountedPrice?: number;\n\tribbonText?: string;\n}\n\nexport interface PricingPlans {\n\t[key: string]: PricingPlan;\n}\n\nexport type PricingInterval = \"monthly\" | \"annually\";\n\nexport enum SubscriptionStatus {\n\tACTIVE = \"ACTIVE\",\n\tEXPIRED = \"EXPIRED\",\n\tCANCELLED = \"CANCELLED\",\n}\n\nexport type BillingInterval = \"MONTH\" | \"YEAR\";\n\nexport interface Subscription {\n\tid: number;\n\tbillingInterval: BillingInterval;\n\tbillingIntervalCount: number;\n\tstartDate: string;\n\tendDate: string;\n\tinterval: PricingInterval;\n\tstatus: SubscriptionStatus;\n\tbusiness_id?: number;\n\tplanName: string;\n}\n"],"names":["MenuAddonSelectType","BusinessSetting","CustomerAuthStep","CustomerAddressType","FeatureSegment","OrderType","OrderStatus","OrderItemStatus","PaymentMethod","OrderStep","ProductView","PlanType","SubscriptionStatus","Feature"],"mappings":"aAAA,IAAYA,ECiBAC,ECjBAC,EAMAC,ECHAC,ECDAC,EAMAC,EAaAC,EAOAC,EAmEAC,ECtDAC,ECzCAC,EAuBAC,ENvBAZ,QAAAA,yBAAAA,GAAAA,EAAAA,QAAmBA,sBAAnBA,4BAGX,CAAA,IAFA,OAAA,SACAA,EAAA,SAAA,WCeWC,QAAAA,qBAAAA,GAAAA,EAAAA,QAAeA,kBAAfA,wBAMX,CAAA,IALA,sBAAA,sBACAA,EAAA,uBAAA,uBACAA,EAAA,qBAAA,qBACAA,EAAA,sBAAA,qBACAA,EAAA,oBAAA,oBCtBWC,QAAAA,sBAAAA,GAAAA,EAAAA,QAAgBA,mBAAhBA,yBAIX,CAAA,IAHA,MAAA,QACAA,EAAA,IAAA,MACAA,EAAA,MAAA,QAGWC,QAAAA,yBAAAA,GAAAA,EAAAA,QAAmBA,sBAAnBA,4BAIX,CAAA,IAHA,KAAA,OACAA,EAAA,KAAA,OACAA,EAAA,OAAA,SCTWU,QAAAA,aAAAA,GAAAA,QAAOA,UAAPA,gBAEX,CAAA,IADA,MAAA,gBAEWT,QAAAA,oBAAAA,GAAAA,EAAAA,QAAcA,iBAAdA,uBAIX,CAAA,IAHA,MAAA,QACAA,EAAA,KAAA,OACAA,EAAA,IAAA,MCJWC,QAAAA,eAAAA,GAAAA,EAAAA,QAASA,YAATA,kBAIX,CAAA,IAHA,QAAA,UACAA,EAAA,QAAA,UACAA,EAAA,SAAA,WAGWC,QAAAA,iBAAAA,GAAAA,EAAAA,QAAWA,cAAXA,oBAWX,CAAA,IAVA,MAAA,QACAA,EAAA,QAAA,UACAA,EAAA,UAAA,YACAA,EAAA,UAAA,YACAA,EAAA,MAAA,QACAA,EAAA,iBAAA,mBACAA,EAAA,UAAA,YACAA,EAAA,UAAA,YACAA,EAAA,UAAA,YACAA,EAAA,OAAA,SAGWC,QAAAA,qBAAAA,GAAAA,EAAAA,QAAeA,kBAAfA,wBAKX,CAAA,IAJA,QAAA,UACAA,EAAA,UAAA,YACAA,EAAA,MAAA,QACAA,EAAA,OAAA,SAGWC,QAAAA,mBAAAA,GAAAA,EAAAA,QAAaA,gBAAbA,sBAKX,CAAA,IAJA,KAAA,OACAA,EAAA,KAAA,OACAA,EAAA,OAAA,SACAA,EAAA,SAAA,WA+DWC,QAAAA,eAAAA,GAAAA,EAAAA,QAASA,YAATA,kBAIX,CAAA,IAHA,KAAA,OACAA,EAAA,QAAA,UACAA,EAAA,UAAA,YCzDWC,QAAAA,iBAAAA,GAAAA,EAAAA,QAAWA,cAAXA,oBAGX,CAAA,IAFA,KAAA,OACAA,EAAA,KAAA,OC3CWC,QAAAA,cAAAA,GAAAA,EAAAA,QAAQA,WAARA,iBAKX,CAAA,IAJA,UAAA,YACAA,EAAA,YAAA,aACAA,EAAA,cAAA,eACAA,EAAA,SAAA,WAmBWC,QAAAA,wBAAAA,GAAAA,EAAAA,QAAkBA,qBAAlBA,2BAIX,CAAA,IAHA,OAAA,SACAA,EAAA,QAAA,UACAA,EAAA,UAAA"}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/modules/addon/models.ts","../../../src/modules/business/models.ts","../../../src/modules/customer/models.ts","../../../src/modules/feature/models.ts","../../../src/modules/order/models.ts","../../../src/modules/product/models.ts","../../../src/modules/subscription/models.ts","../../../src/modules/table/models.ts"],"sourcesContent":["export enum MenuAddonSelectType {\n\tSINGLE = \"SINGLE\",\n\tMULTIPLE = \"MULTIPLE\",\n}\n\nexport interface MenuAddonTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface MenuAddonOptionTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface MenuAddonOption {\n\tid?: number;\n\tprice: number;\n\ttranslations: MenuAddonOptionTranslation[];\n\tremove?: boolean;\n}\n\nexport interface MenuAddon {\n\tid?: number;\n\tselectType: MenuAddonSelectType;\n\ttranslations: MenuAddonTranslation[];\n\toptions: MenuAddonOption[];\n\tbusinessId?: number;\n}\n","import * as featureModels from \"../feature/models\";\nimport * as subscriptionModels from \"../subscription/models\";\n\nexport interface BusinessLanguage {\n\tid: number;\n\tcode: string;\n\tbusinessId: number;\n}\n\nexport interface BusinessSettings {\n\tdeliveryOrderEnabled: boolean;\n\tpickupOrderEnabled: boolean;\n\tdineInOrderEnabled: boolean;\n\tmaxDeliveryDistance: number;\n\tminDeliveryAmount: number;\n}\n\nexport enum BusinessSetting {\n\tMAX_DELIVERY_DISTANCE = \"maxDeliveryDistance\",\n\tDELIVERY_ORDER_ENABLED = \"deliveryOrderEnabled\",\n\tPICKUP_ORDER_ENABLED = \"pickupOrderEnabled\",\n\tDINE_IN_ORDER_ENABLED = \"dineInOrderEnabled\",\n\tMIN_DELIVERY_AMOUNT = \"minDeliveryAmount\",\n}\n\nexport interface Business {\n\tid: number;\n\tname: string;\n\tusername: string;\n\tavatar64?: string;\n\tavatar128?: string;\n\tavatar256?: string;\n\tcoverPhoto?: string;\n\tinstagram?: string;\n\tfacebook?: string;\n\ttiktok?: string;\n\tcreatedAt?: number;\n\tcurrency: string;\n\tlanguages: BusinessLanguage[];\n\tsubscriptions?: subscriptionModels.Subscription[];\n\tsegment?: featureModels.FeatureSegment;\n\tsettings?: BusinessSettings;\n}\n","export enum CustomerAuthStep {\n\tPHONE = \"PHONE\",\n\tOTP = \"OTP\",\n\tEMAIL = \"EMAIL\",\n}\n\nexport enum CustomerAddressType {\n\tHOME = \"HOME\",\n\tWORK = \"WORK\",\n\tTRAVEL = \"TRAVEL\",\n}\n\nexport interface CustomerAddress {\n\tid?: number;\n\taddressId?: number; // Update address temporary\n\tcountryCode: string;\n\tcityName: string;\n\tstreet: string;\n\thouseNumber: string;\n\tadditionalNumber?: string;\n\tpostCode?: string;\n\tinstructions?: string;\n\tfloor?: number;\n\tlongitude?: number;\n\tlatitude?: number;\n\ttitle?: string;\n\ttype?: CustomerAddressType;\n}\n\nexport interface CustomerAuthForm {\n\tphoneNumber: string;\n\totp: string;\n\temail: string;\n}\n\nexport interface CustomerAuthPhoneForm {\n\tcountryCode: string;\n\tphoneNumber: string;\n}\n\nexport interface AuthResponse {\n\taccessToken: string;\n\trefreshToken: string;\n}\n\nexport interface Customer {\n\tid?: number;\n\temail: string;\n\tphoneNumber: string;\n\tfullName: string;\n\tsmsVerified?: boolean;\n\temailVerified?: boolean;\n\taddress?: CustomerAddress;\n\taddresses?: CustomerAddress[];\n}\n\nexport type CustomerUpdatePayload = Partial<Customer>;\n","export enum Feature {\n\tORDER = \"feature_order\",\n}\nexport enum FeatureSegment {\n\tALPHA = \"ALPHA\",\n\tBETA = \"BETA\",\n\tALL = \"ALL\",\n}\n","import * as customerModels from \"../customer/models\";\n\nexport enum OrderType {\n\tDINE_IN = \"DINE_IN\",\n\tPICK_UP = \"PICK_UP\",\n\tDELIVERY = \"DELIVERY\",\n}\n\nexport enum OrderStatus {\n\tDRAFT = \"DRAFT\",\n\tPENDING = \"PENDING\",\n\tCONFIRMED = \"CONFIRMED\",\n\tPREPARING = \"PREPARING\",\n\tREADY = \"READY\",\n\tOUT_FOR_DELIVERY = \"OUT_FOR_DELIVERY\",\n\tDELIVERED = \"DELIVERED\",\n\tCOMPLETED = \"COMPLETED\",\n\tCANCELLED = \"CANCELLED\",\n\tFAILED = \"FAILED\",\n}\n\nexport enum OrderItemStatus {\n\tPENDING = \"PENDING\",\n\tPREPARING = \"PREPARING\",\n\tREADY = \"READY\",\n\tSERVED = \"SERVED\",\n}\n\nexport enum PaymentMethod {\n\tCASH = \"CASH\",\n\tCARD = \"CARD\",\n\tWALLET = \"WALLET\",\n\tTERMINAL = \"TERMINAL\",\n}\n\nexport interface OrderAddonOption {\n\toptionId: number;\n\tprice: number;\n}\n\nexport interface OrderAddon {\n\tid?: number;\n\taddonId: number;\n\toptions: OrderAddonOption[];\n}\n\nexport interface SelectedAddons {\n\t[key: number]: number | number[];\n}\n\nexport interface OrderItemVariant {\n\tid?: number;\n\tvariantId: number;\n\tprice: number;\n}\n\nexport interface OrderItem {\n\tid?: number;\n\tproductId: number;\n\torderId?: number;\n\tquantity: number;\n\tprice: number;\n\tvariant?: OrderItemVariant;\n\taddons: OrderAddon[];\n\tnote?: string;\n\tstatus?: OrderItemStatus;\n\tvat?: number;\n\tisPaid?: boolean;\n}\n\nexport interface Order {\n\tid?: number;\n\tbusinessId?: number;\n\tbranchId?: number;\n\tworkingDayId?: number;\n\ttableId?: number;\n\temployeeId?: number;\n\torderType: OrderType;\n\ttotalPriceWithTax: number;\n\ttotalPriceWithoutTax: number;\n\ttotalTax: number;\n\titems: OrderItem[];\n\tstatus?: OrderStatus;\n\tvat?: number;\n\tpaymentMethod?: PaymentMethod;\n\tnote?: string;\n\tcreatedAt?: number;\n\tupdatedAt?: number;\n\tcustomer?: customerModels.Customer;\n}\n\nexport interface OrderItems {\n\t[key: string]: OrderItem;\n}\n\nexport enum OrderStep {\n\tCART = \"CART\",\n\tDETAILS = \"DETAILS\",\n\tCOMPLETED = \"COMPLETED\",\n}\n\nexport interface OrderPayload extends Order {\n\tcustomerAddressId: number;\n\tcustomerId: number;\n}\n","import { MenuAddon } from \"../addon/models\";\n\nexport interface ProductTranslation {\n\tid: number;\n\tname: string;\n\tdescription?: string;\n\tlanguage: string;\n\tproductId?: number;\n}\n\nexport interface ProductVariantTranslation {\n\tid?: number;\n\ttitle: string;\n\tlanguage: string;\n}\n\nexport interface ProductVariant {\n\tid?: number;\n\tprice: number;\n\ttranslations: ProductVariantTranslation[];\n\tproductId?: number;\n\tremove?: boolean;\n}\n\nexport interface Product {\n\tid: number;\n\tcategoryId: number;\n\tvat?: number;\n\tprice: number;\n\tvolume?: string; // 100qr/250ml/1kq\n\timage160?: string;\n\timage580?: string;\n\timage1024?: string;\n\ttranslations: ProductTranslation[];\n\tvariants: ProductVariant[];\n\taddons: MenuAddon[];\n\tavailable?: boolean;\n\tvisible?: boolean;\n\tposition?: number;\n}\n\nexport enum ProductView {\n\tLIST = \"list\",\n\tGRID = \"grid\",\n}\n\nexport interface DashboardProduct extends Omit<Product, \"addons\"> {\n\taddons: number[];\n}\n","export enum PlanType {\n\tAPPETIZER = \"appetizer\",\n\tMAIN_COURSE = \"mainCourse\",\n\tCHEFS_SPECIAL = \"chefsSpecial\",\n\tLIFETIME = \"lifeTime\",\n}\n\nexport interface PricingPlan {\n\ttitle: string;\n\tprice: {\n\t\tmonthly: number;\n\t\tannually: number;\n\t};\n\tdiscountedPrice?: number;\n\tribbonText?: string;\n}\n\nexport interface PricingPlans {\n\t[key: string]: PricingPlan;\n}\n\nexport type PricingInterval = \"monthly\" | \"annually\";\n\nexport enum SubscriptionStatus {\n\tACTIVE = \"ACTIVE\",\n\tEXPIRED = \"EXPIRED\",\n\tCANCELLED = \"CANCELLED\",\n}\n\nexport type BillingInterval = \"MONTH\" | \"YEAR\";\n\nexport interface Subscription {\n\tid: number;\n\tbillingInterval: BillingInterval;\n\tbillingIntervalCount: number;\n\tstartDate: string;\n\tendDate: string;\n\tinterval: PricingInterval;\n\tstatus: SubscriptionStatus;\n\tbusiness_id?: number;\n\tplanName: string;\n}\n","export enum TableShape {\n\tSQUARE = \"SQUARE\",\n\tCIRCLE = \"CIRCLE\",\n\tRECTANGLE = \"RECTANGLE\",\n\tRECTANGLE_VERTICAL = \"RECTANGLE_VERTICAL\",\n\tSINGLE_AT_BAR = \"SINGLE_AT_BAR\",\n\tOTHER = \"OTHER\",\n}\n\nexport enum TableStatus {\n\tVACANT = \"VACANT\", // Free and available\n\tRESERVED = \"RESERVED\", // Booked but not yet seated\n\tOCCUPIED = \"OCCUPIED\", // Currently in use\n\tBLOCKED = \"BLOCKED\", // Temporarily blocked/unavailable\n\tNEEDS_CLEANING = \"NEEDS_CLEANING\", // Dirty, awaiting cleanup\n\tOUT_OF_SERVICE = \"OUT_OF_SERVICE\", // Permanently unavailable repair/maintenance\n\tPENDING_CONFIRMATION = \"PENDING_CONFIRMATION\", // Reservation not yet confirmed\n\tNO_SHOW = \"NO_SHOW\", // Reserved but guest didn’t arrive\n}\n\nexport enum TableLocation {\n\t// Indoor\n\tMAIN_HALL = \"MAIN_HALL\",\n\tPRIVATE_DINING = \"PRIVATE_DINING\",\n\tVIP_ROOM = \"VIP_ROOM\",\n\tBANQUET_HALL = \"BANQUET_HALL\",\n\tBAR_AREA = \"BAR_AREA\",\n\tLOUNGE = \"LOUNGE\",\n\tOPEN_KITCHEN = \"OPEN_KITCHEN\",\n\tBOOTH_SECTION = \"BOOTH_SECTION\",\n\tMEZZANINE = \"MEZZANINE\",\n\tWINE_CELLAR = \"WINE_CELLAR\",\n\n\t// Outdoor\n\tTERRACE = \"TERRACE\",\n\tPATIO = \"PATIO\",\n\tGARDEN = \"GARDEN\",\n\tCOURTYARD = \"COURTYARD\",\n\tROOFTOP = \"ROOFTOP\",\n\tBALCONY = \"BALCONY\",\n\tSIDEWALK = \"SIDEWALK\",\n\tPOOLSIDE = \"POOLSIDE\",\n\n\t// Special Sections\n\tSMOKING_AREA = \"SMOKING_AREA\",\n\tNON_SMOKING = \"NON_SMOKING\",\n\tFAMILY_SECTION = \"FAMILY_SECTION\",\n\tKIDS_AREA = \"KIDS_AREA\",\n\tWAITING_AREA = \"WAITING_AREA\",\n\tDANCE_FLOOR = \"DANCE_FLOOR\",\n}\n\nexport interface Table {\n\tid: number;\n\tbusinessId: number;\n\tbranchId: number;\n\tname: string;\n\tseatCount: number;\n\tshape: TableShape;\n\tlocation: TableLocation;\n\tstatus: TableStatus;\n}\n\nexport interface TableState {\n\ttables: Table[];\n}\n\nexport type TableForm = Omit<Table, \"id\" | \"businessId\" | \"branchId\"> & {\n\tbranchId: string | number;\n};\n\nexport type TableUpdate = Partial<Omit<Table, \"id\" | \"businessId\">>;\n\nexport type TableFilter = Partial<Pick<Table, \"branchId\" | \"shape\" | \"location\" | \"status\">>;\n\nexport type TableFilterParams = { field: keyof TableFilter; value: TableFilter[keyof TableFilter] };\n"],"names":["MenuAddonSelectType","BusinessSetting","CustomerAuthStep","CustomerAddressType","FeatureSegment","OrderType","OrderStatus","OrderItemStatus","PaymentMethod","OrderStep","ProductView","PlanType","SubscriptionStatus","TableShape","TableStatus","TableLocation","Feature"],"mappings":"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"}
|
package/dist/models/menu.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import * as branchModels from "src/modules/branch/models";
|
|
|
3
3
|
import * as categoryModels from "./category";
|
|
4
4
|
import * as businessModels from "src/modules/business/models";
|
|
5
5
|
import * as featureModels from "src/modules/feature/models";
|
|
6
|
+
import * as tableModels from "src/modules/table/models";
|
|
6
7
|
export interface PublicMenuData {
|
|
7
8
|
businessId: number;
|
|
8
9
|
branches: branchModels.Branch[];
|
|
@@ -27,6 +28,8 @@ export interface PublicMenuData {
|
|
|
27
28
|
businessSegment?: featureModels.FeatureSegment;
|
|
28
29
|
businessSettings?: businessModels.BusinessSettings;
|
|
29
30
|
business: businessModels.Business;
|
|
31
|
+
tableId?: string | null;
|
|
32
|
+
tables?: tableModels.Table[];
|
|
30
33
|
onBranchSelect?: (branchId: number) => void;
|
|
31
34
|
onLanguageSelect?: (code: string) => void;
|
|
32
35
|
}
|
|
@@ -7,5 +7,6 @@ export * from "../modules/order/models";
|
|
|
7
7
|
export * from "../modules/product/models";
|
|
8
8
|
export * from "../modules/view/models";
|
|
9
9
|
export * from "../modules/subscription/models";
|
|
10
|
+
export * from "../modules/table/models";
|
|
10
11
|
export * from "./category";
|
|
11
12
|
export * from "./menu";
|
|
@@ -3,6 +3,7 @@ import * as branchModels from "src/modules/branch/models";
|
|
|
3
3
|
import * as categoryModels from "./category";
|
|
4
4
|
import * as businessModels from "src/modules/business/models";
|
|
5
5
|
import * as featureModels from "src/modules/feature/models";
|
|
6
|
+
import * as tableModels from "src/modules/table/models";
|
|
6
7
|
export interface PublicMenuData {
|
|
7
8
|
businessId: number;
|
|
8
9
|
branches: branchModels.Branch[];
|
|
@@ -27,6 +28,8 @@ export interface PublicMenuData {
|
|
|
27
28
|
businessSegment?: featureModels.FeatureSegment;
|
|
28
29
|
businessSettings?: businessModels.BusinessSettings;
|
|
29
30
|
business: businessModels.Business;
|
|
31
|
+
tableId?: string | null;
|
|
32
|
+
tables?: tableModels.Table[];
|
|
30
33
|
onBranchSelect?: (branchId: number) => void;
|
|
31
34
|
onLanguageSelect?: (code: string) => void;
|
|
32
35
|
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
export declare enum TableShape {
|
|
2
|
+
SQUARE = "SQUARE",
|
|
3
|
+
CIRCLE = "CIRCLE",
|
|
4
|
+
RECTANGLE = "RECTANGLE",
|
|
5
|
+
RECTANGLE_VERTICAL = "RECTANGLE_VERTICAL",
|
|
6
|
+
SINGLE_AT_BAR = "SINGLE_AT_BAR",
|
|
7
|
+
OTHER = "OTHER"
|
|
8
|
+
}
|
|
9
|
+
export declare enum TableStatus {
|
|
10
|
+
VACANT = "VACANT",// Free and available
|
|
11
|
+
RESERVED = "RESERVED",// Booked but not yet seated
|
|
12
|
+
OCCUPIED = "OCCUPIED",// Currently in use
|
|
13
|
+
BLOCKED = "BLOCKED",// Temporarily blocked/unavailable
|
|
14
|
+
NEEDS_CLEANING = "NEEDS_CLEANING",// Dirty, awaiting cleanup
|
|
15
|
+
OUT_OF_SERVICE = "OUT_OF_SERVICE",// Permanently unavailable repair/maintenance
|
|
16
|
+
PENDING_CONFIRMATION = "PENDING_CONFIRMATION",// Reservation not yet confirmed
|
|
17
|
+
NO_SHOW = "NO_SHOW"
|
|
18
|
+
}
|
|
19
|
+
export declare enum TableLocation {
|
|
20
|
+
MAIN_HALL = "MAIN_HALL",
|
|
21
|
+
PRIVATE_DINING = "PRIVATE_DINING",
|
|
22
|
+
VIP_ROOM = "VIP_ROOM",
|
|
23
|
+
BANQUET_HALL = "BANQUET_HALL",
|
|
24
|
+
BAR_AREA = "BAR_AREA",
|
|
25
|
+
LOUNGE = "LOUNGE",
|
|
26
|
+
OPEN_KITCHEN = "OPEN_KITCHEN",
|
|
27
|
+
BOOTH_SECTION = "BOOTH_SECTION",
|
|
28
|
+
MEZZANINE = "MEZZANINE",
|
|
29
|
+
WINE_CELLAR = "WINE_CELLAR",
|
|
30
|
+
TERRACE = "TERRACE",
|
|
31
|
+
PATIO = "PATIO",
|
|
32
|
+
GARDEN = "GARDEN",
|
|
33
|
+
COURTYARD = "COURTYARD",
|
|
34
|
+
ROOFTOP = "ROOFTOP",
|
|
35
|
+
BALCONY = "BALCONY",
|
|
36
|
+
SIDEWALK = "SIDEWALK",
|
|
37
|
+
POOLSIDE = "POOLSIDE",
|
|
38
|
+
SMOKING_AREA = "SMOKING_AREA",
|
|
39
|
+
NON_SMOKING = "NON_SMOKING",
|
|
40
|
+
FAMILY_SECTION = "FAMILY_SECTION",
|
|
41
|
+
KIDS_AREA = "KIDS_AREA",
|
|
42
|
+
WAITING_AREA = "WAITING_AREA",
|
|
43
|
+
DANCE_FLOOR = "DANCE_FLOOR"
|
|
44
|
+
}
|
|
45
|
+
export interface Table {
|
|
46
|
+
id: number;
|
|
47
|
+
businessId: number;
|
|
48
|
+
branchId: number;
|
|
49
|
+
name: string;
|
|
50
|
+
seatCount: number;
|
|
51
|
+
shape: TableShape;
|
|
52
|
+
location: TableLocation;
|
|
53
|
+
status: TableStatus;
|
|
54
|
+
}
|
|
55
|
+
export interface TableState {
|
|
56
|
+
tables: Table[];
|
|
57
|
+
}
|
|
58
|
+
export type TableForm = Omit<Table, "id" | "businessId" | "branchId"> & {
|
|
59
|
+
branchId: string | number;
|
|
60
|
+
};
|
|
61
|
+
export type TableUpdate = Partial<Omit<Table, "id" | "businessId">>;
|
|
62
|
+
export type TableFilter = Partial<Pick<Table, "branchId" | "shape" | "location" | "status">>;
|
|
63
|
+
export type TableFilterParams = {
|
|
64
|
+
field: keyof TableFilter;
|
|
65
|
+
value: TableFilter[keyof TableFilter];
|
|
66
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -8,3 +8,9 @@ export declare const initialOrder: {
|
|
|
8
8
|
paymentMethod: PaymentMethod;
|
|
9
9
|
};
|
|
10
10
|
export declare const ORDER_STEPS: OrderStep[];
|
|
11
|
+
export declare enum OrderErrors {
|
|
12
|
+
FIELD_REQUIRED_ERROR = "This field is required",
|
|
13
|
+
TABLE_NOT_SELECTED = "Please select a table",
|
|
14
|
+
ADDRESS_IS_EMPTY = "Please enter an address",
|
|
15
|
+
EMPTY_ITEMS = "Please choose product"
|
|
16
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Order, OrderItem, OrderPayload, SelectedAddons } from "./models";
|
|
1
|
+
import { Order, OrderItem, OrderPayload, OrderType, PaymentMethod, SelectedAddons } from "./models";
|
|
2
2
|
export declare const useOrderPriceDetails: () => {
|
|
3
3
|
totalPriceWithTax: number;
|
|
4
4
|
totalPriceWithoutTax: number;
|
|
@@ -24,3 +24,12 @@ export declare const useOrderActiveForBusiness: () => boolean;
|
|
|
24
24
|
export declare const useDeliveryDistanceError: () => string | null;
|
|
25
25
|
export declare const useDeliveryAmountError: () => string | null;
|
|
26
26
|
export declare const useOrderErrorInDetails: () => string | null;
|
|
27
|
+
export declare const useInitialOrder: () => {
|
|
28
|
+
orderType: OrderType;
|
|
29
|
+
tableId: number;
|
|
30
|
+
totalPriceWithTax: number;
|
|
31
|
+
totalPriceWithoutTax: number;
|
|
32
|
+
totalTax: number;
|
|
33
|
+
vat: number;
|
|
34
|
+
paymentMethod: PaymentMethod;
|
|
35
|
+
};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { IconType } from "@sorocraft/ui";
|
|
2
|
-
import { Order, OrderAddon, OrderItem, OrderStatus, SelectedAddons } from "./models";
|
|
2
|
+
import { Order, OrderAddon, OrderItem, OrderStatus, OrderType, SelectedAddons } from "./models";
|
|
3
3
|
import * as addonModels from "../addon/models";
|
|
4
|
+
import * as businessModels from "../business/models";
|
|
5
|
+
import { OrderErrors } from "./constants";
|
|
4
6
|
export declare const calculatSingleAddonTotalPrice: (addon: OrderAddon) => number;
|
|
5
7
|
export declare function calculateTotalAddonPrice(addons?: OrderAddon[], quantity?: number): number;
|
|
6
8
|
export declare const getOrderPrice: (order: Order, currency: string, language: string) => {
|
|
@@ -23,3 +25,5 @@ export declare const getOrderItemPrice: (orderItem: OrderItem) => {
|
|
|
23
25
|
export declare const getSelectedAddonsFromOrderItems: (item: OrderItem) => SelectedAddons;
|
|
24
26
|
export declare const getStatusIcon: (status: OrderStatus) => IconType;
|
|
25
27
|
export declare const buildSelectedAddonsPayload: (productAddons?: addonModels.MenuAddon[], selectedAddons?: SelectedAddons) => OrderAddon[];
|
|
28
|
+
export declare const getDefaultOrderType: (settings: businessModels.BusinessSettings) => OrderType;
|
|
29
|
+
export declare const getOrderErrorMessages: (field: keyof Order) => OrderErrors;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
export declare enum TableShape {
|
|
2
|
+
SQUARE = "SQUARE",
|
|
3
|
+
CIRCLE = "CIRCLE",
|
|
4
|
+
RECTANGLE = "RECTANGLE",
|
|
5
|
+
RECTANGLE_VERTICAL = "RECTANGLE_VERTICAL",
|
|
6
|
+
SINGLE_AT_BAR = "SINGLE_AT_BAR",
|
|
7
|
+
OTHER = "OTHER"
|
|
8
|
+
}
|
|
9
|
+
export declare enum TableStatus {
|
|
10
|
+
VACANT = "VACANT",// Free and available
|
|
11
|
+
RESERVED = "RESERVED",// Booked but not yet seated
|
|
12
|
+
OCCUPIED = "OCCUPIED",// Currently in use
|
|
13
|
+
BLOCKED = "BLOCKED",// Temporarily blocked/unavailable
|
|
14
|
+
NEEDS_CLEANING = "NEEDS_CLEANING",// Dirty, awaiting cleanup
|
|
15
|
+
OUT_OF_SERVICE = "OUT_OF_SERVICE",// Permanently unavailable repair/maintenance
|
|
16
|
+
PENDING_CONFIRMATION = "PENDING_CONFIRMATION",// Reservation not yet confirmed
|
|
17
|
+
NO_SHOW = "NO_SHOW"
|
|
18
|
+
}
|
|
19
|
+
export declare enum TableLocation {
|
|
20
|
+
MAIN_HALL = "MAIN_HALL",
|
|
21
|
+
PRIVATE_DINING = "PRIVATE_DINING",
|
|
22
|
+
VIP_ROOM = "VIP_ROOM",
|
|
23
|
+
BANQUET_HALL = "BANQUET_HALL",
|
|
24
|
+
BAR_AREA = "BAR_AREA",
|
|
25
|
+
LOUNGE = "LOUNGE",
|
|
26
|
+
OPEN_KITCHEN = "OPEN_KITCHEN",
|
|
27
|
+
BOOTH_SECTION = "BOOTH_SECTION",
|
|
28
|
+
MEZZANINE = "MEZZANINE",
|
|
29
|
+
WINE_CELLAR = "WINE_CELLAR",
|
|
30
|
+
TERRACE = "TERRACE",
|
|
31
|
+
PATIO = "PATIO",
|
|
32
|
+
GARDEN = "GARDEN",
|
|
33
|
+
COURTYARD = "COURTYARD",
|
|
34
|
+
ROOFTOP = "ROOFTOP",
|
|
35
|
+
BALCONY = "BALCONY",
|
|
36
|
+
SIDEWALK = "SIDEWALK",
|
|
37
|
+
POOLSIDE = "POOLSIDE",
|
|
38
|
+
SMOKING_AREA = "SMOKING_AREA",
|
|
39
|
+
NON_SMOKING = "NON_SMOKING",
|
|
40
|
+
FAMILY_SECTION = "FAMILY_SECTION",
|
|
41
|
+
KIDS_AREA = "KIDS_AREA",
|
|
42
|
+
WAITING_AREA = "WAITING_AREA",
|
|
43
|
+
DANCE_FLOOR = "DANCE_FLOOR"
|
|
44
|
+
}
|
|
45
|
+
export interface Table {
|
|
46
|
+
id: number;
|
|
47
|
+
businessId: number;
|
|
48
|
+
branchId: number;
|
|
49
|
+
name: string;
|
|
50
|
+
seatCount: number;
|
|
51
|
+
shape: TableShape;
|
|
52
|
+
location: TableLocation;
|
|
53
|
+
status: TableStatus;
|
|
54
|
+
}
|
|
55
|
+
export interface TableState {
|
|
56
|
+
tables: Table[];
|
|
57
|
+
}
|
|
58
|
+
export type TableForm = Omit<Table, "id" | "businessId" | "branchId"> & {
|
|
59
|
+
branchId: string | number;
|
|
60
|
+
};
|
|
61
|
+
export type TableUpdate = Partial<Omit<Table, "id" | "businessId">>;
|
|
62
|
+
export type TableFilter = Partial<Pick<Table, "branchId" | "shape" | "location" | "status">>;
|
|
63
|
+
export type TableFilterParams = {
|
|
64
|
+
field: keyof TableFilter;
|
|
65
|
+
value: TableFilter[keyof TableFilter];
|
|
66
|
+
};
|
|
@@ -55,6 +55,12 @@ declare const _default: {
|
|
|
55
55
|
"Product choices": string;
|
|
56
56
|
"Track order": string;
|
|
57
57
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
58
|
+
"This field is required": string;
|
|
59
|
+
"Please select a table": string;
|
|
60
|
+
"Please enter an address": string;
|
|
61
|
+
"Please choose product": string;
|
|
62
|
+
Table: string;
|
|
63
|
+
"Choose Table": string;
|
|
58
64
|
};
|
|
59
65
|
customer: {
|
|
60
66
|
"Unknown address": string;
|
|
@@ -31,5 +31,11 @@ declare const _default: {
|
|
|
31
31
|
"Product choices": string;
|
|
32
32
|
"Track order": string;
|
|
33
33
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
34
|
+
"This field is required": string;
|
|
35
|
+
"Please select a table": string;
|
|
36
|
+
"Please enter an address": string;
|
|
37
|
+
"Please choose product": string;
|
|
38
|
+
Table: string;
|
|
39
|
+
"Choose Table": string;
|
|
34
40
|
};
|
|
35
41
|
export default _default;
|
|
@@ -56,6 +56,12 @@ declare const _default: {
|
|
|
56
56
|
Continue: string;
|
|
57
57
|
"Track order": string;
|
|
58
58
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
59
|
+
"This field is required": string;
|
|
60
|
+
"Please select a table": string;
|
|
61
|
+
"Please enter an address": string;
|
|
62
|
+
"Please choose product": string;
|
|
63
|
+
Table: string;
|
|
64
|
+
"Choose Table": string;
|
|
59
65
|
};
|
|
60
66
|
customer: {
|
|
61
67
|
"Unknown address": string;
|
|
@@ -32,5 +32,11 @@ declare const _default: {
|
|
|
32
32
|
Continue: string;
|
|
33
33
|
"Track order": string;
|
|
34
34
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
35
|
+
"This field is required": string;
|
|
36
|
+
"Please select a table": string;
|
|
37
|
+
"Please enter an address": string;
|
|
38
|
+
"Please choose product": string;
|
|
39
|
+
Table: string;
|
|
40
|
+
"Choose Table": string;
|
|
35
41
|
};
|
|
36
42
|
export default _default;
|
|
@@ -56,6 +56,12 @@ declare const _default: {
|
|
|
56
56
|
"Product choices": string;
|
|
57
57
|
"Track order": string;
|
|
58
58
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
59
|
+
"This field is required": string;
|
|
60
|
+
"Please select a table": string;
|
|
61
|
+
"Please enter an address": string;
|
|
62
|
+
"Please choose product": string;
|
|
63
|
+
Table: string;
|
|
64
|
+
"Choose Table": string;
|
|
59
65
|
};
|
|
60
66
|
customer: {
|
|
61
67
|
"Unknown address": string;
|
|
@@ -201,6 +207,12 @@ declare const _default: {
|
|
|
201
207
|
Continue: string;
|
|
202
208
|
"Track order": string;
|
|
203
209
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
210
|
+
"This field is required": string;
|
|
211
|
+
"Please select a table": string;
|
|
212
|
+
"Please enter an address": string;
|
|
213
|
+
"Please choose product": string;
|
|
214
|
+
Table: string;
|
|
215
|
+
"Choose Table": string;
|
|
204
216
|
};
|
|
205
217
|
customer: {
|
|
206
218
|
"Unknown address": string;
|
|
@@ -322,6 +334,12 @@ declare const _default: {
|
|
|
322
334
|
Continue: string;
|
|
323
335
|
"Track order": string;
|
|
324
336
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
337
|
+
"This field is required": string;
|
|
338
|
+
"Please select a table": string;
|
|
339
|
+
"Please enter an address": string;
|
|
340
|
+
"Please choose product": string;
|
|
341
|
+
Table: string;
|
|
342
|
+
"Choose Table": string;
|
|
325
343
|
};
|
|
326
344
|
customer: {
|
|
327
345
|
"Unknown address": string;
|
|
@@ -443,6 +461,12 @@ declare const _default: {
|
|
|
443
461
|
Continue: string;
|
|
444
462
|
"Track order": string;
|
|
445
463
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
464
|
+
"This field is required": string;
|
|
465
|
+
"Please select a table": string;
|
|
466
|
+
"Please enter an address": string;
|
|
467
|
+
"Please choose product": string;
|
|
468
|
+
Table: string;
|
|
469
|
+
"Choose Table": string;
|
|
446
470
|
};
|
|
447
471
|
customer: {
|
|
448
472
|
"Unknown address": string;
|
|
@@ -564,6 +588,12 @@ declare const _default: {
|
|
|
564
588
|
Continue: string;
|
|
565
589
|
"Track order": string;
|
|
566
590
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
591
|
+
"This field is required": string;
|
|
592
|
+
"Please select a table": string;
|
|
593
|
+
"Please enter an address": string;
|
|
594
|
+
"Please choose product": string;
|
|
595
|
+
Table: string;
|
|
596
|
+
"Choose Table": string;
|
|
567
597
|
};
|
|
568
598
|
customer: {
|
|
569
599
|
"Unknown address": string;
|
|
@@ -56,6 +56,12 @@ declare const _default: {
|
|
|
56
56
|
Continue: string;
|
|
57
57
|
"Track order": string;
|
|
58
58
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
59
|
+
"This field is required": string;
|
|
60
|
+
"Please select a table": string;
|
|
61
|
+
"Please enter an address": string;
|
|
62
|
+
"Please choose product": string;
|
|
63
|
+
Table: string;
|
|
64
|
+
"Choose Table": string;
|
|
59
65
|
};
|
|
60
66
|
customer: {
|
|
61
67
|
"Unknown address": string;
|
|
@@ -32,5 +32,11 @@ declare const _default: {
|
|
|
32
32
|
Continue: string;
|
|
33
33
|
"Track order": string;
|
|
34
34
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
35
|
+
"This field is required": string;
|
|
36
|
+
"Please select a table": string;
|
|
37
|
+
"Please enter an address": string;
|
|
38
|
+
"Please choose product": string;
|
|
39
|
+
Table: string;
|
|
40
|
+
"Choose Table": string;
|
|
35
41
|
};
|
|
36
42
|
export default _default;
|
|
@@ -56,6 +56,12 @@ declare const _default: {
|
|
|
56
56
|
Continue: string;
|
|
57
57
|
"Track order": string;
|
|
58
58
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
59
|
+
"This field is required": string;
|
|
60
|
+
"Please select a table": string;
|
|
61
|
+
"Please enter an address": string;
|
|
62
|
+
"Please choose product": string;
|
|
63
|
+
Table: string;
|
|
64
|
+
"Choose Table": string;
|
|
59
65
|
};
|
|
60
66
|
customer: {
|
|
61
67
|
"Unknown address": string;
|
|
@@ -32,5 +32,11 @@ declare const _default: {
|
|
|
32
32
|
Continue: string;
|
|
33
33
|
"Track order": string;
|
|
34
34
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
35
|
+
"This field is required": string;
|
|
36
|
+
"Please select a table": string;
|
|
37
|
+
"Please enter an address": string;
|
|
38
|
+
"Please choose product": string;
|
|
39
|
+
Table: string;
|
|
40
|
+
"Choose Table": string;
|
|
35
41
|
};
|
|
36
42
|
export default _default;
|
|
@@ -56,6 +56,12 @@ declare const _default: {
|
|
|
56
56
|
Continue: string;
|
|
57
57
|
"Track order": string;
|
|
58
58
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
59
|
+
"This field is required": string;
|
|
60
|
+
"Please select a table": string;
|
|
61
|
+
"Please enter an address": string;
|
|
62
|
+
"Please choose product": string;
|
|
63
|
+
Table: string;
|
|
64
|
+
"Choose Table": string;
|
|
59
65
|
};
|
|
60
66
|
customer: {
|
|
61
67
|
"Unknown address": string;
|
|
@@ -32,5 +32,11 @@ declare const _default: {
|
|
|
32
32
|
Continue: string;
|
|
33
33
|
"Track order": string;
|
|
34
34
|
"Minimum order amount for delivery is {{amount}}": string;
|
|
35
|
+
"This field is required": string;
|
|
36
|
+
"Please select a table": string;
|
|
37
|
+
"Please enter an address": string;
|
|
38
|
+
"Please choose product": string;
|
|
39
|
+
Table: string;
|
|
40
|
+
"Choose Table": string;
|
|
35
41
|
};
|
|
36
42
|
export default _default;
|
package/dist/store/order.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Dispatch, ReactNode } from "react";
|
|
2
|
+
import { FormErrors } from "@sorocraft/ui";
|
|
2
3
|
import * as productModels from "src/modules/product/models";
|
|
3
4
|
import * as orderModels from "src/modules/order/models";
|
|
4
5
|
import * as customerModels from "src/modules/customer/models";
|
|
@@ -16,6 +17,7 @@ type OrderContent = {
|
|
|
16
17
|
isOrderOpen: boolean;
|
|
17
18
|
customer: customerModels.Customer;
|
|
18
19
|
trackingId: string;
|
|
20
|
+
errors?: FormErrors;
|
|
19
21
|
setOrderStep: Dispatch<React.SetStateAction<orderModels.OrderStep>>;
|
|
20
22
|
updateOrder: (updatedFields: Partial<orderModels.Order>) => void;
|
|
21
23
|
addProduct: (params: UpdateOrderItemsParams) => void;
|
|
@@ -25,6 +27,7 @@ type OrderContent = {
|
|
|
25
27
|
getCustomer: () => void;
|
|
26
28
|
resetOrder: () => void;
|
|
27
29
|
setTrackingId: Dispatch<React.SetStateAction<string>>;
|
|
30
|
+
updateOrderErrors: (field: keyof orderModels.Order) => void;
|
|
28
31
|
};
|
|
29
32
|
export declare const OrderProvider: ({ children }: {
|
|
30
33
|
children: ReactNode;
|