@kmkf-fe-packages/basic-components 2.3.0-rc.0 → 2.5.0-rc.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/index.esm.js +846 -29
- package/dist/index.js +850 -30
- package/dist/src/apaas/OrderSubForm/components/customizeUpload.d.ts +15 -0
- package/dist/src/apaas/OrderSubForm/index.d.ts +27 -0
- package/dist/src/apaas/OrderSubForm/utils.d.ts +22 -0
- package/dist/src/bs/component/GoodItem/index.d.ts +14 -0
- package/dist/src/constants/index.d.ts +1 -0
- package/dist/src/constants/orderSubForm.d.ts +62 -0
- package/dist/src/index.d.ts +2 -0
- package/package.json +3 -3
package/dist/index.esm.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React, { useRef, useState, useEffect, forwardRef, useImperativeHandle, useMemo, useCallback } from 'react';
|
|
2
2
|
import { Cascader, DatePicker, InputNumber, Input, Select, Upload, Image, message, Radio, Space, Spin, Modal, Button, Checkbox, Row, Col, Slider, Rate, Form, Tooltip, Popover, Table, Tabs, ConfigProvider, Pagination, Typography, Skeleton, Tag } from 'antd';
|
|
3
|
-
import { EyeOutlined, DeleteOutlined, CloseOutlined, MinusCircleFilled, PlusCircleFilled, CopyOutlined, CloseCircleOutlined, CaretUpOutlined, VideoCameraTwoTone } from '@ant-design/icons';
|
|
3
|
+
import { EyeOutlined, DeleteOutlined, CloseOutlined, MinusCircleFilled, PlusCircleFilled, CopyOutlined, CloseCircleOutlined, CaretUpOutlined, PlusOutlined, VideoCameraTwoTone } from '@ant-design/icons';
|
|
4
4
|
import request, { extend as extend$1 } from 'umi-request';
|
|
5
5
|
import { CopyToClipboard } from 'react-copy-to-clipboard';
|
|
6
|
-
import { AddressData, BsAddressData, WdtAddressData, GyAddressData, request as request$1, ExpressData, uuid, servers, columnsGoodsList, LogisticsAddressData, SendDataCenter, BS_E3_BOOLEAN_STATUS_MAP, isNull, filterWdtOrders, WDT_ORDER_TYPE_MAP, tradeStatusMap, filterBsE3Orders, filterGyOrders, GY_DELIVERY_STATE_MAPPING, filterJstOrders, filterKmOrders, getIsPlatformCodesIncludeOrderNos, BS_SYSTEM_ORDER_CONFIG, KM_SYSTEM_ORDER_CONFIG, WLN_SYSTEM_ORDER_CONFIG, WDT_SYSTEM_ORDER_CONFIG, BS_E3_SYSTEM_ORDER_CONFIG, GY_SYSTEM_ORDER_CONFIG, JST_SYSTEM_ORDER_CONFIG, updateWlnGoodsHandle, updateWdtGoodsHandle, updateBsE3GoodsHandle, updateGyGoodsHandle, updateJstGoodsHandle, updateKmGoodsHandle, jstMergeIdenticalGoods, msgTypeCh, pushGyLog, skxSystemOrderBackValues, updateSkxGoodsHandle } from '@kmkf-fe-packages/kmkf-utils';
|
|
7
|
-
import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, uniqBy, cloneDeep, difference, differenceWith, isBoolean, isEqual, takeRight, reject,
|
|
6
|
+
import { AddressData, BsAddressData, WdtAddressData, GyAddressData, request as request$1, ExpressData, uuid, servers, columnsGoodsList, LogisticsAddressData, SendDataCenter, BS_E3_BOOLEAN_STATUS_MAP, isNull, filterWdtOrders, WDT_ORDER_TYPE_MAP, tradeStatusMap, filterBsE3Orders, filterGyOrders, GY_DELIVERY_STATE_MAPPING, filterJstOrders, filterKmOrders, getIsPlatformCodesIncludeOrderNos, BS_SYSTEM_ORDER_CONFIG, KM_SYSTEM_ORDER_CONFIG, WLN_SYSTEM_ORDER_CONFIG, WDT_SYSTEM_ORDER_CONFIG, BS_E3_SYSTEM_ORDER_CONFIG, GY_SYSTEM_ORDER_CONFIG, JST_SYSTEM_ORDER_CONFIG, updateOrderSubFormGoodsHandle, updateWlnGoodsHandle, updateWdtGoodsHandle, updateBsE3GoodsHandle, updateGyGoodsHandle, updateJstGoodsHandle, updateKmGoodsHandle, jstMergeIdenticalGoods, msgTypeCh, pushGyLog, skxSystemOrderBackValues, updateSkxGoodsHandle } from '@kmkf-fe-packages/kmkf-utils';
|
|
7
|
+
import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, uniqBy, cloneDeep, difference, differenceWith, isBoolean, isEqual, takeRight, reject, intersection, isEmpty } from 'lodash';
|
|
8
8
|
import { useUpdateEffect, useDebounceEffect, useAntdTable } from 'ahooks';
|
|
9
9
|
import zhCN from 'antd/lib/locale/zh_CN';
|
|
10
10
|
import pubsub from 'pubsub-js';
|
|
@@ -1225,7 +1225,7 @@ var ApaasUploadAsync = function ApaasUploadAsync(_ref, ref) {
|
|
|
1225
1225
|
className: "addBtn"
|
|
1226
1226
|
}, "+"), /*#__PURE__*/React.createElement("div", null, uploadText)))));
|
|
1227
1227
|
};
|
|
1228
|
-
var
|
|
1228
|
+
var ApaasUploadAsync$1 = /*#__PURE__*/forwardRef(ApaasUploadAsync);
|
|
1229
1229
|
|
|
1230
1230
|
var css_248z$2 = ".index-module_imageProBox__1u84Y {\n display: flex;\n flex-wrap: wrap;\n}\n.index-module_imageProBox__1u84Y .ant-upload-picture-card-wrapper {\n width: auto;\n}\n.index-module_imageProBox__1u84Y .index-module_inputImage__nm5jb {\n width: 105px;\n height: 105px;\n border: 1px dashed #ccc;\n outline: none;\n background-color: rgba(0, 0, 0, 0);\n text-indent: 8px;\n}\n.index-module_imageProBox__1u84Y .index-module_imageShow__1cG2j {\n padding: 8px;\n border: 1px solid #d9d9d9;\n border-radius: 2px;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProWrap__sx8lo {\n display: flex;\n width: 280px;\n height: 105px;\n border-radius: 5px;\n background-color: rgba(240, 241, 242, 0.72);\n}\n.index-module_imageProBox__1u84Y .index-module_imageProWrap__sx8lo textarea {\n max-width: 174px;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProWrap__sx8lo:hover .index-module_mask__L3q8p:before {\n opacity: 1;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProWrap__sx8lo .index-module_imageProInfo__iHM0C {\n width: 80px;\n height: 80px;\n border-radius: 5px;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProWrap__sx8lo img {\n width: 100%;\n height: 100%;\n -o-object-fit: contain;\n object-fit: contain;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProWrap__sx8lo .index-module_imageProRight__3rPiY {\n position: relative;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProWrap__sx8lo .index-module_imageProOperate__1hFcg {\n position: absolute;\n right: 0;\n bottom: 0;\n display: flex;\n justify-content: flex-end;\n align-items: center;\n}\n.index-module_imageProBox__1u84Y .index-module_mask__L3q8p {\n position: relative;\n height: 100%;\n overflow: hidden;\n}\n.index-module_imageProBox__1u84Y .index-module_mask__L3q8p::before {\n position: absolute;\n z-index: 1;\n width: 100%;\n height: 100%;\n background-color: rgba(0, 0, 0, 0.5);\n opacity: 0;\n transition: all 0.3s;\n content: ' ';\n}\n.index-module_imageProBox__1u84Y .index-module_mask__L3q8p:hover .index-module_actions__3Wwry {\n opacity: 1;\n}\n.index-module_imageProBox__1u84Y .index-module_mask__L3q8p .index-module_actions__3Wwry {\n position: absolute;\n top: 50%;\n left: 50%;\n z-index: 10;\n white-space: nowrap;\n transform: translate(-50%, -50%);\n opacity: 0;\n transition: all 0.3s;\n}\n.index-module_imageProBox__1u84Y .index-module_mask__L3q8p .index-module_actions__3Wwry .index-module_icon__3oJ-1 {\n font-size: 16px;\n color: #fff;\n padding: 0 4px;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProPaste__22O8e {\n display: inline-block;\n margin-right: 8px !important;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProPaste__22O8e .index-module_fakeBox__3EXNG {\n width: 105px;\n height: 105px;\n border-radius: 2px;\n background: #F2F3F5;\n text-align: center;\n color: #86909C;\n}\n.index-module_imageProBox__1u84Y .index-module_imageProPaste__22O8e .index-module_fakeBox__3EXNG .index-module_addBtn__1Dv95 {\n color: #86909C;\n}\n.index-module_imageProBox__1u84Y .index-module_uploadPro__3rAkl .ant-upload {\n height: 105px !important;\n width: 105px !important;\n border: none;\n background-color: #F2F3F5;\n color: #86909C;\n}\n.index-module_imageProBox__1u84Y .index-module_uploadPro__3rAkl .ant-upload .index-module_addBtn__1Dv95 {\n color: #86909C;\n}\n.index-module_tips__z9Yjd {\n color: #4E5969;\n font-size: 12px;\n}\n";
|
|
1231
1231
|
var styles$2 = {"imageProBox":"index-module_imageProBox__1u84Y","inputImage":"index-module_inputImage__nm5jb","imageShow":"index-module_imageShow__1cG2j","imageProWrap":"index-module_imageProWrap__sx8lo","-webkit-mask":"index-module_mask__L3q8p","mask":"index-module_mask__L3q8p","imageProInfo":"index-module_imageProInfo__iHM0C","imageProRight":"index-module_imageProRight__3rPiY","imageProOperate":"index-module_imageProOperate__1hFcg","actions":"index-module_actions__3Wwry","icon":"index-module_icon__3oJ-1","imageProPaste":"index-module_imageProPaste__22O8e","fakeBox":"index-module_fakeBox__3EXNG","addBtn":"index-module_addBtn__1Dv95","uploadPro":"index-module_uploadPro__3rAkl","tips":"index-module_tips__z9Yjd"};
|
|
@@ -1534,7 +1534,7 @@ var ApaasUploadProAsync = function ApaasUploadProAsync(_ref, ref) {
|
|
|
1534
1534
|
className: "addBtn"
|
|
1535
1535
|
}, "+"), /*#__PURE__*/React.createElement("div", null, uploadText))), renderImages(value)));
|
|
1536
1536
|
};
|
|
1537
|
-
var index
|
|
1537
|
+
var index = /*#__PURE__*/forwardRef(ApaasUploadProAsync);
|
|
1538
1538
|
|
|
1539
1539
|
var css_248z$3 = ".index-module_imageBox__1rpoB {\n display: flex;\n flex-wrap: wrap;\n}\n.index-module_imageBox__1rpoB .ant-upload-picture-card-wrapper {\n width: auto;\n}\n.index-module_imageBox__1rpoB .index-module_inputImage__MyiR1 {\n width: 80px;\n height: 80px;\n border: 1px dashed #ccc;\n outline: none;\n background-color: rgba(0, 0, 0, 0);\n text-indent: 8px;\n}\n.index-module_imageBox__1rpoB .index-module_imageShow__3BNqT {\n padding: 8px;\n border: 1px solid #d9d9d9;\n border-radius: 2px;\n}\n.index-module_imageBox__1rpoB .index-module_imageWrap__LyKfP {\n width: 100px;\n height: 80px;\n position: relative;\n border-radius: 2px;\n margin-right: 8px;\n margin-bottom: 8px;\n}\n.index-module_imageBox__1rpoB .index-module_imageWrap__LyKfP:hover {\n background: transparent;\n}\n.index-module_imageBox__1rpoB .index-module_imageWrap__LyKfP:hover .index-module_mask__uy8r2:before {\n opacity: 1;\n}\n.index-module_imageBox__1rpoB .index-module_imageWrap__LyKfP img {\n width: 100%;\n height: 100%;\n -o-object-fit: contain;\n object-fit: contain;\n}\n.index-module_imageBox__1rpoB .index-module_imageWrap__LyKfP .index-module_delete__28zCp {\n position: absolute;\n right: 0px;\n top: 0px;\n}\n.index-module_imageBox__1rpoB .index-module_mask__uy8r2 {\n position: relative;\n height: 100%;\n overflow: hidden;\n}\n.index-module_imageBox__1rpoB .index-module_mask__uy8r2::before {\n position: absolute;\n z-index: 1;\n width: 100%;\n height: 100%;\n background-color: rgba(0, 0, 0, 0.5);\n opacity: 0;\n transition: all 0.3s;\n content: ' ';\n}\n.index-module_imageBox__1rpoB .index-module_mask__uy8r2:hover .index-module_actions__1-6f4 {\n opacity: 1;\n}\n.index-module_imageBox__1rpoB .index-module_mask__uy8r2 .index-module_actions__1-6f4 {\n position: absolute;\n top: 50%;\n left: 50%;\n z-index: 10;\n white-space: nowrap;\n transform: translate(-50%, -50%);\n opacity: 0;\n transition: all 0.3s;\n}\n.index-module_imageBox__1rpoB .index-module_mask__uy8r2 .index-module_actions__1-6f4 .index-module_icon__3yEcS {\n font-size: 16px;\n color: #fff;\n padding: 0 4px;\n}\n.index-module_imageBox__1rpoB .index-module_imagePaste__Ac77C {\n display: inline-block;\n margin-right: 8px;\n margin-bottom: 8px;\n}\n.index-module_imageBox__1rpoB .index-module_imagePaste__Ac77C .index-module_fakeBox__3W1d- {\n width: 80px;\n height: 80px;\n border-radius: 2px;\n background: #F2F3F5;\n text-align: center;\n color: #86909C;\n padding-top: 16px;\n}\n.index-module_imageBox__1rpoB .index-module_imagePaste__Ac77C .index-module_fakeBox__3W1d- .index-module_addBtn__3a1TQ {\n color: #86909C;\n}\n.index-module_imageBox__1rpoB .ant-upload {\n padding: 0;\n height: 80px;\n width: 80px;\n border: none;\n border-radius: 2px;\n background: #F2F3F5;\n text-align: center;\n color: #86909C;\n font-size: 14px;\n}\n.index-module_imageBox__1rpoB .ant-upload .index-module_addBtn__3a1TQ {\n color: #86909C;\n font-size: 14px;\n}\n.index-module_tips__168Vy {\n color: #4E5969;\n font-size: 12px;\n}\n";
|
|
1540
1540
|
var styles$3 = {"imageBox":"index-module_imageBox__1rpoB","inputImage":"index-module_inputImage__MyiR1","imageShow":"index-module_imageShow__3BNqT","imageWrap":"index-module_imageWrap__LyKfP","-webkit-mask":"index-module_mask__uy8r2","mask":"index-module_mask__uy8r2","delete":"index-module_delete__28zCp","actions":"index-module_actions__1-6f4","icon":"index-module_icon__3yEcS","imagePaste":"index-module_imagePaste__Ac77C","fakeBox":"index-module_fakeBox__3W1d-","addBtn":"index-module_addBtn__3a1TQ","tips":"index-module_tips__168Vy"};
|
|
@@ -8417,6 +8417,10 @@ var SubForm = function SubForm(props) {
|
|
|
8417
8417
|
}
|
|
8418
8418
|
});
|
|
8419
8419
|
}
|
|
8420
|
+
if (maxCount && (value === null || value === void 0 ? void 0 : value.length) >= maxCount) {
|
|
8421
|
+
message.error("\u8BE5\u5B50\u8868\u5355\u6700\u591A\u6DFB\u52A0".concat(maxCount, "\u6761"));
|
|
8422
|
+
return;
|
|
8423
|
+
}
|
|
8420
8424
|
onChange === null || onChange === void 0 ? void 0 : onChange([].concat(_toConsumableArray(value || []), [_objectSpread2(_objectSpread2({}, newValue), {}, {
|
|
8421
8425
|
uuid: uuid()
|
|
8422
8426
|
})]));
|
|
@@ -12990,7 +12994,7 @@ var getColumnsBaseInfo = function getColumnsBaseInfo() {
|
|
|
12990
12994
|
});
|
|
12991
12995
|
return newColumns;
|
|
12992
12996
|
};
|
|
12993
|
-
var index$
|
|
12997
|
+
var index$1 = getColumnsBaseInfo();
|
|
12994
12998
|
|
|
12995
12999
|
var initNo = {
|
|
12996
13000
|
dataIndex: 'index',
|
|
@@ -18624,7 +18628,7 @@ var rowKeyMap = {
|
|
|
18624
18628
|
GY_SYSTEM_ORDER: 'billNo',
|
|
18625
18629
|
JST_SYSTEM_ORDER: 'oId'
|
|
18626
18630
|
};
|
|
18627
|
-
var index$
|
|
18631
|
+
var index$2 = (function (props) {
|
|
18628
18632
|
var value = props.value,
|
|
18629
18633
|
_onChange = props.onChange,
|
|
18630
18634
|
disabled = props.disabled,
|
|
@@ -18934,6 +18938,819 @@ var index$3 = (function (props) {
|
|
|
18934
18938
|
}));
|
|
18935
18939
|
});
|
|
18936
18940
|
|
|
18941
|
+
var css_248z$b = ".customizeUpload-module_customizeUpload__2tG-4 {\n display: flex;\n flex-wrap: wrap;\n gap: 8px;\n width: 100%;\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_addButton__2w8Jj {\n display: flex !important;\n align-items: center;\n justify-content: center;\n width: 24px;\n height: 24px;\n border: 1px solid #d9d9d9;\n border-radius: 6px;\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_addButton__2w8Jj:hover:not(:disabled) {\n color: #40a9ff;\n border-color: #40a9ff;\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_addButton__2w8Jj:disabled {\n color: #bfbfbf;\n background-color: #f5f5f5;\n border-color: #d9d9d9;\n cursor: not-allowed;\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_imageItem__yn6H1 {\n position: relative;\n width: 24px;\n height: 24px;\n overflow: hidden;\n border: 1px solid #d9d9d9;\n border-radius: 6px;\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_imageItem__yn6H1 .customizeUpload-module_image__3hOnT {\n width: 100%;\n height: 100%;\n -o-object-fit: cover;\n object-fit: cover;\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_imageItem__yn6H1 .customizeUpload-module_deleteBtn__85Jsl {\n position: absolute;\n top: 2px;\n right: 2px;\n display: flex;\n align-items: center;\n justify-content: center;\n width: 16px;\n height: 16px;\n color: white;\n font-size: 10px;\n background-color: rgba(0, 0, 0, 0.6);\n border-radius: 50%;\n cursor: pointer;\n opacity: 0;\n transition: opacity 0.2s;\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_imageItem__yn6H1 .customizeUpload-module_deleteBtn__85Jsl:hover {\n background-color: rgba(255, 0, 0, 0.8);\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_imageItem__yn6H1:hover .customizeUpload-module_deleteBtn__85Jsl {\n opacity: 1;\n}\n.customizeUpload-module_customizeUpload__2tG-4 .customizeUpload-module_uploadContainer__rUcw7 {\n margin-top: 12px;\n}\n.customizeUpload-module_popoverContent__FrAiq {\n width: 280px;\n}\n.customizeUpload-module_popoverContent__FrAiq .customizeUpload-module_popoverTitle__3Qw2t {\n margin-bottom: 4px;\n color: #262626;\n font-weight: 500;\n font-size: 16px;\n}\n.customizeUpload-module_popoverContent__FrAiq .customizeUpload-module_popoverSubtitle__1NA3m {\n margin-bottom: 16px;\n color: #8c8c8c;\n font-size: 12px;\n}\n.customizeUpload-module_popoverContent__FrAiq .customizeUpload-module_actionButtons__2la0G {\n display: flex;\n gap: 12px;\n}\n.customizeUpload-module_popoverContent__FrAiq .customizeUpload-module_actionButtons__2la0G .customizeUpload-module_actionButton__1Wr1J {\n display: flex;\n flex: 1;\n gap: 6px;\n align-items: center;\n justify-content: center;\n height: 40px;\n background-color: #fafafa;\n border: 1px solid #d9d9d9;\n border-radius: 6px;\n}\n.customizeUpload-module_popoverContent__FrAiq .customizeUpload-module_actionButtons__2la0G .customizeUpload-module_actionButton__1Wr1J:hover:not(:disabled) {\n color: #40a9ff;\n background-color: #f0f8ff;\n border-color: #40a9ff;\n}\n.customizeUpload-module_popoverContent__FrAiq .customizeUpload-module_actionButtons__2la0G .customizeUpload-module_actionButton__1Wr1J:disabled {\n color: #bfbfbf;\n background-color: #f5f5f5;\n border-color: #d9d9d9;\n cursor: not-allowed;\n}\n";
|
|
18942
|
+
var styles$5 = {"customizeUpload":"customizeUpload-module_customizeUpload__2tG-4","addButton":"customizeUpload-module_addButton__2w8Jj","imageItem":"customizeUpload-module_imageItem__yn6H1","image":"customizeUpload-module_image__3hOnT","deleteBtn":"customizeUpload-module_deleteBtn__85Jsl","uploadContainer":"customizeUpload-module_uploadContainer__rUcw7","popoverContent":"customizeUpload-module_popoverContent__FrAiq","popoverTitle":"customizeUpload-module_popoverTitle__3Qw2t","popoverSubtitle":"customizeUpload-module_popoverSubtitle__1NA3m","actionButtons":"customizeUpload-module_actionButtons__2la0G","actionButton":"customizeUpload-module_actionButton__1Wr1J"};
|
|
18943
|
+
styleInject(css_248z$b);
|
|
18944
|
+
|
|
18945
|
+
var CustomizeUpload = function CustomizeUpload(_ref) {
|
|
18946
|
+
var _ref$value = _ref.value,
|
|
18947
|
+
value = _ref$value === void 0 ? '' : _ref$value,
|
|
18948
|
+
onChange = _ref.onChange,
|
|
18949
|
+
_ref$disabled = _ref.disabled,
|
|
18950
|
+
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
18951
|
+
_ref$maxCount = _ref.maxCount,
|
|
18952
|
+
maxCount = _ref$maxCount === void 0 ? 20 : _ref$maxCount,
|
|
18953
|
+
_ref$maxSize = _ref.maxSize,
|
|
18954
|
+
maxSize = _ref$maxSize === void 0 ? 10 : _ref$maxSize;
|
|
18955
|
+
var _useState = useState(false),
|
|
18956
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
18957
|
+
popoverVisible = _useState2[0],
|
|
18958
|
+
setPopoverVisible = _useState2[1];
|
|
18959
|
+
var newValue = useMemo(function () {
|
|
18960
|
+
return value ? value === null || value === void 0 ? void 0 : value.split(',') : [];
|
|
18961
|
+
}, [value]);
|
|
18962
|
+
// 渲染图片显示
|
|
18963
|
+
var renderImages = function renderImages() {
|
|
18964
|
+
if (newValue.length === 0) return null;
|
|
18965
|
+
return /*#__PURE__*/React.createElement(Image.PreviewGroup, null, newValue.map(function (image, index) {
|
|
18966
|
+
var finalSrc = (image === null || image === void 0 ? void 0 : image.startsWith('http')) ? image : "https://kefu.kuaimai.com/".concat(image);
|
|
18967
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
18968
|
+
key: index,
|
|
18969
|
+
className: styles$5.imageItem
|
|
18970
|
+
}, /*#__PURE__*/React.createElement(Image, {
|
|
18971
|
+
src: finalSrc,
|
|
18972
|
+
alt: "\u56FE\u7247".concat(index + 1),
|
|
18973
|
+
className: styles$5.image,
|
|
18974
|
+
preview: {
|
|
18975
|
+
mask: '点击预览'
|
|
18976
|
+
}
|
|
18977
|
+
}));
|
|
18978
|
+
}));
|
|
18979
|
+
};
|
|
18980
|
+
var handleUploadChange = function handleUploadChange(val) {
|
|
18981
|
+
var newValue = val.map(function (t) {
|
|
18982
|
+
return (t === null || t === void 0 ? void 0 : t.startsWith('http')) ? t : "https://kefu.kuaimai.com/".concat(t);
|
|
18983
|
+
});
|
|
18984
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue.join(','));
|
|
18985
|
+
};
|
|
18986
|
+
// Popover 内容
|
|
18987
|
+
var popoverContent = /*#__PURE__*/React.createElement("div", {
|
|
18988
|
+
className: styles$5.popoverContent
|
|
18989
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
18990
|
+
className: styles$5.popoverTitle
|
|
18991
|
+
}, "\u6DFB\u52A0\u56FE\u7247"), /*#__PURE__*/React.createElement("div", {
|
|
18992
|
+
className: styles$5.uploadContainer
|
|
18993
|
+
}, /*#__PURE__*/React.createElement(ApaasUploadAsync$1, {
|
|
18994
|
+
canPreview: true,
|
|
18995
|
+
maxSize: maxSize,
|
|
18996
|
+
maxCount: maxCount,
|
|
18997
|
+
uniqueKey: "remark",
|
|
18998
|
+
hostUrl: "https://kefu.kuaimai.com",
|
|
18999
|
+
value: newValue || [],
|
|
19000
|
+
onChange: handleUploadChange,
|
|
19001
|
+
disabled: disabled
|
|
19002
|
+
})));
|
|
19003
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
19004
|
+
className: styles$5.customizeUpload
|
|
19005
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
19006
|
+
className: styles$5.inputContainer
|
|
19007
|
+
}, /*#__PURE__*/React.createElement(Popover, {
|
|
19008
|
+
getPopupContainer: function getPopupContainer() {
|
|
19009
|
+
return document.body;
|
|
19010
|
+
},
|
|
19011
|
+
content: popoverContent,
|
|
19012
|
+
title: null,
|
|
19013
|
+
trigger: "click",
|
|
19014
|
+
open: popoverVisible,
|
|
19015
|
+
onOpenChange: setPopoverVisible,
|
|
19016
|
+
placement: "bottomLeft",
|
|
19017
|
+
overlayStyle: {
|
|
19018
|
+
zIndex: 2000
|
|
19019
|
+
}
|
|
19020
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
19021
|
+
className: styles$5.addButton,
|
|
19022
|
+
icon: /*#__PURE__*/React.createElement(PlusOutlined, null),
|
|
19023
|
+
disabled: disabled,
|
|
19024
|
+
type: "text"
|
|
19025
|
+
}))), renderImages());
|
|
19026
|
+
};
|
|
19027
|
+
|
|
19028
|
+
var refundTypeMap = {
|
|
19029
|
+
0: '其他',
|
|
19030
|
+
1: '已发货仅退款',
|
|
19031
|
+
2: '退货',
|
|
19032
|
+
3: '补发',
|
|
19033
|
+
4: '换货',
|
|
19034
|
+
5: '未发货仅退款',
|
|
19035
|
+
9: '维修',
|
|
19036
|
+
10: '价保',
|
|
19037
|
+
11: '大家电安装',
|
|
19038
|
+
12: '大家电移机',
|
|
19039
|
+
13: '大家电增值服务',
|
|
19040
|
+
14: '优鲜赔',
|
|
19041
|
+
15: '试用收回'
|
|
19042
|
+
};
|
|
19043
|
+
var refundTypeOptions = Object.entries(refundTypeMap).map(function (_ref) {
|
|
19044
|
+
var _ref2 = _slicedToArray(_ref, 2),
|
|
19045
|
+
key = _ref2[0],
|
|
19046
|
+
value = _ref2[1];
|
|
19047
|
+
return {
|
|
19048
|
+
label: value,
|
|
19049
|
+
value: Number(key)
|
|
19050
|
+
};
|
|
19051
|
+
});
|
|
19052
|
+
var onlineStatusMap = {
|
|
19053
|
+
1: '空',
|
|
19054
|
+
2: '待卖家同意',
|
|
19055
|
+
3: '待买家退货',
|
|
19056
|
+
4: '待卖家确认收货',
|
|
19057
|
+
5: '卖家拒绝退款',
|
|
19058
|
+
6: '退款关闭',
|
|
19059
|
+
7: '退款成功',
|
|
19060
|
+
8: '待发出换货商品',
|
|
19061
|
+
9: '待买家收货',
|
|
19062
|
+
10: '换货关闭',
|
|
19063
|
+
11: '换货成功'
|
|
19064
|
+
};
|
|
19065
|
+
var onlineStatusOptions = Object.entries(onlineStatusMap).map(function (_ref3) {
|
|
19066
|
+
var _ref4 = _slicedToArray(_ref3, 2),
|
|
19067
|
+
key = _ref4[0],
|
|
19068
|
+
value = _ref4[1];
|
|
19069
|
+
return {
|
|
19070
|
+
label: value,
|
|
19071
|
+
value: Number(key)
|
|
19072
|
+
};
|
|
19073
|
+
});
|
|
19074
|
+
var consignTypeMap = {
|
|
19075
|
+
1: '是',
|
|
19076
|
+
0: '否'
|
|
19077
|
+
};
|
|
19078
|
+
var consignTypeOptions = Object.entries(consignTypeMap).map(function (_ref5) {
|
|
19079
|
+
var _ref6 = _slicedToArray(_ref5, 2),
|
|
19080
|
+
key = _ref6[0],
|
|
19081
|
+
value = _ref6[1];
|
|
19082
|
+
return {
|
|
19083
|
+
label: value,
|
|
19084
|
+
value: Number(key)
|
|
19085
|
+
};
|
|
19086
|
+
});
|
|
19087
|
+
var getOrderSubformColumns = function getOrderSubformColumns(parmas) {
|
|
19088
|
+
var _ref7 = parmas || {},
|
|
19089
|
+
_ref7$expressData = _ref7.expressData,
|
|
19090
|
+
expressData = _ref7$expressData === void 0 ? [] : _ref7$expressData;
|
|
19091
|
+
return [{
|
|
19092
|
+
dataIndex: 'title',
|
|
19093
|
+
title: '商品名称',
|
|
19094
|
+
widget: 'input',
|
|
19095
|
+
widgetProps: {},
|
|
19096
|
+
width: 150
|
|
19097
|
+
}, {
|
|
19098
|
+
dataIndex: 'productCode',
|
|
19099
|
+
title: '商品编码',
|
|
19100
|
+
widget: 'input',
|
|
19101
|
+
width: 150,
|
|
19102
|
+
widgetProps: {}
|
|
19103
|
+
}, {
|
|
19104
|
+
dataIndex: 'picUrl',
|
|
19105
|
+
title: '图片',
|
|
19106
|
+
widget: 'upload',
|
|
19107
|
+
widgetProps: {},
|
|
19108
|
+
width: 100,
|
|
19109
|
+
customizeComponent: function customizeComponent(config) {
|
|
19110
|
+
return /*#__PURE__*/React.createElement(CustomizeUpload, {
|
|
19111
|
+
disabled: config.disabled,
|
|
19112
|
+
value: config.value,
|
|
19113
|
+
onChange: config.onChange,
|
|
19114
|
+
maxCount: config.maxCount,
|
|
19115
|
+
maxSize: config.maxSize
|
|
19116
|
+
});
|
|
19117
|
+
}
|
|
19118
|
+
}, {
|
|
19119
|
+
dataIndex: 'numIid',
|
|
19120
|
+
title: '商品id',
|
|
19121
|
+
widget: 'input',
|
|
19122
|
+
widgetProps: {},
|
|
19123
|
+
width: 150
|
|
19124
|
+
}, {
|
|
19125
|
+
dataIndex: 'quantity',
|
|
19126
|
+
title: '商品数量',
|
|
19127
|
+
widget: 'inputNumber',
|
|
19128
|
+
width: 100,
|
|
19129
|
+
widgetProps: {
|
|
19130
|
+
precision: 0,
|
|
19131
|
+
min: 0
|
|
19132
|
+
}
|
|
19133
|
+
}, {
|
|
19134
|
+
dataIndex: 'skuId',
|
|
19135
|
+
title: 'SKU ID',
|
|
19136
|
+
widget: 'input',
|
|
19137
|
+
width: 150,
|
|
19138
|
+
widgetProps: {}
|
|
19139
|
+
}, {
|
|
19140
|
+
dataIndex: 'outerSkuId',
|
|
19141
|
+
title: 'SKU 编码',
|
|
19142
|
+
widget: 'input',
|
|
19143
|
+
width: 150,
|
|
19144
|
+
widgetProps: {}
|
|
19145
|
+
}, {
|
|
19146
|
+
dataIndex: 'propertiesName',
|
|
19147
|
+
title: 'SKU 信息',
|
|
19148
|
+
widget: 'input',
|
|
19149
|
+
width: 200,
|
|
19150
|
+
widgetProps: {}
|
|
19151
|
+
}, {
|
|
19152
|
+
dataIndex: 'oid',
|
|
19153
|
+
title: '子订单号',
|
|
19154
|
+
widget: 'input',
|
|
19155
|
+
width: 150,
|
|
19156
|
+
widgetProps: {}
|
|
19157
|
+
}, {
|
|
19158
|
+
dataIndex: 'price',
|
|
19159
|
+
title: '商品单价',
|
|
19160
|
+
widget: 'inputNumber',
|
|
19161
|
+
width: 100,
|
|
19162
|
+
widgetProps: {
|
|
19163
|
+
precision: 2,
|
|
19164
|
+
min: 0
|
|
19165
|
+
}
|
|
19166
|
+
}, {
|
|
19167
|
+
dataIndex: 'actualPayment',
|
|
19168
|
+
title: '[子]实付金额',
|
|
19169
|
+
widget: 'inputNumber',
|
|
19170
|
+
width: 100,
|
|
19171
|
+
widgetProps: {
|
|
19172
|
+
precision: 2,
|
|
19173
|
+
min: 0
|
|
19174
|
+
}
|
|
19175
|
+
}, {
|
|
19176
|
+
dataIndex: 'expressLogisticsCode',
|
|
19177
|
+
title: '[子]运单号',
|
|
19178
|
+
widget: 'input',
|
|
19179
|
+
width: 150,
|
|
19180
|
+
widgetProps: {}
|
|
19181
|
+
}, {
|
|
19182
|
+
dataIndex: 'expressLogisticsCompany',
|
|
19183
|
+
title: '[子]发货快递',
|
|
19184
|
+
widget: 'select',
|
|
19185
|
+
width: 150,
|
|
19186
|
+
widgetProps: {
|
|
19187
|
+
filterOption: function filterOption(input, option) {
|
|
19188
|
+
return option.label.includes(input);
|
|
19189
|
+
},
|
|
19190
|
+
options: expressData,
|
|
19191
|
+
showSearch: true,
|
|
19192
|
+
allowClear: true
|
|
19193
|
+
}
|
|
19194
|
+
}, {
|
|
19195
|
+
dataIndex: 'refundId',
|
|
19196
|
+
title: '退款单ID',
|
|
19197
|
+
widget: 'input',
|
|
19198
|
+
width: 150,
|
|
19199
|
+
widgetProps: {}
|
|
19200
|
+
}, {
|
|
19201
|
+
dataIndex: 'returnExpressLogisticsCode',
|
|
19202
|
+
title: '退货物流单号',
|
|
19203
|
+
widget: 'input',
|
|
19204
|
+
width: 150,
|
|
19205
|
+
widgetProps: {}
|
|
19206
|
+
}, {
|
|
19207
|
+
dataIndex: 'returnExpressLogisticsCompany',
|
|
19208
|
+
title: '退货物流公司',
|
|
19209
|
+
widget: 'select',
|
|
19210
|
+
width: 150,
|
|
19211
|
+
widgetProps: {
|
|
19212
|
+
filterOption: function filterOption(input, option) {
|
|
19213
|
+
return option.label.includes(input);
|
|
19214
|
+
},
|
|
19215
|
+
options: expressData,
|
|
19216
|
+
showSearch: true,
|
|
19217
|
+
allowClear: true
|
|
19218
|
+
}
|
|
19219
|
+
}, {
|
|
19220
|
+
dataIndex: 'reason',
|
|
19221
|
+
title: '退款原因',
|
|
19222
|
+
widget: 'input',
|
|
19223
|
+
width: 200,
|
|
19224
|
+
widgetProps: {}
|
|
19225
|
+
}, {
|
|
19226
|
+
dataIndex: 'refundAmount',
|
|
19227
|
+
title: '退款金额',
|
|
19228
|
+
widget: 'inputNumber',
|
|
19229
|
+
width: 100,
|
|
19230
|
+
widgetProps: {
|
|
19231
|
+
precision: 2,
|
|
19232
|
+
min: 0
|
|
19233
|
+
}
|
|
19234
|
+
}, {
|
|
19235
|
+
dataIndex: 'afterSaleType',
|
|
19236
|
+
title: '退款类型',
|
|
19237
|
+
widget: 'select',
|
|
19238
|
+
width: 150,
|
|
19239
|
+
widgetProps: {
|
|
19240
|
+
filterOption: function filterOption(input, option) {
|
|
19241
|
+
return option.label.includes(input);
|
|
19242
|
+
},
|
|
19243
|
+
options: refundTypeOptions,
|
|
19244
|
+
showSearch: true,
|
|
19245
|
+
allowClear: true
|
|
19246
|
+
}
|
|
19247
|
+
}, {
|
|
19248
|
+
dataIndex: 'platformStatusText',
|
|
19249
|
+
title: '退款状态(平台)',
|
|
19250
|
+
widget: 'input',
|
|
19251
|
+
width: 150,
|
|
19252
|
+
widgetProps: {}
|
|
19253
|
+
}, {
|
|
19254
|
+
dataIndex: 'onlineStatus',
|
|
19255
|
+
title: '退款状态(快麦)',
|
|
19256
|
+
widget: 'select',
|
|
19257
|
+
width: 150,
|
|
19258
|
+
widgetProps: {
|
|
19259
|
+
filterOption: function filterOption(input, option) {
|
|
19260
|
+
return option.label.includes(input);
|
|
19261
|
+
},
|
|
19262
|
+
options: onlineStatusOptions,
|
|
19263
|
+
showSearch: true,
|
|
19264
|
+
allowClear: true
|
|
19265
|
+
}
|
|
19266
|
+
}, {
|
|
19267
|
+
dataIndex: 'applyTime',
|
|
19268
|
+
title: '退款申请时间',
|
|
19269
|
+
widget: 'datePicker',
|
|
19270
|
+
width: 200,
|
|
19271
|
+
widgetProps: {
|
|
19272
|
+
showTime: true,
|
|
19273
|
+
format: 'YYYY-MM-DD HH:mm:ss'
|
|
19274
|
+
}
|
|
19275
|
+
}, {
|
|
19276
|
+
dataIndex: 'returnFreeShipping',
|
|
19277
|
+
title: '退货免运费',
|
|
19278
|
+
widget: 'input',
|
|
19279
|
+
width: 150,
|
|
19280
|
+
widgetProps: {}
|
|
19281
|
+
}, {
|
|
19282
|
+
dataIndex: 'isCNShipment',
|
|
19283
|
+
title: '是否菜鸟仓发货',
|
|
19284
|
+
widget: 'select',
|
|
19285
|
+
width: 100,
|
|
19286
|
+
widgetProps: {
|
|
19287
|
+
filterOption: function filterOption(input, option) {
|
|
19288
|
+
return option.label.includes(input);
|
|
19289
|
+
},
|
|
19290
|
+
options: consignTypeOptions,
|
|
19291
|
+
showSearch: true,
|
|
19292
|
+
allowClear: true
|
|
19293
|
+
}
|
|
19294
|
+
}];
|
|
19295
|
+
};
|
|
19296
|
+
var getSelectWidgetMap = function getSelectWidgetMap(expressDateInstance) {
|
|
19297
|
+
return {
|
|
19298
|
+
expressLogisticsCompany: function expressLogisticsCompany(code) {
|
|
19299
|
+
return expressDateInstance === null || expressDateInstance === void 0 ? void 0 : expressDateInstance.getExpressNameByCode(code);
|
|
19300
|
+
},
|
|
19301
|
+
returnExpressLogisticsCompany: function returnExpressLogisticsCompany(code) {
|
|
19302
|
+
return expressDateInstance === null || expressDateInstance === void 0 ? void 0 : expressDateInstance.getExpressNameByCode(code);
|
|
19303
|
+
},
|
|
19304
|
+
afterSaleType: refundTypeMap,
|
|
19305
|
+
isCNShipment: consignTypeMap,
|
|
19306
|
+
onlineStatus: onlineStatusMap
|
|
19307
|
+
};
|
|
19308
|
+
};
|
|
19309
|
+
var orderSubFormConstants = {
|
|
19310
|
+
getSelectWidgetMap: getSelectWidgetMap,
|
|
19311
|
+
getOrderSubformColumns: getOrderSubformColumns
|
|
19312
|
+
};
|
|
19313
|
+
|
|
19314
|
+
var getSelectWidgetMap$1 = orderSubFormConstants.getSelectWidgetMap;
|
|
19315
|
+
var singletonMap$7 = new Map();
|
|
19316
|
+
var getOrderListSingleton$3 = function getOrderListSingleton(parmas) {
|
|
19317
|
+
var orderNo = parmas.orderNo,
|
|
19318
|
+
shopId = parmas.shopId;
|
|
19319
|
+
var key = "".concat(orderNo, "-").concat(shopId);
|
|
19320
|
+
if (!singletonMap$7.has(key)) {
|
|
19321
|
+
var p = new Promise(function (resolve, reject) {
|
|
19322
|
+
var doReject = function doReject(err) {
|
|
19323
|
+
// 清空掉错误的请求记录
|
|
19324
|
+
singletonMap$7.delete(key);
|
|
19325
|
+
reject(err);
|
|
19326
|
+
};
|
|
19327
|
+
extendRequest('/qy/gdfw/order/subOrderItemsDetail', {
|
|
19328
|
+
method: 'post',
|
|
19329
|
+
data: _objectSpread2({}, parmas)
|
|
19330
|
+
}).then(function (data) {
|
|
19331
|
+
if (data === null || data === void 0 ? void 0 : data.success) {
|
|
19332
|
+
var _data$data;
|
|
19333
|
+
if (data === null || data === void 0 ? void 0 : (_data$data = data.data) === null || _data$data === void 0 ? void 0 : _data$data.length) {
|
|
19334
|
+
resolve(data === null || data === void 0 ? void 0 : data.data);
|
|
19335
|
+
} else {
|
|
19336
|
+
resolve([]);
|
|
19337
|
+
}
|
|
19338
|
+
// 延迟10秒清除,保证订单的时效性
|
|
19339
|
+
setTimeout(function () {
|
|
19340
|
+
singletonMap$7.delete(key);
|
|
19341
|
+
}, 1000 * 10);
|
|
19342
|
+
} else {
|
|
19343
|
+
doReject(data);
|
|
19344
|
+
}
|
|
19345
|
+
}).catch(doReject);
|
|
19346
|
+
});
|
|
19347
|
+
singletonMap$7.set(key, p);
|
|
19348
|
+
}
|
|
19349
|
+
return singletonMap$7.get(key);
|
|
19350
|
+
};
|
|
19351
|
+
var renderEditItem = function renderEditItem(_ref) {
|
|
19352
|
+
var item = _ref.item,
|
|
19353
|
+
val = _ref.val,
|
|
19354
|
+
disabled = _ref.disabled,
|
|
19355
|
+
index = _ref.index,
|
|
19356
|
+
type = _ref.type,
|
|
19357
|
+
updateHandle = _ref.updateHandle;
|
|
19358
|
+
var Component = /*#__PURE__*/React.createElement(React.Fragment, null, "\u4E0D\u652F\u6301\u7684\u7C7B\u578B\u7EC4\u4EF6\uFF1A", JSON.stringify(item.widget));
|
|
19359
|
+
if (typeof item.customizeComponent === 'function') {
|
|
19360
|
+
Component = item.customizeComponent(_objectSpread2(_objectSpread2({}, item.widgetProps), {}, {
|
|
19361
|
+
disabled: disabled,
|
|
19362
|
+
value: val,
|
|
19363
|
+
onChange: function onChange(e) {
|
|
19364
|
+
return updateHandle(e, index, type);
|
|
19365
|
+
}
|
|
19366
|
+
}));
|
|
19367
|
+
} else if (item.widget === 'input') {
|
|
19368
|
+
Component = /*#__PURE__*/React.createElement(Input, _objectSpread2(_objectSpread2({}, item.widgetProps), {}, {
|
|
19369
|
+
disabled: disabled,
|
|
19370
|
+
value: val,
|
|
19371
|
+
onChange: function onChange(e) {
|
|
19372
|
+
var _e$target;
|
|
19373
|
+
return updateHandle(e === null || e === void 0 ? void 0 : (_e$target = e.target) === null || _e$target === void 0 ? void 0 : _e$target.value, index, type);
|
|
19374
|
+
}
|
|
19375
|
+
}));
|
|
19376
|
+
} else if (item.widget === 'select') {
|
|
19377
|
+
Component = /*#__PURE__*/React.createElement(Select, _objectSpread2(_objectSpread2({
|
|
19378
|
+
dropdownStyle: {
|
|
19379
|
+
zIndex: 2000
|
|
19380
|
+
},
|
|
19381
|
+
getPopupContainer: function getPopupContainer() {
|
|
19382
|
+
return document.body;
|
|
19383
|
+
}
|
|
19384
|
+
}, item.widgetProps), {}, {
|
|
19385
|
+
value: val,
|
|
19386
|
+
disabled: disabled,
|
|
19387
|
+
onChange: function onChange(e) {
|
|
19388
|
+
return updateHandle(e, index, type);
|
|
19389
|
+
}
|
|
19390
|
+
}));
|
|
19391
|
+
} else if (item.widget === 'datePicker') {
|
|
19392
|
+
Component = /*#__PURE__*/React.createElement(DatePicker, _objectSpread2(_objectSpread2({
|
|
19393
|
+
popupStyle: {
|
|
19394
|
+
zIndex: 2000
|
|
19395
|
+
},
|
|
19396
|
+
getPopupContainer: function getPopupContainer() {
|
|
19397
|
+
return document.body;
|
|
19398
|
+
}
|
|
19399
|
+
}, item.widgetProps), {}, {
|
|
19400
|
+
value: val ? hooks(val) : null,
|
|
19401
|
+
disabled: disabled,
|
|
19402
|
+
onChange: function onChange(e) {
|
|
19403
|
+
return updateHandle(hooks(e).format('YYYY-MM-DD HH:mm:ss'), index, type);
|
|
19404
|
+
}
|
|
19405
|
+
}));
|
|
19406
|
+
} else if (item.widget === 'inputNumber') {
|
|
19407
|
+
Component = /*#__PURE__*/React.createElement(InputNumber, _objectSpread2(_objectSpread2({
|
|
19408
|
+
style: {
|
|
19409
|
+
width: '100%'
|
|
19410
|
+
}
|
|
19411
|
+
}, item.widgetProps), {}, {
|
|
19412
|
+
value: val,
|
|
19413
|
+
disabled: disabled,
|
|
19414
|
+
onChange: function onChange(e) {
|
|
19415
|
+
return updateHandle(e, index, type);
|
|
19416
|
+
}
|
|
19417
|
+
}));
|
|
19418
|
+
} else if (item.widget === 'cascader') {
|
|
19419
|
+
Component = /*#__PURE__*/React.createElement(Cascader, _objectSpread2(_objectSpread2({
|
|
19420
|
+
getPopupContainer: function getPopupContainer() {
|
|
19421
|
+
return document.body;
|
|
19422
|
+
}
|
|
19423
|
+
}, item.widgetProps), {}, {
|
|
19424
|
+
value: val,
|
|
19425
|
+
disabled: disabled,
|
|
19426
|
+
onChange: function onChange(e) {
|
|
19427
|
+
return updateHandle(e, index, type);
|
|
19428
|
+
}
|
|
19429
|
+
}));
|
|
19430
|
+
}
|
|
19431
|
+
return Component;
|
|
19432
|
+
};
|
|
19433
|
+
var renderDate = function renderDate(value) {
|
|
19434
|
+
return value ? hooks(value).format('YYYY-MM-DD HH:mm:ss') : '';
|
|
19435
|
+
};
|
|
19436
|
+
var renderImages = function renderImages(value) {
|
|
19437
|
+
var list = value ? value.split(',') : [];
|
|
19438
|
+
return /*#__PURE__*/React.createElement(Image.PreviewGroup, null, /*#__PURE__*/React.createElement("div", {
|
|
19439
|
+
style: {
|
|
19440
|
+
display: 'flex',
|
|
19441
|
+
flexWrap: 'wrap'
|
|
19442
|
+
}
|
|
19443
|
+
}, list.map(function (url) {
|
|
19444
|
+
var finalSrc = (url === null || url === void 0 ? void 0 : url.startsWith('http')) ? url : "https://kefu.kuaimai.com/".concat(url);
|
|
19445
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
19446
|
+
style: {
|
|
19447
|
+
padding: '2px'
|
|
19448
|
+
}
|
|
19449
|
+
}, /*#__PURE__*/React.createElement(Image, {
|
|
19450
|
+
src: finalSrc,
|
|
19451
|
+
width: 24,
|
|
19452
|
+
height: 24
|
|
19453
|
+
}));
|
|
19454
|
+
})));
|
|
19455
|
+
};
|
|
19456
|
+
var renderDetailItem = function renderDetailItem(_ref2) {
|
|
19457
|
+
var item = _ref2.item,
|
|
19458
|
+
val = _ref2.val;
|
|
19459
|
+
var expressDateInstance = ExpressData.getInstance();
|
|
19460
|
+
var Component = /*#__PURE__*/React.createElement(React.Fragment, null, "\u4E0D\u652F\u6301\u7684\u7C7B\u578B\u7EC4\u4EF6\uFF1A", JSON.stringify(item.widget));
|
|
19461
|
+
if (['input', 'inputNumber'].includes(item.widget)) {
|
|
19462
|
+
Component = val;
|
|
19463
|
+
} else if (item.widget === 'select') {
|
|
19464
|
+
var _getSelectWidgetMap;
|
|
19465
|
+
var mapValue = (_getSelectWidgetMap = getSelectWidgetMap$1(expressDateInstance)) === null || _getSelectWidgetMap === void 0 ? void 0 : _getSelectWidgetMap[item.dataIndex];
|
|
19466
|
+
var selectValue;
|
|
19467
|
+
if (mapValue && typeof mapValue === 'function') {
|
|
19468
|
+
selectValue = mapValue === null || mapValue === void 0 ? void 0 : mapValue(val);
|
|
19469
|
+
} else {
|
|
19470
|
+
selectValue = mapValue === null || mapValue === void 0 ? void 0 : mapValue[val];
|
|
19471
|
+
}
|
|
19472
|
+
Component = /*#__PURE__*/React.createElement(React.Fragment, null, selectValue);
|
|
19473
|
+
} else if (item.widget === 'datePicker') {
|
|
19474
|
+
Component = /*#__PURE__*/React.createElement(React.Fragment, null, renderDate(val));
|
|
19475
|
+
} else if (item.widget === 'upload') {
|
|
19476
|
+
Component = /*#__PURE__*/React.createElement(React.Fragment, null, renderImages(val));
|
|
19477
|
+
}
|
|
19478
|
+
return Component;
|
|
19479
|
+
};
|
|
19480
|
+
var utils = {
|
|
19481
|
+
getOrderListSingleton: getOrderListSingleton$3,
|
|
19482
|
+
renderEditItem: renderEditItem,
|
|
19483
|
+
renderDetailItem: renderDetailItem
|
|
19484
|
+
};
|
|
19485
|
+
|
|
19486
|
+
var getOrderSubformColumns$1 = orderSubFormConstants.getOrderSubformColumns;
|
|
19487
|
+
var renderEditItem$1 = utils.renderEditItem,
|
|
19488
|
+
renderDetailItem$1 = utils.renderDetailItem,
|
|
19489
|
+
getOrderListSingleton$4 = utils.getOrderListSingleton;
|
|
19490
|
+
var OrderSubForm = function OrderSubForm(props) {
|
|
19491
|
+
var _props$value = props.value,
|
|
19492
|
+
value = _props$value === void 0 ? {} : _props$value,
|
|
19493
|
+
onChange = props.onChange,
|
|
19494
|
+
_props$tableHeader = props.tableHeader,
|
|
19495
|
+
tableHeader = _props$tableHeader === void 0 ? [] : _props$tableHeader,
|
|
19496
|
+
disabled = props.disabled,
|
|
19497
|
+
maxCount = props.maxCount,
|
|
19498
|
+
manual = props.manual,
|
|
19499
|
+
correlationList = props.subConfig.correlationList,
|
|
19500
|
+
effects = props.effects;
|
|
19501
|
+
var valueRef = useRef(value);
|
|
19502
|
+
useEffect(function () {
|
|
19503
|
+
valueRef.current = value;
|
|
19504
|
+
return;
|
|
19505
|
+
}, [value]);
|
|
19506
|
+
var _useState = useState(null),
|
|
19507
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
19508
|
+
hoveredRowIndex = _useState2[0],
|
|
19509
|
+
setHoveredRowIndex = _useState2[1];
|
|
19510
|
+
var updateHandle = useCallback(function (val, index, type) {
|
|
19511
|
+
var _valueRef$current, _valueRef$current$sub;
|
|
19512
|
+
if ((_valueRef$current = valueRef.current) === null || _valueRef$current === void 0 ? void 0 : (_valueRef$current$sub = _valueRef$current.subOrderList) === null || _valueRef$current$sub === void 0 ? void 0 : _valueRef$current$sub.length) {
|
|
19513
|
+
var _valueRef$current2;
|
|
19514
|
+
var subOrderList = JSON.parse(JSON.stringify((_valueRef$current2 = valueRef.current) === null || _valueRef$current2 === void 0 ? void 0 : _valueRef$current2.subOrderList));
|
|
19515
|
+
subOrderList[index][type] = val;
|
|
19516
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, valueRef.current), {}, {
|
|
19517
|
+
subOrderList: subOrderList
|
|
19518
|
+
}));
|
|
19519
|
+
}
|
|
19520
|
+
}, [value === null || value === void 0 ? void 0 : value.subOrderList]);
|
|
19521
|
+
var orderSubformColumns = useMemo(function () {
|
|
19522
|
+
return getOrderSubformColumns$1({
|
|
19523
|
+
expressData: ExpressData.getInstance().getExpressData()
|
|
19524
|
+
});
|
|
19525
|
+
}, [ExpressData]);
|
|
19526
|
+
var orderSubformColumnMap = useMemo(function () {
|
|
19527
|
+
return orderSubformColumns.reduce(function (prv, next) {
|
|
19528
|
+
prv[next.dataIndex] = next;
|
|
19529
|
+
return prv;
|
|
19530
|
+
}, {});
|
|
19531
|
+
}, [orderSubformColumns]);
|
|
19532
|
+
var initColumns = useMemo(function () {
|
|
19533
|
+
return correlationList && (correlationList === null || correlationList === void 0 ? void 0 : correlationList.length) ? correlationList.map(function (t) {
|
|
19534
|
+
return orderSubformColumnMap === null || orderSubformColumnMap === void 0 ? void 0 : orderSubformColumnMap[t === null || t === void 0 ? void 0 : t.dataIndex];
|
|
19535
|
+
}) : orderSubformColumns;
|
|
19536
|
+
}, [correlationList, orderSubformColumns]);
|
|
19537
|
+
var newTableHeader = useMemo(function () {
|
|
19538
|
+
return initColumns.reduce(function (prv, next) {
|
|
19539
|
+
var t = tableHeader.find(function (t) {
|
|
19540
|
+
return t.key === (next === null || next === void 0 ? void 0 : next.dataIndex);
|
|
19541
|
+
}) || {
|
|
19542
|
+
isShow: true,
|
|
19543
|
+
isEdit: false,
|
|
19544
|
+
isRequired: false,
|
|
19545
|
+
width: Number(next === null || next === void 0 ? void 0 : next.width) || 150
|
|
19546
|
+
};
|
|
19547
|
+
if (t && t.isShow) {
|
|
19548
|
+
prv.push(_objectSpread2(_objectSpread2(_objectSpread2({}, next), t), {}, {
|
|
19549
|
+
widgetProps: (next === null || next === void 0 ? void 0 : next.widgetProps) || {}
|
|
19550
|
+
}));
|
|
19551
|
+
}
|
|
19552
|
+
return prv;
|
|
19553
|
+
}, []);
|
|
19554
|
+
}, [orderSubformColumns, tableHeader]);
|
|
19555
|
+
var column = useMemo(function () {
|
|
19556
|
+
return [{
|
|
19557
|
+
dataIndex: 'index',
|
|
19558
|
+
title: '序号',
|
|
19559
|
+
width: 80,
|
|
19560
|
+
render: function render(val, record, index) {
|
|
19561
|
+
return /*#__PURE__*/React.createElement(HoverTableRowDeleteIcon, {
|
|
19562
|
+
index: index,
|
|
19563
|
+
hoveredRowIndex: hoveredRowIndex,
|
|
19564
|
+
handleClick: function handleClick() {
|
|
19565
|
+
return deleteHandle(record.uuid);
|
|
19566
|
+
}
|
|
19567
|
+
});
|
|
19568
|
+
// return <div style={{ width: 25 }}>{index + 1}</div>;
|
|
19569
|
+
}
|
|
19570
|
+
}].concat(_toConsumableArray(newTableHeader.map(function (t) {
|
|
19571
|
+
return _objectSpread2(_objectSpread2({}, t), {}, {
|
|
19572
|
+
dataIndex: t === null || t === void 0 ? void 0 : t.dataIndex,
|
|
19573
|
+
title: /*#__PURE__*/React.createElement("span", null, t.isRequired ? /*#__PURE__*/React.createElement("span", {
|
|
19574
|
+
style: {
|
|
19575
|
+
color: 'red'
|
|
19576
|
+
}
|
|
19577
|
+
}, "*") : null, (t === null || t === void 0 ? void 0 : t.settingName) || t.title),
|
|
19578
|
+
width: Number(t.width),
|
|
19579
|
+
render: function render(val, record, index) {
|
|
19580
|
+
// const column = orderSubformColumnMap[t.dataIndex];
|
|
19581
|
+
var isDisabled = t.isEdit || disabled;
|
|
19582
|
+
return renderEditItem$1({
|
|
19583
|
+
item: t || {},
|
|
19584
|
+
val: val,
|
|
19585
|
+
disabled: isDisabled,
|
|
19586
|
+
index: index,
|
|
19587
|
+
type: t === null || t === void 0 ? void 0 : t.dataIndex,
|
|
19588
|
+
updateHandle: updateHandle
|
|
19589
|
+
});
|
|
19590
|
+
}
|
|
19591
|
+
});
|
|
19592
|
+
})), [disabled ? {} : {
|
|
19593
|
+
dataIndex: 'operation',
|
|
19594
|
+
title: '操作',
|
|
19595
|
+
width: 70,
|
|
19596
|
+
fixed: 'right',
|
|
19597
|
+
render: function render(val, record, index) {
|
|
19598
|
+
return /*#__PURE__*/React.createElement(Space, null, manual && /*#__PURE__*/React.createElement(Tooltip, {
|
|
19599
|
+
title: "\u6DFB\u52A0"
|
|
19600
|
+
}, /*#__PURE__*/React.createElement(PlusCircleFilled, {
|
|
19601
|
+
style: {
|
|
19602
|
+
fontSize: 18,
|
|
19603
|
+
color: '#1890ff'
|
|
19604
|
+
},
|
|
19605
|
+
onClick: function onClick() {
|
|
19606
|
+
return addHandle(index + 1);
|
|
19607
|
+
}
|
|
19608
|
+
})), /*#__PURE__*/React.createElement(Tooltip, {
|
|
19609
|
+
title: "\u5220\u9664"
|
|
19610
|
+
}, /*#__PURE__*/React.createElement(MinusCircleFilled, {
|
|
19611
|
+
style: {
|
|
19612
|
+
fontSize: 18
|
|
19613
|
+
},
|
|
19614
|
+
onClick: function onClick() {
|
|
19615
|
+
return deleteHandle(record.uuid);
|
|
19616
|
+
}
|
|
19617
|
+
})));
|
|
19618
|
+
}
|
|
19619
|
+
}]);
|
|
19620
|
+
}, [newTableHeader, disabled, updateHandle]);
|
|
19621
|
+
var orderModalColumns = useMemo(function () {
|
|
19622
|
+
return [{
|
|
19623
|
+
dataIndex: '',
|
|
19624
|
+
title: '序号',
|
|
19625
|
+
align: 'center',
|
|
19626
|
+
ellipsis: true,
|
|
19627
|
+
width: 80,
|
|
19628
|
+
render: function render(val, record, index) {
|
|
19629
|
+
return /*#__PURE__*/React.createElement("span", null, index + 1);
|
|
19630
|
+
}
|
|
19631
|
+
}].concat(_toConsumableArray(column.filter(function (item) {
|
|
19632
|
+
return !['operation', 'index'].includes((item === null || item === void 0 ? void 0 : item.dataIndex) || '');
|
|
19633
|
+
}).map(function (item) {
|
|
19634
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
19635
|
+
ellipsis: true,
|
|
19636
|
+
render: function render(val, record, index) {
|
|
19637
|
+
return renderDetailItem$1({
|
|
19638
|
+
item: item,
|
|
19639
|
+
val: val
|
|
19640
|
+
});
|
|
19641
|
+
}
|
|
19642
|
+
});
|
|
19643
|
+
})));
|
|
19644
|
+
}, [column]);
|
|
19645
|
+
var defaultValueMap = useMemo(function () {
|
|
19646
|
+
return newTableHeader.reduce(function (prv, next) {
|
|
19647
|
+
prv["".concat(next.dataIndex)] = '';
|
|
19648
|
+
return prv;
|
|
19649
|
+
}, {});
|
|
19650
|
+
}, [newTableHeader]);
|
|
19651
|
+
var deleteHandle = function deleteHandle(uuid) {
|
|
19652
|
+
var _value$subOrderList;
|
|
19653
|
+
var newList = value === null || value === void 0 ? void 0 : (_value$subOrderList = value.subOrderList) === null || _value$subOrderList === void 0 ? void 0 : _value$subOrderList.filter(function (item) {
|
|
19654
|
+
return item.uuid !== uuid;
|
|
19655
|
+
});
|
|
19656
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
19657
|
+
subOrderList: newList
|
|
19658
|
+
}));
|
|
19659
|
+
};
|
|
19660
|
+
var addHandle = function addHandle(index) {
|
|
19661
|
+
var _value$subOrderList2;
|
|
19662
|
+
if (maxCount && (value === null || value === void 0 ? void 0 : (_value$subOrderList2 = value.subOrderList) === null || _value$subOrderList2 === void 0 ? void 0 : _value$subOrderList2.length) >= maxCount) {
|
|
19663
|
+
message.error("\u8BE5\u5B50\u8868\u5355\u6700\u591A\u6DFB\u52A0".concat(maxCount, "\u6761"));
|
|
19664
|
+
return;
|
|
19665
|
+
}
|
|
19666
|
+
var subOrderList = _toConsumableArray((value === null || value === void 0 ? void 0 : value.subOrderList) || []);
|
|
19667
|
+
subOrderList.splice(index, 0, _objectSpread2(_objectSpread2({}, defaultValueMap), {}, {
|
|
19668
|
+
uuid: uuid()
|
|
19669
|
+
}));
|
|
19670
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
19671
|
+
subOrderList: subOrderList
|
|
19672
|
+
}));
|
|
19673
|
+
};
|
|
19674
|
+
var getDataSourceAsync = function getDataSourceAsync() {
|
|
19675
|
+
var _effects$form;
|
|
19676
|
+
var _ref = (effects === null || effects === void 0 ? void 0 : (_effects$form = effects.form) === null || _effects$form === void 0 ? void 0 : _effects$form.getFieldsValue()) || {},
|
|
19677
|
+
_ref$shopId = _ref.shopId,
|
|
19678
|
+
shopId = _ref$shopId === void 0 ? '' : _ref$shopId;
|
|
19679
|
+
return (value === null || value === void 0 ? void 0 : value.orderNo) && shopId ? getOrderListSingleton$4({
|
|
19680
|
+
orderNo: value === null || value === void 0 ? void 0 : value.orderNo,
|
|
19681
|
+
shopId: shopId
|
|
19682
|
+
}).then(function (data) {
|
|
19683
|
+
var allOrders = updateOrderSubFormGoodsHandle(data || []);
|
|
19684
|
+
onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
19685
|
+
allOrders: allOrders
|
|
19686
|
+
}));
|
|
19687
|
+
}) : Promise.resolve();
|
|
19688
|
+
};
|
|
19689
|
+
var getAllTradeGoodsDetails = function getAllTradeGoodsDetails() {
|
|
19690
|
+
var goodDetails = (value === null || value === void 0 ? void 0 : value.allOrders) || [];
|
|
19691
|
+
return goodDetails;
|
|
19692
|
+
};
|
|
19693
|
+
var selectedGoodsChange = useCallback(function (skuList) {
|
|
19694
|
+
var _uniqBy;
|
|
19695
|
+
var newValue = _objectSpread2({}, value);
|
|
19696
|
+
// 原订单商品
|
|
19697
|
+
var originTradeGoodList = getAllTradeGoodsDetails() || [];
|
|
19698
|
+
// 当前选中的所有商品【包含了原订单+商品库】
|
|
19699
|
+
var currentSelectGoodList = (value === null || value === void 0 ? void 0 : value.subOrderList) || [];
|
|
19700
|
+
newValue['subOrderList'] = (_uniqBy = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
|
|
19701
|
+
return skuList.includes(item.uuid);
|
|
19702
|
+
});
|
|
19703
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
19704
|
+
}, [value === null || value === void 0 ? void 0 : value.subOrderList]);
|
|
19705
|
+
// TODO: 商品订单中以选中商品
|
|
19706
|
+
var selectedGoods = useMemo(function () {
|
|
19707
|
+
var _value$subOrderList3;
|
|
19708
|
+
return value === null || value === void 0 ? void 0 : (_value$subOrderList3 = value.subOrderList) === null || _value$subOrderList3 === void 0 ? void 0 : _value$subOrderList3.map(function (v) {
|
|
19709
|
+
return v === null || v === void 0 ? void 0 : v.uuid;
|
|
19710
|
+
});
|
|
19711
|
+
}, [value === null || value === void 0 ? void 0 : value.subOrderList]);
|
|
19712
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, !disabled && /*#__PURE__*/React.createElement("div", {
|
|
19713
|
+
style: {
|
|
19714
|
+
float: 'right'
|
|
19715
|
+
}
|
|
19716
|
+
}, /*#__PURE__*/React.createElement(SelectTradeGoods, {
|
|
19717
|
+
uniqueKey: 'uuid',
|
|
19718
|
+
columns: orderModalColumns,
|
|
19719
|
+
dataSource: getAllTradeGoodsDetails(),
|
|
19720
|
+
getDataSourceAsync: getDataSourceAsync,
|
|
19721
|
+
selectedRowKeys: selectedGoods,
|
|
19722
|
+
onChangeSelectedKeys: selectedGoodsChange,
|
|
19723
|
+
width: 850
|
|
19724
|
+
})), /*#__PURE__*/React.createElement(Table, {
|
|
19725
|
+
columns: column,
|
|
19726
|
+
dataSource: (value === null || value === void 0 ? void 0 : value.subOrderList) || [],
|
|
19727
|
+
rowKey: 'uuid',
|
|
19728
|
+
size: "small",
|
|
19729
|
+
pagination: false,
|
|
19730
|
+
scroll: {
|
|
19731
|
+
x: '100%'
|
|
19732
|
+
},
|
|
19733
|
+
locale: {
|
|
19734
|
+
emptyText: !disabled && manual ? /*#__PURE__*/React.createElement("span", null, "\u6682\u65E0\u6570\u636E,", /*#__PURE__*/React.createElement(Button, {
|
|
19735
|
+
type: "link",
|
|
19736
|
+
onClick: function onClick() {
|
|
19737
|
+
return addHandle(0);
|
|
19738
|
+
}
|
|
19739
|
+
}, "\u70B9\u51FB\u6DFB\u52A0")) : '暂无数据'
|
|
19740
|
+
},
|
|
19741
|
+
onRow: function onRow(_, index) {
|
|
19742
|
+
return {
|
|
19743
|
+
onMouseEnter: function onMouseEnter() {
|
|
19744
|
+
return setHoveredRowIndex(index !== null && index !== void 0 ? index : null);
|
|
19745
|
+
},
|
|
19746
|
+
onMouseLeave: function onMouseLeave() {
|
|
19747
|
+
return setHoveredRowIndex(null);
|
|
19748
|
+
}
|
|
19749
|
+
};
|
|
19750
|
+
}
|
|
19751
|
+
}));
|
|
19752
|
+
};
|
|
19753
|
+
|
|
18937
19754
|
var isErpType$1 = {
|
|
18938
19755
|
isWdt: function isWdt(type) {
|
|
18939
19756
|
return ['WDT_GOODS'].includes(type);
|
|
@@ -20382,8 +21199,8 @@ var PublicReissue = function PublicReissue(props) {
|
|
|
20382
21199
|
})));
|
|
20383
21200
|
};
|
|
20384
21201
|
|
|
20385
|
-
var css_248z$
|
|
20386
|
-
styleInject(css_248z$
|
|
21202
|
+
var css_248z$c = ".goodsBox {\n display: flex;\n flex-wrap: wrap;\n}\n.goods-imgBox {\n position: relative;\n width: 80px;\n height: 80px;\n border: 1px solid #F2F3F5;\n margin: 0 10px 10px 0;\n text-align: center;\n}\n.icon-close {\n position: absolute;\n top: -5px;\n right: -5px;\n width: 13px;\n height: 13px;\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n z-index: 3;\n background-color: #fff;\n cursor: pointer;\n}\n.img {\n width: 100%;\n height: 100%;\n -o-object-fit: contain;\n object-fit: contain;\n}\n.goods-title {\n margin: 0 0 10px 5px;\n color: #4E5969;\n}\n.deg90 {\n transform: rotate(90deg);\n}\n.goodMain {\n display: flex;\n flex-wrap: wrap;\n height: 265px;\n overflow-y: auto;\n margin-bottom: 10px;\n}\n.goodMain .goodItem {\n width: 140px;\n height: 175px;\n padding: 11px 10px 0;\n text-align: center;\n display: inline-block;\n vertical-align: top;\n margin-bottom: 10px;\n margin-right: 30px;\n border: 1px solid #e6e6e6;\n cursor: pointer;\n transition: border 0.3s;\n}\n.goodMain .goodItem .goodImg {\n width: 120px;\n height: 120px;\n}\n.goodMain .goodItem .goodText {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.goodMain .goodItem.active {\n border: 1px solid #3089dc;\n}\n.right-context {\n display: flex;\n flex-direction: column;\n}\n";
|
|
21203
|
+
styleInject(css_248z$c);
|
|
20387
21204
|
|
|
20388
21205
|
var TabPane$1 = Tabs.TabPane;
|
|
20389
21206
|
var Option$2 = Select.Option;
|
|
@@ -20856,7 +21673,7 @@ var Goods$1 = function Goods(props, ref) {
|
|
|
20856
21673
|
userNick: userNick
|
|
20857
21674
|
}));
|
|
20858
21675
|
};
|
|
20859
|
-
var index$
|
|
21676
|
+
var index$3 = /*#__PURE__*/forwardRef(Goods$1);
|
|
20860
21677
|
|
|
20861
21678
|
var _excluded$k = ["onChange", "value", "failValue"];
|
|
20862
21679
|
function CommonStatus(props) {
|
|
@@ -21457,9 +22274,9 @@ var bsE3Reissue = function bsE3Reissue(props) {
|
|
|
21457
22274
|
})));
|
|
21458
22275
|
};
|
|
21459
22276
|
|
|
21460
|
-
var css_248z$
|
|
21461
|
-
var styles$
|
|
21462
|
-
styleInject(css_248z$
|
|
22277
|
+
var css_248z$d = ".index-module_systemNoDisabled__1s7aJ.ant-select-item-option-disabled {\n color: #dadada !important;\n}\n";
|
|
22278
|
+
var styles$6 = {"systemNoDisabled":"index-module_systemNoDisabled__1s7aJ"};
|
|
22279
|
+
styleInject(css_248z$d);
|
|
21463
22280
|
|
|
21464
22281
|
var _excluded$p = ["value", "onChange", "reasonList", "disabled", "type", "isSettingConfig"],
|
|
21465
22282
|
_excluded2 = ["billNo", "billType", "billTag", "tradeTagName", "deliveryState", "vipCode", "shopCode"];
|
|
@@ -21721,7 +22538,7 @@ var GyReissue = function GyReissue(props) {
|
|
|
21721
22538
|
placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
|
|
21722
22539
|
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s9 = value[(_typeMap$type35 = typeMap$4[type]) === null || _typeMap$type35 === void 0 ? void 0 : _typeMap$type35.systemOrder]) === null || _value$typeMap$type$s9 === void 0 ? void 0 : _value$typeMap$type$s9.showOrderInfo) || []).map(function (item) {
|
|
21723
22540
|
return /*#__PURE__*/React.createElement(Select.Option, {
|
|
21724
|
-
className: styles$
|
|
22541
|
+
className: styles$6.systemNoDisabled,
|
|
21725
22542
|
key: item.billNo,
|
|
21726
22543
|
value: item.billNo,
|
|
21727
22544
|
label: item.billNo,
|
|
@@ -22019,7 +22836,7 @@ var GyReturnGoods = function GyReturnGoods(props) {
|
|
|
22019
22836
|
placeholder: "\u9009\u62E9\u9000\u8D27\u7684\u7CFB\u7EDF\u5355"
|
|
22020
22837
|
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s6 = value[(_typeMap$type30 = typeMap$5[type]) === null || _typeMap$type30 === void 0 ? void 0 : _typeMap$type30.systemOrder]) === null || _value$typeMap$type$s6 === void 0 ? void 0 : _value$typeMap$type$s6.showOrderInfo) || []).map(function (item) {
|
|
22021
22838
|
return /*#__PURE__*/React.createElement(Select.Option, {
|
|
22022
|
-
className: styles$
|
|
22839
|
+
className: styles$6.systemNoDisabled,
|
|
22023
22840
|
key: item.billNo,
|
|
22024
22841
|
value: item.billNo,
|
|
22025
22842
|
label: item.billNo,
|
|
@@ -22070,9 +22887,9 @@ var GyReturnGoods = function GyReturnGoods(props) {
|
|
|
22070
22887
|
})));
|
|
22071
22888
|
};
|
|
22072
22889
|
|
|
22073
|
-
var css_248z$
|
|
22074
|
-
var styles$
|
|
22075
|
-
styleInject(css_248z$
|
|
22890
|
+
var css_248z$e = ".index-module_imageBox__1f2AI {\n display: flex;\n flex-wrap: wrap;\n}\n.index-module_imageBox__1f2AI .ant-upload {\n padding: 0;\n height: 80px;\n width: 80px;\n border: none;\n border-radius: 2px;\n background: #F2F3F5;\n text-align: center;\n color: #86909C;\n font-size: 14px;\n}\n.index-module_imageBox__1f2AI .ant-upload .index-module_addBtn__1DY59 {\n color: #86909C;\n font-size: 14px;\n}\n.index-module_imageBox__1f2AI > span {\n max-width: 100%;\n}\n.index-module_tips__1XQjf {\n color: #4E5969;\n font-size: 12px;\n}\n";
|
|
22891
|
+
var styles$7 = {"imageBox":"index-module_imageBox__1f2AI","addBtn":"index-module_addBtn__1DY59","tips":"index-module_tips__1XQjf"};
|
|
22892
|
+
styleInject(css_248z$e);
|
|
22076
22893
|
|
|
22077
22894
|
var _excluded$r = ["maxCount", "maxSize", "onChange", "value", "disabled", "hostUrl", "canDownload", "actionUrl"];
|
|
22078
22895
|
var Dragger$1 = Upload.Dragger;
|
|
@@ -22248,9 +23065,9 @@ var KmVideo = function KmVideo(_ref) {
|
|
|
22248
23065
|
return /*#__PURE__*/React.createElement(Spin, {
|
|
22249
23066
|
spinning: uploading
|
|
22250
23067
|
}, /*#__PURE__*/React.createElement("p", {
|
|
22251
|
-
className: styles$
|
|
23068
|
+
className: styles$7.tips
|
|
22252
23069
|
}, "\u5141\u8BB8\u4E0A\u4F20", maxCount, "\u4E2A\u6587\u4EF6\uFF0C\u652F\u6301", videoSuffixList.join('/'), "\u683C\u5F0F\u6587\u4EF6"), /*#__PURE__*/React.createElement("div", {
|
|
22253
|
-
className: styles$
|
|
23070
|
+
className: styles$7.imageBox
|
|
22254
23071
|
}, /*#__PURE__*/React.createElement(Dragger$1, _objectSpread2({
|
|
22255
23072
|
disabled: disabled,
|
|
22256
23073
|
multiple: true,
|
|
@@ -22276,9 +23093,9 @@ var KmVideo = function KmVideo(_ref) {
|
|
|
22276
23093
|
}), file.kmVideoType && "".concat(file.kmVideoType));
|
|
22277
23094
|
}
|
|
22278
23095
|
}, resetProps), /*#__PURE__*/React.createElement("span", {
|
|
22279
|
-
className: styles$
|
|
23096
|
+
className: styles$7.addBtn
|
|
22280
23097
|
}, "+"), /*#__PURE__*/React.createElement("p", {
|
|
22281
|
-
className: styles$
|
|
23098
|
+
className: styles$7.addBtn
|
|
22282
23099
|
}, "\u9009\u62E9\u6587\u4EF6")), /*#__PURE__*/React.createElement(Modal, {
|
|
22283
23100
|
visible: visible,
|
|
22284
23101
|
title: fileName,
|
|
@@ -22313,15 +23130,15 @@ var KmVideo = function KmVideo(_ref) {
|
|
|
22313
23130
|
}))));
|
|
22314
23131
|
};
|
|
22315
23132
|
|
|
22316
|
-
var singletonMap$
|
|
23133
|
+
var singletonMap$8 = new Map();
|
|
22317
23134
|
var getAllGoods = function getAllGoods(params, setLoading) {
|
|
22318
23135
|
var id = params.tid || params.onBillNo || '';
|
|
22319
|
-
if (!singletonMap$
|
|
23136
|
+
if (!singletonMap$8.has(id)) {
|
|
22320
23137
|
setLoading && setLoading(true);
|
|
22321
23138
|
var p = new Promise(function (resolve, reject) {
|
|
22322
23139
|
var doReject = function doReject(err) {
|
|
22323
23140
|
// 清空掉错误的请求记录
|
|
22324
|
-
singletonMap$
|
|
23141
|
+
singletonMap$8.delete(id);
|
|
22325
23142
|
reject(err);
|
|
22326
23143
|
};
|
|
22327
23144
|
extendRequest('/qy/gdfw/order/skxOrderDetail', {
|
|
@@ -22343,7 +23160,7 @@ var getAllGoods = function getAllGoods(params, setLoading) {
|
|
|
22343
23160
|
resolve(res.data);
|
|
22344
23161
|
// 延迟10秒清除,保证订单的时效性
|
|
22345
23162
|
setTimeout(function () {
|
|
22346
|
-
singletonMap$
|
|
23163
|
+
singletonMap$8.delete(id);
|
|
22347
23164
|
}, 1000 * 10);
|
|
22348
23165
|
} else {
|
|
22349
23166
|
doReject(res);
|
|
@@ -22352,9 +23169,9 @@ var getAllGoods = function getAllGoods(params, setLoading) {
|
|
|
22352
23169
|
setLoading && setLoading(false);
|
|
22353
23170
|
});
|
|
22354
23171
|
});
|
|
22355
|
-
singletonMap$
|
|
23172
|
+
singletonMap$8.set(id, p);
|
|
22356
23173
|
}
|
|
22357
|
-
return singletonMap$
|
|
23174
|
+
return singletonMap$8.get(id);
|
|
22358
23175
|
};
|
|
22359
23176
|
var skxUtils = {
|
|
22360
23177
|
getAllGoods: getAllGoods
|
|
@@ -22670,4 +23487,4 @@ var SkxGoods = function SkxGoods(props) {
|
|
|
22670
23487
|
}));
|
|
22671
23488
|
};
|
|
22672
23489
|
|
|
22673
|
-
export { ApaasAddress as Address, AliPay, Province as ApaasAddress, ApaasCascader, ApaasCheckbox, ApaasDate, withFormItem as ApaasHoc, ApaasInput, ApaasInputNumber, ApaasLogistics, ApaasMultipleSelect, ApaasPosting, ApaasRadio, ApaasRate, ApaasSelect, ApaasSlider, ApaasTextArea, ApaasUpload,
|
|
23490
|
+
export { ApaasAddress as Address, AliPay, Province as ApaasAddress, ApaasCascader, ApaasCheckbox, ApaasDate, withFormItem as ApaasHoc, ApaasInput, ApaasInputNumber, ApaasLogistics, ApaasMultipleSelect, ApaasPosting, ApaasRadio, ApaasRate, ApaasSelect, ApaasSlider, ApaasTextArea, ApaasUpload, ApaasUploadAsync$1 as ApaasUploadAsync, ApaasUploadFile, index as ApaasUploadProAsync, AsyncSelect, bsE3Reissue as BsE3Reissue, BsExchange, BsGoods, BsReissue, BsReturnGoods as BsReturn, index$2 as BsSystemOrder, BuyerNick, CalculationInput, ChooseBaby, CommonExchangeGoods, CommonGoods, CommonSystemOrder$1 as CommonMultiStatus, CommonReturnGoods, CommonStatus, CommonSystemOrder, CopyTextIcon, ExpressLogistics, Goods, index$3 as GoodsTable, GyReissue, GyReturnGoods as GyReturn, IdentifyAddress, Invoice, jstGoods as JstGoods, ItemList as JstItemList, KmVideo, LogisticsInterception, LogisticsMoreInterception, LogisticsMoreTrajectory, LogisticsTrajectory, MsgStatus, OrderSubForm, utils as OrderSubFormUtils, ParseLogistics, Payment, PublicReissue, RemarkInput as Remark, ExpressLogistics as ReturnLogistics, ShopNameSelect as ShopName, SkxGoods, IdInputSelect as SkxIdInputSelect, Status, SubForm, Supplier, TBGoodId, TBGoodSerial, TradeId, WdtGoodList, wdtReissue as WdtReissue, WlnGoods, columnsBaseInfoMap, erpColumnsMap, erpFormValidator, index$1 as erpModalColumnsMap, getColumns$4 as getGyColumns, getColumns$5 as getJstColumns, getColumns$6 as getKmColumns, getColumns$7 as getSkxColumns, getColumns$2 as getWdtColumns, getColumns$3 as getWlnColumns, orderSubFormConstants, skxUtils };
|