@kmkf-fe-packages/basic-components 2.0.0-rc.1 → 2.0.0-rc.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/dist/index.esm.js CHANGED
@@ -3,8 +3,8 @@ import { Cascader, DatePicker, InputNumber, Input, Select, Upload, Image, messag
3
3
  import { EyeOutlined, DeleteOutlined, CloseCircleOutlined, CaretUpOutlined } 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, request as request$1, ExpressData, uuid, LogisticsAddressData, WdtSendData, filterWdtOrders, WDT_ORDER_TYPE_MAP, filterBsE3Orders, BS_E3_ORDER_STATUS_MAP, BS_E3_BOOLEAN_STATUS_MAP, updateWdtGoodsHandle, updateBsE3GoodsHandle } from '@kmkf-fe-packages/kmkf-utils';
7
- import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, cloneDeep, difference, differenceWith, takeRight, reject } from 'lodash';
6
+ import { AddressData, BsAddressData, WdtAddressData, request as request$1, ExpressData, uuid, LogisticsAddressData, SendDataCenter, BS_E3_BOOLEAN_STATUS_MAP, filterWdtOrders, WDT_ORDER_TYPE_MAP, filterBsE3Orders, filterKmOrders, KM_SYSTEM_ORDER_CONFIG, BS_E3_ORDER_STATUS_MAP, updateWdtGoodsHandle, updateBsE3GoodsHandle } from '@kmkf-fe-packages/kmkf-utils';
7
+ import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, cloneDeep, difference, differenceWith, takeRight, reject, isEmpty, intersection, uniqBy } 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';
@@ -921,11 +921,12 @@ var css_248z$1 = ".index-module_imageBox__8zj7A {\n display: flex;\n flex-wrap
921
921
  var styles$1 = {"imageBox":"index-module_imageBox__8zj7A","inputImage":"index-module_inputImage__3VrvC","imageShow":"index-module_imageShow__3wD4d","imageWrap":"index-module_imageWrap__JkMJo","-webkit-mask":"index-module_mask__3LUIn","mask":"index-module_mask__3LUIn","deleteIcon":"index-module_deleteIcon__20Wzd","actions":"index-module_actions__2tY_V","icon":"index-module_icon__ZI-2P","imagePaste":"index-module_imagePaste__2X-K1","fakeBox":"index-module_fakeBox__2_3rA","addBtn":"index-module_addBtn__2m5lC","upload":"index-module_upload__2igU3","tips":"index-module_tips__1ATcr"};
922
922
  styleInject(css_248z$1);
923
923
 
924
- var _excluded$6 = ["maxCount", "maxSize", "uploadText", "onChange", "value", "accept", "canPreview", "disabled", "uniqueKey", "hostUrl", "actionUrl"];
924
+ var _excluded$6 = ["maxCount", "maxSize", "uploadText", "onChange", "value", "accept", "canPreview", "disabled", "uniqueKey", "hostUrl", "actionUrl", "platform"];
925
925
  var fn$1 = function fn() {
926
926
  return void 0;
927
927
  };
928
928
  var ApaasUploadAsync = function ApaasUploadAsync(_ref, ref) {
929
+ var _document;
929
930
  var _ref$maxCount = _ref.maxCount,
930
931
  maxCount = _ref$maxCount === void 0 ? 10 : _ref$maxCount,
931
932
  _ref$maxSize = _ref.maxSize,
@@ -946,6 +947,8 @@ var ApaasUploadAsync = function ApaasUploadAsync(_ref, ref) {
946
947
  hostUrl = _ref$hostUrl === void 0 ? '' : _ref$hostUrl,
947
948
  _ref$actionUrl = _ref.actionUrl,
948
949
  actionUrl = _ref$actionUrl === void 0 ? '/qy/common/uploadWorkOrderImg' : _ref$actionUrl,
950
+ _ref$platform = _ref.platform,
951
+ platform = _ref$platform === void 0 ? '' : _ref$platform,
949
952
  resetProps = _objectWithoutProperties(_ref, _excluded$6);
950
953
  var inputRef = useRef(null);
951
954
  var valueRef = useRef(value);
@@ -953,18 +956,13 @@ var ApaasUploadAsync = function ApaasUploadAsync(_ref, ref) {
953
956
  _useState2 = _slicedToArray(_useState, 2),
954
957
  uploading = _useState2[0],
955
958
  setUploading = _useState2[1];
956
- var _useState3 = useState(false),
959
+ var _useState3 = useState(true),
957
960
  _useState4 = _slicedToArray(_useState3, 2),
958
- visible = _useState4[0],
959
- setVisible = _useState4[1];
960
- var _useState5 = useState(''),
961
- _useState6 = _slicedToArray(_useState5, 2),
962
- currentPreviewImg = _useState6[0],
963
- setCurrentPreviewImg = _useState6[1];
964
- var _useState7 = useState(true),
965
- _useState8 = _slicedToArray(_useState7, 2),
966
- pasteDefaultStates = _useState8[0],
967
- setPasteDefaultStates = _useState8[1];
961
+ pasteDefaultStates = _useState4[0],
962
+ setPasteDefaultStates = _useState4[1];
963
+ var preview = platform === 'ks' ? {
964
+ getContainer: (_document = document) === null || _document === void 0 ? void 0 : _document.getElementById('root')
965
+ } : true;
968
966
  useEffect(function () {
969
967
  valueRef.current = value;
970
968
  }, [value]);
@@ -1096,7 +1094,9 @@ var ApaasUploadAsync = function ApaasUploadAsync(_ref, ref) {
1096
1094
  };
1097
1095
  };
1098
1096
  var renderImages = function renderImages(images) {
1099
- return /*#__PURE__*/React.createElement(Image.PreviewGroup, null, images.map(function (image, index) {
1097
+ return /*#__PURE__*/React.createElement(Image.PreviewGroup, {
1098
+ preview: preview
1099
+ }, images.map(function (image, index) {
1100
1100
  var finalImage = "".concat(/^pic\/[\s\S]*$/.test(image) ? "".concat(hostUrl, "/").concat(image) : image, "?x-oss-process=image/resize,h_60,w_60");
1101
1101
  var showImage = /^pic\/[\s\S]*$/.test(image) ? "".concat(hostUrl, "/").concat(image) : image;
1102
1102
  return /*#__PURE__*/React.createElement("div", {
@@ -1172,21 +1172,7 @@ var ApaasUploadAsync = function ApaasUploadAsync(_ref, ref) {
1172
1172
  beforeUpload: beforeUpload
1173
1173
  }, resetProps), value.length >= maxCount ? null : /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("span", {
1174
1174
  className: "addBtn"
1175
- }, "+"), /*#__PURE__*/React.createElement("div", null, uploadText))), /*#__PURE__*/React.createElement(Image, {
1176
- width: 0,
1177
- style: {
1178
- display: visible ? '' : 'none'
1179
- },
1180
- src: currentPreviewImg,
1181
- preview: {
1182
- visible: visible,
1183
- src: "".concat(currentPreviewImg),
1184
- onVisibleChange: function onVisibleChange(value) {
1185
- setCurrentPreviewImg('');
1186
- setVisible(value);
1187
- }
1188
- }
1189
- })));
1175
+ }, "+"), /*#__PURE__*/React.createElement("div", null, uploadText)))));
1190
1176
  };
1191
1177
  var index = /*#__PURE__*/forwardRef(ApaasUploadAsync);
1192
1178
 
@@ -10969,13 +10955,19 @@ var jstGoods = function jstGoods(props) {
10969
10955
  _useState2 = _slicedToArray(_useState, 2),
10970
10956
  changeIndex = _useState2[0],
10971
10957
  setChangeIndex = _useState2[1]; //选中的包裹
10972
- var wdtSendOptions = WdtSendData.getInstance().wdtSendData || [];
10958
+ var sendOptions = SendDataCenter.getInstance(platformType).getSendData();
10959
+ var isSelectName = ['wdt', 'bsE3', 'km'].includes(platformType);
10973
10960
  useEffect(function () {
10974
10961
  //没有值塞个默认值
10975
10962
  if (!(value === null || value === void 0 ? void 0 : value.length) && type !== 1) {
10976
10963
  onChange === null || onChange === void 0 ? void 0 : onChange(typeInitValueMap[type]);
10977
10964
  }
10978
10965
  }, [value, type]);
10966
+ useEffect(function () {
10967
+ if (changeIndex > (value === null || value === void 0 ? void 0 : value.length) - 1) {
10968
+ setChangeIndex(0);
10969
+ }
10970
+ }, value);
10979
10971
  var content = function content(item, index) {
10980
10972
  return /*#__PURE__*/React.createElement("div", {
10981
10973
  style: {
@@ -10986,7 +10978,7 @@ var jstGoods = function jstGoods(props) {
10986
10978
  style: {
10987
10979
  textAlign: 'center'
10988
10980
  }
10989
- }, "\u5305\u88F9".concat(index + 1, "\u5546\u54C1\u4FE1\u606F")), ((item === null || item === void 0 ? void 0 : item.items) || []).map(function (t, index) {
10981
+ }, "\u5305\u88F9".concat(index + 1, "\u5546\u54C1\u4FE1\u606F"), item.sid && /*#__PURE__*/React.createElement("span", null, "(\u7CFB\u7EDF\u5355\u53F7:", item.sid, ")")), ((item === null || item === void 0 ? void 0 : item.items) || []).map(function (t, index) {
10990
10982
  return /*#__PURE__*/React.createElement("div", {
10991
10983
  key: index
10992
10984
  }, /*#__PURE__*/React.createElement(Space, null, /*#__PURE__*/React.createElement(Image, {
@@ -11000,7 +10992,7 @@ var jstGoods = function jstGoods(props) {
11000
10992
  var changeOrderInfo = _objectSpread2({}, value[changeIndex]);
11001
10993
  changeOrderInfo[type] = val;
11002
10994
  changeOrderInfo['sendId'] = option.value;
11003
- if (platformType === 'wdt' && type === 'sendName') {
10995
+ if (isSelectName && type === 'sendName') {
11004
10996
  changeOrderInfo['sendSnapshotName'] = option.label;
11005
10997
  }
11006
10998
  var newList = _toConsumableArray(value);
@@ -11083,7 +11075,7 @@ var jstGoods = function jstGoods(props) {
11083
11075
  return changeInputHandle(e.target.value, 'sendId');
11084
11076
  },
11085
11077
  value: (_value$changeIndex5 = value[changeIndex]) === null || _value$changeIndex5 === void 0 ? void 0 : _value$changeIndex5.sendId
11086
- }), ['sendName', 'all'].includes(showField) && (platformType === 'wdt' ? /*#__PURE__*/React.createElement(Select, {
11078
+ }), ['sendName', 'all'].includes(showField) && (isSelectName ? /*#__PURE__*/React.createElement(Select, {
11087
11079
  style: {
11088
11080
  minWidth: '100px',
11089
11081
  maxWidth: '180px'
@@ -11091,7 +11083,7 @@ var jstGoods = function jstGoods(props) {
11091
11083
  disabled: disabled,
11092
11084
  placeholder: "\u53D1\u8D27\u4ED3\u540D\u79F0",
11093
11085
  showSearch: true,
11094
- options: wdtSendOptions,
11086
+ options: sendOptions,
11095
11087
  filterOption: filterOption,
11096
11088
  value: ((_value$changeIndex6 = value[changeIndex]) === null || _value$changeIndex6 === void 0 ? void 0 : _value$changeIndex6.sendName) || null,
11097
11089
  onChange: function onChange(value, option) {
@@ -12083,9 +12075,9 @@ var getTableData$1 = function getTableData(_ref, formData) {
12083
12075
  var current = _ref.current,
12084
12076
  pageSize = _ref.pageSize;
12085
12077
  var data = {
12086
- goodsSn: formData.goodsSn || null,
12087
- goodsName: formData.goodsName || null,
12088
- sku: formData.sku || null,
12078
+ goodNo: formData.goodNo || null,
12079
+ goodName: formData.goodName || null,
12080
+ skuCode: formData.skuCode || null,
12089
12081
  skuId: formData.skuId || null
12090
12082
  };
12091
12083
  return extendRequest('/qy/gdfw/product/product/page', {
@@ -12093,7 +12085,7 @@ var getTableData$1 = function getTableData(_ref, formData) {
12093
12085
  data: _objectSpread2({
12094
12086
  pageSize: pageSize,
12095
12087
  pageNo: current,
12096
- platform: 'WDT_ERP'
12088
+ platform: 'BS_E3_ERP'
12097
12089
  }, data)
12098
12090
  }).then(function (res) {
12099
12091
  var _res$data = res.data,
@@ -12122,127 +12114,91 @@ var columns$2 = [{
12122
12114
  }
12123
12115
  }, index + 1);
12124
12116
  },
12125
- width: 100
12117
+ width: 80
12126
12118
  }, {
12127
- dataIndex: 'sku',
12119
+ dataIndex: 'specNo',
12128
12120
  title: "SKU",
12129
12121
  ellipsis: true,
12130
- width: 70
12122
+ width: 200
12131
12123
  }, {
12132
- dataIndex: 'skuId',
12124
+ dataIndex: 'specId',
12133
12125
  title: "SKU ID",
12134
12126
  ellipsis: true,
12135
- width: 70
12127
+ width: 80
12136
12128
  }, {
12137
- dataIndex: 'goodsName',
12129
+ dataIndex: 'goodName',
12138
12130
  title: "\u5546\u54C1\u540D\u79F0",
12139
12131
  ellipsis: true,
12140
- width: 70
12132
+ width: 250
12141
12133
  }, {
12142
- dataIndex: 'goodsShortName',
12134
+ dataIndex: 'goodShortName',
12143
12135
  title: "\u5546\u54C1\u7B80\u79F0",
12144
12136
  ellipsis: true,
12145
- width: 70
12146
- }, {
12147
- dataIndex: 'picPath',
12148
- title: "\u5546\u54C1\u56FE\u7247",
12149
- ellipsis: true,
12150
- width: 100,
12151
- render: function render(picUrl) {
12152
- return /*#__PURE__*/React.createElement("img", {
12153
- style: {
12154
- width: '60px',
12155
- height: '60px',
12156
- objectFit: 'contain'
12157
- },
12158
- src: picUrl
12159
- });
12160
- }
12161
- }, {
12162
- dataIndex: 'goodsSn',
12137
+ width: 250
12138
+ },
12139
+ // {
12140
+ // dataIndex: 'goodPicUrl',
12141
+ // title: `商品图片`,
12142
+ // ellipsis: true,
12143
+ // width: 100,
12144
+ // render: (picUrl: string) => {
12145
+ // return (
12146
+ // <img
12147
+ // style={{
12148
+ // width: '40px',
12149
+ // height: '40px',
12150
+ // objectFit: 'contain',
12151
+ // }}
12152
+ // src={picUrl}
12153
+ // ></img>
12154
+ // );
12155
+ // },
12156
+ // },
12157
+ {
12158
+ dataIndex: 'goodNo',
12163
12159
  title: "\u8D27\u53F7",
12164
12160
  ellipsis: true,
12165
- width: 70
12161
+ width: 150
12166
12162
  }, {
12167
- dataIndex: 'goodsId',
12163
+ dataIndex: 'goodId',
12168
12164
  title: "\u8D27\u53F7ID",
12169
12165
  ellipsis: true,
12170
- width: 70
12166
+ width: 100
12171
12167
  }, {
12172
12168
  dataIndex: 'colorName',
12173
12169
  title: "\u989C\u8272\u540D\u79F0",
12174
12170
  ellipsis: true,
12175
- width: 70
12171
+ width: 100
12176
12172
  }, {
12177
12173
  dataIndex: 'colorCode',
12178
12174
  title: "\u989C\u8272\u4EE3\u7801",
12179
12175
  ellipsis: true,
12180
- width: 70
12176
+ width: 100
12181
12177
  }, {
12182
12178
  dataIndex: 'sizeName',
12183
12179
  title: "\u5C3A\u7801\u540D\u79F0",
12184
12180
  ellipsis: true,
12185
- width: 70
12181
+ width: 100
12186
12182
  }, {
12187
12183
  dataIndex: 'sizeCode',
12188
12184
  title: "\u5C3A\u7801\u4EE3\u7801",
12189
12185
  ellipsis: true,
12190
- width: 70
12186
+ width: 100
12191
12187
  }, {
12192
12188
  dataIndex: 'brandName',
12193
12189
  title: "\u54C1\u724C\u540D\u79F0",
12194
12190
  ellipsis: true,
12195
- width: 70
12196
- }, {
12197
- dataIndex: 'goodsNumber',
12198
- title: "\u5546\u54C1\u6570\u91CF",
12199
- ellipsis: true,
12200
- width: 70
12201
- }, {
12202
- dataIndex: 'goodsPrice',
12203
- title: "\u5546\u54C1\u5355\u4EF7",
12204
- ellipsis: true,
12205
- width: 70
12206
- }, {
12207
- dataIndex: 'shopPrice',
12208
- title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
12209
- ellipsis: true,
12210
- width: 70
12211
- }, {
12212
- dataIndex: 'sharePrice',
12213
- title: "\u5206\u644A\u4EF7",
12214
- ellipsis: true,
12215
- width: 70
12216
- }, {
12217
- dataIndex: 'sharePayment',
12218
- title: "\u5206\u644A\u5B9E\u4ED8\u91D1\u989D",
12219
- ellipsis: true,
12220
- width: 70
12221
- }, {
12222
- dataIndex: 'payment',
12223
- title: "\u5B9E\u4ED8\u91D1\u989D",
12224
- ellipsis: true,
12225
- width: 70
12226
- }, {
12227
- dataIndex: 'tcSku',
12228
- title: "\u5957\u9910SKU",
12229
- ellipsis: true,
12230
- width: 70
12231
- }, {
12232
- dataIndex: 'tcGoodsNumber',
12233
- title: "\u5957\u9910\u5957\u6570",
12234
- ellipsis: true,
12235
- width: 70
12191
+ width: 100
12236
12192
  }, {
12237
- dataIndex: 'taoCanSingleSl',
12238
- title: "\u5355\u4E2A\u5957\u9910\u6570\u91CF",
12193
+ dataIndex: 'marketPrice',
12194
+ title: "\u5E02\u573A\u4EF7",
12239
12195
  ellipsis: true,
12240
- width: 70
12196
+ width: 100
12241
12197
  }, {
12242
- dataIndex: 'isGift',
12243
- title: "\u662F\u5426\u8D60\u54C1",
12198
+ dataIndex: 'retailPrice',
12199
+ title: "\u552E\u4EF7",
12244
12200
  ellipsis: true,
12245
- width: 70
12201
+ width: 100
12246
12202
  }];
12247
12203
  var GoodList$1 = function GoodList(props, ref) {
12248
12204
  var _useState = useState([]),
@@ -12276,7 +12232,7 @@ var GoodList$1 = function GoodList(props, ref) {
12276
12232
  layout: "inline",
12277
12233
  form: form
12278
12234
  }, /*#__PURE__*/React.createElement(Form.Item, {
12279
- name: "goodsSn",
12235
+ name: "goodNo",
12280
12236
  style: {
12281
12237
  marginBottom: '12px'
12282
12238
  }
@@ -12287,7 +12243,7 @@ var GoodList$1 = function GoodList(props, ref) {
12287
12243
  width: 150
12288
12244
  }
12289
12245
  })), /*#__PURE__*/React.createElement(Form.Item, {
12290
- name: "goodsName",
12246
+ name: "goodName",
12291
12247
  style: {
12292
12248
  marginBottom: '12px'
12293
12249
  }
@@ -12298,7 +12254,7 @@ var GoodList$1 = function GoodList(props, ref) {
12298
12254
  width: 150
12299
12255
  }
12300
12256
  })), /*#__PURE__*/React.createElement(Form.Item, {
12301
- name: "sku",
12257
+ name: "skuCode",
12302
12258
  style: {
12303
12259
  marginBottom: '12px'
12304
12260
  }
@@ -12415,7 +12371,7 @@ var GoodList$1 = function GoodList(props, ref) {
12415
12371
  }
12416
12372
  }, /*#__PURE__*/React.createElement(Table, _objectSpread2({
12417
12373
  rowSelection: rowSelection,
12418
- rowKey: "goodsId",
12374
+ rowKey: "specNo",
12419
12375
  columns: columns$2,
12420
12376
  scroll: {
12421
12377
  x: '100%',
@@ -12475,15 +12431,314 @@ var GoodsModal$4 = function GoodsModal(props, ref) {
12475
12431
  };
12476
12432
  var BsE3GoodsModal = /*#__PURE__*/forwardRef(GoodsModal$4);
12477
12433
 
12478
- // interface GoodsItem {
12479
- // title: string;
12480
- // pic: string;
12481
- // platform: string;
12482
- // skuId: string;
12483
- // styleId: string;
12484
- // }
12434
+ var columns$3 = [{
12435
+ dataIndex: 'sku',
12436
+ title: "SKU",
12437
+ width: 150
12438
+ }, {
12439
+ dataIndex: 'skuId',
12440
+ title: "SKU ID",
12441
+ width: 150
12442
+ }, {
12443
+ dataIndex: 'goodsName',
12444
+ title: "\u5546\u54C1\u540D\u79F0",
12445
+ width: 150
12446
+ }, {
12447
+ dataIndex: 'goodsShortName',
12448
+ title: "\u5546\u54C1\u7B80\u79F0",
12449
+ width: 150
12450
+ }, {
12451
+ dataIndex: 'picPath',
12452
+ title: "\u5546\u54C1\u56FE\u7247",
12453
+ width: 150
12454
+ }, {
12455
+ dataIndex: 'goodsSn',
12456
+ title: "\u8D27\u53F7",
12457
+ width: 150
12458
+ }, {
12459
+ dataIndex: 'goodsId',
12460
+ title: "\u8D27\u53F7ID",
12461
+ width: 150
12462
+ }, {
12463
+ dataIndex: 'colorName',
12464
+ title: "\u989C\u8272\u540D\u79F0",
12465
+ width: 150
12466
+ }, {
12467
+ dataIndex: 'colorCode',
12468
+ title: "\u989C\u8272\u4EE3\u7801",
12469
+ width: 150
12470
+ }, {
12471
+ dataIndex: 'sizeName',
12472
+ title: "\u5C3A\u7801\u540D\u79F0",
12473
+ width: 150
12474
+ }, {
12475
+ dataIndex: 'sizeCode',
12476
+ title: "\u5C3A\u7801\u4EE3\u7801",
12477
+ width: 150
12478
+ }, {
12479
+ dataIndex: 'brandName',
12480
+ title: "\u54C1\u724C\u540D\u79F0",
12481
+ width: 150
12482
+ }, {
12483
+ dataIndex: 'goodsNumber',
12484
+ title: "\u5546\u54C1\u6570\u91CF",
12485
+ width: 150
12486
+ }, {
12487
+ dataIndex: 'goodsPrice',
12488
+ title: "\u5546\u54C1\u5355\u4EF7",
12489
+ width: 150
12490
+ }, {
12491
+ dataIndex: 'shopPrice',
12492
+ title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
12493
+ width: 150
12494
+ }, {
12495
+ dataIndex: 'isGift',
12496
+ title: "\u662F\u5426\u8D60\u54C1",
12497
+ width: 150,
12498
+ render: function render(val) {
12499
+ return /*#__PURE__*/React.createElement("span", null, +val ? '是' : '否');
12500
+ }
12501
+ }];
12502
+ var renderFieldMap = {
12503
+ goodsNumber: function goodsNumber(_ref) {
12504
+ var disabled = _ref.disabled,
12505
+ updateHandle = _ref.updateHandle;
12506
+ return function (val, record, index) {
12507
+ return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
12508
+ style: {
12509
+ width: 70
12510
+ },
12511
+ value: val,
12512
+ min: 1,
12513
+ precision: 0,
12514
+ onChange: function onChange(num) {
12515
+ return updateHandle(num, index, 'goodsNumber');
12516
+ }
12517
+ }) : /*#__PURE__*/React.createElement("span", null, val);
12518
+ };
12519
+ },
12520
+ goodsPrice: function goodsPrice(_ref2) {
12521
+ var disabled = _ref2.disabled,
12522
+ updateHandle = _ref2.updateHandle;
12523
+ return function (val, record, index) {
12524
+ return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
12525
+ style: {
12526
+ width: 70
12527
+ },
12528
+ value: val,
12529
+ min: 0,
12530
+ onChange: function onChange(value) {
12531
+ return updateHandle(value, index, 'goodsPrice');
12532
+ }
12533
+ }) : /*#__PURE__*/React.createElement("span", null, val);
12534
+ };
12535
+ },
12536
+ isGift: function isGift(_ref3) {
12537
+ var disabled = _ref3.disabled,
12538
+ updateHandle = _ref3.updateHandle;
12539
+ return function (val, record, index) {
12540
+ var options = [{
12541
+ label: '是',
12542
+ value: 1
12543
+ }, {
12544
+ label: '否',
12545
+ value: 0
12546
+ }];
12547
+ return !disabled ? /*#__PURE__*/React.createElement(Select, {
12548
+ style: {
12549
+ width: 70
12550
+ },
12551
+ options: options,
12552
+ value: val,
12553
+ onChange: function onChange(value) {
12554
+ return updateHandle(value, index, 'isGift');
12555
+ },
12556
+ getPopupContainer: function getPopupContainer() {
12557
+ return document.getElementById('bsE3ReissueGoods');
12558
+ }
12559
+ }) : /*#__PURE__*/React.createElement("span", null, +val ? '是' : '否');
12560
+ };
12561
+ }
12562
+ };
12563
+ var getBsE3ReissueGoodColumns = function getBsE3ReissueGoodColumns(_ref4) {
12564
+ var disabled = _ref4.disabled,
12565
+ updateHandle = _ref4.updateHandle,
12566
+ operate = _ref4.operate;
12567
+ return columns$3.map(function (item) {
12568
+ var newItem = _objectSpread2({
12569
+ align: 'center',
12570
+ ellipsis: true
12571
+ }, item);
12572
+ if (operate && (renderFieldMap === null || renderFieldMap === void 0 ? void 0 : renderFieldMap[item.dataIndex])) {
12573
+ return _objectSpread2(_objectSpread2({}, newItem), {}, {
12574
+ render: renderFieldMap === null || renderFieldMap === void 0 ? void 0 : renderFieldMap[item.dataIndex]({
12575
+ disabled: disabled,
12576
+ updateHandle: updateHandle
12577
+ })
12578
+ });
12579
+ }
12580
+ return newItem;
12581
+ });
12582
+ };
12583
+
12584
+ var renderGiftType = function renderGiftType(val) {
12585
+ var giftTypeMap = {
12586
+ 0: '非赠品',
12587
+ 1: '自动赠送',
12588
+ 2: '手工赠送',
12589
+ 3: '回购自动送赠品',
12590
+ 4: '前N有礼送赠品',
12591
+ 6: '天猫优仓赠品',
12592
+ 7: '淘宝CRM会员送赠'
12593
+ };
12594
+ return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
12595
+ };
12596
+ var columns$4 = [{
12597
+ dataIndex: 'goodId',
12598
+ title: "\u5546\u54C1ID",
12599
+ width: 120
12600
+ }, {
12601
+ dataIndex: 'goodNo',
12602
+ title: "\u5546\u54C1\u7F16\u7801",
12603
+ width: 200
12604
+ }, {
12605
+ dataIndex: 'goodName',
12606
+ title: "\u5546\u54C1\u540D\u79F0",
12607
+ width: 200
12608
+ }, {
12609
+ dataIndex: 'specId',
12610
+ title: "SKUID",
12611
+ width: 150
12612
+ }, {
12613
+ dataIndex: 'specNo',
12614
+ title: "\u5546\u54C1SKU\u7F16\u7801",
12615
+ width: 200
12616
+ }, {
12617
+ dataIndex: 'specName',
12618
+ title: "\u5546\u54C1SKU\u540D\u79F0",
12619
+ width: 250
12620
+ }, {
12621
+ dataIndex: 'orderPrice',
12622
+ title: "\u5B9E\u4ED8\u603B\u91D1\u989D",
12623
+ width: 200
12624
+ }, {
12625
+ dataIndex: 'num',
12626
+ title: "\u6570\u91CF",
12627
+ width: 100
12628
+ }, {
12629
+ dataIndex: 'sharePrice',
12630
+ title: "\u5206\u644A\u4EF7",
12631
+ width: 150
12632
+ }, {
12633
+ dataIndex: 'giftType',
12634
+ title: "\u8D60\u54C1\u65B9\u5F0F",
12635
+ width: 100,
12636
+ render: renderGiftType
12637
+ }];
12638
+ var renderFieldMap$1 = {
12639
+ num: function num(_ref) {
12640
+ var disabled = _ref.disabled,
12641
+ updateHandle = _ref.updateHandle;
12642
+ return function (val, record, index) {
12643
+ return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
12644
+ style: {
12645
+ width: 70
12646
+ },
12647
+ value: val,
12648
+ min: 1,
12649
+ precision: 0,
12650
+ onChange: function onChange(num) {
12651
+ return updateHandle(num, index, 'num');
12652
+ }
12653
+ }) : /*#__PURE__*/React.createElement("span", null, val);
12654
+ };
12655
+ },
12656
+ giftType: function giftType() {
12657
+ return renderGiftType;
12658
+ }
12659
+ };
12660
+ var getWdtReissueGoodColumns = function getWdtReissueGoodColumns(_ref2) {
12661
+ var disabled = _ref2.disabled,
12662
+ updateHandle = _ref2.updateHandle,
12663
+ operate = _ref2.operate;
12664
+ return columns$4.map(function (item) {
12665
+ var newItem = _objectSpread2({
12666
+ align: 'center',
12667
+ ellipsis: true
12668
+ }, item);
12669
+ if (operate && (renderFieldMap$1 === null || renderFieldMap$1 === void 0 ? void 0 : renderFieldMap$1[item.dataIndex])) {
12670
+ return _objectSpread2(_objectSpread2({}, newItem), {}, {
12671
+ render: renderFieldMap$1 === null || renderFieldMap$1 === void 0 ? void 0 : renderFieldMap$1[item.dataIndex]({
12672
+ disabled: disabled,
12673
+ updateHandle: updateHandle
12674
+ })
12675
+ });
12676
+ }
12677
+ return newItem;
12678
+ });
12679
+ };
12680
+
12681
+ var MAIN_FIELD = 'uuid';
12682
+ var SelectTradeGoods = function SelectTradeGoods(_ref) {
12683
+ var columns = _ref.columns,
12684
+ dataSource = _ref.dataSource,
12685
+ selectedRowKeys = _ref.selectedRowKeys,
12686
+ onChangeSelectedKeys = _ref.onChangeSelectedKeys;
12687
+ var _useState = useState(false),
12688
+ _useState2 = _slicedToArray(_useState, 2),
12689
+ tradeGoodsVisible = _useState2[0],
12690
+ setTradeGoodsVisible = _useState2[1];
12691
+ var openModal = function openModal() {
12692
+ return setTradeGoodsVisible(true);
12693
+ };
12694
+ var closeModal = function closeModal() {
12695
+ return setTradeGoodsVisible(false);
12696
+ };
12697
+ var currentTradeOriginGoods = intersection(dataSource === null || dataSource === void 0 ? void 0 : dataSource.map(function (item) {
12698
+ return item === null || item === void 0 ? void 0 : item[MAIN_FIELD];
12699
+ }), selectedRowKeys);
12700
+ var unCurrentTradeOriginGoods = difference(selectedRowKeys, dataSource === null || dataSource === void 0 ? void 0 : dataSource.map(function (item) {
12701
+ return item === null || item === void 0 ? void 0 : item[MAIN_FIELD];
12702
+ }));
12703
+ var handleChangeSelectedKeys = function handleChangeSelectedKeys(keys) {
12704
+ console.log('handleChangeSelectedKeys', keys, unCurrentTradeOriginGoods);
12705
+ onChangeSelectedKeys(keys.concat(unCurrentTradeOriginGoods));
12706
+ };
12707
+ var rowSelection = {
12708
+ selectedRowKeys: selectedRowKeys,
12709
+ onChange: handleChangeSelectedKeys
12710
+ };
12711
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Button, {
12712
+ type: "link",
12713
+ onClick: openModal
12714
+ }, "\u9009\u62E9\u8BA2\u5355\u5546\u54C1"), /*#__PURE__*/React.createElement(Modal, {
12715
+ title: "\u8BA2\u5355\u5546\u54C1",
12716
+ visible: tradeGoodsVisible,
12717
+ footer: null,
12718
+ onCancel: closeModal
12719
+ }, /*#__PURE__*/React.createElement(Table, {
12720
+ rowKey: MAIN_FIELD,
12721
+ rowSelection: rowSelection,
12722
+ columns: columns,
12723
+ dataSource: dataSource,
12724
+ pagination: false,
12725
+ scroll: {
12726
+ x: 500,
12727
+ y: 500
12728
+ }
12729
+ }), /*#__PURE__*/React.createElement("span", null, "\u5DF2\u9009\u62E9(", currentTradeOriginGoods === null || currentTradeOriginGoods === void 0 ? void 0 : currentTradeOriginGoods.length, "/", dataSource === null || dataSource === void 0 ? void 0 : dataSource.length, ")")));
12730
+ };
12731
+ var getButtonText = function getButtonText() {
12732
+ var type = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
12733
+ if (['BS_E3_GOODS', 'BS_E3_REISSUE_GOODS', 'BS_E3_EXCHANGE_GOODS'].includes(type)) {
12734
+ return '选择百胜ERP商品';
12735
+ }
12736
+ if (['WDT_REISSUE_GOODS'].includes(type)) {
12737
+ return '选择旺店通商品';
12738
+ }
12739
+ return '选择商品';
12740
+ };
12485
12741
  var GoodItem$1 = function GoodItem(props) {
12486
- var _ref;
12487
12742
  var _props$value = props.value,
12488
12743
  value = _props$value === void 0 ? [] : _props$value,
12489
12744
  type = props.type,
@@ -12517,8 +12772,10 @@ var GoodItem$1 = function GoodItem(props) {
12517
12772
  companyKey = _props$companyKey === void 0 ? '' : _props$companyKey,
12518
12773
  onSelect = props.onSelect,
12519
12774
  onDelete = props.onDelete,
12520
- onModeChange = props.onModeChange;
12775
+ onModeChange = props.onModeChange,
12776
+ tradeGoods = props.tradeGoods;
12521
12777
  var refModal = useRef();
12778
+ console.debug('表格数据', value);
12522
12779
  var handleDelete = function handleDelete(record, index) {
12523
12780
  onDelete === null || onDelete === void 0 ? void 0 : onDelete(value[index]);
12524
12781
  var newList = _toConsumableArray(value).filter(function (item, i) {
@@ -12526,13 +12783,19 @@ var GoodItem$1 = function GoodItem(props) {
12526
12783
  });
12527
12784
  onChange === null || onChange === void 0 ? void 0 : onChange(_toConsumableArray(newList));
12528
12785
  };
12529
- var _useState = useState([]),
12530
- _useState2 = _slicedToArray(_useState, 2),
12531
- selectedRowKeys = _useState2[0],
12532
- setSelectedRowKeys = _useState2[1];
12786
+ var _useState3 = useState([]),
12787
+ _useState4 = _slicedToArray(_useState3, 2),
12788
+ selectedRowKeys = _useState4[0],
12789
+ setSelectedRowKeys = _useState4[1];
12533
12790
  useEffect(function () {
12534
12791
  setSelectedRowKeys([]);
12535
12792
  }, [tableSelect, selectType]);
12793
+ // TODO: 商品订单中以选中商品
12794
+ var selectedGoods = useMemo(function () {
12795
+ return value === null || value === void 0 ? void 0 : value.map(function (v) {
12796
+ return v === null || v === void 0 ? void 0 : v[MAIN_FIELD];
12797
+ });
12798
+ }, [value]);
12536
12799
  var updateHandle = function updateHandle(val, index, columnType) {
12537
12800
  if (value === null || value === void 0 ? void 0 : value.length) {
12538
12801
  value[index][columnType] = val;
@@ -12566,10 +12829,19 @@ var GoodItem$1 = function GoodItem(props) {
12566
12829
  };
12567
12830
  var COLUMNS_MAP = function COLUMNS_MAP() {
12568
12831
  var text = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
12832
+ var operate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
12569
12833
  return function (type) {
12570
12834
  var columns = [];
12571
12835
  switch (type) {
12572
12836
  case 'WDT_REISSUE_GOODS':
12837
+ {
12838
+ columns = getWdtReissueGoodColumns({
12839
+ disabled: disabled,
12840
+ updateHandle: updateHandle,
12841
+ operate: operate
12842
+ });
12843
+ }
12844
+ break;
12573
12845
  case 'WDT_GOODS':
12574
12846
  columns = [{
12575
12847
  dataIndex: 'goodId',
@@ -13059,10 +13331,22 @@ var GoodItem$1 = function GoodItem(props) {
13059
13331
  title: "\u662F\u5426\u8D60\u54C1",
13060
13332
  align: 'center',
13061
13333
  ellipsis: true,
13062
- width: 100
13334
+ width: 100,
13335
+ render: function render(val) {
13336
+ return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
13337
+ }
13063
13338
  }];
13064
13339
  }
13065
13340
  break;
13341
+ case 'BS_E3_REISSUE_GOODS':
13342
+ {
13343
+ columns = getBsE3ReissueGoodColumns({
13344
+ disabled: disabled,
13345
+ updateHandle: updateHandle,
13346
+ operate: operate
13347
+ });
13348
+ }
13349
+ break;
13066
13350
  default:
13067
13351
  columns = [{
13068
13352
  dataIndex: 'mark',
@@ -13202,6 +13486,19 @@ var GoodItem$1 = function GoodItem(props) {
13202
13486
  }
13203
13487
  return columnList;
13204
13488
  }, [showHeader, value, disabled]);
13489
+ var orderColumns = useMemo(function () {
13490
+ var columns = COLUMNS_MAP('', false)(type);
13491
+ return [{
13492
+ dataIndex: '',
13493
+ title: '序号',
13494
+ align: 'center',
13495
+ ellipsis: true,
13496
+ width: 50,
13497
+ render: function render(val, record, index) {
13498
+ return /*#__PURE__*/React.createElement("span", null, index + 1);
13499
+ }
13500
+ }].concat(_toConsumableArray(columns));
13501
+ }, []);
13205
13502
  var onSubmit = function onSubmit(list) {
13206
13503
  var newList = [];
13207
13504
  if (['WDT_REISSUE_GOODS', 'WDT_GOODS', 'WDT_EXCHANGE_GOODS'].includes(type)) {
@@ -13220,12 +13517,36 @@ var GoodItem$1 = function GoodItem(props) {
13220
13517
  });
13221
13518
  } else if (['BS_E3_GOODS', 'BS_E3_REISSUE_GOODS', 'BS_E3_EXCHANGE_GOODS'].includes(type)) {
13222
13519
  newList = list.map(function (item) {
13223
- item.uuid = uuid();
13224
- item.canDelete = true;
13225
- item.goodsNumber = 1;
13226
- item.goodsPrice = 0;
13227
- item.canUpdateNumber = canUpdateNumber;
13228
- return item;
13520
+ var specNo = item.specNo,
13521
+ specId = item.specId,
13522
+ goodName = item.goodName,
13523
+ goodShortName = item.goodShortName,
13524
+ goodPicUrl = item.goodPicUrl,
13525
+ goodNo = item.goodNo,
13526
+ goodId = item.goodId,
13527
+ retailPrice = item.retailPrice;
13528
+ return _objectSpread2(_objectSpread2({}, item), {}, {
13529
+ sku: specNo,
13530
+ skuId: specId,
13531
+ goodsName: goodName,
13532
+ goodsShortName: goodShortName,
13533
+ picPath: goodPicUrl,
13534
+ goodsSn: goodNo,
13535
+ goodsId: goodId,
13536
+ goodsPrice: retailPrice,
13537
+ shopPrice: retailPrice,
13538
+ sharePayment: '',
13539
+ sharePrice: '',
13540
+ payment: '',
13541
+ tcSku: '',
13542
+ tcGoodsNumber: '',
13543
+ taoCanSingleSl: '',
13544
+ isGift: '',
13545
+ uuid: uuid(),
13546
+ canDelete: true,
13547
+ goodsNumber: 1,
13548
+ canUpdateNumber: canUpdateNumber
13549
+ });
13229
13550
  });
13230
13551
  } else {
13231
13552
  newList = list.map(function (item) {
@@ -13286,10 +13607,15 @@ var GoodItem$1 = function GoodItem(props) {
13286
13607
  }, showModeBtn && /*#__PURE__*/React.createElement(Checkbox, {
13287
13608
  checked: isStrict,
13288
13609
  onChange: handleCheckboxChange
13289
- }, "\u5408\u5E76\u5355\uFF0C\u52FE\u9009\u540E\u53EA\u5C55\u793A\u5F53\u524D\u5E73\u53F0\u8BA2\u5355\u5546\u54C1"), !((_ref = ['BS_E3_GOODS']) === null || _ref === void 0 ? void 0 : _ref.includes(type)) && /*#__PURE__*/React.createElement(Button, {
13610
+ }, "\u5408\u5E76\u5355\uFF0C\u52FE\u9009\u540E\u53EA\u5C55\u793A\u5F53\u524D\u5E73\u53F0\u8BA2\u5355\u5546\u54C1"), !isEmpty(tradeGoods) && /*#__PURE__*/React.createElement(SelectTradeGoods, {
13611
+ columns: orderColumns,
13612
+ dataSource: tradeGoods.originDataSource,
13613
+ selectedRowKeys: selectedGoods,
13614
+ onChangeSelectedKeys: tradeGoods.selectedGoodsChange
13615
+ }), /*#__PURE__*/React.createElement(Button, {
13290
13616
  type: "link",
13291
13617
  onClick: handleChangeGoods
13292
- }, "\u9009\u62E9\u5546\u54C1"), otherOperations), /*#__PURE__*/React.createElement(Table, _objectSpread2(_objectSpread2({}, tableConfig), {}, {
13618
+ }, getButtonText(type)), otherOperations), /*#__PURE__*/React.createElement(Table, _objectSpread2(_objectSpread2({}, tableConfig), {}, {
13293
13619
  columns: newColumns,
13294
13620
  dataSource: value,
13295
13621
  rowKey: 'uuid',
@@ -13998,25 +14324,7 @@ var getBsE3OrderListSingleton = function getBsE3OrderListSingleton(orderNo) {
13998
14324
  if (data === null || data === void 0 ? void 0 : data.success) {
13999
14325
  var _data$data, _data$data$orderList;
14000
14326
  if (data === null || data === void 0 ? void 0 : (_data$data = data.data) === null || _data$data === void 0 ? void 0 : (_data$data$orderList = _data$data.orderList) === null || _data$data$orderList === void 0 ? void 0 : _data$data$orderList.length) {
14001
- var _filterBsE3Orders;
14002
- data.data.orderList = (_filterBsE3Orders = filterBsE3Orders(data === null || data === void 0 ? void 0 : data.data, orderNo)) === null || _filterBsE3Orders === void 0 ? void 0 : _filterBsE3Orders.map(function (item) {
14003
- var isSplit = item.isSplit,
14004
- isSplitNew = item.isSplitNew,
14005
- isCopy = item.isCopy,
14006
- isExchangeOrder = item.isExchangeOrder,
14007
- isCombineNew = item.isCombineNew,
14008
- isCombine = item.isCombine,
14009
- orderStatus = item.orderStatus;
14010
- return _objectSpread2(_objectSpread2({}, item), {}, {
14011
- orderStatus: BS_E3_ORDER_STATUS_MAP[orderStatus],
14012
- isSplit: BS_E3_BOOLEAN_STATUS_MAP[isSplit],
14013
- isSplitNew: BS_E3_BOOLEAN_STATUS_MAP[isSplitNew],
14014
- isExchangeOrder: BS_E3_BOOLEAN_STATUS_MAP[isExchangeOrder],
14015
- isCopy: BS_E3_BOOLEAN_STATUS_MAP[isCopy],
14016
- isCombineNew: BS_E3_BOOLEAN_STATUS_MAP[isCombineNew],
14017
- isCombine: BS_E3_BOOLEAN_STATUS_MAP[isCombine]
14018
- });
14019
- });
14327
+ data.data.orderList = filterBsE3Orders(data === null || data === void 0 ? void 0 : data.data, orderNo);
14020
14328
  }
14021
14329
  resolve(data.data);
14022
14330
  } else {
@@ -14032,6 +14340,53 @@ var bsE3Utils = {
14032
14340
  getBsE3OrderListSingleton: getBsE3OrderListSingleton
14033
14341
  };
14034
14342
 
14343
+ var singletonMap$2 = new Map();
14344
+ var getOrderListSingleton = function getOrderListSingleton(orderNo) {
14345
+ if (!singletonMap$2.has(orderNo)) {
14346
+ var p = new Promise(function (resolve, reject) {
14347
+ var doReject = function doReject(err) {
14348
+ // 清空掉错误的请求记录
14349
+ singletonMap$2.delete(orderNo);
14350
+ reject(err);
14351
+ };
14352
+ extendRequest('/qy/gdfw/order/kmErpOrderDetail', {
14353
+ method: 'post',
14354
+ data: {
14355
+ tid: orderNo
14356
+ }
14357
+ }).then(function (data) {
14358
+ if (data === null || data === void 0 ? void 0 : data.success) {
14359
+ var _data$data, _data$data$orderDetai;
14360
+ if (data === null || data === void 0 ? void 0 : (_data$data = data.data) === null || _data$data === void 0 ? void 0 : (_data$data$orderDetai = _data$data.orderDetailDtoList) === null || _data$data$orderDetai === void 0 ? void 0 : _data$data$orderDetai.length) {
14361
+ var list = filterKmOrders(data === null || data === void 0 ? void 0 : data.data, orderNo).map(function (item) {
14362
+ return _objectSpread2(_objectSpread2({}, item), {}, {
14363
+ billNo: item.sid,
14364
+ sysStatus: item.sysStatus,
14365
+ billType: item.type,
14366
+ billTag: item.tags
14367
+ });
14368
+ });
14369
+ resolve(list);
14370
+ } else {
14371
+ resolve([]);
14372
+ }
14373
+ // 延迟10秒清除,保证订单的时效性
14374
+ setTimeout(function () {
14375
+ singletonMap$2.delete(orderNo);
14376
+ }, 1000 * 10);
14377
+ } else {
14378
+ doReject(data);
14379
+ }
14380
+ }).catch(doReject);
14381
+ });
14382
+ singletonMap$2.set(orderNo, p);
14383
+ }
14384
+ return singletonMap$2.get(orderNo);
14385
+ };
14386
+ var kmUtils = {
14387
+ getOrderListSingleton: getOrderListSingleton
14388
+ };
14389
+
14035
14390
  var columnsMap = {
14036
14391
  BS_SYSTEM_ORDER: [{
14037
14392
  title: '单据类型',
@@ -14045,7 +14400,23 @@ var columnsMap = {
14045
14400
  title: '标签',
14046
14401
  dataIndex: 'billTag',
14047
14402
  width: 150
14048
- }],
14403
+ }, {
14404
+ title: '主播名称',
14405
+ dataIndex: 'authorName',
14406
+ width: 150
14407
+ }, {
14408
+ title: '主播ID',
14409
+ dataIndex: 'authorId',
14410
+ width: 150
14411
+ }
14412
+ // {
14413
+ // title: '直播活动',
14414
+ // dataIndex: 'liveActivites',
14415
+ // width: 150,
14416
+ // },
14417
+ ],
14418
+
14419
+ KM_SYSTEM_ORDER: KM_SYSTEM_ORDER_CONFIG.columns,
14049
14420
  WLN_SYSTEM_ORDER: [{
14050
14421
  title: '订单类型',
14051
14422
  dataIndex: 'billType',
@@ -14081,37 +14452,58 @@ var columnsMap = {
14081
14452
  title: '订单状态',
14082
14453
  dataIndex: 'orderStatus',
14083
14454
  width: 100,
14084
- ellipsis: true
14455
+ ellipsis: true,
14456
+ render: function render(val) {
14457
+ return /*#__PURE__*/React.createElement("span", null, BS_E3_ORDER_STATUS_MAP[val] || val);
14458
+ }
14085
14459
  }, {
14086
14460
  title: '是否被拆分',
14087
14461
  dataIndex: 'isSplit',
14088
- width: 70,
14089
- ellipsis: true
14462
+ width: 100,
14463
+ ellipsis: true,
14464
+ render: function render(val) {
14465
+ return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
14466
+ }
14090
14467
  }, {
14091
14468
  title: '是否拆分子单',
14092
14469
  dataIndex: 'isSplitNew',
14093
- width: 70,
14094
- ellipsis: true
14470
+ width: 100,
14471
+ ellipsis: true,
14472
+ render: function render(val) {
14473
+ return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
14474
+ }
14095
14475
  }, {
14096
14476
  title: '是否被合并',
14097
14477
  dataIndex: 'isCombine',
14098
- width: 70,
14099
- ellipsis: true
14478
+ width: 100,
14479
+ ellipsis: true,
14480
+ render: function render(val) {
14481
+ return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
14482
+ }
14100
14483
  }, {
14101
14484
  title: '是否合并新单',
14102
14485
  dataIndex: 'isCombineNew',
14103
- width: 70,
14104
- ellipsis: true
14486
+ width: 100,
14487
+ ellipsis: true,
14488
+ render: function render(val) {
14489
+ return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
14490
+ }
14105
14491
  }, {
14106
14492
  title: '是否复制单',
14107
14493
  dataIndex: 'isCopy',
14108
- width: 70,
14109
- ellipsis: true
14494
+ width: 100,
14495
+ ellipsis: true,
14496
+ render: function render(val) {
14497
+ return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
14498
+ }
14110
14499
  }, {
14111
14500
  title: '是否换货单',
14112
14501
  dataIndex: 'isExchangeOrder',
14113
- width: 70,
14114
- ellipsis: true
14502
+ width: 100,
14503
+ ellipsis: true,
14504
+ render: function render(val) {
14505
+ return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
14506
+ }
14115
14507
  }, {
14116
14508
  title: '订单备注',
14117
14509
  dataIndex: 'orderMsg',
@@ -14121,6 +14513,7 @@ var columnsMap = {
14121
14513
  };
14122
14514
  var rowKeyMap = {
14123
14515
  BS_SYSTEM_ORDER: 'billNo',
14516
+ KM_SYSTEM_ORDER: 'billNo',
14124
14517
  WLN_SYSTEM_ORDER: 'billNo',
14125
14518
  WDT_SYSTEM_ORDER: 'billNo',
14126
14519
  BS_E3_SYSTEM_ORDER: 'orderSn'
@@ -14137,6 +14530,8 @@ var index$1 = (function (props) {
14137
14530
  onceRef.current = true;
14138
14531
  if (type === 'BS_SYSTEM_ORDER') {
14139
14532
  getOrderList(value.orderNo);
14533
+ } else if (type === 'KM_SYSTEM_ORDER') {
14534
+ getKmOrderList(value.orderNo);
14140
14535
  } else if (type === 'WLN_SYSTEM_ORDER') {
14141
14536
  getWlnOrderList(value.orderNo);
14142
14537
  } else if (type === 'WDT_SYSTEM_ORDER') {
@@ -14173,11 +14568,15 @@ var index$1 = (function (props) {
14173
14568
  return {
14174
14569
  billNo: item.billNo,
14175
14570
  billType: item.billType,
14176
- billTag: item.billTag
14571
+ billTag: item.billTag,
14572
+ authorName: item.authorName,
14573
+ authorId: item.authorId
14574
+ // liveActivites: item.liveActivites,
14177
14575
  };
14178
14576
  })
14179
14577
  }));
14180
14578
  }
14579
+
14181
14580
  onceRef.current = false;
14182
14581
  case 7:
14183
14582
  case "end":
@@ -14294,6 +14693,37 @@ var index$1 = (function (props) {
14294
14693
  return _ref5.apply(this, arguments);
14295
14694
  };
14296
14695
  }();
14696
+ var getKmOrderList = /*#__PURE__*/function () {
14697
+ var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(orderNo) {
14698
+ return _regeneratorRuntime().wrap(function _callee5$(_context5) {
14699
+ while (1) switch (_context5.prev = _context5.next) {
14700
+ case 0:
14701
+ kmUtils.getOrderListSingleton(orderNo).then(function (trades) {
14702
+ _onChange === null || _onChange === void 0 ? void 0 : _onChange(_objectSpread2(_objectSpread2({}, value), {}, {
14703
+ orders: trades,
14704
+ showOrderInfo: trades.map(function (_ref7) {
14705
+ var billNo = _ref7.billNo,
14706
+ billType = _ref7.billType,
14707
+ billTag = _ref7.billTag;
14708
+ return {
14709
+ billNo: billNo,
14710
+ billType: billType,
14711
+ billTag: billTag
14712
+ };
14713
+ })
14714
+ }));
14715
+ });
14716
+ onceRef.current = false;
14717
+ case 2:
14718
+ case "end":
14719
+ return _context5.stop();
14720
+ }
14721
+ }, _callee5);
14722
+ }));
14723
+ return function getKmOrderList(_x5) {
14724
+ return _ref6.apply(this, arguments);
14725
+ };
14726
+ }();
14297
14727
  var rowSelection = {
14298
14728
  selectedRowKeys: (value === null || value === void 0 ? void 0 : value.selectIds) || [],
14299
14729
  fixed: true,
@@ -14422,7 +14852,7 @@ var CommonGoods = function CommonGoods(props) {
14422
14852
  valueRef.current = value;
14423
14853
  if (!getOrderFlag.current && !(value === null || value === void 0 ? void 0 : (_value$orders = value.orders) === null || _value$orders === void 0 ? void 0 : _value$orders.length) && (value === null || value === void 0 ? void 0 : value.orderNo)) {
14424
14854
  getOrderFlag.current = true;
14425
- getWdtOrderList(value === null || value === void 0 ? void 0 : value.orderNo);
14855
+ compType.indexOf('WDT') > -1 && getWdtOrderList(value === null || value === void 0 ? void 0 : value.orderNo);
14426
14856
  }
14427
14857
  }, [value]);
14428
14858
  var getWdtOrderList = /*#__PURE__*/function () {
@@ -14859,11 +15289,12 @@ var typeMap$1 = {
14859
15289
  formatDefaultField: {
14860
15290
  money: 'orderPrice',
14861
15291
  share: 'sharePrice'
14862
- }
15292
+ },
15293
+ getOrderList: wdtUtils.getWdtOrderListSingleton
14863
15294
  }
14864
15295
  };
14865
15296
  var wdtReissue = function wdtReissue(props) {
14866
- var _value$wdtSystemOrder, _typeMap$type7, _typeMap$type25, _typeMap$type26, _value$typeMap$type$s5, _typeMap$type27, _typeMap$type28, _typeMap$type29;
15297
+ var _value$wdtSystemOrder, _typeMap$type26, _typeMap$type28, _typeMap$type29, _value$typeMap$type$s5, _typeMap$type30, _typeMap$type31, _typeMap$type32;
14867
15298
  var value = props.value,
14868
15299
  onChange = props.onChange,
14869
15300
  _props$reasonList = props.reasonList,
@@ -14885,31 +15316,48 @@ var wdtReissue = function wdtReissue(props) {
14885
15316
  if (!getOrderFlag.current && !(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s = value[(_typeMap$type = typeMap$1[type]) === null || _typeMap$type === void 0 ? void 0 : _typeMap$type.systemOrder]) === null || _value$typeMap$type$s === void 0 ? void 0 : (_value$typeMap$type$s2 = _value$typeMap$type$s.orders) === null || _value$typeMap$type$s2 === void 0 ? void 0 : _value$typeMap$type$s2.length) && (value === null || value === void 0 ? void 0 : (_value$typeMap$type$s3 = value[(_typeMap$type2 = typeMap$1[type]) === null || _typeMap$type2 === void 0 ? void 0 : _typeMap$type2.systemOrder]) === null || _value$typeMap$type$s3 === void 0 ? void 0 : _value$typeMap$type$s3.orderNo)) {
14886
15317
  var _value$typeMap$type$s4, _typeMap$type3;
14887
15318
  getOrderFlag.current = true;
14888
- getWdtOrderList(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s4 = value[(_typeMap$type3 = typeMap$1[type]) === null || _typeMap$type3 === void 0 ? void 0 : _typeMap$type3.systemOrder]) === null || _value$typeMap$type$s4 === void 0 ? void 0 : _value$typeMap$type$s4.orderNo);
15319
+ getOrderList(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s4 = value[(_typeMap$type3 = typeMap$1[type]) === null || _typeMap$type3 === void 0 ? void 0 : _typeMap$type3.systemOrder]) === null || _value$typeMap$type$s4 === void 0 ? void 0 : _value$typeMap$type$s4.orderNo);
14889
15320
  }
14890
15321
  return;
14891
15322
  }, [value]);
14892
- useEffect(function () {
14893
- var _typeMap$type4;
14894
- var systemOrderNo = value === null || value === void 0 ? void 0 : value[(_typeMap$type4 = typeMap$1[type]) === null || _typeMap$type4 === void 0 ? void 0 : _typeMap$type4.systemOrderNo];
14895
- if (systemOrderNo) {
14896
- var _value$typeMap$type$t, _typeMap$type5;
14897
- if (['1'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t = value[(_typeMap$type5 = typeMap$1[type]) === null || _typeMap$type5 === void 0 ? void 0 : _typeMap$type5.typeName]) === null || _value$typeMap$type$t === void 0 ? void 0 : _value$typeMap$type$t[0])) {
14898
- var _typeMap$type6;
14899
- onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type6 = typeMap$1[type]) === null || _typeMap$type6 === void 0 ? void 0 : _typeMap$type6.key, getGoodDetails({
14900
- mode: isStrict
14901
- }))));
14902
- }
14903
- }
14904
- return;
14905
- }, [value === null || value === void 0 ? void 0 : value[(_typeMap$type7 = typeMap$1[type]) === null || _typeMap$type7 === void 0 ? void 0 : _typeMap$type7.systemOrderNo]]);
14906
- var getWdtOrderList = /*#__PURE__*/function () {
15323
+ // useEffect(() => {
15324
+ // const systemOrderNo = value?.[typeMap[type]?.systemOrderNo];
15325
+ // if (systemOrderNo) {
15326
+ // if (['1'].includes(value?.[typeMap[type]?.typeName]?.[0])) {
15327
+ // onChange?.({
15328
+ // ...value,
15329
+ // [typeMap[type]?.key]: getGoodDetails({
15330
+ // mode: isStrict
15331
+ // })
15332
+ // })
15333
+ // }
15334
+ // }
15335
+ // return;
15336
+ // }, [value?.[typeMap[type]?.systemOrderNo]]);
15337
+ // const getWdtOrderList = async (orderNo: string) => {
15338
+ // wdtUtils.getWdtOrderListSingleton(orderNo).then(data => {
15339
+ // const orders = data?.trades || [];
15340
+ // const showOrderInfo = orders.map(({ billNo, billType, billTag }: any) => {
15341
+ // return { billNo, billType, billTag }
15342
+ // });
15343
+ // onChange({
15344
+ // ...value,
15345
+ // [typeMap[type]?.systemOrder]: {
15346
+ // ...value[typeMap[type]?.systemOrder],
15347
+ // showOrderInfo,
15348
+ // orders,
15349
+ // },
15350
+ // });
15351
+ // })
15352
+ // };
15353
+ var getOrderList = /*#__PURE__*/function () {
14907
15354
  var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderNo) {
15355
+ var _typeMap$type4;
14908
15356
  return _regeneratorRuntime().wrap(function _callee$(_context) {
14909
15357
  while (1) switch (_context.prev = _context.next) {
14910
15358
  case 0:
14911
- wdtUtils.getWdtOrderListSingleton(orderNo).then(function (data) {
14912
- var _typeMap$type8, _typeMap$type9;
15359
+ (_typeMap$type4 = typeMap$1[type]) === null || _typeMap$type4 === void 0 ? void 0 : _typeMap$type4.getOrderList(orderNo).then(function (data) {
15360
+ var _typeMap$type5, _typeMap$type6;
14913
15361
  var orders = (data === null || data === void 0 ? void 0 : data.trades) || [];
14914
15362
  var showOrderInfo = orders.map(function (_ref2) {
14915
15363
  var billNo = _ref2.billNo,
@@ -14921,7 +15369,7 @@ var wdtReissue = function wdtReissue(props) {
14921
15369
  billTag: billTag
14922
15370
  };
14923
15371
  });
14924
- onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type8 = typeMap$1[type]) === null || _typeMap$type8 === void 0 ? void 0 : _typeMap$type8.systemOrder, _objectSpread2(_objectSpread2({}, value[(_typeMap$type9 = typeMap$1[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.systemOrder]), {}, {
15372
+ onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type5 = typeMap$1[type]) === null || _typeMap$type5 === void 0 ? void 0 : _typeMap$type5.systemOrder, _objectSpread2(_objectSpread2({}, value[(_typeMap$type6 = typeMap$1[type]) === null || _typeMap$type6 === void 0 ? void 0 : _typeMap$type6.systemOrder]), {}, {
14925
15373
  showOrderInfo: showOrderInfo,
14926
15374
  orders: orders
14927
15375
  }))));
@@ -14932,43 +15380,44 @@ var wdtReissue = function wdtReissue(props) {
14932
15380
  }
14933
15381
  }, _callee);
14934
15382
  }));
14935
- return function getWdtOrderList(_x) {
15383
+ return function getOrderList(_x) {
14936
15384
  return _ref.apply(this, arguments);
14937
15385
  };
14938
15386
  }();
14939
15387
  var changeTypeHandle = function changeTypeHandle(val) {
14940
- var _value$typeMap$type$t2, _typeMap$type10, _typeMap$type11;
15388
+ var _value$typeMap$type$t, _typeMap$type7, _typeMap$type8;
14941
15389
  var typeName = val === null || val === void 0 ? void 0 : val[0];
14942
- if (typeName === (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t2 = value[(_typeMap$type10 = typeMap$1[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.typeName]) === null || _value$typeMap$type$t2 === void 0 ? void 0 : _value$typeMap$type$t2[0])) return;
15390
+ if (typeName === (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t = value[(_typeMap$type7 = typeMap$1[type]) === null || _typeMap$type7 === void 0 ? void 0 : _typeMap$type7.typeName]) === null || _value$typeMap$type$t === void 0 ? void 0 : _value$typeMap$type$t[0])) return;
14943
15391
  // const systemOrderNo = value?.[typeMap[type]?.systemOrderNo];
14944
15392
  var newValue = _objectSpread2({}, value);
14945
- newValue[(_typeMap$type11 = typeMap$1[type]) === null || _typeMap$type11 === void 0 ? void 0 : _typeMap$type11.typeName] = val;
15393
+ newValue[(_typeMap$type8 = typeMap$1[type]) === null || _typeMap$type8 === void 0 ? void 0 : _typeMap$type8.typeName] = val;
14946
15394
  if (typeName === '1') {
14947
- var _typeMap$type12;
14948
- newValue[(_typeMap$type12 = typeMap$1[type]) === null || _typeMap$type12 === void 0 ? void 0 : _typeMap$type12.key] = getGoodDetails({
15395
+ var _typeMap$type9;
15396
+ newValue[(_typeMap$type9 = typeMap$1[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.key] = getGoodDetails({
14949
15397
  mode: isStrict
14950
15398
  });
14951
15399
  } else if (typeName === '2') {
14952
- var _typeMap$type13;
15400
+ var _typeMap$type10;
14953
15401
  // 切换到非原单,清空列表
14954
- newValue[(_typeMap$type13 = typeMap$1[type]) === null || _typeMap$type13 === void 0 ? void 0 : _typeMap$type13.key] = [];
15402
+ newValue[(_typeMap$type10 = typeMap$1[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.key] = [];
14955
15403
  }
14956
15404
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
14957
15405
  };
14958
15406
  var handleModeChange = function handleModeChange(mode) {
14959
- var _value$typeMap$type$t3, _typeMap$type14, _typeMap$type15;
14960
- var isOriginalOrder = (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t3 = value[(_typeMap$type14 = typeMap$1[type]) === null || _typeMap$type14 === void 0 ? void 0 : _typeMap$type14.typeName]) === null || _value$typeMap$type$t3 === void 0 ? void 0 : _value$typeMap$type$t3[0]) === '1';
15407
+ var _value$typeMap$type$t2, _typeMap$type11, _typeMap$type12;
15408
+ var isOriginalOrder = (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t2 = value[(_typeMap$type11 = typeMap$1[type]) === null || _typeMap$type11 === void 0 ? void 0 : _typeMap$type11.typeName]) === null || _value$typeMap$type$t2 === void 0 ? void 0 : _value$typeMap$type$t2[0]) === '1';
14961
15409
  setIsStrict(mode);
14962
15410
  if (!isOriginalOrder) return;
14963
- onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type15 = typeMap$1[type]) === null || _typeMap$type15 === void 0 ? void 0 : _typeMap$type15.key, getGoodDetails({
15411
+ onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type12 = typeMap$1[type]) === null || _typeMap$type12 === void 0 ? void 0 : _typeMap$type12.key, getGoodDetails({
14964
15412
  mode: mode
14965
15413
  }))));
14966
15414
  };
14967
15415
  var getGoodDetails = function getGoodDetails(_ref3) {
14968
- var _typeMap$type16, _typeMap$type17, _order$goodDetails;
14969
- var mode = _ref3.mode;
14970
- var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type16 = typeMap$1[type]) === null || _typeMap$type16 === void 0 ? void 0 : _typeMap$type16.systemOrder];
14971
- var systemOrderNo = value === null || value === void 0 ? void 0 : value[(_typeMap$type17 = typeMap$1[type]) === null || _typeMap$type17 === void 0 ? void 0 : _typeMap$type17.systemOrderNo];
15416
+ var _typeMap$type13, _typeMap$type14, _order$goodDetails;
15417
+ var mode = _ref3.mode,
15418
+ sysOrderNo = _ref3.sysOrderNo;
15419
+ var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type13 = typeMap$1[type]) === null || _typeMap$type13 === void 0 ? void 0 : _typeMap$type13.systemOrder];
15420
+ var systemOrderNo = sysOrderNo !== null && sysOrderNo !== void 0 ? sysOrderNo : value === null || value === void 0 ? void 0 : value[(_typeMap$type14 = typeMap$1[type]) === null || _typeMap$type14 === void 0 ? void 0 : _typeMap$type14.systemOrderNo];
14972
15421
  var order = systemOrderNo && ((systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orders) || []).find(function (order) {
14973
15422
  return order.tradeNo === systemOrderNo;
14974
15423
  });
@@ -14979,31 +15428,52 @@ var wdtReissue = function wdtReissue(props) {
14979
15428
  }) : goodDetails;
14980
15429
  };
14981
15430
  var changeGoodHandle = function changeGoodHandle(val) {
14982
- var _typeMap$type18;
15431
+ var _typeMap$type15;
14983
15432
  var newValue = _objectSpread2({}, value);
14984
- newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type18 = typeMap$1[type]) === null || _typeMap$type18 === void 0 ? void 0 : _typeMap$type18.key)] = (val || []).map(function (item) {
14985
- var _typeMap$type19, _typeMap$type20;
14986
- item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type19 = typeMap$1[type]) === null || _typeMap$type19 === void 0 ? void 0 : _typeMap$type19.formatDefaultField.money)] = 0;
14987
- item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type20 = typeMap$1[type]) === null || _typeMap$type20 === void 0 ? void 0 : _typeMap$type20.formatDefaultField.share)] = 0;
15433
+ newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type15 = typeMap$1[type]) === null || _typeMap$type15 === void 0 ? void 0 : _typeMap$type15.key)] = (val || []).map(function (item) {
15434
+ var _typeMap$type16, _typeMap$type17;
15435
+ item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type16 = typeMap$1[type]) === null || _typeMap$type16 === void 0 ? void 0 : _typeMap$type16.formatDefaultField.money)] = 0;
15436
+ item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type17 = typeMap$1[type]) === null || _typeMap$type17 === void 0 ? void 0 : _typeMap$type17.formatDefaultField.share)] = 0;
14988
15437
  return item;
14989
15438
  });
14990
15439
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
14991
15440
  };
14992
15441
  var changeSystemOrderHandle = function changeSystemOrderHandle(val) {
14993
- var _typeMap$type21, _value$typeMap$type$t4, _typeMap$type22;
15442
+ var _typeMap$type18, _value$typeMap$type$t3, _typeMap$type19, _value$typeMap$type$t4, _typeMap$type21;
14994
15443
  var newValue = _objectSpread2({}, value);
14995
- newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type21 = typeMap$1[type]) === null || _typeMap$type21 === void 0 ? void 0 : _typeMap$type21.systemOrderNo)] = val;
14996
- if (['2'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t4 = value[(_typeMap$type22 = typeMap$1[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.typeName]) === null || _value$typeMap$type$t4 === void 0 ? void 0 : _value$typeMap$type$t4[0])) {
14997
- var _typeMap$type23;
14998
- newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type23 = typeMap$1[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.key)] = [];
15444
+ newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type18 = typeMap$1[type]) === null || _typeMap$type18 === void 0 ? void 0 : _typeMap$type18.systemOrderNo)] = val;
15445
+ if (['2'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t3 = value[(_typeMap$type19 = typeMap$1[type]) === null || _typeMap$type19 === void 0 ? void 0 : _typeMap$type19.typeName]) === null || _value$typeMap$type$t3 === void 0 ? void 0 : _value$typeMap$type$t3[0])) {
15446
+ var _typeMap$type20;
15447
+ newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type20 = typeMap$1[type]) === null || _typeMap$type20 === void 0 ? void 0 : _typeMap$type20.key)] = [];
15448
+ } else if (['1'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t4 = value[(_typeMap$type21 = typeMap$1[type]) === null || _typeMap$type21 === void 0 ? void 0 : _typeMap$type21.typeName]) === null || _value$typeMap$type$t4 === void 0 ? void 0 : _value$typeMap$type$t4[0])) {
15449
+ var _typeMap$type22;
15450
+ newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type22 = typeMap$1[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.key)] = getGoodDetails({
15451
+ mode: isStrict,
15452
+ sysOrderNo: val
15453
+ });
14999
15454
  }
15000
15455
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
15001
15456
  };
15457
+ var selectedGoodsChange = useCallback(function (skuList) {
15458
+ var _typeMap$type23, _typeMap$type24, _uniqBy, _typeMap$type25;
15459
+ var newValue = _objectSpread2({}, value);
15460
+ // 原订单商品
15461
+ var originTradeGoodList = getGoodDetails({
15462
+ mode: isStrict
15463
+ }) || [];
15464
+ // 当前选中的所有商品【包含了原订单+商品库】
15465
+ var currentSelectGoodList = (value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type23 = typeMap$1[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.key)]) || [];
15466
+ newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type24 = typeMap$1[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.key)] = (_uniqBy = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
15467
+ return skuList.includes(item.uuid);
15468
+ });
15469
+ console.log('商品发生变化', newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type25 = typeMap$1[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.key)]);
15470
+ onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
15471
+ }, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type26 = typeMap$1[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.key)], isStrict]);
15002
15472
  //显示选择商品按钮 原单换不显示选择商品
15003
15473
  var showChangeBtn = useMemo(function () {
15004
- var _typeMap$type24;
15005
- return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type24 = typeMap$1[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.systemOrderNo]);
15006
- }, [value === null || value === void 0 ? void 0 : value[(_typeMap$type25 = typeMap$1[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.systemOrderNo]]);
15474
+ var _typeMap$type27;
15475
+ return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type27 = typeMap$1[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrderNo]);
15476
+ }, [value === null || value === void 0 ? void 0 : value[(_typeMap$type28 = typeMap$1[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.systemOrderNo]]);
15007
15477
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
15008
15478
  gutter: 8,
15009
15479
  wrap: true
@@ -15021,12 +15491,12 @@ var wdtReissue = function wdtReissue(props) {
15021
15491
  },
15022
15492
  disabled: disabled,
15023
15493
  allowClear: false,
15024
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type26 = typeMap$1[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.systemOrderNo)],
15494
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type29 = typeMap$1[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.systemOrderNo)],
15025
15495
  onChange: function onChange(val) {
15026
15496
  return changeSystemOrderHandle(val);
15027
15497
  },
15028
15498
  placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
15029
- }, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type27 = typeMap$1[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
15499
+ }, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type30 = typeMap$1[type]) === null || _typeMap$type30 === void 0 ? void 0 : _typeMap$type30.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
15030
15500
  return /*#__PURE__*/React.createElement(Select.Option, {
15031
15501
  key: item.billNo,
15032
15502
  value: item.billNo,
@@ -15047,7 +15517,7 @@ var wdtReissue = function wdtReissue(props) {
15047
15517
  disabled: disabled,
15048
15518
  allowClear: false,
15049
15519
  options: reasonList,
15050
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type28 = typeMap$1[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.typeName)],
15520
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type31 = typeMap$1[type]) === null || _typeMap$type31 === void 0 ? void 0 : _typeMap$type31.typeName)],
15051
15521
  onChange: function onChange(val) {
15052
15522
  return changeTypeHandle(val);
15053
15523
  }
@@ -15059,13 +15529,19 @@ var wdtReissue = function wdtReissue(props) {
15059
15529
  canUpdateNumber: showChangeBtn,
15060
15530
  showChangeBtn: showChangeBtn,
15061
15531
  shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
15062
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type29 = typeMap$1[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.key)],
15532
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type32 = typeMap$1[type]) === null || _typeMap$type32 === void 0 ? void 0 : _typeMap$type32.key)],
15063
15533
  onChange: function onChange(val) {
15064
15534
  return changeGoodHandle(val);
15065
15535
  },
15066
15536
  onModeChange: handleModeChange,
15067
15537
  showModeBtn: showModeBtn,
15068
- isStrict: isStrict
15538
+ isStrict: isStrict,
15539
+ tradeGoods: {
15540
+ originDataSource: getGoodDetails({
15541
+ mode: isStrict
15542
+ }),
15543
+ selectedGoodsChange: selectedGoodsChange
15544
+ }
15069
15545
  })));
15070
15546
  };
15071
15547
 
@@ -15839,4 +16315,238 @@ var CalculationInput = function CalculationInput(props) {
15839
16315
  }, config === null || config === void 0 ? void 0 : config.unit));
15840
16316
  };
15841
16317
 
15842
- 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, index as ApaasUploadAsync, ApaasUploadFile, BsExchange, BsGoods, BsReissue, BsReturnGoods as BsReturn, index$1 as BsSystemOrder, BuyerNick, CalculationInput, ChooseBaby, CommonExchangeGoods, CommonGoods, CommonSystemOrder$1 as CommonMultiStatus, CommonReturnGoods, CommonStatus, CommonSystemOrder, ExpressLogistics, Goods, index$2 as GoodsTable, IdentifyAddress, Invoice, jstGoods as JstGoods, ItemList as JstItemList, LogisticsInterception, LogisticsMoreInterception, LogisticsMoreTrajectory, LogisticsTrajectory, MsgStatus, ParseLogistics, Payment, RemarkInput as Remark, ExpressLogistics as ReturnLogistics, ShopNameSelect as ShopName, Status, SubForm, Supplier, TBGoodId, TBGoodSerial, TradeId, WdtGoodList, wdtReissue as WdtReissue, WlnGoods };
16318
+ var _excluded$k = ["value", "onChange", "reasonList", "disabled", "type"];
16319
+ var typeMap$2 = {
16320
+ BS_E3_REISSUE_GOODS: {
16321
+ key: 'bsE3ReissueGoods',
16322
+ typeName: 'bsE3ReissueType',
16323
+ systemOrder: 'bsE3SystemOrder',
16324
+ systemOrderNo: 'bsE3SystemOrderNo',
16325
+ getOrderList: bsE3Utils.getBsE3OrderListSingleton
16326
+ }
16327
+ };
16328
+ var bsE3Reissue = function bsE3Reissue(props) {
16329
+ var _typeMap$type21, _typeMap$type24, _typeMap$type25, _value$typeMap$type$s5, _typeMap$type26, _typeMap$type27, _typeMap$type28;
16330
+ var value = props.value,
16331
+ onChange = props.onChange,
16332
+ _props$reasonList = props.reasonList,
16333
+ reasonList = _props$reasonList === void 0 ? [] : _props$reasonList,
16334
+ disabled = props.disabled,
16335
+ type = props.type,
16336
+ other = _objectWithoutProperties(props, _excluded$k);
16337
+ var getOrderFlag = useRef(false);
16338
+ var _useState = useState(false),
16339
+ _useState2 = _slicedToArray(_useState, 2),
16340
+ isStrict = _useState2[0],
16341
+ setIsStrict = _useState2[1];
16342
+ // TODO: 在修改场景下手动获取一次订单详情中数据
16343
+ useEffect(function () {
16344
+ var _value$typeMap$type$s, _value$typeMap$type$s2, _typeMap$type, _value$typeMap$type$s3, _typeMap$type2;
16345
+ if (!getOrderFlag.current && !(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s = value[(_typeMap$type = typeMap$2[type]) === null || _typeMap$type === void 0 ? void 0 : _typeMap$type.systemOrder]) === null || _value$typeMap$type$s === void 0 ? void 0 : (_value$typeMap$type$s2 = _value$typeMap$type$s.orders) === null || _value$typeMap$type$s2 === void 0 ? void 0 : _value$typeMap$type$s2.length) && (value === null || value === void 0 ? void 0 : (_value$typeMap$type$s3 = value[(_typeMap$type2 = typeMap$2[type]) === null || _typeMap$type2 === void 0 ? void 0 : _typeMap$type2.systemOrder]) === null || _value$typeMap$type$s3 === void 0 ? void 0 : _value$typeMap$type$s3.orderNo)) {
16346
+ var _value$typeMap$type$s4, _typeMap$type3;
16347
+ getOrderFlag.current = true;
16348
+ getOrderList(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s4 = value[(_typeMap$type3 = typeMap$2[type]) === null || _typeMap$type3 === void 0 ? void 0 : _typeMap$type3.systemOrder]) === null || _value$typeMap$type$s4 === void 0 ? void 0 : _value$typeMap$type$s4.orderNo);
16349
+ }
16350
+ return;
16351
+ }, [value]);
16352
+ // useEffect(() => {
16353
+ // const systemOrderNo = value?.[typeMap[type]?.systemOrderNo];
16354
+ // if (systemOrderNo) {
16355
+ // if (['1'].includes(value?.[typeMap[type]?.typeName]?.[0])) {
16356
+ // onChange?.({
16357
+ // ...value,
16358
+ // [typeMap[type]?.key]: getGoodDetails({
16359
+ // mode: isStrict
16360
+ // })
16361
+ // })
16362
+ // }
16363
+ // }
16364
+ // return;
16365
+ // }, [value?.[typeMap[type]?.systemOrderNo]]);
16366
+ var getOrderList = /*#__PURE__*/function () {
16367
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderNo) {
16368
+ var _typeMap$type4;
16369
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
16370
+ while (1) switch (_context.prev = _context.next) {
16371
+ case 0:
16372
+ (_typeMap$type4 = typeMap$2[type]) === null || _typeMap$type4 === void 0 ? void 0 : _typeMap$type4.getOrderList(orderNo).then(function (data) {
16373
+ var _typeMap$type5, _typeMap$type6;
16374
+ var orders = (data === null || data === void 0 ? void 0 : data.orderList) || [];
16375
+ var showOrderInfo = orders.map(function (_ref2) {
16376
+ var orderSn = _ref2.orderSn;
16377
+ return {
16378
+ billNo: orderSn
16379
+ };
16380
+ });
16381
+ onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type5 = typeMap$2[type]) === null || _typeMap$type5 === void 0 ? void 0 : _typeMap$type5.systemOrder, _objectSpread2(_objectSpread2({}, value[(_typeMap$type6 = typeMap$2[type]) === null || _typeMap$type6 === void 0 ? void 0 : _typeMap$type6.systemOrder]), {}, {
16382
+ showOrderInfo: showOrderInfo,
16383
+ orders: orders
16384
+ }))));
16385
+ });
16386
+ case 1:
16387
+ case "end":
16388
+ return _context.stop();
16389
+ }
16390
+ }, _callee);
16391
+ }));
16392
+ return function getOrderList(_x) {
16393
+ return _ref.apply(this, arguments);
16394
+ };
16395
+ }();
16396
+ var changeTypeHandle = function changeTypeHandle(val) {
16397
+ var _typeMap$type7;
16398
+ var typeName = val === null || val === void 0 ? void 0 : val[0];
16399
+ // if (typeName === value?.[typeMap[type]?.typeName]?.[0]) return
16400
+ // const systemOrderNo = value?.[typeMap[type]?.systemOrderNo];
16401
+ var newValue = _objectSpread2({}, value);
16402
+ newValue[(_typeMap$type7 = typeMap$2[type]) === null || _typeMap$type7 === void 0 ? void 0 : _typeMap$type7.typeName] = val;
16403
+ if (typeName === '1') {
16404
+ var _typeMap$type8;
16405
+ newValue[(_typeMap$type8 = typeMap$2[type]) === null || _typeMap$type8 === void 0 ? void 0 : _typeMap$type8.key] = getGoodDetails({
16406
+ mode: isStrict
16407
+ });
16408
+ } else if (typeName === '2') {
16409
+ var _typeMap$type9;
16410
+ // 切换到非原单,清空列表
16411
+ newValue[(_typeMap$type9 = typeMap$2[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.key] = [];
16412
+ }
16413
+ onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
16414
+ };
16415
+ var handleModeChange = function handleModeChange(mode) {
16416
+ var _value$typeMap$type$t, _typeMap$type10, _typeMap$type11;
16417
+ var isOriginalOrder = (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t = value[(_typeMap$type10 = typeMap$2[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.typeName]) === null || _value$typeMap$type$t === void 0 ? void 0 : _value$typeMap$type$t[0]) === '1';
16418
+ setIsStrict(mode);
16419
+ if (!isOriginalOrder) return;
16420
+ onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type11 = typeMap$2[type]) === null || _typeMap$type11 === void 0 ? void 0 : _typeMap$type11.key, getGoodDetails({
16421
+ mode: mode
16422
+ }))));
16423
+ };
16424
+ var getGoodDetails = function getGoodDetails(_ref3) {
16425
+ var _typeMap$type12, _typeMap$type13, _order$orderDetailGet;
16426
+ var mode = _ref3.mode,
16427
+ sysOrderNo = _ref3.sysOrderNo;
16428
+ var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type12 = typeMap$2[type]) === null || _typeMap$type12 === void 0 ? void 0 : _typeMap$type12.systemOrder];
16429
+ var systemOrderNo = sysOrderNo !== null && sysOrderNo !== void 0 ? sysOrderNo : value === null || value === void 0 ? void 0 : value[(_typeMap$type13 = typeMap$2[type]) === null || _typeMap$type13 === void 0 ? void 0 : _typeMap$type13.systemOrderNo];
16430
+ var order = systemOrderNo && ((systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orders) || []).find(function (order) {
16431
+ return order.orderSn === systemOrderNo;
16432
+ });
16433
+ var goodDetails = (order === null || order === void 0 ? void 0 : (_order$orderDetailGet = order.orderDetailGets) === null || _order$orderDetailGet === void 0 ? void 0 : _order$orderDetailGet.length) ? updateBsE3GoodsHandle([order]) : [];
16434
+ var orderNo = systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orderNo;
16435
+ return mode ? goodDetails.filter(function (goodItem) {
16436
+ return !orderNo || goodItem.originalOrderSn === orderNo;
16437
+ }) : goodDetails;
16438
+ };
16439
+ var changeGoodHandle = function changeGoodHandle(val) {
16440
+ var _typeMap$type14;
16441
+ var newValue = _objectSpread2({}, value);
16442
+ newValue["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type14 = typeMap$2[type]) === null || _typeMap$type14 === void 0 ? void 0 : _typeMap$type14.key)] = val || [];
16443
+ onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
16444
+ };
16445
+ var changeSystemOrderHandle = function changeSystemOrderHandle(val) {
16446
+ var _typeMap$type15, _value$typeMap$type$t2, _typeMap$type16, _value$typeMap$type$t3, _typeMap$type18;
16447
+ var newValue = _objectSpread2({}, value);
16448
+ newValue["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type15 = typeMap$2[type]) === null || _typeMap$type15 === void 0 ? void 0 : _typeMap$type15.systemOrderNo)] = val;
16449
+ if (['2'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t2 = value[(_typeMap$type16 = typeMap$2[type]) === null || _typeMap$type16 === void 0 ? void 0 : _typeMap$type16.typeName]) === null || _value$typeMap$type$t2 === void 0 ? void 0 : _value$typeMap$type$t2[0])) {
16450
+ var _typeMap$type17;
16451
+ newValue["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type17 = typeMap$2[type]) === null || _typeMap$type17 === void 0 ? void 0 : _typeMap$type17.key)] = [];
16452
+ } else if (['1'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t3 = value[(_typeMap$type18 = typeMap$2[type]) === null || _typeMap$type18 === void 0 ? void 0 : _typeMap$type18.typeName]) === null || _value$typeMap$type$t3 === void 0 ? void 0 : _value$typeMap$type$t3[0])) {
16453
+ var _typeMap$type19;
16454
+ newValue["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type19 = typeMap$2[type]) === null || _typeMap$type19 === void 0 ? void 0 : _typeMap$type19.key)] = getGoodDetails({
16455
+ mode: isStrict,
16456
+ sysOrderNo: val
16457
+ });
16458
+ }
16459
+ onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
16460
+ };
16461
+ //显示选择商品按钮 原单换不显示选择商品
16462
+ var showChangeBtn = useMemo(function () {
16463
+ var _typeMap$type20;
16464
+ return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type20 = typeMap$2[type]) === null || _typeMap$type20 === void 0 ? void 0 : _typeMap$type20.systemOrderNo]);
16465
+ }, [value === null || value === void 0 ? void 0 : value[(_typeMap$type21 = typeMap$2[type]) === null || _typeMap$type21 === void 0 ? void 0 : _typeMap$type21.systemOrderNo]]);
16466
+ var selectedGoodsChange = useCallback(function (skuList) {
16467
+ var _typeMap$type22, _typeMap$type23, _uniqBy;
16468
+ var newValue = _objectSpread2({}, value);
16469
+ // 原订单商品
16470
+ var originTradeGoodList = getGoodDetails({
16471
+ mode: isStrict
16472
+ }) || [];
16473
+ // 当前选中的所有商品【包含了原订单+商品库】
16474
+ var currentSelectGoodList = (value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type22 = typeMap$2[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.key)]) || [];
16475
+ newValue["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type23 = typeMap$2[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.key)] = (_uniqBy = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
16476
+ return skuList.includes(item.uuid);
16477
+ });
16478
+ onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
16479
+ }, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type24 = typeMap$2[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.key)], isStrict]);
16480
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
16481
+ gutter: 8,
16482
+ wrap: true,
16483
+ id: "bsE3ReissueGoods"
16484
+ }, /*#__PURE__*/React.createElement(Col, {
16485
+ className: "gutter-row",
16486
+ xs: {
16487
+ span: 11
16488
+ },
16489
+ sm: {
16490
+ span: 6
16491
+ }
16492
+ }, /*#__PURE__*/React.createElement(Select, {
16493
+ style: {
16494
+ marginBottom: '8px'
16495
+ },
16496
+ disabled: disabled,
16497
+ allowClear: false,
16498
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type25 = typeMap$2[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.systemOrderNo)],
16499
+ onChange: function onChange(val) {
16500
+ return changeSystemOrderHandle(val);
16501
+ },
16502
+ placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
16503
+ }, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type26 = typeMap$2[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
16504
+ return /*#__PURE__*/React.createElement(Select.Option, {
16505
+ key: item.billNo,
16506
+ value: item.billNo,
16507
+ label: item.billNo
16508
+ }, item.billNo);
16509
+ }))), /*#__PURE__*/React.createElement(Col, {
16510
+ className: "gutter-row",
16511
+ xs: {
16512
+ span: 11
16513
+ },
16514
+ sm: {
16515
+ span: 6
16516
+ }
16517
+ }, /*#__PURE__*/React.createElement(Cascader, {
16518
+ style: {
16519
+ marginBottom: '8px'
16520
+ },
16521
+ disabled: disabled,
16522
+ allowClear: false,
16523
+ options: reasonList,
16524
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type27 = typeMap$2[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.typeName)],
16525
+ onChange: function onChange(val) {
16526
+ return changeTypeHandle(val);
16527
+ }
16528
+ }))), /*#__PURE__*/React.createElement(GoodItem$1, _objectSpread2(_objectSpread2({
16529
+ key: 'reissueGoods'
16530
+ }, other), {}, {
16531
+ type: type,
16532
+ disabled: disabled,
16533
+ canUpdateNumber: showChangeBtn,
16534
+ showChangeBtn: showChangeBtn,
16535
+ shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
16536
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type28 = typeMap$2[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.key)],
16537
+ onChange: function onChange(val) {
16538
+ return changeGoodHandle(val);
16539
+ },
16540
+ onModeChange: handleModeChange,
16541
+ showModeBtn: false,
16542
+ isStrict: isStrict,
16543
+ tradeGoods: {
16544
+ originDataSource: getGoodDetails({
16545
+ mode: isStrict
16546
+ }),
16547
+ selectedGoodsChange: selectedGoodsChange
16548
+ }
16549
+ })));
16550
+ };
16551
+
16552
+ 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, index as ApaasUploadAsync, ApaasUploadFile, bsE3Reissue as BsE3Reissue, BsExchange, BsGoods, BsReissue, BsReturnGoods as BsReturn, index$1 as BsSystemOrder, BuyerNick, CalculationInput, ChooseBaby, CommonExchangeGoods, CommonGoods, CommonSystemOrder$1 as CommonMultiStatus, CommonReturnGoods, CommonStatus, CommonSystemOrder, ExpressLogistics, Goods, index$2 as GoodsTable, IdentifyAddress, Invoice, jstGoods as JstGoods, ItemList as JstItemList, LogisticsInterception, LogisticsMoreInterception, LogisticsMoreTrajectory, LogisticsTrajectory, MsgStatus, ParseLogistics, Payment, RemarkInput as Remark, ExpressLogistics as ReturnLogistics, ShopNameSelect as ShopName, Status, SubForm, Supplier, TBGoodId, TBGoodSerial, TradeId, WdtGoodList, wdtReissue as WdtReissue, WlnGoods };