@open-tender/cloud 0.0.63 → 0.0.65
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/cjs/slices/customer/groupOrders.js +3 -3
- package/dist/cjs/slices/groupOrder.js +2 -2
- package/dist/cjs/slices/guest.js +2 -2
- package/dist/cjs/slices/menu.js +1 -1
- package/dist/cjs/slices/order.js +2 -2
- package/dist/esm/slices/customer/groupOrders.js +3 -3
- package/dist/esm/slices/groupOrder.js +2 -2
- package/dist/esm/slices/guest.js +2 -2
- package/dist/esm/slices/menu.js +1 -1
- package/dist/esm/slices/order.js +2 -2
- package/package.json +2 -2
|
@@ -253,7 +253,7 @@ const customerGroupOrdersSlice = (0, toolkit_1.createSlice)({
|
|
|
253
253
|
state.loading = 'idle';
|
|
254
254
|
})
|
|
255
255
|
.addCase(exports.reopenGroupOrder.fulfilled, (state, action) => {
|
|
256
|
-
|
|
256
|
+
return Object.assign(Object.assign(Object.assign({}, state), action.payload), { loading: 'idle', error: null });
|
|
257
257
|
})
|
|
258
258
|
.addCase(exports.reopenGroupOrder.pending, state => {
|
|
259
259
|
state.loading = 'pending';
|
|
@@ -263,7 +263,7 @@ const customerGroupOrdersSlice = (0, toolkit_1.createSlice)({
|
|
|
263
263
|
state.loading = 'idle';
|
|
264
264
|
})
|
|
265
265
|
.addCase(exports.updateCustomerGroupOrder.fulfilled, (state, action) => {
|
|
266
|
-
|
|
266
|
+
return Object.assign(Object.assign(Object.assign({}, state), action.payload), { loading: 'idle', error: null });
|
|
267
267
|
})
|
|
268
268
|
.addCase(exports.updateCustomerGroupOrder.pending, state => {
|
|
269
269
|
state.loading = 'pending';
|
|
@@ -273,7 +273,7 @@ const customerGroupOrdersSlice = (0, toolkit_1.createSlice)({
|
|
|
273
273
|
state.loading = 'idle';
|
|
274
274
|
})
|
|
275
275
|
.addCase(exports.closeGroupOrder.fulfilled, (state, action) => {
|
|
276
|
-
|
|
276
|
+
return Object.assign(Object.assign({}, state), { closed: action.payload, loading: 'idle', error: null });
|
|
277
277
|
})
|
|
278
278
|
.addCase(exports.closeGroupOrder.pending, state => {
|
|
279
279
|
state.loading = 'pending';
|
|
@@ -151,7 +151,7 @@ const groupOrderSlice = (0, toolkit_1.createSlice)({
|
|
|
151
151
|
state.error = action.payload;
|
|
152
152
|
})
|
|
153
153
|
.addCase(exports.fetchGroupOrder.fulfilled, (state, action) => {
|
|
154
|
-
|
|
154
|
+
return Object.assign(Object.assign(Object.assign({}, state), { loading: 'idle', error: null }), action.payload);
|
|
155
155
|
})
|
|
156
156
|
.addCase(exports.fetchGroupOrder.pending, state => {
|
|
157
157
|
state.loading = 'pending';
|
|
@@ -161,7 +161,7 @@ const groupOrderSlice = (0, toolkit_1.createSlice)({
|
|
|
161
161
|
state.error = action.payload;
|
|
162
162
|
})
|
|
163
163
|
.addCase(exports.updateGroupOrder.fulfilled, (state, action) => {
|
|
164
|
-
|
|
164
|
+
return Object.assign(Object.assign(Object.assign({}, state), { loading: 'idle', error: null }), action.payload);
|
|
165
165
|
})
|
|
166
166
|
.addCase(exports.updateGroupOrder.pending, state => {
|
|
167
167
|
state.loading = 'pending';
|
package/dist/cjs/slices/guest.js
CHANGED
|
@@ -67,7 +67,7 @@ const guestSlice = (0, toolkit_1.createSlice)({
|
|
|
67
67
|
extraReducers: builder => {
|
|
68
68
|
builder
|
|
69
69
|
.addCase(exports.fetchGuest.fulfilled, (state, action) => {
|
|
70
|
-
|
|
70
|
+
return Object.assign(Object.assign(Object.assign({}, state), { loading: 'idle', errors: null }), action.payload);
|
|
71
71
|
})
|
|
72
72
|
.addCase(exports.fetchGuest.pending, state => {
|
|
73
73
|
state.loading = 'pending';
|
|
@@ -80,7 +80,7 @@ const guestSlice = (0, toolkit_1.createSlice)({
|
|
|
80
80
|
state.brands = null;
|
|
81
81
|
})
|
|
82
82
|
.addCase(exports.fetchGuestThanx.fulfilled, (state, action) => {
|
|
83
|
-
|
|
83
|
+
return Object.assign(Object.assign(Object.assign({}, state), { loading: 'idle', errors: null, showMagicLink: true }), action.payload);
|
|
84
84
|
})
|
|
85
85
|
.addCase(exports.fetchGuestThanx.pending, state => {
|
|
86
86
|
state.loading = 'pending';
|
package/dist/cjs/slices/menu.js
CHANGED
|
@@ -69,7 +69,7 @@ const menuSlice = (0, toolkit_1.createSlice)({
|
|
|
69
69
|
extraReducers: builder => {
|
|
70
70
|
builder
|
|
71
71
|
.addCase(exports.fetchMenu.fulfilled, (state, action) => {
|
|
72
|
-
|
|
72
|
+
return Object.assign(Object.assign(Object.assign({}, state), { previousMenuVars: state.menuVars || null, loading: 'idle', error: null }), action.payload);
|
|
73
73
|
})
|
|
74
74
|
.addCase(exports.fetchMenu.pending, state => {
|
|
75
75
|
state.loading = 'pending';
|
package/dist/cjs/slices/order.js
CHANGED
|
@@ -404,7 +404,7 @@ const orderSlice = (0, toolkit_1.createSlice)({
|
|
|
404
404
|
state.loading = 'idle';
|
|
405
405
|
})
|
|
406
406
|
.addCase(exports.editOrder.fulfilled, (state, action) => {
|
|
407
|
-
|
|
407
|
+
return Object.assign(Object.assign(Object.assign({}, state), action.payload), { loading: 'idle', error: null });
|
|
408
408
|
})
|
|
409
409
|
.addCase(exports.editOrder.pending, state => {
|
|
410
410
|
state.loading = 'pending';
|
|
@@ -413,7 +413,7 @@ const orderSlice = (0, toolkit_1.createSlice)({
|
|
|
413
413
|
state.loading = 'idle';
|
|
414
414
|
})
|
|
415
415
|
.addCase(exports.reorderPastOrder.fulfilled, (state, action) => {
|
|
416
|
-
|
|
416
|
+
return Object.assign(Object.assign(Object.assign({}, state), action.payload), { loading: 'idle', error: null });
|
|
417
417
|
})
|
|
418
418
|
.addCase(exports.reorderPastOrder.pending, state => {
|
|
419
419
|
state.loading = 'pending';
|
|
@@ -249,7 +249,7 @@ const customerGroupOrdersSlice = createSlice({
|
|
|
249
249
|
state.loading = 'idle';
|
|
250
250
|
})
|
|
251
251
|
.addCase(reopenGroupOrder.fulfilled, (state, action) => {
|
|
252
|
-
|
|
252
|
+
return Object.assign(Object.assign(Object.assign({}, state), action.payload), { loading: 'idle', error: null });
|
|
253
253
|
})
|
|
254
254
|
.addCase(reopenGroupOrder.pending, state => {
|
|
255
255
|
state.loading = 'pending';
|
|
@@ -259,7 +259,7 @@ const customerGroupOrdersSlice = createSlice({
|
|
|
259
259
|
state.loading = 'idle';
|
|
260
260
|
})
|
|
261
261
|
.addCase(updateCustomerGroupOrder.fulfilled, (state, action) => {
|
|
262
|
-
|
|
262
|
+
return Object.assign(Object.assign(Object.assign({}, state), action.payload), { loading: 'idle', error: null });
|
|
263
263
|
})
|
|
264
264
|
.addCase(updateCustomerGroupOrder.pending, state => {
|
|
265
265
|
state.loading = 'pending';
|
|
@@ -269,7 +269,7 @@ const customerGroupOrdersSlice = createSlice({
|
|
|
269
269
|
state.loading = 'idle';
|
|
270
270
|
})
|
|
271
271
|
.addCase(closeGroupOrder.fulfilled, (state, action) => {
|
|
272
|
-
|
|
272
|
+
return Object.assign(Object.assign({}, state), { closed: action.payload, loading: 'idle', error: null });
|
|
273
273
|
})
|
|
274
274
|
.addCase(closeGroupOrder.pending, state => {
|
|
275
275
|
state.loading = 'pending';
|
|
@@ -147,7 +147,7 @@ const groupOrderSlice = createSlice({
|
|
|
147
147
|
state.error = action.payload;
|
|
148
148
|
})
|
|
149
149
|
.addCase(fetchGroupOrder.fulfilled, (state, action) => {
|
|
150
|
-
|
|
150
|
+
return Object.assign(Object.assign(Object.assign({}, state), { loading: 'idle', error: null }), action.payload);
|
|
151
151
|
})
|
|
152
152
|
.addCase(fetchGroupOrder.pending, state => {
|
|
153
153
|
state.loading = 'pending';
|
|
@@ -157,7 +157,7 @@ const groupOrderSlice = createSlice({
|
|
|
157
157
|
state.error = action.payload;
|
|
158
158
|
})
|
|
159
159
|
.addCase(updateGroupOrder.fulfilled, (state, action) => {
|
|
160
|
-
|
|
160
|
+
return Object.assign(Object.assign(Object.assign({}, state), { loading: 'idle', error: null }), action.payload);
|
|
161
161
|
})
|
|
162
162
|
.addCase(updateGroupOrder.pending, state => {
|
|
163
163
|
state.loading = 'pending';
|
package/dist/esm/slices/guest.js
CHANGED
|
@@ -64,7 +64,7 @@ const guestSlice = createSlice({
|
|
|
64
64
|
extraReducers: builder => {
|
|
65
65
|
builder
|
|
66
66
|
.addCase(fetchGuest.fulfilled, (state, action) => {
|
|
67
|
-
|
|
67
|
+
return Object.assign(Object.assign(Object.assign({}, state), { loading: 'idle', errors: null }), action.payload);
|
|
68
68
|
})
|
|
69
69
|
.addCase(fetchGuest.pending, state => {
|
|
70
70
|
state.loading = 'pending';
|
|
@@ -77,7 +77,7 @@ const guestSlice = createSlice({
|
|
|
77
77
|
state.brands = null;
|
|
78
78
|
})
|
|
79
79
|
.addCase(fetchGuestThanx.fulfilled, (state, action) => {
|
|
80
|
-
|
|
80
|
+
return Object.assign(Object.assign(Object.assign({}, state), { loading: 'idle', errors: null, showMagicLink: true }), action.payload);
|
|
81
81
|
})
|
|
82
82
|
.addCase(fetchGuestThanx.pending, state => {
|
|
83
83
|
state.loading = 'pending';
|
package/dist/esm/slices/menu.js
CHANGED
|
@@ -65,7 +65,7 @@ const menuSlice = createSlice({
|
|
|
65
65
|
extraReducers: builder => {
|
|
66
66
|
builder
|
|
67
67
|
.addCase(fetchMenu.fulfilled, (state, action) => {
|
|
68
|
-
|
|
68
|
+
return Object.assign(Object.assign(Object.assign({}, state), { previousMenuVars: state.menuVars || null, loading: 'idle', error: null }), action.payload);
|
|
69
69
|
})
|
|
70
70
|
.addCase(fetchMenu.pending, state => {
|
|
71
71
|
state.loading = 'pending';
|
package/dist/esm/slices/order.js
CHANGED
|
@@ -399,7 +399,7 @@ const orderSlice = createSlice({
|
|
|
399
399
|
state.loading = 'idle';
|
|
400
400
|
})
|
|
401
401
|
.addCase(editOrder.fulfilled, (state, action) => {
|
|
402
|
-
|
|
402
|
+
return Object.assign(Object.assign(Object.assign({}, state), action.payload), { loading: 'idle', error: null });
|
|
403
403
|
})
|
|
404
404
|
.addCase(editOrder.pending, state => {
|
|
405
405
|
state.loading = 'pending';
|
|
@@ -408,7 +408,7 @@ const orderSlice = createSlice({
|
|
|
408
408
|
state.loading = 'idle';
|
|
409
409
|
})
|
|
410
410
|
.addCase(reorderPastOrder.fulfilled, (state, action) => {
|
|
411
|
-
|
|
411
|
+
return Object.assign(Object.assign(Object.assign({}, state), action.payload), { loading: 'idle', error: null });
|
|
412
412
|
})
|
|
413
413
|
.addCase(reorderPastOrder.pending, state => {
|
|
414
414
|
state.loading = 'pending';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@open-tender/cloud",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.65",
|
|
4
4
|
"description": "A library of hooks, reducers, utility functions, and types 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",
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"react": "^18.2.0"
|
|
56
56
|
},
|
|
57
57
|
"dependencies": {
|
|
58
|
-
"@open-tender/types": "^0.0.
|
|
58
|
+
"@open-tender/types": "^0.0.90",
|
|
59
59
|
"@open-tender/utils": "^0.0.23"
|
|
60
60
|
}
|
|
61
61
|
}
|