ordering-ui-admin-external 1.3.1 → 1.3.3
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/_bundles/{ordering-ui-admin.0bfe9a0aef33a990bc0a.js → ordering-ui-admin.7b1ded1d480e937548f3.js} +2 -2
- package/_bundles/{ordering-ui-admin.0bfe9a0aef33a990bc0a.js.LICENSE.txt → ordering-ui-admin.7b1ded1d480e937548f3.js.LICENSE.txt} +0 -0
- package/_modules/components/BusinessIntelligence/Reports/index.js +3 -27
- package/_modules/components/BusinessIntelligence/Reports/styles.js +2 -9
- package/_modules/components/Loyalty/RewardsPrograms/index.js +12 -38
- package/_modules/components/Loyalty/RewardsPrograms/styles.js +6 -13
- package/_modules/components/Marketing/CampaignHeader/index.js +2 -5
- package/_modules/components/Marketing/CampaignHeader/styles.js +4 -7
- package/_modules/components/Marketing/CampaignList/index.js +4 -8
- package/_modules/components/Marketing/CampaignList/styles.js +22 -30
- package/_modules/components/Marketing/CampaignListing/index.js +3 -29
- package/_modules/components/OrderingProducts/OrderingProductDetails/index.js +4 -2
- package/_modules/components/Orders/CurrencyFilter/index.js +24 -47
- package/_modules/components/Orders/OrderBill/index.js +40 -11
- package/_modules/components/Orders/OrderDetails/index.js +2 -1
- package/_modules/components/Orders/OrdersTable/index.js +5 -2
- package/_modules/components/Orders/ProductItemAccordion/index.js +10 -5
- package/_modules/components/Settings/PluginList/index.js +31 -1
- package/_modules/components/Settings/SettingsDetail/index.js +3 -40
- package/_modules/components/Settings/SettingsDetail/styles.js +13 -26
- package/_modules/components/Settings/SettingsList/index.js +6 -43
- package/_modules/components/SidebarMenu/index.js +17 -20
- package/_modules/components/Stores/BusinessMenu/index.js +5 -36
- package/_modules/components/Stores/BusinessMenu/styles.js +19 -27
- package/_modules/components/Stores/BusinessPaymentMethods/index.js +16 -53
- package/_modules/components/Stores/BusinessProductAddForm/index.js +4 -2
- package/_modules/components/Stores/BusinessesListingHeader/index.js +7 -1
- package/_modules/components/Stores/ImportersList/index.js +2 -5
- package/_modules/components/Stores/ImportersList/styles.js +15 -18
- package/_modules/components/Stores/ImportersListing/index.js +4 -31
- package/_modules/components/Stores/PaymentOption/index.js +7 -12
- package/_modules/components/Stores/PaymentOptionMethods/index.js +4 -9
- package/_modules/components/Stores/PaymentOptionPaypal/index.js +4 -9
- package/_modules/components/Stores/PaymentOptionSquare/index.js +4 -9
- package/_modules/components/Stores/PaymentOptionStripeDirect/index.js +5 -10
- package/_modules/components/Stores/PaymentOptionStripeDirect/styles.js +5 -10
- package/_modules/components/Stores/PaymethodOptionPaypalExpress/index.js +4 -9
- package/_modules/components/Stores/PaymethodOptionStripeConnect/index.js +4 -9
- package/_modules/components/Stores/PaymethodOptionStripeRedirect/index.js +4 -9
- package/_modules/config/constants.js +412 -2
- package/package.json +1 -1
- package/src/components/BusinessIntelligence/Reports/index.js +4 -18
- package/src/components/BusinessIntelligence/Reports/styles.js +0 -11
- package/src/components/Loyalty/RewardsPrograms/index.js +5 -18
- package/src/components/Loyalty/RewardsPrograms/styles.js +0 -10
- package/src/components/Marketing/CampaignHeader/index.js +2 -3
- package/src/components/Marketing/CampaignHeader/styles.js +0 -8
- package/src/components/Marketing/CampaignList/index.js +3 -5
- package/src/components/Marketing/CampaignList/styles.js +0 -16
- package/src/components/Marketing/CampaignListing/index.js +2 -18
- package/src/components/OrderingProducts/OrderingProductDetails/index.js +1 -1
- package/src/components/Orders/CurrencyFilter/index.js +22 -41
- package/src/components/Orders/OrderBill/index.js +15 -15
- package/src/components/Orders/OrderDetails/index.js +1 -0
- package/src/components/Orders/OrdersTable/index.js +2 -2
- package/src/components/Orders/ProductItemAccordion/index.js +4 -3
- package/src/components/Settings/PluginList/index.js +2 -2
- package/src/components/Settings/SettingsDetail/index.js +2 -23
- package/src/components/Settings/SettingsDetail/styles.js +13 -8
- package/src/components/Settings/SettingsList/index.js +1 -24
- package/src/components/SidebarMenu/index.js +17 -17
- package/src/components/Stores/BusinessMenu/index.js +3 -21
- package/src/components/Stores/BusinessMenu/styles.js +0 -15
- package/src/components/Stores/BusinessPaymentMethods/index.js +32 -62
- package/src/components/Stores/BusinessProductAddForm/index.js +1 -1
- package/src/components/Stores/BusinessesListingHeader/index.js +2 -2
- package/src/components/Stores/ImportersList/index.js +2 -3
- package/src/components/Stores/ImportersList/styles.js +1 -9
- package/src/components/Stores/ImportersListing/index.js +0 -19
- package/src/components/Stores/PaymentOption/index.js +4 -9
- package/src/components/Stores/PaymentOptionMethods/index.js +3 -8
- package/src/components/Stores/PaymentOptionPaypal/index.js +3 -8
- package/src/components/Stores/PaymentOptionSquare/index.js +3 -8
- package/src/components/Stores/PaymentOptionStripeDirect/index.js +3 -8
- package/src/components/Stores/PaymentOptionStripeDirect/styles.js +0 -8
- package/src/components/Stores/PaymethodOptionPaypalExpress/index.js +3 -8
- package/src/components/Stores/PaymethodOptionStripeConnect/index.js +3 -8
- package/src/components/Stores/PaymethodOptionStripeRedirect/index.js +3 -8
- package/src/config/constants.js +547 -0
|
@@ -25,8 +25,6 @@ var _ImporterHelpContent = require("../ImporterHelpContent");
|
|
|
25
25
|
|
|
26
26
|
var _Shared = require("../../Shared");
|
|
27
27
|
|
|
28
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
29
|
-
|
|
30
28
|
var _styles2 = require("./styles");
|
|
31
29
|
|
|
32
30
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
@@ -63,16 +61,6 @@ var ImportersListingUI = function ImportersListingUI(props) {
|
|
|
63
61
|
_useLanguage2 = _slicedToArray(_useLanguage, 2),
|
|
64
62
|
t = _useLanguage2[1];
|
|
65
63
|
|
|
66
|
-
var _useConfig = (0, _orderingComponentsAdminExternal.useConfig)(),
|
|
67
|
-
_useConfig2 = _slicedToArray(_useConfig, 1),
|
|
68
|
-
configs = _useConfig2[0].configs;
|
|
69
|
-
|
|
70
|
-
var _useSession = (0, _orderingComponentsAdminExternal.useSession)(),
|
|
71
|
-
_useSession2 = _slicedToArray(_useSession, 1),
|
|
72
|
-
user = _useSession2[0].user;
|
|
73
|
-
|
|
74
|
-
var featureName = 'massive_importer';
|
|
75
|
-
|
|
76
64
|
var _useState = (0, _react.useState)(false),
|
|
77
65
|
_useState2 = _slicedToArray(_useState, 2),
|
|
78
66
|
openNewImporter = _useState2[0],
|
|
@@ -108,11 +96,6 @@ var ImportersListingUI = function ImportersListingUI(props) {
|
|
|
108
96
|
openMappingDetails = _useState14[0],
|
|
109
97
|
setOpenMappingDetails = _useState14[1];
|
|
110
98
|
|
|
111
|
-
var _useState15 = (0, _react.useState)(false),
|
|
112
|
-
_useState16 = _slicedToArray(_useState15, 2),
|
|
113
|
-
isDisabledFeature = _useState16[0],
|
|
114
|
-
setIsDisabledFeature = _useState16[1];
|
|
115
|
-
|
|
116
99
|
var addNewImporter = function addNewImporter() {
|
|
117
100
|
setSelectedImporter({});
|
|
118
101
|
setOpenImportCsv(false);
|
|
@@ -137,26 +120,17 @@ var ImportersListingUI = function ImportersListingUI(props) {
|
|
|
137
120
|
(0, _react.useEffect)(function () {
|
|
138
121
|
setExtraOpen && setExtraOpen(openNewImporter);
|
|
139
122
|
}, [openNewImporter]);
|
|
140
|
-
(0, _react.useEffect)(function () {
|
|
141
|
-
if (configs && Object.keys(configs).length > 0 && user) {
|
|
142
|
-
if (!Object.keys(configs).includes(featureName) && (user === null || user === void 0 ? void 0 : user.level) === 0) {
|
|
143
|
-
setIsDisabledFeature(true);
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
}, [configs]);
|
|
147
123
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles2.ImportersListingContainer, null, /*#__PURE__*/_react.default.createElement(_styles2.Header, null, /*#__PURE__*/_react.default.createElement(_styles2.Title, null, /*#__PURE__*/_react.default.createElement(_styles2.TitleContent, null, t('IMPORTERS', 'Importers')), /*#__PURE__*/_react.default.createElement(_styles.IconButton, {
|
|
148
124
|
color: "primary",
|
|
149
125
|
onClick: function onClick() {
|
|
150
126
|
return setOpenImporterHelp(true);
|
|
151
|
-
}
|
|
152
|
-
disabled: isDisabledFeature
|
|
127
|
+
}
|
|
153
128
|
}, /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.InfoCircle, null))), /*#__PURE__*/_react.default.createElement(_styles2.ActionButtons, null, /*#__PURE__*/_react.default.createElement(_styles.Button, {
|
|
154
129
|
color: "lightPrimary",
|
|
155
130
|
borderRadius: "5px",
|
|
156
131
|
onClick: function onClick() {
|
|
157
132
|
return addNewImporter();
|
|
158
|
-
}
|
|
159
|
-
disabled: isDisabledFeature
|
|
133
|
+
}
|
|
160
134
|
}, t('ADD_IMPORTER', 'Add importer')))), /*#__PURE__*/_react.default.createElement(_ImportersList.ImportersList, {
|
|
161
135
|
importerList: importerList,
|
|
162
136
|
paginationDetail: paginationDetail,
|
|
@@ -165,9 +139,8 @@ var ImportersListingUI = function ImportersListingUI(props) {
|
|
|
165
139
|
handleDeleteImporter: handleDeleteImporter,
|
|
166
140
|
selectedImporter: selectedImporter,
|
|
167
141
|
setSelectedImporter: setSelectedImporter,
|
|
168
|
-
handleEditImporter: handleEditImporter
|
|
169
|
-
|
|
170
|
-
}), isDisabledFeature && /*#__PURE__*/_react.default.createElement(_DisabledFeatureAlert.DisabledFeatureAlert, null), openNewImporter && /*#__PURE__*/_react.default.createElement(_Shared.SideBar, {
|
|
142
|
+
handleEditImporter: handleEditImporter
|
|
143
|
+
}), openNewImporter && /*#__PURE__*/_react.default.createElement(_Shared.SideBar, {
|
|
171
144
|
isBorderShow: !openMappingDetails,
|
|
172
145
|
open: openNewImporter,
|
|
173
146
|
defaultSideBarWidth: openMappingDetails ? 1000 : 500,
|
|
@@ -29,8 +29,6 @@ var _reactBootstrap = require("react-bootstrap");
|
|
|
29
29
|
|
|
30
30
|
var _Shared = require("../../Shared");
|
|
31
31
|
|
|
32
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
33
|
-
|
|
34
32
|
var _styles3 = require("./styles");
|
|
35
33
|
|
|
36
34
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
@@ -78,8 +76,7 @@ var PaymentOption = function PaymentOption(props) {
|
|
|
78
76
|
actionState = props.actionState,
|
|
79
77
|
handleSaveClick = props.handleSaveClick,
|
|
80
78
|
businessPaymethod = props.businessPaymethod,
|
|
81
|
-
handleDeletePaymethod = props.handleDeletePaymethod
|
|
82
|
-
isDisabledFeature = props.isDisabledFeature;
|
|
79
|
+
handleDeletePaymethod = props.handleDeletePaymethod;
|
|
83
80
|
var theme = (0, _styledComponents.useTheme)();
|
|
84
81
|
|
|
85
82
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -200,12 +197,11 @@ var PaymentOption = function PaymentOption(props) {
|
|
|
200
197
|
return /*#__PURE__*/_react.default.createElement(_styles3.TabOption, {
|
|
201
198
|
key: site.id,
|
|
202
199
|
onClick: function onClick() {
|
|
203
|
-
return
|
|
200
|
+
return setPaymethodInfo({
|
|
204
201
|
key: 'sites',
|
|
205
202
|
value: site.id
|
|
206
203
|
});
|
|
207
|
-
}
|
|
208
|
-
isDisabledFeature: isDisabledFeature
|
|
204
|
+
}
|
|
209
205
|
}, (_ref2 = (_changesState$sites = changesState === null || changesState === void 0 ? void 0 : changesState.sites) !== null && _changesState$sites !== void 0 ? _changesState$sites : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : (_businessPaymethod$si = businessPaymethod.sites) === null || _businessPaymethod$si === void 0 ? void 0 : _businessPaymethod$si.map(function (s) {
|
|
210
206
|
return s.id;
|
|
211
207
|
})) !== null && _ref2 !== void 0 && _ref2.includes(site.id) ? /*#__PURE__*/_react.default.createElement(_RiCheckboxFill.default, {
|
|
@@ -217,23 +213,22 @@ var PaymentOption = function PaymentOption(props) {
|
|
|
217
213
|
return /*#__PURE__*/_react.default.createElement(_styles3.TabOption, {
|
|
218
214
|
key: type.value,
|
|
219
215
|
onClick: function onClick() {
|
|
220
|
-
return
|
|
216
|
+
return setPaymethodInfo({
|
|
221
217
|
key: 'allowed_order_types',
|
|
222
218
|
value: type.value
|
|
223
219
|
});
|
|
224
|
-
}
|
|
225
|
-
isDisabledFeature: isDisabledFeature
|
|
220
|
+
}
|
|
226
221
|
}, (_ref3 = (_changesState$allowed = changesState === null || changesState === void 0 ? void 0 : changesState.allowed_order_types) !== null && _changesState$allowed !== void 0 ? _changesState$allowed : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : businessPaymethod.allowed_order_types) !== null && _ref3 !== void 0 && _ref3.includes(type.value) ? /*#__PURE__*/_react.default.createElement(_RiCheckboxFill.default, {
|
|
227
222
|
className: "fill"
|
|
228
223
|
}) : /*#__PURE__*/_react.default.createElement(_RiCheckboxBlankLine.default, null), /*#__PURE__*/_react.default.createElement(_styles3.TabOptionName, null, type.text));
|
|
229
224
|
}), /*#__PURE__*/_react.default.createElement(_styles.Button, {
|
|
230
225
|
borderRadius: "5px",
|
|
231
226
|
color: "primary",
|
|
232
|
-
disabled:
|
|
227
|
+
disabled: actionState.loading || Object.keys(changesState).length === 0,
|
|
233
228
|
onClick: function onClick() {
|
|
234
229
|
return handleSaveClick(businessPaymethod.id);
|
|
235
230
|
}
|
|
236
|
-
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))),
|
|
231
|
+
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))), /*#__PURE__*/_react.default.createElement(_Shared.Confirm, {
|
|
237
232
|
width: "700px",
|
|
238
233
|
title: t('WEB_APPNAME', 'Ordering'),
|
|
239
234
|
content: confirm.content,
|
|
@@ -27,8 +27,6 @@ var _reactBootstrap = require("react-bootstrap");
|
|
|
27
27
|
|
|
28
28
|
var _Shared = require("../../Shared");
|
|
29
29
|
|
|
30
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
31
|
-
|
|
32
30
|
var _styles2 = require("./styles");
|
|
33
31
|
|
|
34
32
|
var _styles3 = require("../BusinessMenu/styles");
|
|
@@ -82,8 +80,7 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
82
80
|
businessPaymethod = props.businessPaymethod,
|
|
83
81
|
handleDeletePaymethod = props.handleDeletePaymethod,
|
|
84
82
|
id = props.id,
|
|
85
|
-
title = props.title
|
|
86
|
-
isDisabledFeature = props.isDisabledFeature;
|
|
83
|
+
title = props.title;
|
|
87
84
|
var theme = (0, _styledComponents.useTheme)();
|
|
88
85
|
|
|
89
86
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -247,9 +244,8 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
247
244
|
|
|
248
245
|
return /*#__PURE__*/_react.default.createElement(_styles2.TabOption, {
|
|
249
246
|
key: site.id,
|
|
250
|
-
isDisabledFeature: isDisabledFeature,
|
|
251
247
|
onClick: function onClick() {
|
|
252
|
-
return
|
|
248
|
+
return setPaymethodInfo({
|
|
253
249
|
key: 'sites',
|
|
254
250
|
value: site.id
|
|
255
251
|
});
|
|
@@ -264,9 +260,8 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
264
260
|
|
|
265
261
|
return /*#__PURE__*/_react.default.createElement(_styles2.TabOption, {
|
|
266
262
|
key: type.value,
|
|
267
|
-
isDisabledFeature: isDisabledFeature,
|
|
268
263
|
onClick: function onClick() {
|
|
269
|
-
return
|
|
264
|
+
return setPaymethodInfo({
|
|
270
265
|
key: 'allowed_order_types',
|
|
271
266
|
value: type.value
|
|
272
267
|
});
|
|
@@ -281,7 +276,7 @@ var PaymentOptionMethods = function PaymentOptionMethods(props) {
|
|
|
281
276
|
onClick: function onClick() {
|
|
282
277
|
return handleSaveClick(businessPaymethod.id);
|
|
283
278
|
}
|
|
284
|
-
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))),
|
|
279
|
+
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))), /*#__PURE__*/_react.default.createElement(_Shared.Confirm, {
|
|
285
280
|
width: "700px",
|
|
286
281
|
title: t('WEB_APPNAME', 'Ordering'),
|
|
287
282
|
content: confirm.content,
|
|
@@ -27,8 +27,6 @@ var _reactBootstrap = require("react-bootstrap");
|
|
|
27
27
|
|
|
28
28
|
var _Shared = require("../../Shared");
|
|
29
29
|
|
|
30
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
31
|
-
|
|
32
30
|
var _styles2 = require("./styles");
|
|
33
31
|
|
|
34
32
|
var _styles3 = require("../BusinessMenu/styles");
|
|
@@ -82,8 +80,7 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
82
80
|
handleSaveClick = props.handleSaveClick,
|
|
83
81
|
businessPaymethod = props.businessPaymethod,
|
|
84
82
|
handleChangeBusinessPaymentState = props.handleChangeBusinessPaymentState,
|
|
85
|
-
handleDeletePaymethod = props.handleDeletePaymethod
|
|
86
|
-
isDisabledFeature = props.isDisabledFeature;
|
|
83
|
+
handleDeletePaymethod = props.handleDeletePaymethod;
|
|
87
84
|
var theme = (0, _styledComponents.useTheme)();
|
|
88
85
|
|
|
89
86
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -247,9 +244,8 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
247
244
|
|
|
248
245
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
249
246
|
key: site.id,
|
|
250
|
-
isDisabledFeature: isDisabledFeature,
|
|
251
247
|
onClick: function onClick() {
|
|
252
|
-
return
|
|
248
|
+
return setPaymethodInfo({
|
|
253
249
|
key: 'sites',
|
|
254
250
|
value: site.id
|
|
255
251
|
});
|
|
@@ -264,9 +260,8 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
264
260
|
|
|
265
261
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
266
262
|
key: type.value,
|
|
267
|
-
isDisabledFeature: isDisabledFeature,
|
|
268
263
|
onClick: function onClick() {
|
|
269
|
-
return
|
|
264
|
+
return setPaymethodInfo({
|
|
270
265
|
key: 'allowed_order_types',
|
|
271
266
|
value: type.value
|
|
272
267
|
});
|
|
@@ -281,7 +276,7 @@ var PaymentOptionPaypal = function PaymentOptionPaypal(props) {
|
|
|
281
276
|
onClick: function onClick() {
|
|
282
277
|
return handleSaveClick(businessPaymethod.id);
|
|
283
278
|
}
|
|
284
|
-
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))),
|
|
279
|
+
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))), /*#__PURE__*/_react.default.createElement(_Shared.Confirm, {
|
|
285
280
|
width: "700px",
|
|
286
281
|
title: t('WEB_APPNAME', 'Ordering'),
|
|
287
282
|
content: confirm.content,
|
|
@@ -33,8 +33,6 @@ var _RiCheckboxFill = _interopRequireDefault(require("@meronex/icons/ri/RiCheckb
|
|
|
33
33
|
|
|
34
34
|
var _SiSquare = _interopRequireDefault(require("@meronex/icons/si/SiSquare"));
|
|
35
35
|
|
|
36
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
37
|
-
|
|
38
36
|
var _styles4 = require("./styles");
|
|
39
37
|
|
|
40
38
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
@@ -86,8 +84,7 @@ var PaymentOptionSquareUI = function PaymentOptionSquareUI(props) {
|
|
|
86
84
|
handleSavePaymethod = props.handleSavePaymethod,
|
|
87
85
|
handleChangeDataInput = props.handleChangeDataInput,
|
|
88
86
|
handleChangeSanboxDataInput = props.handleChangeSanboxDataInput,
|
|
89
|
-
handleChangeSandbox = props.handleChangeSandbox
|
|
90
|
-
isDisabledFeature = props.isDisabledFeature;
|
|
87
|
+
handleChangeSandbox = props.handleChangeSandbox;
|
|
91
88
|
var theme = (0, _styledComponents.useTheme)();
|
|
92
89
|
|
|
93
90
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -261,9 +258,8 @@ var PaymentOptionSquareUI = function PaymentOptionSquareUI(props) {
|
|
|
261
258
|
|
|
262
259
|
return /*#__PURE__*/_react.default.createElement(_styles3.TabOption, {
|
|
263
260
|
key: site.id,
|
|
264
|
-
isDisabledFeature: isDisabledFeature,
|
|
265
261
|
onClick: function onClick() {
|
|
266
|
-
return
|
|
262
|
+
return setPaymethodInfo({
|
|
267
263
|
key: 'sites',
|
|
268
264
|
value: site.id
|
|
269
265
|
});
|
|
@@ -278,9 +274,8 @@ var PaymentOptionSquareUI = function PaymentOptionSquareUI(props) {
|
|
|
278
274
|
|
|
279
275
|
return /*#__PURE__*/_react.default.createElement(_styles3.TabOption, {
|
|
280
276
|
key: type.value,
|
|
281
|
-
isDisabledFeature: isDisabledFeature,
|
|
282
277
|
onClick: function onClick() {
|
|
283
|
-
return
|
|
278
|
+
return setPaymethodInfo({
|
|
284
279
|
key: 'allowed_order_types',
|
|
285
280
|
value: type.value
|
|
286
281
|
});
|
|
@@ -324,7 +319,7 @@ var PaymentOptionSquareUI = function PaymentOptionSquareUI(props) {
|
|
|
324
319
|
});
|
|
325
320
|
},
|
|
326
321
|
closeOnBackdrop: false
|
|
327
|
-
}))
|
|
322
|
+
})));
|
|
328
323
|
};
|
|
329
324
|
|
|
330
325
|
var PaymentOptionSquare = function PaymentOptionSquare(props) {
|
|
@@ -27,8 +27,6 @@ var _reactBootstrap = require("react-bootstrap");
|
|
|
27
27
|
|
|
28
28
|
var _Shared = require("../../Shared");
|
|
29
29
|
|
|
30
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
31
|
-
|
|
32
30
|
var _styles2 = require("./styles");
|
|
33
31
|
|
|
34
32
|
var _styles3 = require("../BusinessMenu/styles");
|
|
@@ -80,8 +78,7 @@ var PaymentOptionStripeDirect = function PaymentOptionStripeDirect(props) {
|
|
|
80
78
|
handleChangeInput = props.handleChangeInput,
|
|
81
79
|
handleSaveClick = props.handleSaveClick,
|
|
82
80
|
businessPaymethod = props.businessPaymethod,
|
|
83
|
-
handleDeletePaymethod = props.handleDeletePaymethod
|
|
84
|
-
isDisabledFeature = props.isDisabledFeature;
|
|
81
|
+
handleDeletePaymethod = props.handleDeletePaymethod;
|
|
85
82
|
var theme = (0, _styledComponents.useTheme)();
|
|
86
83
|
|
|
87
84
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -246,12 +243,11 @@ var PaymentOptionStripeDirect = function PaymentOptionStripeDirect(props) {
|
|
|
246
243
|
return /*#__PURE__*/_react.default.createElement(_styles2.TabOption, {
|
|
247
244
|
key: site.id,
|
|
248
245
|
onClick: function onClick() {
|
|
249
|
-
return
|
|
246
|
+
return setPaymethodInfo({
|
|
250
247
|
key: 'sites',
|
|
251
248
|
value: site.id
|
|
252
249
|
});
|
|
253
|
-
}
|
|
254
|
-
isDisabledFeature: isDisabledFeature
|
|
250
|
+
}
|
|
255
251
|
}, (_ref2 = (_changesState$sites = changesState === null || changesState === void 0 ? void 0 : changesState.sites) !== null && _changesState$sites !== void 0 ? _changesState$sites : businessPaymethod === null || businessPaymethod === void 0 ? void 0 : (_businessPaymethod$si = businessPaymethod.sites) === null || _businessPaymethod$si === void 0 ? void 0 : _businessPaymethod$si.map(function (s) {
|
|
256
252
|
return s.id;
|
|
257
253
|
})) !== null && _ref2 !== void 0 && _ref2.includes(site.id) ? /*#__PURE__*/_react.default.createElement(_RiCheckboxFill.default, {
|
|
@@ -262,9 +258,8 @@ var PaymentOptionStripeDirect = function PaymentOptionStripeDirect(props) {
|
|
|
262
258
|
|
|
263
259
|
return /*#__PURE__*/_react.default.createElement(_styles2.TabOption, {
|
|
264
260
|
key: type.value,
|
|
265
|
-
isDisabledFeature: isDisabledFeature,
|
|
266
261
|
onClick: function onClick() {
|
|
267
|
-
return
|
|
262
|
+
return setPaymethodInfo({
|
|
268
263
|
key: 'allowed_order_types',
|
|
269
264
|
value: type.value
|
|
270
265
|
});
|
|
@@ -279,7 +274,7 @@ var PaymentOptionStripeDirect = function PaymentOptionStripeDirect(props) {
|
|
|
279
274
|
onClick: function onClick() {
|
|
280
275
|
return handleSaveClick(businessPaymethod.id);
|
|
281
276
|
}
|
|
282
|
-
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))),
|
|
277
|
+
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))), /*#__PURE__*/_react.default.createElement(_Shared.Confirm, {
|
|
283
278
|
width: "700px",
|
|
284
279
|
title: t('WEB_APPNAME', 'Ordering'),
|
|
285
280
|
content: confirm.content,
|
|
@@ -11,7 +11,7 @@ var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
|
11
11
|
|
|
12
12
|
var _polished = require("polished");
|
|
13
13
|
|
|
14
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14
|
|
14
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14;
|
|
15
15
|
|
|
16
16
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
17
17
|
|
|
@@ -57,30 +57,25 @@ var CloseButton = _styledComponents.default.div(_templateObject9 || (_templateOb
|
|
|
57
57
|
|
|
58
58
|
exports.CloseButton = CloseButton;
|
|
59
59
|
|
|
60
|
-
var TabOption = _styledComponents.default.div(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n padding: 12px 0;\n cursor: pointer;\n color: ", ";\n \n > svg {\n font-size: 20px;\n &.fill {\n color: ", ";\n }\n }\n
|
|
60
|
+
var TabOption = _styledComponents.default.div(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n padding: 12px 0;\n cursor: pointer;\n color: ", ";\n \n > svg {\n font-size: 20px;\n &.fill {\n color: ", ";\n }\n }\n"])), function (props) {
|
|
61
61
|
return props.theme.colors.headingColor;
|
|
62
62
|
}, function (props) {
|
|
63
63
|
return props.theme.colors.primary;
|
|
64
|
-
}, function (_ref) {
|
|
65
|
-
var isDisabledFeature = _ref.isDisabledFeature;
|
|
66
|
-
return isDisabledFeature && (0, _styledComponents.css)(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["\n cursor: not-allowed;\n opacity: 0.4;\n &:hover {\n background-color: ", ";\n }\n "])), function (props) {
|
|
67
|
-
return props.theme.colors.white;
|
|
68
|
-
});
|
|
69
64
|
});
|
|
70
65
|
|
|
71
66
|
exports.TabOption = TabOption;
|
|
72
67
|
|
|
73
|
-
var TabOptionName = _styledComponents.default.span(
|
|
68
|
+
var TabOptionName = _styledComponents.default.span(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["\n color: ", ";\n ", "\n"])), function (props) {
|
|
74
69
|
return props.theme.colors.headingColor;
|
|
75
70
|
}, function (props) {
|
|
76
71
|
var _props$theme3;
|
|
77
72
|
|
|
78
|
-
return (_props$theme3 = props.theme) !== null && _props$theme3 !== void 0 && _props$theme3.rtl ? (0, _styledComponents.css)(
|
|
73
|
+
return (_props$theme3 = props.theme) !== null && _props$theme3 !== void 0 && _props$theme3.rtl ? (0, _styledComponents.css)(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["\n margin-right: 10px;\n "]))) : (0, _styledComponents.css)(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["\n margin-left: 10px;\n "])));
|
|
79
74
|
});
|
|
80
75
|
|
|
81
76
|
exports.TabOptionName = TabOptionName;
|
|
82
77
|
|
|
83
|
-
var ActionSelectorWrapper = _styledComponents.default.div(
|
|
78
|
+
var ActionSelectorWrapper = _styledComponents.default.div(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["\n margin: 0 10px;\n button {\n background: transparent !important;\n border: none;\n padding: 0px 5px;\n &:active,\n &:focus {\n border-color: unset !important;\n box-shadow: none !important;\n }\n svg {\n color: ", ";\n font-size: 20px;\n }\n\n &:after {\n display: none;\n }\n\n &:hover {\n background: ", " !important;\n }\n &:active {\n background: ", " !important;\n }\n }\n\n .show {\n button {\n background: ", " !important;\n }\n >div {\n border: 1px solid ", ";\n box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.12);\n }\n }\n\n > div {\n > div {\n border-radius: 8px;\n .dropdown-item {\n font-size: 12px;\n color: ", ";\n &:active {\n background: ", " !important;\n }\n }\n .dropdown-item:last-child {\n color: #E63757;\n }\n }\n }\n"])), function (props) {
|
|
84
79
|
return props.theme.colors.headingColor;
|
|
85
80
|
}, function (props) {
|
|
86
81
|
return (0, _polished.darken)(0.04, props.theme.colors.secundary);
|
|
@@ -27,8 +27,6 @@ var _reactBootstrap = require("react-bootstrap");
|
|
|
27
27
|
|
|
28
28
|
var _Shared = require("../../Shared");
|
|
29
29
|
|
|
30
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
31
|
-
|
|
32
30
|
var _styles2 = require("./styles");
|
|
33
31
|
|
|
34
32
|
var _styles3 = require("../BusinessMenu/styles");
|
|
@@ -82,8 +80,7 @@ var PaymethodOptionPaypalExpress = function PaymethodOptionPaypalExpress(props)
|
|
|
82
80
|
businessPaymethod = props.businessPaymethod,
|
|
83
81
|
orderTypes = props.orderTypes,
|
|
84
82
|
handleChangeBusinessPaymentState = props.handleChangeBusinessPaymentState,
|
|
85
|
-
handleDeletePaymethod = props.handleDeletePaymethod
|
|
86
|
-
isDisabledFeature = props.isDisabledFeature;
|
|
83
|
+
handleDeletePaymethod = props.handleDeletePaymethod;
|
|
87
84
|
var theme = (0, _styledComponents.useTheme)();
|
|
88
85
|
|
|
89
86
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -234,9 +231,8 @@ var PaymethodOptionPaypalExpress = function PaymethodOptionPaypalExpress(props)
|
|
|
234
231
|
|
|
235
232
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
236
233
|
key: site.id,
|
|
237
|
-
isDisabledFeature: isDisabledFeature,
|
|
238
234
|
onClick: function onClick() {
|
|
239
|
-
return
|
|
235
|
+
return setPaymethodInfo({
|
|
240
236
|
key: 'sites',
|
|
241
237
|
value: site.id
|
|
242
238
|
});
|
|
@@ -251,9 +247,8 @@ var PaymethodOptionPaypalExpress = function PaymethodOptionPaypalExpress(props)
|
|
|
251
247
|
|
|
252
248
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
253
249
|
key: type.value,
|
|
254
|
-
isDisabledFeature: isDisabledFeature,
|
|
255
250
|
onClick: function onClick() {
|
|
256
|
-
return
|
|
251
|
+
return setPaymethodInfo({
|
|
257
252
|
key: 'allowed_order_types',
|
|
258
253
|
value: type.value
|
|
259
254
|
});
|
|
@@ -268,7 +263,7 @@ var PaymethodOptionPaypalExpress = function PaymethodOptionPaypalExpress(props)
|
|
|
268
263
|
onClick: function onClick() {
|
|
269
264
|
return handleSaveClick(businessPaymethod.id);
|
|
270
265
|
}
|
|
271
|
-
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))),
|
|
266
|
+
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))), /*#__PURE__*/_react.default.createElement(_Shared.Confirm, {
|
|
272
267
|
width: "700px",
|
|
273
268
|
title: t('WEB_APPNAME', 'Ordering'),
|
|
274
269
|
content: confirm.content,
|
|
@@ -29,8 +29,6 @@ var _reactBootstrap = require("react-bootstrap");
|
|
|
29
29
|
|
|
30
30
|
var _Shared = require("../../Shared");
|
|
31
31
|
|
|
32
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
33
|
-
|
|
34
32
|
var _styles2 = require("./styles");
|
|
35
33
|
|
|
36
34
|
var _styles3 = require("../BusinessMenu/styles");
|
|
@@ -84,8 +82,7 @@ var PaymethodOptionStripeConnect = function PaymethodOptionStripeConnect(props)
|
|
|
84
82
|
businessPaymethod = props.businessPaymethod,
|
|
85
83
|
orderTypes = props.orderTypes,
|
|
86
84
|
handleChangeBusinessPaymentState = props.handleChangeBusinessPaymentState,
|
|
87
|
-
handleDeletePaymethod = props.handleDeletePaymethod
|
|
88
|
-
isDisabledFeature = props.isDisabledFeature;
|
|
85
|
+
handleDeletePaymethod = props.handleDeletePaymethod;
|
|
89
86
|
var theme = (0, _styledComponents.useTheme)();
|
|
90
87
|
|
|
91
88
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -244,9 +241,8 @@ var PaymethodOptionStripeConnect = function PaymethodOptionStripeConnect(props)
|
|
|
244
241
|
|
|
245
242
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
246
243
|
key: site.id,
|
|
247
|
-
isDisabledFeature: isDisabledFeature,
|
|
248
244
|
onClick: function onClick() {
|
|
249
|
-
return
|
|
245
|
+
return setPaymethodInfo({
|
|
250
246
|
key: 'sites',
|
|
251
247
|
value: site.id
|
|
252
248
|
});
|
|
@@ -261,9 +257,8 @@ var PaymethodOptionStripeConnect = function PaymethodOptionStripeConnect(props)
|
|
|
261
257
|
|
|
262
258
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
263
259
|
key: type.value,
|
|
264
|
-
isDisabledFeature: isDisabledFeature,
|
|
265
260
|
onClick: function onClick() {
|
|
266
|
-
return
|
|
261
|
+
return setPaymethodInfo({
|
|
267
262
|
key: 'allowed_order_types',
|
|
268
263
|
value: type.value
|
|
269
264
|
});
|
|
@@ -278,7 +273,7 @@ var PaymethodOptionStripeConnect = function PaymethodOptionStripeConnect(props)
|
|
|
278
273
|
onClick: function onClick() {
|
|
279
274
|
return handleStripeSave(businessPaymethod.id);
|
|
280
275
|
}
|
|
281
|
-
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))),
|
|
276
|
+
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))), /*#__PURE__*/_react.default.createElement(_Shared.Confirm, {
|
|
282
277
|
width: "700px",
|
|
283
278
|
title: t('WEB_APPNAME', 'Ordering'),
|
|
284
279
|
content: confirm.content,
|
|
@@ -27,8 +27,6 @@ var _reactBootstrap = require("react-bootstrap");
|
|
|
27
27
|
|
|
28
28
|
var _Shared = require("../../Shared");
|
|
29
29
|
|
|
30
|
-
var _DisabledFeatureAlert = require("../../DisabledFeatureAlert");
|
|
31
|
-
|
|
32
30
|
var _styles2 = require("./styles");
|
|
33
31
|
|
|
34
32
|
var _styles3 = require("../BusinessMenu/styles");
|
|
@@ -82,8 +80,7 @@ var PaymethodOptionStripeRedirect = function PaymethodOptionStripeRedirect(props
|
|
|
82
80
|
businessPaymethod = props.businessPaymethod,
|
|
83
81
|
orderTypes = props.orderTypes,
|
|
84
82
|
handleChangeBusinessPaymentState = props.handleChangeBusinessPaymentState,
|
|
85
|
-
handleDeletePaymethod = props.handleDeletePaymethod
|
|
86
|
-
isDisabledFeature = props.isDisabledFeature;
|
|
83
|
+
handleDeletePaymethod = props.handleDeletePaymethod;
|
|
87
84
|
var theme = (0, _styledComponents.useTheme)();
|
|
88
85
|
|
|
89
86
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
@@ -247,9 +244,8 @@ var PaymethodOptionStripeRedirect = function PaymethodOptionStripeRedirect(props
|
|
|
247
244
|
|
|
248
245
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
249
246
|
key: site.id,
|
|
250
|
-
isDisabledFeature: isDisabledFeature,
|
|
251
247
|
onClick: function onClick() {
|
|
252
|
-
return
|
|
248
|
+
return setPaymethodInfo({
|
|
253
249
|
key: 'sites',
|
|
254
250
|
value: site.id
|
|
255
251
|
});
|
|
@@ -264,9 +260,8 @@ var PaymethodOptionStripeRedirect = function PaymethodOptionStripeRedirect(props
|
|
|
264
260
|
|
|
265
261
|
return /*#__PURE__*/_react.default.createElement(_styles4.TabOption, {
|
|
266
262
|
key: type.value,
|
|
267
|
-
isDisabledFeature: isDisabledFeature,
|
|
268
263
|
onClick: function onClick() {
|
|
269
|
-
return
|
|
264
|
+
return setPaymethodInfo({
|
|
270
265
|
key: 'allowed_order_types',
|
|
271
266
|
value: type.value
|
|
272
267
|
});
|
|
@@ -281,7 +276,7 @@ var PaymethodOptionStripeRedirect = function PaymethodOptionStripeRedirect(props
|
|
|
281
276
|
onClick: function onClick() {
|
|
282
277
|
return handleSaveClick(businessPaymethod.id);
|
|
283
278
|
}
|
|
284
|
-
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))),
|
|
279
|
+
}, actionState.loading ? t('LOADING', 'Loading') : t('SAVE', 'Save'))), /*#__PURE__*/_react.default.createElement(_Shared.Confirm, {
|
|
285
280
|
width: "700px",
|
|
286
281
|
title: t('WEB_APPNAME', 'Ordering'),
|
|
287
282
|
content: confirm.content,
|