@open-tender/utils 0.4.85 → 0.4.86

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.
@@ -48,7 +48,6 @@ export declare const useMenuItem: (builtItem: CartItem, auth: Auth | null, looku
48
48
  name: string;
49
49
  nutritionalInfo: import("@open-tender/types").NutritionalInfo | null;
50
50
  points: number | null;
51
- pos_ext_id: string | null;
52
51
  price: number;
53
52
  quantity: number;
54
53
  shorthand: string | null;
@@ -40,7 +40,6 @@ export declare const useModifier: (group: CartItemGroup, option: CartItemOption,
40
40
  name: string;
41
41
  nutritionalInfo: import("@open-tender/types").NutritionalInfo | null;
42
42
  points: number | null;
43
- pos_ext_id: string | null;
44
43
  quantity: number;
45
44
  shorthand: string | null;
46
45
  shortDescription: string | null;
@@ -37,7 +37,6 @@ export declare const useOrderItem: (orderItem: CartItem, favorite?: MenuItemFavo
37
37
  name: string;
38
38
  nutritionalInfo: import("@open-tender/types").NutritionalInfo | null;
39
39
  points: number | null;
40
- pos_ext_id: string | null;
41
40
  price: number;
42
41
  quantity: number;
43
42
  shorthand: string | null;
@@ -42,7 +42,6 @@ export declare const rehydrateCart: (menuItems: MenuItems, simpleCartItems: Simp
42
42
  name: string;
43
43
  nutritionalInfo: NutritionalInfo | null;
44
44
  points: number | null;
45
- pos_ext_id: string | null;
46
45
  price: number;
47
46
  quantity: number;
48
47
  shorthand: string | null;
@@ -138,7 +137,6 @@ export declare const combineCarts: (cart: Cart, guestCart: Cart, cartOwner: Cart
138
137
  name: string;
139
138
  nutritionalInfo: NutritionalInfo | null;
140
139
  points: number | null;
141
- pos_ext_id: string | null;
142
140
  price: number;
143
141
  quantity: number;
144
142
  shorthand: string | null;
@@ -229,6 +229,7 @@ const makeOrderItemGroups = (optionGroups, isEdit, soldOut = []) => {
229
229
  name: o.name,
230
230
  nutritionalInfo: o.nutritional_info,
231
231
  points: o.points || 0,
232
+ // @ts-ignore
232
233
  pos_ext_id: o.pos_ext_id,
233
234
  price: parseFloat(o.price),
234
235
  quantity: quantity,
@@ -294,6 +295,7 @@ const makeOrderItem = (item, isEdit, soldOut = [], simpleItem, hasPoints = false
294
295
  notes: simpleItem ? simpleItem.notes || null : null,
295
296
  nutritionalInfo: item.nutritional_info,
296
297
  points: hasPoints ? item.points || null : null,
298
+ // @ts-ignore
297
299
  pos_ext_id: item.pos_ext_id,
298
300
  price: parseFloat(item.price),
299
301
  quantity: item.min_quantity || 1 * item.increment,
@@ -35,7 +35,6 @@ export declare const makeOtherMenuSections: (displayedSections: MenuDisplayedSec
35
35
  plu: string | null;
36
36
  points: number | null;
37
37
  pos_display_color: string | null;
38
- pos_ext_id: string | null;
39
38
  price: string;
40
39
  sales_tax_override: `${number}.${number}` | null;
41
40
  short_description: string | null;
@@ -84,7 +83,6 @@ export declare const makeFlatCategories: (categories: MenuCategories) => {
84
83
  plu: string | null;
85
84
  points: number | null;
86
85
  pos_display_color: string | null;
87
- pos_ext_id: string | null;
88
86
  price: string;
89
87
  sales_tax_override: `${number}.${number}` | null;
90
88
  short_description: string | null;
@@ -95,7 +95,7 @@ const makeNotAcceptingOrdersMsg = (serviceType) => {
95
95
  if (!serviceTypeName) {
96
96
  return 'This location is not currently accepting orders.';
97
97
  }
98
- return `This location is not currently accepting ${serviceTypeName.toLowerCase()} orders. Please try switching to a different order type.`;
98
+ return `This location is not currently accepting ${serviceTypeName.toLowerCase()} orders.`;
99
99
  };
100
100
  exports.makeNotAcceptingOrdersMsg = makeNotAcceptingOrdersMsg;
101
101
  const makeRevenueCenterMsg = (revenueCenter, serviceType, requestedAt, statusMessages) => {
@@ -48,7 +48,6 @@ export declare const useMenuItem: (builtItem: CartItem, auth: Auth | null, looku
48
48
  name: string;
49
49
  nutritionalInfo: import("@open-tender/types").NutritionalInfo | null;
50
50
  points: number | null;
51
- pos_ext_id: string | null;
52
51
  price: number;
53
52
  quantity: number;
54
53
  shorthand: string | null;
@@ -40,7 +40,6 @@ export declare const useModifier: (group: CartItemGroup, option: CartItemOption,
40
40
  name: string;
41
41
  nutritionalInfo: import("@open-tender/types").NutritionalInfo | null;
42
42
  points: number | null;
43
- pos_ext_id: string | null;
44
43
  quantity: number;
45
44
  shorthand: string | null;
46
45
  shortDescription: string | null;
@@ -37,7 +37,6 @@ export declare const useOrderItem: (orderItem: CartItem, favorite?: MenuItemFavo
37
37
  name: string;
38
38
  nutritionalInfo: import("@open-tender/types").NutritionalInfo | null;
39
39
  points: number | null;
40
- pos_ext_id: string | null;
41
40
  price: number;
42
41
  quantity: number;
43
42
  shorthand: string | null;
@@ -42,7 +42,6 @@ export declare const rehydrateCart: (menuItems: MenuItems, simpleCartItems: Simp
42
42
  name: string;
43
43
  nutritionalInfo: NutritionalInfo | null;
44
44
  points: number | null;
45
- pos_ext_id: string | null;
46
45
  price: number;
47
46
  quantity: number;
48
47
  shorthand: string | null;
@@ -138,7 +137,6 @@ export declare const combineCarts: (cart: Cart, guestCart: Cart, cartOwner: Cart
138
137
  name: string;
139
138
  nutritionalInfo: NutritionalInfo | null;
140
139
  points: number | null;
141
- pos_ext_id: string | null;
142
140
  price: number;
143
141
  quantity: number;
144
142
  shorthand: string | null;
@@ -214,6 +214,7 @@ const makeOrderItemGroups = (optionGroups, isEdit, soldOut = []) => {
214
214
  name: o.name,
215
215
  nutritionalInfo: o.nutritional_info,
216
216
  points: o.points || 0,
217
+ // @ts-ignore
217
218
  pos_ext_id: o.pos_ext_id,
218
219
  price: parseFloat(o.price),
219
220
  quantity: quantity,
@@ -279,6 +280,7 @@ export const makeOrderItem = (item, isEdit, soldOut = [], simpleItem, hasPoints
279
280
  notes: simpleItem ? simpleItem.notes || null : null,
280
281
  nutritionalInfo: item.nutritional_info,
281
282
  points: hasPoints ? item.points || null : null,
283
+ // @ts-ignore
282
284
  pos_ext_id: item.pos_ext_id,
283
285
  price: parseFloat(item.price),
284
286
  quantity: item.min_quantity || 1 * item.increment,
@@ -35,7 +35,6 @@ export declare const makeOtherMenuSections: (displayedSections: MenuDisplayedSec
35
35
  plu: string | null;
36
36
  points: number | null;
37
37
  pos_display_color: string | null;
38
- pos_ext_id: string | null;
39
38
  price: string;
40
39
  sales_tax_override: `${number}.${number}` | null;
41
40
  short_description: string | null;
@@ -84,7 +83,6 @@ export declare const makeFlatCategories: (categories: MenuCategories) => {
84
83
  plu: string | null;
85
84
  points: number | null;
86
85
  pos_display_color: string | null;
87
- pos_ext_id: string | null;
88
86
  price: string;
89
87
  sales_tax_override: `${number}.${number}` | null;
90
88
  short_description: string | null;
@@ -87,7 +87,7 @@ export const makeNotAcceptingOrdersMsg = (serviceType) => {
87
87
  if (!serviceTypeName) {
88
88
  return 'This location is not currently accepting orders.';
89
89
  }
90
- return `This location is not currently accepting ${serviceTypeName.toLowerCase()} orders. Please try switching to a different order type.`;
90
+ return `This location is not currently accepting ${serviceTypeName.toLowerCase()} orders.`;
91
91
  };
92
92
  export const makeRevenueCenterMsg = (revenueCenter, serviceType, requestedAt, statusMessages) => {
93
93
  var _a;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@open-tender/utils",
3
- "version": "0.4.85",
3
+ "version": "0.4.86",
4
4
  "description": "A library of utils for use with Open Tender applications that utilize our cloud-based Order API.",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/esm/index.js",
@@ -36,6 +36,7 @@
36
36
  "private": false,
37
37
  "devDependencies": {
38
38
  "@emotion/react": "^11.10.4",
39
+ "@open-tender/types": "^0.4.124",
39
40
  "@reduxjs/toolkit": "^1.8.5",
40
41
  "@types/google.maps": "^3.53.5",
41
42
  "@types/jest": "^29.5.11",
@@ -57,7 +58,7 @@
57
58
  "typescript": "^4.8.2"
58
59
  },
59
60
  "peerDependencies": {
60
- "@open-tender/types": "^0.4.121",
61
+ "@open-tender/types": "^0.4.124",
61
62
  "@reduxjs/toolkit": "^1.8.5",
62
63
  "react": "^18.2.0"
63
64
  },