@open-tender/cloud 0.0.138 → 0.1.0
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/app/hooks.d.ts +1 -1
- package/dist/cjs/app/store.d.ts +9 -9
- package/dist/cjs/app/store.js +1 -1
- package/dist/cjs/index.d.ts +2 -2
- package/dist/cjs/services/api.d.ts +7 -7
- package/dist/cjs/services/api.js +70 -69
- package/dist/cjs/slices/alerts.d.ts +1 -1
- package/dist/cjs/slices/allergens.d.ts +7 -1
- package/dist/cjs/slices/announcements.d.ts +7 -1
- package/dist/cjs/slices/checkout.d.ts +20 -1
- package/dist/cjs/slices/completedOrders.d.ts +7 -1
- package/dist/cjs/slices/config.d.ts +7 -1
- package/dist/cjs/slices/config.js +18 -4
- package/dist/cjs/slices/confirmation.d.ts +1 -1
- package/dist/cjs/slices/customer/account.d.ts +55 -1
- package/dist/cjs/slices/customer/account.js +1 -1
- package/dist/cjs/slices/customer/addresses.d.ts +19 -1
- package/dist/cjs/slices/customer/allergens.d.ts +13 -1
- package/dist/cjs/slices/customer/communicationPreferences.d.ts +25 -1
- package/dist/cjs/slices/customer/creditCards.d.ts +25 -1
- package/dist/cjs/slices/customer/favorites.d.ts +28 -3
- package/dist/cjs/slices/customer/favorites.js +5 -6
- package/dist/cjs/slices/customer/fcmToken.d.ts +19 -1
- package/dist/cjs/slices/customer/giftCards.d.ts +37 -1
- package/dist/cjs/slices/customer/groupOrders.d.ts +65 -41
- package/dist/cjs/slices/customer/groupOrders.js +54 -54
- package/dist/cjs/slices/customer/houseAccounts.d.ts +7 -1
- package/dist/cjs/slices/customer/levelup.d.ts +19 -1
- package/dist/cjs/slices/customer/levelup.js +3 -3
- package/dist/cjs/slices/customer/loyalty.d.ts +7 -1
- package/dist/cjs/slices/customer/order.d.ts +13 -1
- package/dist/cjs/slices/customer/orders.d.ts +7 -1
- package/dist/cjs/slices/customer/qrCode.d.ts +7 -1
- package/dist/cjs/slices/customer/rewards.d.ts +7 -1
- package/dist/cjs/slices/customer/thanx.d.ts +7 -1
- package/dist/cjs/slices/deals.d.ts +7 -1
- package/dist/cjs/slices/donations.d.ts +7 -1
- package/dist/cjs/slices/geolocation.d.ts +1 -1
- package/dist/cjs/slices/geolocation.js +3 -3
- package/dist/cjs/slices/giftCards.d.ts +7 -1
- package/dist/cjs/slices/groupOrder.d.ts +42 -12
- package/dist/cjs/slices/groupOrder.js +23 -19
- package/dist/cjs/slices/guest.d.ts +13 -1
- package/dist/cjs/slices/levelup.d.ts +7 -1
- package/dist/cjs/slices/levelup.js +1 -1
- package/dist/cjs/slices/loader.d.ts +1 -1
- package/dist/cjs/slices/loader.js +3 -3
- package/dist/cjs/slices/menu.d.ts +7 -1
- package/dist/cjs/slices/menu.js +1 -1
- package/dist/cjs/slices/menuDisplay.d.ts +7 -1
- package/dist/cjs/slices/menuItems.d.ts +7 -1
- package/dist/cjs/slices/misc.d.ts +1 -1
- package/dist/cjs/slices/misc.js +2 -2
- package/dist/cjs/slices/modalSlice.d.ts +1 -1
- package/dist/cjs/slices/modalSlice.js +4 -4
- package/dist/cjs/slices/navSiteSlice.d.ts +1 -1
- package/dist/cjs/slices/navSiteSlice.js +4 -4
- package/dist/cjs/slices/navSlice.d.ts +1 -1
- package/dist/cjs/slices/navSlice.js +4 -4
- package/dist/cjs/slices/notifications.d.ts +1 -1
- package/dist/cjs/slices/order.d.ts +51 -15
- package/dist/cjs/slices/order.js +22 -14
- package/dist/cjs/slices/orderFulfillment.d.ts +13 -1
- package/dist/cjs/slices/orderRating.d.ts +19 -1
- package/dist/cjs/slices/orders.d.ts +43 -1
- package/dist/cjs/slices/postsSlice.d.ts +7 -1
- package/dist/cjs/slices/postsSlice.js +3 -3
- package/dist/cjs/slices/qr.d.ts +1 -1
- package/dist/cjs/slices/qr.js +3 -3
- package/dist/cjs/slices/resetPassword.d.ts +13 -1
- package/dist/cjs/slices/revenueCenters.d.ts +13 -1
- package/dist/cjs/slices/sidebarModalSlice.d.ts +1 -1
- package/dist/cjs/slices/sidebarModalSlice.js +4 -4
- package/dist/cjs/slices/sidebarSlice.d.ts +1 -1
- package/dist/cjs/slices/sidebarSlice.js +4 -4
- package/dist/cjs/slices/signUp.d.ts +7 -1
- package/dist/cjs/slices/signUp.js +4 -1
- package/dist/cjs/slices/validTimes.d.ts +7 -1
- package/dist/cjs/slices/verifyAccount.d.ts +7 -1
- package/dist/esm/app/hooks.d.ts +1 -1
- package/dist/esm/app/store.d.ts +9 -9
- package/dist/esm/app/store.js +2 -2
- package/dist/esm/index.d.ts +2 -2
- package/dist/esm/services/api.d.ts +7 -7
- package/dist/esm/services/api.js +70 -69
- package/dist/esm/slices/alerts.d.ts +1 -1
- package/dist/esm/slices/allergens.d.ts +7 -1
- package/dist/esm/slices/announcements.d.ts +7 -1
- package/dist/esm/slices/checkout.d.ts +20 -1
- package/dist/esm/slices/checkout.js +1 -1
- package/dist/esm/slices/completedOrders.d.ts +7 -1
- package/dist/esm/slices/config.d.ts +7 -1
- package/dist/esm/slices/config.js +18 -4
- package/dist/esm/slices/confirmation.d.ts +1 -1
- package/dist/esm/slices/customer/account.d.ts +55 -1
- package/dist/esm/slices/customer/account.js +1 -1
- package/dist/esm/slices/customer/addresses.d.ts +19 -1
- package/dist/esm/slices/customer/allergens.d.ts +13 -1
- package/dist/esm/slices/customer/communicationPreferences.d.ts +25 -1
- package/dist/esm/slices/customer/creditCards.d.ts +25 -1
- package/dist/esm/slices/customer/favorites.d.ts +28 -3
- package/dist/esm/slices/customer/favorites.js +5 -6
- package/dist/esm/slices/customer/fcmToken.d.ts +19 -1
- package/dist/esm/slices/customer/giftCards.d.ts +37 -1
- package/dist/esm/slices/customer/groupOrders.d.ts +65 -41
- package/dist/esm/slices/customer/groupOrders.js +54 -54
- package/dist/esm/slices/customer/houseAccounts.d.ts +7 -1
- package/dist/esm/slices/customer/levelup.d.ts +19 -1
- package/dist/esm/slices/customer/levelup.js +3 -3
- package/dist/esm/slices/customer/loyalty.d.ts +7 -1
- package/dist/esm/slices/customer/order.d.ts +13 -1
- package/dist/esm/slices/customer/orders.d.ts +7 -1
- package/dist/esm/slices/customer/qrCode.d.ts +7 -1
- package/dist/esm/slices/customer/rewards.d.ts +7 -1
- package/dist/esm/slices/customer/thanx.d.ts +7 -1
- package/dist/esm/slices/deals.d.ts +7 -1
- package/dist/esm/slices/donations.d.ts +7 -1
- package/dist/esm/slices/geolocation.d.ts +1 -1
- package/dist/esm/slices/geolocation.js +3 -3
- package/dist/esm/slices/giftCards.d.ts +7 -1
- package/dist/esm/slices/groupOrder.d.ts +42 -12
- package/dist/esm/slices/groupOrder.js +24 -23
- package/dist/esm/slices/guest.d.ts +13 -1
- package/dist/esm/slices/levelup.d.ts +7 -1
- package/dist/esm/slices/levelup.js +1 -1
- package/dist/esm/slices/loader.d.ts +1 -1
- package/dist/esm/slices/loader.js +3 -3
- package/dist/esm/slices/menu.d.ts +7 -1
- package/dist/esm/slices/menu.js +1 -1
- package/dist/esm/slices/menuDisplay.d.ts +7 -1
- package/dist/esm/slices/menuItems.d.ts +7 -1
- package/dist/esm/slices/misc.d.ts +1 -1
- package/dist/esm/slices/misc.js +3 -3
- package/dist/esm/slices/modalSlice.d.ts +1 -1
- package/dist/esm/slices/modalSlice.js +4 -4
- package/dist/esm/slices/navSiteSlice.d.ts +1 -1
- package/dist/esm/slices/navSiteSlice.js +4 -4
- package/dist/esm/slices/navSlice.d.ts +1 -1
- package/dist/esm/slices/navSlice.js +4 -4
- package/dist/esm/slices/notifications.d.ts +1 -1
- package/dist/esm/slices/order.d.ts +51 -15
- package/dist/esm/slices/order.js +23 -15
- package/dist/esm/slices/orderFulfillment.d.ts +13 -1
- package/dist/esm/slices/orderRating.d.ts +19 -1
- package/dist/esm/slices/orders.d.ts +43 -1
- package/dist/esm/slices/postsSlice.d.ts +7 -1
- package/dist/esm/slices/postsSlice.js +3 -3
- package/dist/esm/slices/qr.d.ts +1 -1
- package/dist/esm/slices/qr.js +3 -3
- package/dist/esm/slices/resetPassword.d.ts +13 -1
- package/dist/esm/slices/revenueCenters.d.ts +13 -1
- package/dist/esm/slices/sidebarModalSlice.d.ts +1 -1
- package/dist/esm/slices/sidebarModalSlice.js +4 -4
- package/dist/esm/slices/sidebarSlice.d.ts +1 -1
- package/dist/esm/slices/sidebarSlice.js +4 -4
- package/dist/esm/slices/signUp.d.ts +7 -1
- package/dist/esm/slices/signUp.js +4 -1
- package/dist/esm/slices/validTimes.d.ts +7 -1
- package/dist/esm/slices/verifyAccount.d.ts +7 -1
- package/package.json +4 -7
package/dist/esm/services/api.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { __awaiter } from "tslib";
|
|
1
2
|
import { serialize } from '@open-tender/utils';
|
|
2
3
|
class requestException extends Error {
|
|
3
4
|
constructor(message, response, exception, extracted) {
|
|
@@ -13,13 +14,13 @@ const fiveHundredError = (status = 500, statusText = 'Unknown 500 error') => ({
|
|
|
13
14
|
status: status,
|
|
14
15
|
code: 'errors.server.internal',
|
|
15
16
|
title: 'Internal Server Error',
|
|
16
|
-
detail: statusText
|
|
17
|
+
detail: statusText
|
|
17
18
|
});
|
|
18
19
|
const unauthorizedError = {
|
|
19
20
|
status: 401,
|
|
20
21
|
code: 'errors.unauthorized',
|
|
21
22
|
title: 'Unauthorized',
|
|
22
|
-
detail: 'Provided token is not valid'
|
|
23
|
+
detail: 'Provided token is not valid'
|
|
23
24
|
};
|
|
24
25
|
const handleResponse = (response) => {
|
|
25
26
|
const { status, statusText } = response;
|
|
@@ -52,74 +53,74 @@ const handleResponse = (response) => {
|
|
|
52
53
|
};
|
|
53
54
|
class OpenTenderAPI {
|
|
54
55
|
constructor(config) {
|
|
55
|
-
this.
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
})
|
|
98
|
-
.finally(() => {
|
|
99
|
-
if (timeout)
|
|
100
|
-
clearTimeout(timer);
|
|
56
|
+
this.request = (endpoint, method = 'GET', data = null, timeout = null, token = null) => __awaiter(this, void 0, void 0, function* () {
|
|
57
|
+
let didTimeOut = false;
|
|
58
|
+
return new Promise((resolve, reject) => {
|
|
59
|
+
let timer;
|
|
60
|
+
if (timeout) {
|
|
61
|
+
timer = setTimeout(() => {
|
|
62
|
+
didTimeOut = true;
|
|
63
|
+
reject(new Error('Request timed out'));
|
|
64
|
+
}, timeout);
|
|
65
|
+
}
|
|
66
|
+
const headers = {
|
|
67
|
+
Accept: 'application/json',
|
|
68
|
+
'Content-Type': 'application/json'
|
|
69
|
+
};
|
|
70
|
+
if (this.clientId)
|
|
71
|
+
headers['client-id'] = `${this.clientId}`;
|
|
72
|
+
if (this.brandId)
|
|
73
|
+
headers['brand-id'] = `${this.brandId}`;
|
|
74
|
+
if (token)
|
|
75
|
+
headers.Authorization = `Bearer ${token}`;
|
|
76
|
+
const options = {
|
|
77
|
+
method: method,
|
|
78
|
+
headers: headers
|
|
79
|
+
};
|
|
80
|
+
if (data)
|
|
81
|
+
options.body = JSON.stringify(data);
|
|
82
|
+
fetch(`${this.baseUrl}${endpoint}`, options)
|
|
83
|
+
.then(handleResponse)
|
|
84
|
+
.then(json => {
|
|
85
|
+
if (didTimeOut)
|
|
86
|
+
return;
|
|
87
|
+
resolve(json);
|
|
88
|
+
})
|
|
89
|
+
.catch(err => {
|
|
90
|
+
if (didTimeOut)
|
|
91
|
+
return;
|
|
92
|
+
err.code ? reject(err) : reject(fiveHundredError());
|
|
93
|
+
})
|
|
94
|
+
.finally(() => {
|
|
95
|
+
if (timeout)
|
|
96
|
+
clearTimeout(timer);
|
|
97
|
+
});
|
|
101
98
|
});
|
|
102
99
|
});
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
100
|
+
this.authRequest = (endpoint, data) => __awaiter(this, void 0, void 0, function* () {
|
|
101
|
+
return new Promise((resolve, reject) => {
|
|
102
|
+
data.client_id = this.clientId;
|
|
103
|
+
const options = {
|
|
104
|
+
method: 'POST',
|
|
105
|
+
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
|
|
106
|
+
body: serialize(data)
|
|
107
|
+
};
|
|
108
|
+
fetch(`${this.authUrl}/oauth2${endpoint}`, options)
|
|
109
|
+
.then(res => res.json())
|
|
110
|
+
.then(json => {
|
|
111
|
+
if (json.error)
|
|
112
|
+
throw new Error(json.error_description);
|
|
113
|
+
resolve(json);
|
|
114
|
+
})
|
|
115
|
+
.catch(err => {
|
|
116
|
+
reject(err);
|
|
117
|
+
});
|
|
121
118
|
});
|
|
122
119
|
});
|
|
120
|
+
this.brandId = config === null || config === void 0 ? void 0 : config.brandId;
|
|
121
|
+
this.clientId = config === null || config === void 0 ? void 0 : config.clientId;
|
|
122
|
+
this.baseUrl = config === null || config === void 0 ? void 0 : config.baseUrl;
|
|
123
|
+
this.authUrl = config === null || config === void 0 ? void 0 : config.authUrl;
|
|
123
124
|
}
|
|
124
125
|
post(endpoint, data) {
|
|
125
126
|
return this.request(`/${endpoint}`, 'POST', data);
|
|
@@ -416,11 +417,11 @@ class OpenTenderAPI {
|
|
|
416
417
|
params = [
|
|
417
418
|
`prep_status=TODO,IN_PROGRESS,DONE`,
|
|
418
419
|
`sort_by=fire_at`,
|
|
419
|
-
`sort_direction=ASC
|
|
420
|
+
`sort_direction=ASC`
|
|
420
421
|
];
|
|
421
422
|
}
|
|
422
423
|
else {
|
|
423
|
-
const { business_date, channel_type, prep_status, receipt_type, parent_receipt_uuid, search, sort_by, sort_direction
|
|
424
|
+
const { business_date, channel_type, prep_status, receipt_type, parent_receipt_uuid, search, sort_by, sort_direction } = args;
|
|
424
425
|
if (business_date)
|
|
425
426
|
params.push(`business_date=${business_date}`);
|
|
426
427
|
if (channel_type)
|
|
@@ -509,7 +510,7 @@ class OpenTenderAPI {
|
|
|
509
510
|
const data = {
|
|
510
511
|
grant_type: 'password',
|
|
511
512
|
username: email,
|
|
512
|
-
password: password
|
|
513
|
+
password: password
|
|
513
514
|
};
|
|
514
515
|
return this.authRequest('/token', data);
|
|
515
516
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Alerts } from '@open-tender/types';
|
|
2
2
|
import { AppState } from '../app';
|
|
3
|
-
export declare const clearAlerts: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
3
|
+
export declare const clearAlerts: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"alerts/clearAlerts">, addAlert: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "alerts/addAlert">, dismissAlert: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "alerts/dismissAlert">;
|
|
4
4
|
export declare const selectAlerts: (state: AppState) => Alerts;
|
|
5
5
|
export declare const alertsReducer: import("redux").Reducer<Alerts, import("redux").AnyAction>;
|
|
@@ -12,8 +12,14 @@ export declare enum AllergensActionType {
|
|
|
12
12
|
export declare const fetchAllergens: import("@reduxjs/toolkit").AsyncThunk<Allergens, void, {
|
|
13
13
|
state: AppState;
|
|
14
14
|
rejectValue: RequestError;
|
|
15
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
16
|
+
extra?: unknown;
|
|
17
|
+
serializedErrorType?: unknown;
|
|
18
|
+
pendingMeta?: unknown;
|
|
19
|
+
fulfilledMeta?: unknown;
|
|
20
|
+
rejectedMeta?: unknown;
|
|
15
21
|
}>;
|
|
16
|
-
export declare const resetAllergens: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
22
|
+
export declare const resetAllergens: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"allergens/resetAllergens">, setSelectedAllergens: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "allergens/setSelectedAllergens">;
|
|
17
23
|
export declare const selectAllergens: (state: AppState) => AllergensState;
|
|
18
24
|
export declare const selectSelectedAllergenNames: (state: AppState) => string[];
|
|
19
25
|
export declare const allergensReducer: import("redux").Reducer<AllergensState, import("redux").AnyAction>;
|
|
@@ -15,8 +15,14 @@ export declare const fetchAnnouncementPage: import("@reduxjs/toolkit").AsyncThun
|
|
|
15
15
|
error: RequestError;
|
|
16
16
|
page: AuthType;
|
|
17
17
|
};
|
|
18
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
19
|
+
extra?: unknown;
|
|
20
|
+
serializedErrorType?: unknown;
|
|
21
|
+
pendingMeta?: unknown;
|
|
22
|
+
fulfilledMeta?: unknown;
|
|
23
|
+
rejectedMeta?: unknown;
|
|
18
24
|
}>;
|
|
19
|
-
export declare const resetAnnouncements: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
25
|
+
export declare const resetAnnouncements: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"announcements/resetAnnouncements">;
|
|
20
26
|
export declare const selectAnnouncements: (state: AppState) => AnnouncementsState;
|
|
21
27
|
export declare const selectAnnouncementsPage: (page: AuthType) => (state: AppState) => {
|
|
22
28
|
settings: import("@open-tender/types").AnnouncementSettings | null;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Dispatch } from '@reduxjs/toolkit';
|
|
1
2
|
import { AppState } from '../app';
|
|
2
3
|
import { CheckoutCheck, CheckoutForm, CompletedOrder, Order, RequestStatus } from '@open-tender/types';
|
|
3
4
|
export interface CheckoutState {
|
|
@@ -21,16 +22,34 @@ export declare const validateOrder: import("@reduxjs/toolkit").AsyncThunk<{
|
|
|
21
22
|
}, Partial<Order> | undefined, {
|
|
22
23
|
state: AppState;
|
|
23
24
|
rejectValue: any;
|
|
25
|
+
dispatch?: Dispatch<import("redux").AnyAction> | undefined;
|
|
26
|
+
extra?: unknown;
|
|
27
|
+
serializedErrorType?: unknown;
|
|
28
|
+
pendingMeta?: unknown;
|
|
29
|
+
fulfilledMeta?: unknown;
|
|
30
|
+
rejectedMeta?: unknown;
|
|
24
31
|
}>;
|
|
25
32
|
export declare const submitOrder: import("@reduxjs/toolkit").AsyncThunk<CompletedOrder, void, {
|
|
26
33
|
state: AppState;
|
|
27
34
|
rejectValue: any;
|
|
35
|
+
dispatch?: Dispatch<import("redux").AnyAction> | undefined;
|
|
36
|
+
extra?: unknown;
|
|
37
|
+
serializedErrorType?: unknown;
|
|
38
|
+
pendingMeta?: unknown;
|
|
39
|
+
fulfilledMeta?: unknown;
|
|
40
|
+
rejectedMeta?: unknown;
|
|
28
41
|
}>;
|
|
29
42
|
export declare const submitOrderPay: import("@reduxjs/toolkit").AsyncThunk<CompletedOrder, boolean | undefined, {
|
|
30
43
|
state: AppState;
|
|
31
44
|
rejectValue: any;
|
|
45
|
+
dispatch?: Dispatch<import("redux").AnyAction> | undefined;
|
|
46
|
+
extra?: unknown;
|
|
47
|
+
serializedErrorType?: unknown;
|
|
48
|
+
pendingMeta?: unknown;
|
|
49
|
+
fulfilledMeta?: unknown;
|
|
50
|
+
rejectedMeta?: unknown;
|
|
32
51
|
}>;
|
|
33
|
-
export declare const resetCheckout: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
52
|
+
export declare const resetCheckout: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"checkout/resetCheckout">, resetCheck: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"checkout/resetCheck">, resetCompletedOrder: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"checkout/resetCompletedOrder">, resetErrors: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"checkout/resetErrors">, resetTip: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"checkout/resetTip">, setCompletedOrder: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "checkout/setCompletedOrder">, setGuest: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "checkout/setGuest">, setSubmitting: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "checkout/setSubmitting">, updateCheckoutCustomer: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "checkout/updateCheckoutCustomer">, updateForm: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "checkout/updateForm">;
|
|
34
53
|
export declare const selectCheckout: (state: AppState) => CheckoutState;
|
|
35
54
|
export declare const selectCheck: (state: AppState) => CheckoutCheck | null;
|
|
36
55
|
export declare const selectCompletedOrder: (state: AppState) => CompletedOrder | null;
|
|
@@ -2,7 +2,7 @@ import { __awaiter } from "tslib";
|
|
|
2
2
|
import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';
|
|
3
3
|
import { ReducerType } from './types';
|
|
4
4
|
import { loginCustomer, selectToken } from './customer';
|
|
5
|
-
import { isEmpty, prepareOrder, handleCheckoutErrors, contains, isString
|
|
5
|
+
import { isEmpty, prepareOrder, handleCheckoutErrors, contains, isString } from '@open-tender/utils';
|
|
6
6
|
import { refreshRevenueCenter, setAlert } from './order';
|
|
7
7
|
import { fetchMenu } from './menu';
|
|
8
8
|
const initialState = {
|
|
@@ -15,8 +15,14 @@ export declare const fetchCompletedOrders: import("@reduxjs/toolkit").AsyncThunk
|
|
|
15
15
|
}, {
|
|
16
16
|
state: AppState;
|
|
17
17
|
rejectValue: RequestError;
|
|
18
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
19
|
+
extra?: unknown;
|
|
20
|
+
serializedErrorType?: unknown;
|
|
21
|
+
pendingMeta?: unknown;
|
|
22
|
+
fulfilledMeta?: unknown;
|
|
23
|
+
rejectedMeta?: unknown;
|
|
18
24
|
}>;
|
|
19
|
-
export declare const resetCompletedOrders: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
25
|
+
export declare const resetCompletedOrders: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"completedOrders/resetCompletedOrders">;
|
|
20
26
|
export declare const selectCompletedOrders: (state: AppState) => {
|
|
21
27
|
orders: CompletedOrders;
|
|
22
28
|
loading: RequestStatus;
|
|
@@ -26,8 +26,14 @@ export declare const fetchConfig: import("@reduxjs/toolkit").AsyncThunk<ConfigSt
|
|
|
26
26
|
}, {
|
|
27
27
|
state: AppState;
|
|
28
28
|
rejectValue: RequestError;
|
|
29
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
30
|
+
extra?: unknown;
|
|
31
|
+
serializedErrorType?: unknown;
|
|
32
|
+
pendingMeta?: unknown;
|
|
33
|
+
fulfilledMeta?: unknown;
|
|
34
|
+
rejectedMeta?: unknown;
|
|
29
35
|
}>;
|
|
30
|
-
export declare const resetConfig: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
36
|
+
export declare const resetConfig: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"config/resetConfig">, resetRetries: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"config/resetRetries">, incrementRetries: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"config/incrementRetries">;
|
|
31
37
|
export declare const selectCateringOnly: (state: AppState) => boolean;
|
|
32
38
|
export declare const selectConfig: (state: AppState) => ConfigState;
|
|
33
39
|
export declare const selectBrand: (state: AppState) => ConfigBrand | null;
|
|
@@ -24,7 +24,12 @@ export const fetchConfig = createAsyncThunk(ConfigActionType.FetchConfig, (optio
|
|
|
24
24
|
try {
|
|
25
25
|
const api = new OpenTenderAPI(options);
|
|
26
26
|
const response = yield api.getConfig();
|
|
27
|
-
const app = {
|
|
27
|
+
const app = {
|
|
28
|
+
baseUrl: options.baseUrl,
|
|
29
|
+
authUrl: options.authUrl,
|
|
30
|
+
clientId: options.clientId,
|
|
31
|
+
brandId: options.brandId
|
|
32
|
+
};
|
|
28
33
|
options.callback && options.callback();
|
|
29
34
|
return Object.assign(Object.assign({}, response), { app });
|
|
30
35
|
}
|
|
@@ -42,7 +47,7 @@ const configSlice = createSlice({
|
|
|
42
47
|
},
|
|
43
48
|
incrementRetries: state => {
|
|
44
49
|
state.retries = state.retries + 1;
|
|
45
|
-
}
|
|
50
|
+
}
|
|
46
51
|
},
|
|
47
52
|
extraReducers: builder => {
|
|
48
53
|
builder
|
|
@@ -51,7 +56,11 @@ const configSlice = createSlice({
|
|
|
51
56
|
state.app = app;
|
|
52
57
|
state.brand = brand;
|
|
53
58
|
state.content = content;
|
|
54
|
-
state.theme = theme
|
|
59
|
+
state.theme = theme
|
|
60
|
+
? action.meta.arg.isMobile
|
|
61
|
+
? decorateTheme(theme)
|
|
62
|
+
: theme
|
|
63
|
+
: null;
|
|
55
64
|
state.settings = settings;
|
|
56
65
|
state.loading = 'idle';
|
|
57
66
|
state.api = new OpenTenderAPI(app);
|
|
@@ -107,7 +116,12 @@ export const selectHeaderHeight = (state) => (isBrowser) => {
|
|
|
107
116
|
const height = isBrowser ? navHeight : navHeightMobile;
|
|
108
117
|
return parseInt(height.replace('rem', '')) * 10;
|
|
109
118
|
};
|
|
110
|
-
export const selectOutpostName = (state) => {
|
|
119
|
+
export const selectOutpostName = (state) => {
|
|
120
|
+
var _a, _b, _c;
|
|
121
|
+
return ((_a = state.config.settings) === null || _a === void 0 ? void 0 : _a.locationName.OUTPOST)
|
|
122
|
+
? capitalize((_c = (_b = state.config.settings) === null || _b === void 0 ? void 0 : _b.locationName.OUTPOST[0]) !== null && _c !== void 0 ? _c : '')
|
|
123
|
+
: undefined;
|
|
124
|
+
};
|
|
111
125
|
export const selectHasCatering = (state) => {
|
|
112
126
|
var _a;
|
|
113
127
|
const { orderTypes } = state.config.settings || {};
|
|
@@ -3,6 +3,6 @@ import { AppState } from '../app';
|
|
|
3
3
|
export interface ConfirmationState {
|
|
4
4
|
order: Order | null;
|
|
5
5
|
}
|
|
6
|
-
export declare const resetConfirmation: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
6
|
+
export declare const resetConfirmation: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"confirmation/resetConfirmation">, setConfirmationOrder: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "confirmation/setConfirmationOrder">;
|
|
7
7
|
export declare const selectConfirmationOrder: (state: AppState) => Order | null;
|
|
8
8
|
export declare const confirmationReducer: import("redux").Reducer<ConfirmationState, import("redux").AnyAction>;
|
|
@@ -20,18 +20,42 @@ export declare const checkAuth: (err: RequestError, dispatch: ThunkDispatch<AppS
|
|
|
20
20
|
export declare const fetchCustomer: import("@reduxjs/toolkit").AsyncThunk<Partial<Profile>, void, {
|
|
21
21
|
state: AppState;
|
|
22
22
|
rejectValue: RequestError;
|
|
23
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
24
|
+
extra?: unknown;
|
|
25
|
+
serializedErrorType?: unknown;
|
|
26
|
+
pendingMeta?: unknown;
|
|
27
|
+
fulfilledMeta?: unknown;
|
|
28
|
+
rejectedMeta?: unknown;
|
|
23
29
|
}>;
|
|
24
30
|
export declare const loginCustomer: import("@reduxjs/toolkit").AsyncThunk<Auth, LoginData, {
|
|
25
31
|
state: AppState;
|
|
26
32
|
rejectValue: RequestError;
|
|
33
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
34
|
+
extra?: unknown;
|
|
35
|
+
serializedErrorType?: unknown;
|
|
36
|
+
pendingMeta?: unknown;
|
|
37
|
+
fulfilledMeta?: unknown;
|
|
38
|
+
rejectedMeta?: unknown;
|
|
27
39
|
}>;
|
|
28
40
|
export declare const logoutCustomer: import("@reduxjs/toolkit").AsyncThunk<null, boolean | undefined, {
|
|
29
41
|
state: AppState;
|
|
30
42
|
rejectValue: RequestError;
|
|
43
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
44
|
+
extra?: unknown;
|
|
45
|
+
serializedErrorType?: unknown;
|
|
46
|
+
pendingMeta?: unknown;
|
|
47
|
+
fulfilledMeta?: unknown;
|
|
48
|
+
rejectedMeta?: unknown;
|
|
31
49
|
}>;
|
|
32
50
|
export declare const linkPosToken: import("@reduxjs/toolkit").AsyncThunk<void, string, {
|
|
33
51
|
state: AppState;
|
|
34
52
|
rejectValue: RequestError;
|
|
53
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
54
|
+
extra?: unknown;
|
|
55
|
+
serializedErrorType?: unknown;
|
|
56
|
+
pendingMeta?: unknown;
|
|
57
|
+
fulfilledMeta?: unknown;
|
|
58
|
+
rejectedMeta?: unknown;
|
|
35
59
|
}>;
|
|
36
60
|
export declare const updateCustomer: import("@reduxjs/toolkit").AsyncThunk<Partial<Profile>, {
|
|
37
61
|
data: Partial<Profile>;
|
|
@@ -39,10 +63,22 @@ export declare const updateCustomer: import("@reduxjs/toolkit").AsyncThunk<Parti
|
|
|
39
63
|
}, {
|
|
40
64
|
state: AppState;
|
|
41
65
|
rejectValue: RequestError;
|
|
66
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
67
|
+
extra?: unknown;
|
|
68
|
+
serializedErrorType?: unknown;
|
|
69
|
+
pendingMeta?: unknown;
|
|
70
|
+
fulfilledMeta?: unknown;
|
|
71
|
+
rejectedMeta?: unknown;
|
|
42
72
|
}>;
|
|
43
73
|
export declare const sendCustomerVerificationEmail: import("@reduxjs/toolkit").AsyncThunk<void, string, {
|
|
44
74
|
state: AppState;
|
|
45
75
|
rejectValue: RequestError;
|
|
76
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
77
|
+
extra?: unknown;
|
|
78
|
+
serializedErrorType?: unknown;
|
|
79
|
+
pendingMeta?: unknown;
|
|
80
|
+
fulfilledMeta?: unknown;
|
|
81
|
+
rejectedMeta?: unknown;
|
|
46
82
|
}>;
|
|
47
83
|
export declare const loginCustomerThanx: import("@reduxjs/toolkit").AsyncThunk<null, {
|
|
48
84
|
email: string;
|
|
@@ -50,6 +86,12 @@ export declare const loginCustomerThanx: import("@reduxjs/toolkit").AsyncThunk<n
|
|
|
50
86
|
}, {
|
|
51
87
|
state: AppState;
|
|
52
88
|
rejectValue: RequestError;
|
|
89
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
90
|
+
extra?: unknown;
|
|
91
|
+
serializedErrorType?: unknown;
|
|
92
|
+
pendingMeta?: unknown;
|
|
93
|
+
fulfilledMeta?: unknown;
|
|
94
|
+
rejectedMeta?: unknown;
|
|
53
95
|
}>;
|
|
54
96
|
export declare const authCustomerThanx: import("@reduxjs/toolkit").AsyncThunk<Auth, {
|
|
55
97
|
code: any;
|
|
@@ -58,6 +100,12 @@ export declare const authCustomerThanx: import("@reduxjs/toolkit").AsyncThunk<Au
|
|
|
58
100
|
}, {
|
|
59
101
|
state: AppState;
|
|
60
102
|
rejectValue: RequestError;
|
|
103
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
104
|
+
extra?: unknown;
|
|
105
|
+
serializedErrorType?: unknown;
|
|
106
|
+
pendingMeta?: unknown;
|
|
107
|
+
fulfilledMeta?: unknown;
|
|
108
|
+
rejectedMeta?: unknown;
|
|
61
109
|
}>;
|
|
62
110
|
export declare const deleteCustomer: import("@reduxjs/toolkit").AsyncThunk<void, {
|
|
63
111
|
data?: Partial<Profile> | undefined;
|
|
@@ -65,8 +113,14 @@ export declare const deleteCustomer: import("@reduxjs/toolkit").AsyncThunk<void,
|
|
|
65
113
|
}, {
|
|
66
114
|
state: AppState;
|
|
67
115
|
rejectValue: RequestError;
|
|
116
|
+
dispatch?: import("redux").Dispatch<AnyAction> | undefined;
|
|
117
|
+
extra?: unknown;
|
|
118
|
+
serializedErrorType?: unknown;
|
|
119
|
+
pendingMeta?: unknown;
|
|
120
|
+
fulfilledMeta?: unknown;
|
|
121
|
+
rejectedMeta?: unknown;
|
|
68
122
|
}>;
|
|
69
|
-
export declare const resetCustomer: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
123
|
+
export declare const resetCustomer: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"account/resetCustomer">, resetLoginError: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"account/resetLoginError">, fulfillLoginCustomer: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "account/fulfillLoginCustomer">;
|
|
70
124
|
export declare const selectToken: (state: AppState) => string | null;
|
|
71
125
|
export declare const selectCustomer: (state: AppState) => AccountState;
|
|
72
126
|
export declare const accountReducer: import("redux").Reducer<AccountState, AnyAction>;
|
|
@@ -309,7 +309,7 @@ const accountSlice = createSlice({
|
|
|
309
309
|
//do nothing
|
|
310
310
|
})
|
|
311
311
|
.addCase(deleteCustomer.fulfilled, () => initialState)
|
|
312
|
-
.addCase(deleteCustomer.pending,
|
|
312
|
+
.addCase(deleteCustomer.pending, state => {
|
|
313
313
|
state.loading = 'pending';
|
|
314
314
|
})
|
|
315
315
|
.addCase(deleteCustomer.rejected, () => initialState);
|
|
@@ -16,6 +16,12 @@ export declare enum CustomerAddressesActionType {
|
|
|
16
16
|
export declare const fetchCustomerAddresses: import("@reduxjs/toolkit").AsyncThunk<Addresses, number, {
|
|
17
17
|
state: AppState;
|
|
18
18
|
rejectValue: RequestError;
|
|
19
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
20
|
+
extra?: unknown;
|
|
21
|
+
serializedErrorType?: unknown;
|
|
22
|
+
pendingMeta?: unknown;
|
|
23
|
+
fulfilledMeta?: unknown;
|
|
24
|
+
rejectedMeta?: unknown;
|
|
19
25
|
}>;
|
|
20
26
|
export declare const updateCustomerAddress: import("@reduxjs/toolkit").AsyncThunk<Addresses, {
|
|
21
27
|
addressId: number;
|
|
@@ -24,6 +30,12 @@ export declare const updateCustomerAddress: import("@reduxjs/toolkit").AsyncThun
|
|
|
24
30
|
}, {
|
|
25
31
|
state: AppState;
|
|
26
32
|
rejectValue: RequestError;
|
|
33
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
34
|
+
extra?: unknown;
|
|
35
|
+
serializedErrorType?: unknown;
|
|
36
|
+
pendingMeta?: unknown;
|
|
37
|
+
fulfilledMeta?: unknown;
|
|
38
|
+
rejectedMeta?: unknown;
|
|
27
39
|
}>;
|
|
28
40
|
export declare const removeCustomerAddress: import("@reduxjs/toolkit").AsyncThunk<Addresses, {
|
|
29
41
|
addressId: number;
|
|
@@ -31,7 +43,13 @@ export declare const removeCustomerAddress: import("@reduxjs/toolkit").AsyncThun
|
|
|
31
43
|
}, {
|
|
32
44
|
state: AppState;
|
|
33
45
|
rejectValue: RequestError;
|
|
46
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
47
|
+
extra?: unknown;
|
|
48
|
+
serializedErrorType?: unknown;
|
|
49
|
+
pendingMeta?: unknown;
|
|
50
|
+
fulfilledMeta?: unknown;
|
|
51
|
+
rejectedMeta?: unknown;
|
|
34
52
|
}>;
|
|
35
|
-
export declare const resetCustomerAddresses: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
53
|
+
export declare const resetCustomerAddresses: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"addresses/resetCustomerAddresses">, setCustomerAddresses: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "addresses/setCustomerAddresses">, resetCustomerAddressesError: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"addresses/resetCustomerAddressesError">;
|
|
36
54
|
export declare const selectCustomerAddresses: (state: AppState) => CustomerAddressesState;
|
|
37
55
|
export declare const customerAddressesReducer: import("redux").Reducer<CustomerAddressesState, import("redux").AnyAction>;
|
|
@@ -15,11 +15,23 @@ export declare enum CustomerAllergensActionType {
|
|
|
15
15
|
export declare const fetchCustomerAllergens: import("@reduxjs/toolkit").AsyncThunk<Allergens, void, {
|
|
16
16
|
state: AppState;
|
|
17
17
|
rejectValue: RequestError;
|
|
18
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
19
|
+
extra?: unknown;
|
|
20
|
+
serializedErrorType?: unknown;
|
|
21
|
+
pendingMeta?: unknown;
|
|
22
|
+
fulfilledMeta?: unknown;
|
|
23
|
+
rejectedMeta?: unknown;
|
|
18
24
|
}>;
|
|
19
25
|
export declare const updateCustomerAllergens: import("@reduxjs/toolkit").AsyncThunk<Allergens, Allergens, {
|
|
20
26
|
state: AppState;
|
|
21
27
|
rejectValue: RequestError;
|
|
28
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
29
|
+
extra?: unknown;
|
|
30
|
+
serializedErrorType?: unknown;
|
|
31
|
+
pendingMeta?: unknown;
|
|
32
|
+
fulfilledMeta?: unknown;
|
|
33
|
+
rejectedMeta?: unknown;
|
|
22
34
|
}>;
|
|
23
|
-
export declare const resetCustomerAllergens: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
35
|
+
export declare const resetCustomerAllergens: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"allergens/resetCustomerAllergens">, setCustomerAllergens: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "allergens/setCustomerAllergens">;
|
|
24
36
|
export declare const selectCustomerAllergens: (state: AppState) => CustomerAllergensState;
|
|
25
37
|
export declare const customerAllergensReducer: import("redux").Reducer<CustomerAllergensState, import("redux").AnyAction>;
|
|
@@ -17,6 +17,12 @@ export declare enum CustomerCommunicationPrefsActionType {
|
|
|
17
17
|
export declare const fetchCustomerCommunicationPreferences: import("@reduxjs/toolkit").AsyncThunk<CustomerNotificationPrefs, void, {
|
|
18
18
|
state: AppState;
|
|
19
19
|
rejectValue: RequestError;
|
|
20
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
21
|
+
extra?: unknown;
|
|
22
|
+
serializedErrorType?: unknown;
|
|
23
|
+
pendingMeta?: unknown;
|
|
24
|
+
fulfilledMeta?: unknown;
|
|
25
|
+
rejectedMeta?: unknown;
|
|
20
26
|
}>;
|
|
21
27
|
export declare const addCustomerCommunicationPreference: import("@reduxjs/toolkit").AsyncThunk<CustomerNotificationPrefs, {
|
|
22
28
|
area: NotificationArea;
|
|
@@ -25,6 +31,12 @@ export declare const addCustomerCommunicationPreference: import("@reduxjs/toolki
|
|
|
25
31
|
}, {
|
|
26
32
|
state: AppState;
|
|
27
33
|
rejectValue: RequestError;
|
|
34
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
35
|
+
extra?: unknown;
|
|
36
|
+
serializedErrorType?: unknown;
|
|
37
|
+
pendingMeta?: unknown;
|
|
38
|
+
fulfilledMeta?: unknown;
|
|
39
|
+
rejectedMeta?: unknown;
|
|
28
40
|
}>;
|
|
29
41
|
export declare const removeCustomerCommunicationPreference: import("@reduxjs/toolkit").AsyncThunk<CustomerNotificationPrefs, {
|
|
30
42
|
prefId: number;
|
|
@@ -32,6 +44,12 @@ export declare const removeCustomerCommunicationPreference: import("@reduxjs/too
|
|
|
32
44
|
}, {
|
|
33
45
|
state: AppState;
|
|
34
46
|
rejectValue: RequestError;
|
|
47
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
48
|
+
extra?: unknown;
|
|
49
|
+
serializedErrorType?: unknown;
|
|
50
|
+
pendingMeta?: unknown;
|
|
51
|
+
fulfilledMeta?: unknown;
|
|
52
|
+
rejectedMeta?: unknown;
|
|
35
53
|
}>;
|
|
36
54
|
export declare const setCustomerCommunicationDefaultPreferences: import("@reduxjs/toolkit").AsyncThunk<CustomerNotificationPrefs, {
|
|
37
55
|
prefs: CustomerNotificationPrefs;
|
|
@@ -39,7 +57,13 @@ export declare const setCustomerCommunicationDefaultPreferences: import("@reduxj
|
|
|
39
57
|
}, {
|
|
40
58
|
state: AppState;
|
|
41
59
|
rejectValue: RequestError;
|
|
60
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
61
|
+
extra?: unknown;
|
|
62
|
+
serializedErrorType?: unknown;
|
|
63
|
+
pendingMeta?: unknown;
|
|
64
|
+
fulfilledMeta?: unknown;
|
|
65
|
+
rejectedMeta?: unknown;
|
|
42
66
|
}>;
|
|
43
|
-
export declare const resetCustomerCommunicationPreferences: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
67
|
+
export declare const resetCustomerCommunicationPreferences: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"communicationPreferences/resetCustomerCommunicationPreferences">, resetCustomerCommunicationPreferencesError: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"communicationPreferences/resetCustomerCommunicationPreferencesError">, setCustomerCommunicationPreferences: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "communicationPreferences/setCustomerCommunicationPreferences">;
|
|
44
68
|
export declare const customerCommunicationPrefsReducer: import("redux").Reducer<CustomerCommunicationPrefsState, import("redux").AnyAction>;
|
|
45
69
|
export declare const selectCustomerCommunicationPreferences: (state: AppState) => CustomerCommunicationPrefsState;
|