ordering-ui-admin-external 1.43.98 → 1.43.99
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.332418468be0f49b4414.js → ordering-ui-admin.1feeff976554444c349e.js} +2 -2
- package/_modules/components/Orders/OrdersExportCSV/index.js +13 -5
- package/_modules/components/Orders/OrdersListing/index.js +43 -20
- package/_modules/components/Orders/OrdersTable/Order.js +1 -1
- package/_modules/components/Orders/OrdersTable/index.js +56 -32
- package/package.json +2 -2
- package/src/components/Orders/OrdersExportCSV/index.js +10 -4
- package/src/components/Orders/OrdersListing/index.js +132 -106
- package/src/components/Orders/OrdersTable/Order.js +2 -2
- package/src/components/Orders/OrdersTable/index.js +238 -209
- /package/_bundles/{ordering-ui-admin.332418468be0f49b4414.js.LICENSE.txt → ordering-ui-admin.1feeff976554444c349e.js.LICENSE.txt} +0 -0
|
@@ -49,13 +49,13 @@ var ExportCSVUI = function ExportCSVUI(props) {
|
|
|
49
49
|
_useState6 = _slicedToArray(_useState5, 2),
|
|
50
50
|
alertState = _useState6[0],
|
|
51
51
|
setAlertState = _useState6[1];
|
|
52
|
-
var handleExportAll = function handleExportAll() {
|
|
52
|
+
var handleExportAll = function handleExportAll(withoutMetafields) {
|
|
53
53
|
setPopoverOpen(false);
|
|
54
|
-
getCSV(false);
|
|
54
|
+
getCSV(false, withoutMetafields);
|
|
55
55
|
};
|
|
56
|
-
var handleExportFiltered = function handleExportFiltered() {
|
|
56
|
+
var handleExportFiltered = function handleExportFiltered(withoutMetafields) {
|
|
57
57
|
setPopoverOpen(false);
|
|
58
|
-
getCSV(true);
|
|
58
|
+
getCSV(true, withoutMetafields);
|
|
59
59
|
};
|
|
60
60
|
var closePopover = function closePopover() {
|
|
61
61
|
setPopoverOpen(false);
|
|
@@ -100,7 +100,15 @@ var ExportCSVUI = function ExportCSVUI(props) {
|
|
|
100
100
|
onClick: function onClick() {
|
|
101
101
|
return handleExportFiltered();
|
|
102
102
|
}
|
|
103
|
-
}, t('EXPORT_FILTERED', 'Export filtered'))
|
|
103
|
+
}, t('EXPORT_FILTERED', 'Export filtered')), /*#__PURE__*/_react.default.createElement(_styles2.Item, {
|
|
104
|
+
onClick: function onClick() {
|
|
105
|
+
return handleExportAll(true);
|
|
106
|
+
}
|
|
107
|
+
}, t('EXPORT_ALL_WITHOUT_METAFIELDS', 'Export all without metafields')), /*#__PURE__*/_react.default.createElement(_styles2.Item, {
|
|
108
|
+
onClick: function onClick() {
|
|
109
|
+
return handleExportFiltered(true);
|
|
110
|
+
}
|
|
111
|
+
}, t('EXPORT_FILTERED_WITHOUT_METAFIELDS', 'Export filtered without metafields'))), actionStatus.loading && /*#__PURE__*/_react.default.createElement(_Shared.SpinnerLoader, {
|
|
104
112
|
primary: true
|
|
105
113
|
})), /*#__PURE__*/_react.default.createElement(_Shared.Modal, {
|
|
106
114
|
open: modalOpen,
|
|
@@ -29,7 +29,7 @@ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length)
|
|
|
29
29
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
30
30
|
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
31
31
|
var OrdersListing = exports.OrdersListing = /*#__PURE__*/(0, _react.memo)(function (props) {
|
|
32
|
-
var _theme$images;
|
|
32
|
+
var _configState$configs, _theme$images;
|
|
33
33
|
var hidePhoto = props.hidePhoto,
|
|
34
34
|
isSelectedOrders = props.isSelectedOrders,
|
|
35
35
|
orderList = props.orderList,
|
|
@@ -72,10 +72,14 @@ var OrdersListing = exports.OrdersListing = /*#__PURE__*/(0, _react.memo)(functi
|
|
|
72
72
|
var _useLanguage = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
73
73
|
_useLanguage2 = _slicedToArray(_useLanguage, 2),
|
|
74
74
|
t = _useLanguage2[1];
|
|
75
|
+
var _useConfig = (0, _orderingComponentsAdminExternal.useConfig)(),
|
|
76
|
+
_useConfig2 = _slicedToArray(_useConfig, 1),
|
|
77
|
+
configState = _useConfig2[0];
|
|
75
78
|
var _useState = (0, _react.useState)(false),
|
|
76
79
|
_useState2 = _slicedToArray(_useState, 2),
|
|
77
80
|
filterApplied = _useState2[0],
|
|
78
81
|
setFilterApplied = _useState2[1];
|
|
82
|
+
var showExternalId = (configState === null || configState === void 0 || (_configState$configs = configState.configs) === null || _configState$configs === void 0 || (_configState$configs = _configState$configs.change_order_id) === null || _configState$configs === void 0 ? void 0 : _configState$configs.value) === '1';
|
|
79
83
|
var handleDobleClick = function handleDobleClick() {
|
|
80
84
|
if (handleSetOpenOrderDetail && orderDetailId) {
|
|
81
85
|
handleSetOpenOrderDetail(true);
|
|
@@ -83,49 +87,64 @@ var OrdersListing = exports.OrdersListing = /*#__PURE__*/(0, _react.memo)(functi
|
|
|
83
87
|
};
|
|
84
88
|
var optionsDefault = [{
|
|
85
89
|
value: 'status',
|
|
86
|
-
content: t('STATUS', 'Status')
|
|
90
|
+
content: t('STATUS', 'Status'),
|
|
91
|
+
enabled: true
|
|
87
92
|
}, {
|
|
88
93
|
value: 'orderNumber',
|
|
89
|
-
content: t('INVOICE_ORDER_NO', 'Order No.')
|
|
94
|
+
content: t('INVOICE_ORDER_NO', 'Order No.'),
|
|
95
|
+
enabled: !showExternalId
|
|
96
|
+
}, {
|
|
97
|
+
value: 'dateTime',
|
|
98
|
+
content: t('DATE_TIME', 'Date and time'),
|
|
99
|
+
enabled: true
|
|
90
100
|
}, {
|
|
91
101
|
value: 'agent',
|
|
92
|
-
content: t('AGENT', 'Agent')
|
|
102
|
+
content: t('AGENT', 'Agent'),
|
|
103
|
+
enabled: true
|
|
93
104
|
}, {
|
|
94
105
|
value: 'cartGroupId',
|
|
95
|
-
content: t('GROUP_ORDER', 'Group Order')
|
|
106
|
+
content: t('GROUP_ORDER', 'Group Order'),
|
|
107
|
+
enabled: true
|
|
96
108
|
}, {
|
|
97
109
|
value: 'driverGroupId',
|
|
98
|
-
content: t('EXPORT_DRIVER_GROUP_ID', 'Driver Group Id')
|
|
99
|
-
|
|
100
|
-
value: 'dateTime',
|
|
101
|
-
content: t('DATE_TIME', 'Date and time')
|
|
110
|
+
content: t('EXPORT_DRIVER_GROUP_ID', 'Driver Group Id'),
|
|
111
|
+
enabled: true
|
|
102
112
|
}, {
|
|
103
113
|
value: 'business',
|
|
104
|
-
content: t('BUSINESS', 'Business')
|
|
114
|
+
content: t('BUSINESS', 'Business'),
|
|
115
|
+
enabled: true
|
|
105
116
|
}, {
|
|
106
117
|
value: 'customer',
|
|
107
|
-
content: t('CUSTOMER', 'Customer')
|
|
118
|
+
content: t('CUSTOMER', 'Customer'),
|
|
119
|
+
enabled: true
|
|
108
120
|
}, {
|
|
109
121
|
value: 'driver',
|
|
110
|
-
content: t('DRIVER', 'Driver')
|
|
122
|
+
content: t('DRIVER', 'Driver'),
|
|
123
|
+
enabled: true
|
|
111
124
|
}, {
|
|
112
125
|
value: 'advanced',
|
|
113
|
-
content: t('ADVANCED_LOGISTICS', 'Advance Logistics')
|
|
126
|
+
content: t('ADVANCED_LOGISTICS', 'Advance Logistics'),
|
|
127
|
+
enabled: true
|
|
114
128
|
}, {
|
|
115
129
|
value: 'timer',
|
|
116
|
-
content: t('SLA_TIMER', 'SLA’s timer')
|
|
130
|
+
content: t('SLA_TIMER', 'SLA’s timer'),
|
|
131
|
+
enabled: true
|
|
117
132
|
}, {
|
|
118
133
|
value: 'eta',
|
|
119
|
-
content: t('ETA', 'ETA')
|
|
134
|
+
content: t('ETA', 'ETA'),
|
|
135
|
+
enabled: true
|
|
120
136
|
}, {
|
|
121
137
|
value: 'total',
|
|
122
|
-
content: t('EXPORT_TOTAL', 'Total')
|
|
138
|
+
content: t('EXPORT_TOTAL', 'Total'),
|
|
139
|
+
enabled: true
|
|
123
140
|
}, {
|
|
124
141
|
value: 'externalId',
|
|
125
|
-
content: t('EXTERNAL_ID', 'External id')
|
|
142
|
+
content: t('EXTERNAL_ID', 'External id'),
|
|
143
|
+
enabled: true
|
|
126
144
|
}, {
|
|
127
145
|
value: 'channel',
|
|
128
|
-
content: t('CHANNEL', 'Channel')
|
|
146
|
+
content: t('CHANNEL', 'Channel'),
|
|
147
|
+
enabled: true
|
|
129
148
|
}];
|
|
130
149
|
var handleChangeAllowColumns = function handleChangeAllowColumns(type) {
|
|
131
150
|
var _column2;
|
|
@@ -194,7 +213,10 @@ var OrdersListing = exports.OrdersListing = /*#__PURE__*/(0, _react.memo)(functi
|
|
|
194
213
|
return ((_allowColumns$col = allowColumns[col]) === null || _allowColumns$col === void 0 ? void 0 : _allowColumns$col.visable) && ((_allowColumns$col2 = allowColumns[col]) === null || _allowColumns$col2 === void 0 ? void 0 : _allowColumns$col2.order) !== 0;
|
|
195
214
|
}).length === 0) && /*#__PURE__*/_react.default.createElement(_styles2.ColumnPopoverContainer, null, /*#__PURE__*/_react.default.createElement(_Shared.ColumnAllowSettingPopover, {
|
|
196
215
|
allowColumns: allowColumns,
|
|
197
|
-
optionsDefault: optionsDefault
|
|
216
|
+
optionsDefault: optionsDefault === null || optionsDefault === void 0 ? void 0 : optionsDefault.filter(function (_ref) {
|
|
217
|
+
var enabled = _ref.enabled;
|
|
218
|
+
return enabled;
|
|
219
|
+
}),
|
|
198
220
|
handleChangeAllowColumns: handleChangeAllowColumns,
|
|
199
221
|
isOrder: true
|
|
200
222
|
})), /*#__PURE__*/_react.default.createElement(_OrdersTable.OrdersTable, {
|
|
@@ -240,4 +262,5 @@ var OrdersListing = exports.OrdersListing = /*#__PURE__*/(0, _react.memo)(functi
|
|
|
240
262
|
isUseQuery: isUseQuery,
|
|
241
263
|
franchisesList: props.franchisesList
|
|
242
264
|
})), handleSetOpenOrderDetail && orderDetailId && /*#__PURE__*/_react.default.createElement(_styles2.InfoMessage, null, /*#__PURE__*/_react.default.createElement(_AiOutlineInfoCircle.default, null), /*#__PURE__*/_react.default.createElement("span", null, t('DOBLE_CLICK_OPEN_ORDER_INFO', 'Doble click order to open details')))));
|
|
243
|
-
});
|
|
265
|
+
});
|
|
266
|
+
OrdersListing.displayName = 'OrdersListing';
|
|
@@ -82,7 +82,7 @@ var Order = exports.Order = /*#__PURE__*/_react.default.memo(function (props) {
|
|
|
82
82
|
className: "bold"
|
|
83
83
|
}, order === null || order === void 0 ? void 0 : order.external_id)));
|
|
84
84
|
}
|
|
85
|
-
if (column === 'orderNumber') {
|
|
85
|
+
if (showExternalId ? column === 'dateTime' : column === 'orderNumber') {
|
|
86
86
|
var _allowColumns$orderNu, _allowColumns$dateTim, _allowColumns$orderNu2, _allowColumns$dateTim2;
|
|
87
87
|
return /*#__PURE__*/_react.default.createElement("td", {
|
|
88
88
|
className: !(allowColumns !== null && allowColumns !== void 0 && (_allowColumns$orderNu = allowColumns.orderNumber) !== null && _allowColumns$orderNu !== void 0 && _allowColumns$orderNu.visable || allowColumns !== null && allowColumns !== void 0 && (_allowColumns$dateTim = allowColumns.dateTime) !== null && _allowColumns$dateTim !== void 0 && _allowColumns$dateTim.visable) ? 'small' : '',
|
|
@@ -38,7 +38,7 @@ var OrderTablePropsAreEqual = function OrderTablePropsAreEqual(prevProps, nextPr
|
|
|
38
38
|
return prevProps.isSelectedOrders === nextProps.isSelectedOrders && JSON.stringify(prevProps.orderList) === JSON.stringify(nextProps.orderList) && JSON.stringify(prevProps.pagination) === JSON.stringify(nextProps.pagination) && JSON.stringify(prevProps.selectedOrderIds) === JSON.stringify(nextProps.selectedOrderIds) && JSON.stringify(prevProps.isTourOpen) === JSON.stringify(nextProps.isTourOpen) && prevProps.groupStatus === nextProps.groupStatus && JSON.stringify(prevProps.allowColumns) === JSON.stringify(nextProps.allowColumns) && prevProps.isUseQuery === nextProps.isUseQuery;
|
|
39
39
|
};
|
|
40
40
|
var OrdersTable = exports.OrdersTable = /*#__PURE__*/(0, _react.memo)(function (props) {
|
|
41
|
-
var _configState$configs, _configState$configs2, _franchisesList$franc, _orderList$orders3;
|
|
41
|
+
var _configState$configs, _configState$configs2, _configState$configs3, _configState$configs4, _franchisesList$franc, _orderList$orders3;
|
|
42
42
|
var hidePhoto = props.hidePhoto,
|
|
43
43
|
isSelectedOrders = props.isSelectedOrders,
|
|
44
44
|
orderList = props.orderList,
|
|
@@ -68,6 +68,9 @@ var OrdersTable = exports.OrdersTable = /*#__PURE__*/(0, _react.memo)(function (
|
|
|
68
68
|
var _useUtils = (0, _orderingComponentsAdminExternal.useUtils)(),
|
|
69
69
|
_useUtils2 = _slicedToArray(_useUtils, 1),
|
|
70
70
|
parseDate = _useUtils2[0].parseDate;
|
|
71
|
+
var _useConfig = (0, _orderingComponentsAdminExternal.useConfig)(),
|
|
72
|
+
_useConfig2 = _slicedToArray(_useConfig, 1),
|
|
73
|
+
configState = _useConfig2[0];
|
|
71
74
|
var _useState = (0, _react.useState)(false),
|
|
72
75
|
_useState2 = _slicedToArray(_useState, 2),
|
|
73
76
|
isAllChecked = _useState2[0],
|
|
@@ -87,63 +90,81 @@ var OrdersTable = exports.OrdersTable = /*#__PURE__*/(0, _react.memo)(function (
|
|
|
87
90
|
getPageOrders(pageSize, expectedPage);
|
|
88
91
|
}
|
|
89
92
|
}, [pagination.from, pagination.pageSize, getPageOrders]);
|
|
90
|
-
var _useConfig = (0, _orderingComponentsAdminExternal.useConfig)(),
|
|
91
|
-
_useConfig2 = _slicedToArray(_useConfig, 1),
|
|
92
|
-
configState = _useConfig2[0];
|
|
93
93
|
var isEnabledRowInColor = (configState === null || configState === void 0 || (_configState$configs = configState.configs) === null || _configState$configs === void 0 || (_configState$configs = _configState$configs.row_in_color_enabled) === null || _configState$configs === void 0 ? void 0 : _configState$configs.value) === '1';
|
|
94
94
|
var showExternalId = (configState === null || configState === void 0 || (_configState$configs2 = configState.configs) === null || _configState$configs2 === void 0 || (_configState$configs2 = _configState$configs2.change_order_id) === null || _configState$configs2 === void 0 ? void 0 : _configState$configs2.value) === '1';
|
|
95
|
+
var isProjectEnterpricePlan = (configState === null || configState === void 0 || (_configState$configs3 = configState.configs) === null || _configState$configs3 === void 0 ? void 0 : _configState$configs3.plan_enterprise) && (configState === null || configState === void 0 || (_configState$configs4 = configState.configs) === null || _configState$configs4 === void 0 || (_configState$configs4 = _configState$configs4.plan_enterprise) === null || _configState$configs4 === void 0 ? void 0 : _configState$configs4.value);
|
|
95
96
|
var franchiseImages = !(franchisesList !== null && franchisesList !== void 0 && franchisesList.error) && (franchisesList === null || franchisesList === void 0 || (_franchisesList$franc = franchisesList.franchises) === null || _franchisesList$franc === void 0 ? void 0 : _franchisesList$franc.reduce(function (imageKeys, franchise) {
|
|
96
97
|
imageKeys[franchise.id] = franchise.logo;
|
|
97
98
|
return imageKeys;
|
|
98
99
|
}, {}));
|
|
99
100
|
var optionsDefault = [{
|
|
100
101
|
value: 'status',
|
|
101
|
-
content: t('STATUS', 'Status')
|
|
102
|
+
content: t('STATUS', 'Status'),
|
|
103
|
+
enabled: true
|
|
102
104
|
}, {
|
|
103
105
|
value: 'orderNumber',
|
|
104
|
-
content: t('INVOICE_ORDER_NO', 'Order No.')
|
|
106
|
+
content: t('INVOICE_ORDER_NO', 'Order No.'),
|
|
107
|
+
enabled: !showExternalId
|
|
108
|
+
}, {
|
|
109
|
+
value: 'dateTime',
|
|
110
|
+
content: t('DATE_TIME', 'Date and time'),
|
|
111
|
+
enabled: true
|
|
105
112
|
}, {
|
|
106
113
|
value: 'agent',
|
|
107
|
-
content: t('AGENT', 'Agent')
|
|
114
|
+
content: t('AGENT', 'Agent'),
|
|
115
|
+
enabled: true
|
|
108
116
|
}, {
|
|
109
117
|
value: 'cartGroupId',
|
|
110
|
-
content: t('GROUP_ORDER', 'Group Order')
|
|
118
|
+
content: t('GROUP_ORDER', 'Group Order'),
|
|
119
|
+
enabled: true
|
|
111
120
|
}, {
|
|
112
121
|
value: 'driverGroupId',
|
|
113
|
-
content: t('EXPORT_DRIVER_GROUP_ID', 'Driver Group Id')
|
|
114
|
-
|
|
115
|
-
value: 'dateTime',
|
|
116
|
-
content: t('DATE_TIME', 'Date and time')
|
|
122
|
+
content: t('EXPORT_DRIVER_GROUP_ID', 'Driver Group Id'),
|
|
123
|
+
enabled: true
|
|
117
124
|
}, {
|
|
118
125
|
value: 'business',
|
|
119
|
-
content: t('BUSINESS', 'Business')
|
|
126
|
+
content: t('BUSINESS', 'Business'),
|
|
127
|
+
enabled: true
|
|
120
128
|
}, {
|
|
121
129
|
value: 'customer',
|
|
122
|
-
content: t('CUSTOMER', 'Customer')
|
|
130
|
+
content: t('CUSTOMER', 'Customer'),
|
|
131
|
+
enabled: true
|
|
123
132
|
}, {
|
|
124
133
|
value: 'driver',
|
|
125
|
-
content: t('DRIVER', 'Driver')
|
|
134
|
+
content: t('DRIVER', 'Driver'),
|
|
135
|
+
enabled: true
|
|
126
136
|
}, {
|
|
127
137
|
value: 'advanced',
|
|
128
|
-
content: t('ADVANCED_LOGISTICS', 'Advance Logistics')
|
|
138
|
+
content: t('ADVANCED_LOGISTICS', 'Advance Logistics'),
|
|
139
|
+
enabled: true
|
|
140
|
+
}, {
|
|
141
|
+
value: 'cloned',
|
|
142
|
+
content: t('CLONED', 'Cloned'),
|
|
143
|
+
enabled: true
|
|
129
144
|
}, {
|
|
130
145
|
value: 'timer',
|
|
131
|
-
content: t('SLA_TIMER', 'SLA’s timer')
|
|
146
|
+
content: t('SLA_TIMER', 'SLA’s timer'),
|
|
147
|
+
enabled: isProjectEnterpricePlan
|
|
132
148
|
}, {
|
|
133
149
|
value: 'eta',
|
|
134
|
-
content: t('ETA', 'ETA')
|
|
150
|
+
content: t('ETA', 'ETA'),
|
|
151
|
+
enabled: true
|
|
135
152
|
}, {
|
|
136
153
|
value: 'total',
|
|
137
|
-
content: t('EXPORT_TOTAL', 'Total')
|
|
154
|
+
content: t('EXPORT_TOTAL', 'Total'),
|
|
155
|
+
enabled: true
|
|
138
156
|
}, {
|
|
139
157
|
value: 'externalId',
|
|
140
|
-
content: t('EXTERNAL_ID', 'External id')
|
|
158
|
+
content: t('EXTERNAL_ID', 'External id'),
|
|
159
|
+
enabled: true
|
|
141
160
|
}, {
|
|
142
161
|
value: 'channel',
|
|
143
|
-
content: t('CHANNEL', 'Channel')
|
|
162
|
+
content: t('CHANNEL', 'Channel'),
|
|
163
|
+
enabled: true
|
|
144
164
|
}, {
|
|
145
165
|
value: 'pod',
|
|
146
|
-
content: t('PODS', 'Pod')
|
|
166
|
+
content: t('PODS', 'Pod'),
|
|
167
|
+
enabled: true
|
|
147
168
|
}];
|
|
148
169
|
var getDelayMinutes = function getDelayMinutes(order) {
|
|
149
170
|
// targetMin = delivery_datetime + eta_time - now()
|
|
@@ -376,7 +397,10 @@ var OrdersTable = exports.OrdersTable = /*#__PURE__*/(0, _react.memo)(function (
|
|
|
376
397
|
className: "orderPrice"
|
|
377
398
|
}, /*#__PURE__*/_react.default.createElement(_Shared.ColumnAllowSettingPopover, {
|
|
378
399
|
allowColumns: allowColumns,
|
|
379
|
-
optionsDefault: optionsDefault
|
|
400
|
+
optionsDefault: optionsDefault.filter(function (_ref) {
|
|
401
|
+
var enabled = _ref.enabled;
|
|
402
|
+
return enabled;
|
|
403
|
+
}),
|
|
380
404
|
handleChangeAllowColumns: handleChangeAllowColumns,
|
|
381
405
|
isOrder: true
|
|
382
406
|
})) : Object.keys(allowColumns).filter(function (col) {
|
|
@@ -390,7 +414,7 @@ var OrdersTable = exports.OrdersTable = /*#__PURE__*/(0, _react.memo)(function (
|
|
|
390
414
|
if (column === 'slaBar') {
|
|
391
415
|
return;
|
|
392
416
|
}
|
|
393
|
-
if (column === 'orderNumber') {
|
|
417
|
+
if (showExternalId ? column === 'dateTime' : column === 'orderNumber') {
|
|
394
418
|
var _allowColumns$orderNu, _allowColumns$dateTim, _allowColumns$slaBar;
|
|
395
419
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, {
|
|
396
420
|
key: i
|
|
@@ -409,7 +433,10 @@ var OrdersTable = exports.OrdersTable = /*#__PURE__*/(0, _react.memo)(function (
|
|
|
409
433
|
key: "noDragTh-".concat(i)
|
|
410
434
|
}, /*#__PURE__*/_react.default.createElement(_Shared.ColumnAllowSettingPopover, {
|
|
411
435
|
allowColumns: allowColumns,
|
|
412
|
-
optionsDefault: optionsDefault
|
|
436
|
+
optionsDefault: optionsDefault.filter(function (_ref2) {
|
|
437
|
+
var enabled = _ref2.enabled;
|
|
438
|
+
return enabled;
|
|
439
|
+
}),
|
|
413
440
|
handleChangeAllowColumns: handleChangeAllowColumns,
|
|
414
441
|
isOrder: true
|
|
415
442
|
})));
|
|
@@ -613,13 +640,9 @@ var OrdersTable = exports.OrdersTable = /*#__PURE__*/(0, _react.memo)(function (
|
|
|
613
640
|
className: "priority"
|
|
614
641
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
615
642
|
className: "info"
|
|
616
|
-
}, /*#__PURE__*/_react.default.createElement("p", {
|
|
617
|
-
className: "bold"
|
|
618
643
|
}, /*#__PURE__*/_react.default.createElement(_reactLoadingSkeleton.default, {
|
|
619
|
-
width:
|
|
620
|
-
})),
|
|
621
|
-
width: 60
|
|
622
|
-
})))), (allowColumns === null || allowColumns === void 0 || (_allowColumns$channel = allowColumns.channel) === null || _allowColumns$channel === void 0 ? void 0 : _allowColumns$channel.visable) && !isSelectedOrders && /*#__PURE__*/_react.default.createElement("td", {
|
|
644
|
+
width: 45
|
|
645
|
+
}))), (allowColumns === null || allowColumns === void 0 || (_allowColumns$channel = allowColumns.channel) === null || _allowColumns$channel === void 0 ? void 0 : _allowColumns$channel.visable) && !isSelectedOrders && /*#__PURE__*/_react.default.createElement("td", {
|
|
623
646
|
className: "orderStatusTitle"
|
|
624
647
|
}, /*#__PURE__*/_react.default.createElement(_styles.WrapOrderStatusSelector, null, /*#__PURE__*/_react.default.createElement(_reactLoadingSkeleton.default, {
|
|
625
648
|
width: 100,
|
|
@@ -669,4 +692,5 @@ var OrdersTable = exports.OrdersTable = /*#__PURE__*/(0, _react.memo)(function (
|
|
|
669
692
|
defaultPageSize: pagination.pageSize,
|
|
670
693
|
handleChangePageSize: handleChangePageSize
|
|
671
694
|
})));
|
|
672
|
-
}, OrderTablePropsAreEqual);
|
|
695
|
+
}, OrderTablePropsAreEqual);
|
|
696
|
+
OrdersTable.displayName = 'OrdersTable';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ordering-ui-admin-external",
|
|
3
|
-
"version": "1.43.
|
|
3
|
+
"version": "1.43.99",
|
|
4
4
|
"description": "Ordering UI Admin Components",
|
|
5
5
|
"main": "./_modules/index.js",
|
|
6
6
|
"exports": {
|
|
@@ -83,7 +83,7 @@
|
|
|
83
83
|
"lodash": "^4.17.20",
|
|
84
84
|
"moment": "^2.29.1",
|
|
85
85
|
"moment-range": "^4.0.2",
|
|
86
|
-
"ordering-components-admin-external": "1.43.
|
|
86
|
+
"ordering-components-admin-external": "1.43.62",
|
|
87
87
|
"polished": "^3.6.7",
|
|
88
88
|
"prop-types": "^15.7.2",
|
|
89
89
|
"react-big-calendar": "^1.4.2",
|
|
@@ -22,14 +22,14 @@ const ExportCSVUI = (props) => {
|
|
|
22
22
|
const [modalOpen, setModalOpen] = useState(false)
|
|
23
23
|
const [alertState, setAlertState] = useState({ open: false, content: [] })
|
|
24
24
|
|
|
25
|
-
const handleExportAll = () => {
|
|
25
|
+
const handleExportAll = (withoutMetafields) => {
|
|
26
26
|
setPopoverOpen(false)
|
|
27
|
-
getCSV(false)
|
|
27
|
+
getCSV(false, withoutMetafields)
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
-
const handleExportFiltered = () => {
|
|
30
|
+
const handleExportFiltered = (withoutMetafields) => {
|
|
31
31
|
setPopoverOpen(false)
|
|
32
|
-
getCSV(true)
|
|
32
|
+
getCSV(true, withoutMetafields)
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
const closePopover = () => {
|
|
@@ -80,6 +80,12 @@ const ExportCSVUI = (props) => {
|
|
|
80
80
|
<Item onClick={() => handleExportFiltered()}>
|
|
81
81
|
{t('EXPORT_FILTERED', 'Export filtered')}
|
|
82
82
|
</Item>
|
|
83
|
+
<Item onClick={() => handleExportAll(true)}>
|
|
84
|
+
{t('EXPORT_ALL_WITHOUT_METAFIELDS', 'Export all without metafields')}
|
|
85
|
+
</Item>
|
|
86
|
+
<Item onClick={() => handleExportFiltered(true)}>
|
|
87
|
+
{t('EXPORT_FILTERED_WITHOUT_METAFIELDS', 'Export filtered without metafields')}
|
|
88
|
+
</Item>
|
|
83
89
|
</PopoverContainer>
|
|
84
90
|
)}
|
|
85
91
|
|