@kmkf-fe-packages/basic-components 1.26.0 → 1.27.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 +1379 -440
- package/dist/index.js +1378 -438
- package/dist/src/apaas/ApaasLogistics/index.d.ts +1 -0
- package/dist/src/bs/component/model/GyGoodsList.d.ts +36 -0
- package/dist/src/bs/component/model/GyGoodsModal.d.ts +12 -0
- package/dist/src/constants/bs.d.ts +3 -0
- package/dist/src/constants/defaultColumns.d.ts +3 -0
- package/dist/src/constants/gy.d.ts +3 -0
- package/dist/src/gy/Reissue/index.d.ts +3 -0
- package/dist/src/gy/common/index.d.ts +3 -0
- package/dist/src/index.d.ts +1 -0
- package/dist/src/jst/Goods/index.d.ts +1 -0
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -7373,7 +7373,8 @@ var Province = function Province(props) {
|
|
|
7373
7373
|
var mapping = {
|
|
7374
7374
|
workOrder: kmkfUtils.AddressData.getInstance(),
|
|
7375
7375
|
bs: kmkfUtils.BsAddressData.getInstance(),
|
|
7376
|
-
wdt: kmkfUtils.WdtAddressData.getInstance()
|
|
7376
|
+
wdt: kmkfUtils.WdtAddressData.getInstance(),
|
|
7377
|
+
gy: kmkfUtils.GyAddressData.getInstance()
|
|
7377
7378
|
};
|
|
7378
7379
|
return /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement(antd.Cascader, _objectSpread2(_objectSpread2({}, props), {}, {
|
|
7379
7380
|
options: ((_mapping$type = mapping[type]) === null || _mapping$type === void 0 ? void 0 : _mapping$type.addressOptions) || [],
|
|
@@ -7478,6 +7479,7 @@ var IdentifyAddress = function IdentifyAddress(props) {
|
|
|
7478
7479
|
var addressData = (type && {
|
|
7479
7480
|
bs: kmkfUtils.BsAddressData,
|
|
7480
7481
|
wdt: kmkfUtils.WdtAddressData,
|
|
7482
|
+
gy: kmkfUtils.GyAddressData,
|
|
7481
7483
|
workOrder: kmkfUtils.AddressData
|
|
7482
7484
|
}[type] || kmkfUtils.AddressData).getInstance();
|
|
7483
7485
|
if ((val === null || val === void 0 ? void 0 : val.province) && addressData.getProCodeByName(val === null || val === void 0 ? void 0 : val.province)) {
|
|
@@ -7559,11 +7561,13 @@ function ApaasPosting(props) {
|
|
|
7559
7561
|
});
|
|
7560
7562
|
}
|
|
7561
7563
|
|
|
7562
|
-
var _excluded$a = ["value", "onChange", "platformType"];
|
|
7564
|
+
var _excluded$a = ["value", "onChange", "platformType", "type"];
|
|
7563
7565
|
function ApaasLogistics(props) {
|
|
7564
7566
|
var value = props.value,
|
|
7565
7567
|
onChange = props.onChange,
|
|
7566
7568
|
platformType = props.platformType,
|
|
7569
|
+
_props$type = props.type,
|
|
7570
|
+
type = _props$type === void 0 ? 'select' : _props$type,
|
|
7567
7571
|
other = _objectWithoutProperties(props, _excluded$a);
|
|
7568
7572
|
var _useState = React.useState([]),
|
|
7569
7573
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -7594,7 +7598,14 @@ function ApaasLogistics(props) {
|
|
|
7594
7598
|
isFirst.current = true;
|
|
7595
7599
|
}
|
|
7596
7600
|
}, []);
|
|
7597
|
-
|
|
7601
|
+
var handleInputChange = function handleInputChange(e) {
|
|
7602
|
+
var val = e.target.value;
|
|
7603
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(val);
|
|
7604
|
+
};
|
|
7605
|
+
return type === 'input' ? /*#__PURE__*/React__default['default'].createElement(antd.Input, _objectSpread2(_objectSpread2({}, other), {}, {
|
|
7606
|
+
value: value,
|
|
7607
|
+
onChange: handleInputChange
|
|
7608
|
+
})) : /*#__PURE__*/React__default['default'].createElement(antd.Select, _objectSpread2(_objectSpread2({}, other), {}, {
|
|
7598
7609
|
value: value,
|
|
7599
7610
|
onChange: onChange,
|
|
7600
7611
|
options: option,
|
|
@@ -8128,11 +8139,6 @@ function ApaasAddress(props) {
|
|
|
8128
8139
|
};
|
|
8129
8140
|
var addressData = type === 'bs' ? kmkfUtils.BsAddressData.getInstance() : kmkfUtils.AddressData.getInstance();
|
|
8130
8141
|
if ((val === null || val === void 0 ? void 0 : val.province) && addressData.getProCodeByName(val === null || val === void 0 ? void 0 : val.province)) {
|
|
8131
|
-
// params.address = [
|
|
8132
|
-
// addressData.getProCodeByName(val?.province),
|
|
8133
|
-
// addressData.getProCodeByName(val?.city),
|
|
8134
|
-
// addressData.getProCodeByName(val?.district),
|
|
8135
|
-
// ];
|
|
8136
8142
|
params.address = addressData.getCodesByNames([val === null || val === void 0 ? void 0 : val.province, val === null || val === void 0 ? void 0 : val.city, val === null || val === void 0 ? void 0 : val.district]);
|
|
8137
8143
|
}
|
|
8138
8144
|
onChange === null || onChange === void 0 ? void 0 : onChange(params);
|
|
@@ -11024,13 +11030,15 @@ var jstGoods = function jstGoods(props) {
|
|
|
11024
11030
|
_props$showField = props.showField,
|
|
11025
11031
|
showField = _props$showField === void 0 ? '' : _props$showField,
|
|
11026
11032
|
_props$platformType = props.platformType,
|
|
11027
|
-
platformType = _props$platformType === void 0 ? 'default' : _props$platformType
|
|
11033
|
+
platformType = _props$platformType === void 0 ? 'default' : _props$platformType,
|
|
11034
|
+
onlyShowFieldSelect = props.onlyShowFieldSelect;
|
|
11028
11035
|
var _useState = React.useState(0),
|
|
11029
11036
|
_useState2 = _slicedToArray(_useState, 2),
|
|
11030
11037
|
changeIndex = _useState2[0],
|
|
11031
11038
|
setChangeIndex = _useState2[1]; //选中的包裹
|
|
11032
11039
|
var sendOptions = kmkfUtils.SendDataCenter.getInstance(platformType).getSendData();
|
|
11033
|
-
var isSelectName = ['wdt', 'bsE3', 'km'].includes(platformType);
|
|
11040
|
+
var isSelectName = ['wdt', 'bsE3', 'km', 'gy'].includes(platformType);
|
|
11041
|
+
var logisticsType = type === 1 && platformType === 'gy' ? 'input' : 'select';
|
|
11034
11042
|
React.useEffect(function () {
|
|
11035
11043
|
//没有值塞个默认值
|
|
11036
11044
|
if (!(value === null || value === void 0 ? void 0 : value.length) && type !== 1) {
|
|
@@ -11062,10 +11070,12 @@ var jstGoods = function jstGoods(props) {
|
|
|
11062
11070
|
}), /*#__PURE__*/React__default['default'].createElement("div", null, /*#__PURE__*/React__default['default'].createElement("div", null, t.title), /*#__PURE__*/React__default['default'].createElement("div", null, "\u7F16\u7801\uFF1A", t.skuId))));
|
|
11063
11071
|
}));
|
|
11064
11072
|
};
|
|
11065
|
-
var handleSelected = function handleSelected(val, type, option) {
|
|
11073
|
+
var handleSelected = function handleSelected(val, type, option, onlyShowFieldSelect) {
|
|
11066
11074
|
var changeOrderInfo = _objectSpread2({}, value[changeIndex]);
|
|
11067
11075
|
changeOrderInfo[type] = val;
|
|
11068
|
-
|
|
11076
|
+
if (!onlyShowFieldSelect) {
|
|
11077
|
+
changeOrderInfo['sendId'] = option.value;
|
|
11078
|
+
}
|
|
11069
11079
|
if (isSelectName && type === 'sendName') {
|
|
11070
11080
|
changeOrderInfo['sendSnapshotName'] = option.label;
|
|
11071
11081
|
}
|
|
@@ -11104,24 +11114,32 @@ var jstGoods = function jstGoods(props) {
|
|
|
11104
11114
|
return setChangeIndex(index);
|
|
11105
11115
|
}
|
|
11106
11116
|
}, "\u5305\u88F9".concat(index + 1)));
|
|
11107
|
-
}))) : null, value.length || type === 1 ? /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, type === 1 ? /*#__PURE__*/React__default['default'].createElement(antd.Space, null, !showField || showField === 'logisticsCompany' ? /*#__PURE__*/React__default['default'].createElement(ApaasLogistics, {
|
|
11117
|
+
}))) : null, value.length || type === 1 ? /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, type === 1 ? /*#__PURE__*/React__default['default'].createElement(antd.Space, null, !showField || showField === 'logisticsCompany' ? /*#__PURE__*/React__default['default'].createElement(ApaasLogistics, _objectSpread2(_objectSpread2({
|
|
11118
|
+
type: logisticsType,
|
|
11108
11119
|
disabled: disabled,
|
|
11109
11120
|
placeholder: "\u7269\u6D41\u516C\u53F8",
|
|
11110
11121
|
onChange: function onChange(val) {
|
|
11111
|
-
|
|
11122
|
+
if (logisticsType === 'input') {
|
|
11123
|
+
changeInputHandle(null, 'logisticsCompany');
|
|
11124
|
+
changeInputHandle(val, 'logisticsCompanyName');
|
|
11125
|
+
} else {
|
|
11126
|
+
changeInputHandle(val, 'logisticsCompany');
|
|
11127
|
+
}
|
|
11112
11128
|
},
|
|
11113
|
-
value: (_value$changeIndex = value[changeIndex]) === null || _value$changeIndex === void 0 ? void 0 : _value$changeIndex
|
|
11129
|
+
value: (_value$changeIndex = value[changeIndex]) === null || _value$changeIndex === void 0 ? void 0 : _value$changeIndex[logisticsType === 'input' ? 'logisticsCompanyName' : 'logisticsCompany']
|
|
11130
|
+
}, logisticsType === 'input' ? {} : {
|
|
11114
11131
|
showSearch: true,
|
|
11132
|
+
dropdownMatchSelectWidth: false,
|
|
11115
11133
|
filterOption: function filterOption(input, option) {
|
|
11116
11134
|
return option.label.includes(input);
|
|
11117
|
-
}
|
|
11118
|
-
|
|
11135
|
+
}
|
|
11136
|
+
}), {}, {
|
|
11119
11137
|
style: {
|
|
11120
11138
|
minWidth: '100px',
|
|
11121
11139
|
maxWidth: '180px'
|
|
11122
11140
|
},
|
|
11123
11141
|
platformType: platformType
|
|
11124
|
-
}) : null, !showField || showField === 'logisticsCode' ? /*#__PURE__*/React__default['default'].createElement(antd.Input, {
|
|
11142
|
+
})) : null, !showField || showField === 'logisticsCode' ? /*#__PURE__*/React__default['default'].createElement(antd.Input, {
|
|
11125
11143
|
disabled: disabled,
|
|
11126
11144
|
placeholder: "\u7269\u6D41\u5355\u53F7",
|
|
11127
11145
|
onChange: function onChange(e) {
|
|
@@ -11161,7 +11179,7 @@ var jstGoods = function jstGoods(props) {
|
|
|
11161
11179
|
filterOption: filterOption,
|
|
11162
11180
|
value: ((_value$changeIndex6 = value[changeIndex]) === null || _value$changeIndex6 === void 0 ? void 0 : _value$changeIndex6.sendName) || null,
|
|
11163
11181
|
onChange: function onChange(value, option) {
|
|
11164
|
-
return handleSelected(value, 'sendName', option);
|
|
11182
|
+
return handleSelected(value, 'sendName', option, onlyShowFieldSelect);
|
|
11165
11183
|
}
|
|
11166
11184
|
}) : /*#__PURE__*/React__default['default'].createElement(antd.Input, {
|
|
11167
11185
|
disabled: disabled,
|
|
@@ -12505,102 +12523,435 @@ var GoodsModal$4 = function GoodsModal(props, ref) {
|
|
|
12505
12523
|
};
|
|
12506
12524
|
var BsE3GoodsModal = /*#__PURE__*/React.forwardRef(GoodsModal$4);
|
|
12507
12525
|
|
|
12508
|
-
var
|
|
12509
|
-
var
|
|
12510
|
-
|
|
12511
|
-
|
|
12512
|
-
|
|
12513
|
-
|
|
12514
|
-
|
|
12515
|
-
|
|
12516
|
-
|
|
12517
|
-
|
|
12518
|
-
|
|
12519
|
-
|
|
12520
|
-
|
|
12521
|
-
|
|
12522
|
-
|
|
12523
|
-
},
|
|
12524
|
-
|
|
12525
|
-
|
|
12526
|
-
|
|
12527
|
-
|
|
12528
|
-
|
|
12529
|
-
|
|
12530
|
-
|
|
12531
|
-
|
|
12532
|
-
|
|
12533
|
-
|
|
12534
|
-
|
|
12535
|
-
|
|
12536
|
-
|
|
12537
|
-
|
|
12538
|
-
|
|
12539
|
-
|
|
12540
|
-
|
|
12541
|
-
|
|
12542
|
-
|
|
12543
|
-
|
|
12544
|
-
|
|
12545
|
-
|
|
12546
|
-
width: 150
|
|
12547
|
-
}, {
|
|
12548
|
-
dataIndex: 'colorCode',
|
|
12549
|
-
title: "\u989C\u8272\u4EE3\u7801",
|
|
12550
|
-
width: 150
|
|
12551
|
-
}, {
|
|
12552
|
-
dataIndex: 'sizeName',
|
|
12553
|
-
title: "\u5C3A\u7801\u540D\u79F0",
|
|
12554
|
-
width: 150
|
|
12555
|
-
}, {
|
|
12556
|
-
dataIndex: 'sizeCode',
|
|
12557
|
-
title: "\u5C3A\u7801\u4EE3\u7801",
|
|
12558
|
-
width: 150
|
|
12559
|
-
}, {
|
|
12560
|
-
dataIndex: 'brandName',
|
|
12561
|
-
title: "\u54C1\u724C\u540D\u79F0",
|
|
12562
|
-
width: 150
|
|
12563
|
-
}, {
|
|
12564
|
-
dataIndex: 'goodsNumber',
|
|
12565
|
-
title: "\u5546\u54C1\u6570\u91CF",
|
|
12566
|
-
width: 150
|
|
12567
|
-
}, {
|
|
12568
|
-
dataIndex: 'goodsPrice',
|
|
12569
|
-
title: "\u5546\u54C1\u5355\u4EF7",
|
|
12570
|
-
width: 150
|
|
12571
|
-
}, {
|
|
12572
|
-
dataIndex: 'shopPrice',
|
|
12573
|
-
title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
|
|
12574
|
-
width: 150
|
|
12575
|
-
}, {
|
|
12576
|
-
dataIndex: 'isGift',
|
|
12577
|
-
title: "\u662F\u5426\u8D60\u54C1",
|
|
12578
|
-
width: 150,
|
|
12579
|
-
render: function render(val) {
|
|
12580
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, +val ? '是' : '否');
|
|
12526
|
+
var getTableData$2 = function getTableData(_ref, formData) {
|
|
12527
|
+
var current = _ref.current,
|
|
12528
|
+
pageSize = _ref.pageSize;
|
|
12529
|
+
var data = {
|
|
12530
|
+
skuName: formData.skuName || null,
|
|
12531
|
+
skuCode: formData.skuCode || null,
|
|
12532
|
+
goodName: formData.goodName || null,
|
|
12533
|
+
goodNo: formData.goodNo || null
|
|
12534
|
+
};
|
|
12535
|
+
return extendRequest('/qy/gdfw/product/product/page', {
|
|
12536
|
+
method: 'post',
|
|
12537
|
+
data: _objectSpread2({
|
|
12538
|
+
pageSize: pageSize,
|
|
12539
|
+
pageNo: current,
|
|
12540
|
+
platform: 'GY_ERP'
|
|
12541
|
+
}, data)
|
|
12542
|
+
}).then(function (res) {
|
|
12543
|
+
var _res$data = res.data,
|
|
12544
|
+
_res$data$productSkuL = _res$data.productSkuList,
|
|
12545
|
+
productSkuList = _res$data$productSkuL === void 0 ? [] : _res$data$productSkuL,
|
|
12546
|
+
_res$data$total = _res$data.total,
|
|
12547
|
+
total = _res$data$total === void 0 ? 0 : _res$data$total;
|
|
12548
|
+
var newProducts = productSkuList.map(function (item, index) {
|
|
12549
|
+
return _objectSpread2({}, item);
|
|
12550
|
+
});
|
|
12551
|
+
return {
|
|
12552
|
+
total: total,
|
|
12553
|
+
list: newProducts
|
|
12554
|
+
};
|
|
12555
|
+
});
|
|
12556
|
+
};
|
|
12557
|
+
var columns$3 = [{
|
|
12558
|
+
dataIndex: 'index',
|
|
12559
|
+
title: 'NO',
|
|
12560
|
+
render: function render(val, record, index) {
|
|
12561
|
+
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
12562
|
+
style: {
|
|
12563
|
+
width: 25
|
|
12581
12564
|
}
|
|
12582
|
-
}
|
|
12583
|
-
|
|
12584
|
-
|
|
12585
|
-
|
|
12586
|
-
|
|
12587
|
-
|
|
12588
|
-
|
|
12565
|
+
}, index + 1);
|
|
12566
|
+
},
|
|
12567
|
+
width: 80
|
|
12568
|
+
}, {
|
|
12569
|
+
dataIndex: 'specName',
|
|
12570
|
+
title: 'SKU名称',
|
|
12571
|
+
width: 250,
|
|
12572
|
+
ellipsis: true
|
|
12573
|
+
}, {
|
|
12574
|
+
dataIndex: 'specNo',
|
|
12575
|
+
title: 'SKU编码',
|
|
12576
|
+
width: 200,
|
|
12577
|
+
ellipsis: true
|
|
12578
|
+
}, {
|
|
12579
|
+
dataIndex: 'goodName',
|
|
12580
|
+
title: '商品名称',
|
|
12581
|
+
width: 250,
|
|
12582
|
+
ellipsis: true
|
|
12583
|
+
}, {
|
|
12584
|
+
dataIndex: 'goodShortName',
|
|
12585
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12586
|
+
ellipsis: true,
|
|
12587
|
+
width: 250
|
|
12588
|
+
}, {
|
|
12589
|
+
dataIndex: 'goodNo',
|
|
12590
|
+
title: '商品编码',
|
|
12591
|
+
width: 200,
|
|
12592
|
+
ellipsis: true
|
|
12593
|
+
}, {
|
|
12594
|
+
dataIndex: 'goodPicUrl',
|
|
12595
|
+
title: '商品图片',
|
|
12596
|
+
width: 100,
|
|
12597
|
+
render: function render(picUrl) {
|
|
12598
|
+
return /*#__PURE__*/React__default['default'].createElement("img", {
|
|
12599
|
+
style: {
|
|
12600
|
+
width: '40px',
|
|
12601
|
+
height: '40px',
|
|
12602
|
+
objectFit: 'contain'
|
|
12603
|
+
},
|
|
12604
|
+
src: picUrl
|
|
12605
|
+
});
|
|
12606
|
+
}
|
|
12607
|
+
}, {
|
|
12608
|
+
dataIndex: 'brandName',
|
|
12609
|
+
title: '品牌名称',
|
|
12610
|
+
width: 200,
|
|
12611
|
+
ellipsis: true
|
|
12612
|
+
}, {
|
|
12613
|
+
dataIndex: 'retailPrice',
|
|
12614
|
+
title: "\u6807\u51C6\u552E\u4EF7",
|
|
12615
|
+
ellipsis: true,
|
|
12616
|
+
width: 100
|
|
12617
|
+
}, {
|
|
12618
|
+
dataIndex: 'costPrice',
|
|
12619
|
+
title: "\u6210\u672C\u4EF7",
|
|
12620
|
+
ellipsis: true,
|
|
12621
|
+
width: 100
|
|
12622
|
+
}];
|
|
12623
|
+
var GoodList$2 = function GoodList(props, ref) {
|
|
12624
|
+
var _useState = React.useState([]),
|
|
12625
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
12626
|
+
selectList = _useState2[0],
|
|
12627
|
+
setSelect = _useState2[1];
|
|
12628
|
+
var _useState3 = React.useState([]),
|
|
12629
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
12630
|
+
selectIds = _useState4[0],
|
|
12631
|
+
setSelectIds = _useState4[1];
|
|
12632
|
+
React.useImperativeHandle(ref, function () {
|
|
12633
|
+
return {
|
|
12634
|
+
getSelectGoodList: function getSelectGoodList() {
|
|
12635
|
+
return selectList;
|
|
12636
|
+
}
|
|
12637
|
+
};
|
|
12638
|
+
});
|
|
12639
|
+
var _Form$useForm = antd.Form.useForm(),
|
|
12640
|
+
_Form$useForm2 = _slicedToArray(_Form$useForm, 1),
|
|
12641
|
+
form = _Form$useForm2[0];
|
|
12642
|
+
var _useAntdTable = ahooks.useAntdTable(getTableData$2, {
|
|
12643
|
+
defaultPageSize: 10,
|
|
12644
|
+
form: form
|
|
12645
|
+
}),
|
|
12646
|
+
tableProps = _useAntdTable.tableProps,
|
|
12647
|
+
search = _useAntdTable.search,
|
|
12648
|
+
params = _useAntdTable.params;
|
|
12649
|
+
var submit = search.submit,
|
|
12650
|
+
reset = search.reset;
|
|
12651
|
+
var advanceSearchForm = /*#__PURE__*/React__default['default'].createElement(antd.Form, {
|
|
12652
|
+
layout: "inline",
|
|
12653
|
+
form: form
|
|
12654
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Form.Item, {
|
|
12655
|
+
name: "skuName",
|
|
12656
|
+
style: {
|
|
12657
|
+
marginBottom: '12px'
|
|
12658
|
+
}
|
|
12659
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Input, {
|
|
12660
|
+
placeholder: "\u5546\u54C1sku\u540D\u79F0",
|
|
12661
|
+
allowClear: true,
|
|
12662
|
+
style: {
|
|
12589
12663
|
width: 150
|
|
12590
|
-
}
|
|
12591
|
-
|
|
12592
|
-
|
|
12593
|
-
|
|
12594
|
-
|
|
12664
|
+
}
|
|
12665
|
+
})), /*#__PURE__*/React__default['default'].createElement(antd.Form.Item, {
|
|
12666
|
+
name: "skuCode",
|
|
12667
|
+
style: {
|
|
12668
|
+
marginBottom: '12px'
|
|
12669
|
+
}
|
|
12670
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Input, {
|
|
12671
|
+
placeholder: "\u5546\u54C1sku\u7F16\u7801",
|
|
12672
|
+
allowClear: true,
|
|
12673
|
+
style: {
|
|
12595
12674
|
width: 150
|
|
12596
|
-
}
|
|
12597
|
-
|
|
12598
|
-
|
|
12599
|
-
|
|
12600
|
-
|
|
12675
|
+
}
|
|
12676
|
+
})), /*#__PURE__*/React__default['default'].createElement(antd.Form.Item, {
|
|
12677
|
+
name: "goodName",
|
|
12678
|
+
style: {
|
|
12679
|
+
marginBottom: '12px'
|
|
12680
|
+
}
|
|
12681
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Input, {
|
|
12682
|
+
placeholder: "\u5546\u54C1\u540D\u79F0",
|
|
12683
|
+
allowClear: true,
|
|
12684
|
+
style: {
|
|
12601
12685
|
width: 150
|
|
12602
|
-
}
|
|
12603
|
-
|
|
12686
|
+
}
|
|
12687
|
+
})), /*#__PURE__*/React__default['default'].createElement(antd.Form.Item, {
|
|
12688
|
+
name: "goodNo",
|
|
12689
|
+
style: {
|
|
12690
|
+
marginBottom: '12px'
|
|
12691
|
+
}
|
|
12692
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Input, {
|
|
12693
|
+
placeholder: "\u5546\u54C1\u7F16\u7801",
|
|
12694
|
+
allowClear: true,
|
|
12695
|
+
style: {
|
|
12696
|
+
width: 150
|
|
12697
|
+
}
|
|
12698
|
+
})), /*#__PURE__*/React__default['default'].createElement(antd.Form.Item, {
|
|
12699
|
+
style: {
|
|
12700
|
+
marginBottom: '12px'
|
|
12701
|
+
}
|
|
12702
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Button, {
|
|
12703
|
+
type: "primary",
|
|
12704
|
+
style: {
|
|
12705
|
+
marginRight: '8px'
|
|
12706
|
+
},
|
|
12707
|
+
onClick: submit
|
|
12708
|
+
}, "\u67E5\u8BE2"), /*#__PURE__*/React__default['default'].createElement(antd.Button, {
|
|
12709
|
+
onClick: reset
|
|
12710
|
+
}, "\u91CD\u7F6E")));
|
|
12711
|
+
var rowSelection = {
|
|
12712
|
+
selectedRowKeys: selectIds,
|
|
12713
|
+
fixed: true,
|
|
12714
|
+
onSelect: function onSelect(record, selected) {
|
|
12715
|
+
if (selected) {
|
|
12716
|
+
setSelectIds([].concat(_toConsumableArray(selectIds), [record.specNo]));
|
|
12717
|
+
setSelect([].concat(_toConsumableArray(selectList), [record]));
|
|
12718
|
+
} else {
|
|
12719
|
+
setSelectIds(selectIds.filter(function (t) {
|
|
12720
|
+
return t !== record.specNo;
|
|
12721
|
+
}));
|
|
12722
|
+
setSelect(selectList.filter(function (t) {
|
|
12723
|
+
return t.specNo !== record.specNo;
|
|
12724
|
+
}));
|
|
12725
|
+
}
|
|
12726
|
+
},
|
|
12727
|
+
onSelectAll: function onSelectAll(selected, selectedRows, changeRows) {
|
|
12728
|
+
if (selected) {
|
|
12729
|
+
setSelectIds([].concat(_toConsumableArray(selectIds), _toConsumableArray(changeRows.map(function (t) {
|
|
12730
|
+
return t.specNo;
|
|
12731
|
+
}))));
|
|
12732
|
+
setSelect([].concat(_toConsumableArray(selectList), _toConsumableArray(changeRows)));
|
|
12733
|
+
} else {
|
|
12734
|
+
setSelectIds(lodash.difference(selectIds, changeRows.map(function (t) {
|
|
12735
|
+
return t.specNo;
|
|
12736
|
+
})));
|
|
12737
|
+
var list = lodash.differenceWith(selectList, changeRows, function (arrVal, othVal) {
|
|
12738
|
+
return arrVal.specNo !== othVal.specNo;
|
|
12739
|
+
});
|
|
12740
|
+
setSelect(list);
|
|
12741
|
+
}
|
|
12742
|
+
}
|
|
12743
|
+
};
|
|
12744
|
+
var showTable = function showTable() {
|
|
12745
|
+
var handleDelete = function handleDelete(record) {
|
|
12746
|
+
setSelectIds(selectIds.filter(function (t) {
|
|
12747
|
+
return t !== record.specNo;
|
|
12748
|
+
}));
|
|
12749
|
+
setSelect(selectList.filter(function (t) {
|
|
12750
|
+
return t.specNo !== record.specNo;
|
|
12751
|
+
}));
|
|
12752
|
+
};
|
|
12753
|
+
var showColumns = [{
|
|
12754
|
+
dataIndex: '',
|
|
12755
|
+
title: "\u64CD\u4F5C",
|
|
12756
|
+
ellipsis: true,
|
|
12757
|
+
width: 100,
|
|
12758
|
+
render: function render(val, record) {
|
|
12759
|
+
return /*#__PURE__*/React__default['default'].createElement(antd.Button, {
|
|
12760
|
+
type: "link",
|
|
12761
|
+
onClick: function onClick() {
|
|
12762
|
+
return handleDelete(record);
|
|
12763
|
+
}
|
|
12764
|
+
}, "\u5220\u9664");
|
|
12765
|
+
}
|
|
12766
|
+
}].concat(lodash.takeRight(columns$3, columns$3.length - 1));
|
|
12767
|
+
return selectList.length ? /*#__PURE__*/React__default['default'].createElement("div", {
|
|
12768
|
+
style: {
|
|
12769
|
+
width: '100%',
|
|
12770
|
+
maxWidth: '387px'
|
|
12771
|
+
}
|
|
12772
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Table, {
|
|
12773
|
+
columns: showColumns,
|
|
12774
|
+
rowKey: 'specNo',
|
|
12775
|
+
dataSource: selectList,
|
|
12776
|
+
scroll: {
|
|
12777
|
+
x: '100%',
|
|
12778
|
+
y: 250
|
|
12779
|
+
},
|
|
12780
|
+
pagination: {
|
|
12781
|
+
size: 'small',
|
|
12782
|
+
total: selectIds.length,
|
|
12783
|
+
pageSize: 10,
|
|
12784
|
+
showSizeChanger: false
|
|
12785
|
+
}
|
|
12786
|
+
})) : null;
|
|
12787
|
+
};
|
|
12788
|
+
return /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, advanceSearchForm, /*#__PURE__*/React__default['default'].createElement("div", {
|
|
12789
|
+
style: {
|
|
12790
|
+
marginTop: '4px'
|
|
12791
|
+
}
|
|
12792
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Table, _objectSpread2({
|
|
12793
|
+
rowSelection: rowSelection,
|
|
12794
|
+
rowKey: "specNo",
|
|
12795
|
+
columns: columns$3,
|
|
12796
|
+
scroll: {
|
|
12797
|
+
x: '100%',
|
|
12798
|
+
y: 250
|
|
12799
|
+
}
|
|
12800
|
+
}, tableProps))), /*#__PURE__*/React__default['default'].createElement(antd.Popover, {
|
|
12801
|
+
getPopupContainer: function getPopupContainer(triggerNode) {
|
|
12802
|
+
return triggerNode.parentElement;
|
|
12803
|
+
},
|
|
12804
|
+
content: showTable(),
|
|
12805
|
+
title: "\u5DF2\u9009\u62E9".concat(selectList.length, "\u4E2A\u5546\u54C1")
|
|
12806
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Button, {
|
|
12807
|
+
danger: true,
|
|
12808
|
+
type: "text"
|
|
12809
|
+
}, "\u5DF2\u9009".concat(selectList.length > 99 ? '99+' : selectList.length, "\u4E2A\u5546\u54C1"), /*#__PURE__*/React__default['default'].createElement(icons.CaretUpOutlined, null))));
|
|
12810
|
+
};
|
|
12811
|
+
var GyGoodsList = /*#__PURE__*/React.forwardRef(GoodList$2);
|
|
12812
|
+
|
|
12813
|
+
var GyGoodsModal = function GyGoodsModal(props, ref) {
|
|
12814
|
+
React.useImperativeHandle(ref, function () {
|
|
12815
|
+
return {
|
|
12816
|
+
open: function open() {
|
|
12817
|
+
setVisible(true);
|
|
12818
|
+
}
|
|
12819
|
+
};
|
|
12820
|
+
});
|
|
12821
|
+
var onSubmit = props.onSubmit,
|
|
12822
|
+
width = props.width;
|
|
12823
|
+
var _useState = React.useState(false),
|
|
12824
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
12825
|
+
visible = _useState2[0],
|
|
12826
|
+
setVisible = _useState2[1];
|
|
12827
|
+
var gyGoodsListRef = React.useRef(null);
|
|
12828
|
+
var _onCancel = function onCancel() {
|
|
12829
|
+
setVisible(false);
|
|
12830
|
+
};
|
|
12831
|
+
var onOk = function onOk() {
|
|
12832
|
+
var _gyGoodsListRef$curre;
|
|
12833
|
+
var selectedList = ((_gyGoodsListRef$curre = gyGoodsListRef.current) === null || _gyGoodsListRef$curre === void 0 ? void 0 : _gyGoodsListRef$curre.getSelectGoodList()) || [];
|
|
12834
|
+
onSubmit(selectedList);
|
|
12835
|
+
_onCancel();
|
|
12836
|
+
};
|
|
12837
|
+
return /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, visible && /*#__PURE__*/React__default['default'].createElement(antd.Modal, {
|
|
12838
|
+
title: '选择商品',
|
|
12839
|
+
okText: '确认',
|
|
12840
|
+
cancelText: '取消',
|
|
12841
|
+
visible: visible,
|
|
12842
|
+
width: width || 850,
|
|
12843
|
+
onCancel: function onCancel() {
|
|
12844
|
+
_onCancel();
|
|
12845
|
+
},
|
|
12846
|
+
onOk: onOk,
|
|
12847
|
+
wrapClassName: "goodModal"
|
|
12848
|
+
}, /*#__PURE__*/React__default['default'].createElement(GyGoodsList, {
|
|
12849
|
+
ref: gyGoodsListRef
|
|
12850
|
+
})));
|
|
12851
|
+
};
|
|
12852
|
+
var GyGoodsModal$1 = /*#__PURE__*/React.forwardRef(GyGoodsModal);
|
|
12853
|
+
|
|
12854
|
+
var getColumns = function getColumns(_ref) {
|
|
12855
|
+
var _ref$text = _ref.text,
|
|
12856
|
+
disabled = _ref.disabled,
|
|
12857
|
+
updateHandle = _ref.updateHandle;
|
|
12858
|
+
return {
|
|
12859
|
+
//百胜E3补发商品
|
|
12860
|
+
BS_E3_REISSUE_GOODS: [{
|
|
12861
|
+
dataIndex: 'sku',
|
|
12862
|
+
title: "SKU",
|
|
12863
|
+
width: 150
|
|
12864
|
+
}, {
|
|
12865
|
+
dataIndex: 'skuId',
|
|
12866
|
+
title: "SKU ID",
|
|
12867
|
+
width: 150
|
|
12868
|
+
}, {
|
|
12869
|
+
dataIndex: 'goodsName',
|
|
12870
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
12871
|
+
width: 150
|
|
12872
|
+
}, {
|
|
12873
|
+
dataIndex: 'goodsShortName',
|
|
12874
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12875
|
+
width: 150
|
|
12876
|
+
}, {
|
|
12877
|
+
dataIndex: 'picPath',
|
|
12878
|
+
title: "\u5546\u54C1\u56FE\u7247",
|
|
12879
|
+
width: 150,
|
|
12880
|
+
render: function render(val) {
|
|
12881
|
+
return /*#__PURE__*/React__default['default'].createElement(antd.Image, {
|
|
12882
|
+
width: 60,
|
|
12883
|
+
src: val
|
|
12884
|
+
});
|
|
12885
|
+
}
|
|
12886
|
+
}, {
|
|
12887
|
+
dataIndex: 'goodsSn',
|
|
12888
|
+
title: "\u8D27\u53F7",
|
|
12889
|
+
width: 150
|
|
12890
|
+
}, {
|
|
12891
|
+
dataIndex: 'goodsId',
|
|
12892
|
+
title: "\u8D27\u53F7ID",
|
|
12893
|
+
width: 150
|
|
12894
|
+
}, {
|
|
12895
|
+
dataIndex: 'colorName',
|
|
12896
|
+
title: "\u989C\u8272\u540D\u79F0",
|
|
12897
|
+
width: 150
|
|
12898
|
+
}, {
|
|
12899
|
+
dataIndex: 'colorCode',
|
|
12900
|
+
title: "\u989C\u8272\u4EE3\u7801",
|
|
12901
|
+
width: 150
|
|
12902
|
+
}, {
|
|
12903
|
+
dataIndex: 'sizeName',
|
|
12904
|
+
title: "\u5C3A\u7801\u540D\u79F0",
|
|
12905
|
+
width: 150
|
|
12906
|
+
}, {
|
|
12907
|
+
dataIndex: 'sizeCode',
|
|
12908
|
+
title: "\u5C3A\u7801\u4EE3\u7801",
|
|
12909
|
+
width: 150
|
|
12910
|
+
}, {
|
|
12911
|
+
dataIndex: 'brandName',
|
|
12912
|
+
title: "\u54C1\u724C\u540D\u79F0",
|
|
12913
|
+
width: 150
|
|
12914
|
+
}, {
|
|
12915
|
+
dataIndex: 'goodsNumber',
|
|
12916
|
+
title: "\u5546\u54C1\u6570\u91CF",
|
|
12917
|
+
width: 150
|
|
12918
|
+
}, {
|
|
12919
|
+
dataIndex: 'goodsPrice',
|
|
12920
|
+
title: "\u5546\u54C1\u5355\u4EF7",
|
|
12921
|
+
width: 150
|
|
12922
|
+
}, {
|
|
12923
|
+
dataIndex: 'shopPrice',
|
|
12924
|
+
title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
|
|
12925
|
+
width: 150
|
|
12926
|
+
}, {
|
|
12927
|
+
dataIndex: 'isGift',
|
|
12928
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
12929
|
+
width: 150,
|
|
12930
|
+
render: function render(val) {
|
|
12931
|
+
return /*#__PURE__*/React__default['default'].createElement("span", null, +val ? '是' : '否');
|
|
12932
|
+
}
|
|
12933
|
+
}],
|
|
12934
|
+
//百胜E3商品信息
|
|
12935
|
+
BS_E3_GOODS: [{
|
|
12936
|
+
dataIndex: 'sku',
|
|
12937
|
+
title: "SKU",
|
|
12938
|
+
align: 'center',
|
|
12939
|
+
ellipsis: true,
|
|
12940
|
+
width: 150
|
|
12941
|
+
}, {
|
|
12942
|
+
dataIndex: 'skuId',
|
|
12943
|
+
title: "SKU ID",
|
|
12944
|
+
align: 'center',
|
|
12945
|
+
ellipsis: true,
|
|
12946
|
+
width: 150
|
|
12947
|
+
}, {
|
|
12948
|
+
dataIndex: 'goodsName',
|
|
12949
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
12950
|
+
align: 'center',
|
|
12951
|
+
ellipsis: true,
|
|
12952
|
+
width: 150
|
|
12953
|
+
}, {
|
|
12954
|
+
dataIndex: 'goodsShortName',
|
|
12604
12955
|
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12605
12956
|
align: 'center',
|
|
12606
12957
|
ellipsis: true,
|
|
@@ -12761,7 +13112,17 @@ var getColumns = function getColumns(_ref) {
|
|
|
12761
13112
|
render: function render(val) {
|
|
12762
13113
|
return /*#__PURE__*/React__default['default'].createElement("span", null, kmkfUtils.BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
12763
13114
|
}
|
|
12764
|
-
}]
|
|
13115
|
+
}]
|
|
13116
|
+
};
|
|
13117
|
+
};
|
|
13118
|
+
|
|
13119
|
+
var getColumns$1 = function getColumns(_ref) {
|
|
13120
|
+
var _ref$text = _ref.text,
|
|
13121
|
+
text = _ref$text === void 0 ? '' : _ref$text,
|
|
13122
|
+
disabled = _ref.disabled,
|
|
13123
|
+
updateHandle = _ref.updateHandle;
|
|
13124
|
+
return {
|
|
13125
|
+
//bs商品信息
|
|
12765
13126
|
BS_GOODS: [{
|
|
12766
13127
|
dataIndex: 'mark',
|
|
12767
13128
|
title: "\u5546\u54C1\u6807\u8BB0",
|
|
@@ -12928,7 +13289,7 @@ var getWdtReissueGoodColumns = function getWdtReissueGoodColumns(_ref2) {
|
|
|
12928
13289
|
});
|
|
12929
13290
|
};
|
|
12930
13291
|
|
|
12931
|
-
var getColumns$
|
|
13292
|
+
var getColumns$2 = function getColumns(_ref) {
|
|
12932
13293
|
var _ref$text = _ref.text,
|
|
12933
13294
|
text = _ref$text === void 0 ? '' : _ref$text,
|
|
12934
13295
|
disabled = _ref.disabled,
|
|
@@ -13014,20 +13375,101 @@ var getColumns$1 = function getColumns(_ref) {
|
|
|
13014
13375
|
align: 'center',
|
|
13015
13376
|
ellipsis: true,
|
|
13016
13377
|
width: 250
|
|
13017
|
-
}, {
|
|
13018
|
-
dataIndex: 'orderPrice',
|
|
13019
|
-
title: "\u5B9E\u4ED8\u603B\u91D1\u989D",
|
|
13020
|
-
align: 'center',
|
|
13021
|
-
ellipsis: true,
|
|
13022
|
-
width: 100
|
|
13378
|
+
}, {
|
|
13379
|
+
dataIndex: 'orderPrice',
|
|
13380
|
+
title: "\u5B9E\u4ED8\u603B\u91D1\u989D",
|
|
13381
|
+
align: 'center',
|
|
13382
|
+
ellipsis: true,
|
|
13383
|
+
width: 100
|
|
13384
|
+
}, {
|
|
13385
|
+
dataIndex: 'num',
|
|
13386
|
+
title: "".concat(text, "\u6570\u91CF"),
|
|
13387
|
+
align: 'center',
|
|
13388
|
+
ellipsis: true,
|
|
13389
|
+
width: 100,
|
|
13390
|
+
render: function render(val, record, index) {
|
|
13391
|
+
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13392
|
+
style: {
|
|
13393
|
+
width: 70
|
|
13394
|
+
},
|
|
13395
|
+
value: val,
|
|
13396
|
+
min: 1,
|
|
13397
|
+
precision: 0,
|
|
13398
|
+
onChange: function onChange(num) {
|
|
13399
|
+
return updateHandle(num, index, 'num');
|
|
13400
|
+
}
|
|
13401
|
+
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13402
|
+
}
|
|
13403
|
+
}, {
|
|
13404
|
+
dataIndex: 'sharePrice',
|
|
13405
|
+
title: "\u5206\u644A\u4EF7",
|
|
13406
|
+
align: 'center',
|
|
13407
|
+
ellipsis: true,
|
|
13408
|
+
width: 70
|
|
13409
|
+
}, {
|
|
13410
|
+
dataIndex: 'giftType',
|
|
13411
|
+
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
13412
|
+
align: 'center',
|
|
13413
|
+
ellipsis: true,
|
|
13414
|
+
width: 100,
|
|
13415
|
+
render: function render(val) {
|
|
13416
|
+
var giftTypeMap = {
|
|
13417
|
+
0: '非赠品',
|
|
13418
|
+
1: '自动赠送',
|
|
13419
|
+
2: '手工赠送',
|
|
13420
|
+
3: '回购自动送赠品',
|
|
13421
|
+
4: '前N有礼送赠品',
|
|
13422
|
+
6: '天猫优仓赠品',
|
|
13423
|
+
7: '淘宝CRM会员送赠'
|
|
13424
|
+
};
|
|
13425
|
+
return /*#__PURE__*/React__default['default'].createElement("span", null, giftTypeMap[val]);
|
|
13426
|
+
}
|
|
13427
|
+
}],
|
|
13428
|
+
//旺店通退货商品信息
|
|
13429
|
+
WDT_RETURN_GOODS: [{
|
|
13430
|
+
dataIndex: 'goodId',
|
|
13431
|
+
title: "\u5546\u54C1ID",
|
|
13432
|
+
align: 'center',
|
|
13433
|
+
ellipsis: true,
|
|
13434
|
+
width: 70
|
|
13435
|
+
}, {
|
|
13436
|
+
dataIndex: 'goodNo',
|
|
13437
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13438
|
+
align: 'center',
|
|
13439
|
+
ellipsis: true,
|
|
13440
|
+
width: 180
|
|
13441
|
+
}, {
|
|
13442
|
+
dataIndex: 'goodName',
|
|
13443
|
+
title: "".concat(text, "\u5546\u54C1\u540D\u79F0"),
|
|
13444
|
+
align: 'center',
|
|
13445
|
+
ellipsis: true,
|
|
13446
|
+
width: 250
|
|
13447
|
+
}, {
|
|
13448
|
+
dataIndex: 'specId',
|
|
13449
|
+
title: "".concat(text, "SKUID"),
|
|
13450
|
+
align: 'center',
|
|
13451
|
+
ellipsis: true,
|
|
13452
|
+
width: 100
|
|
13453
|
+
}, {
|
|
13454
|
+
dataIndex: 'specNo',
|
|
13455
|
+
title: "".concat(text, "\u5546\u54C1SKU\u7F16\u7801"),
|
|
13456
|
+
align: 'center',
|
|
13457
|
+
ellipsis: true,
|
|
13458
|
+
width: 180
|
|
13459
|
+
}, {
|
|
13460
|
+
dataIndex: 'specName',
|
|
13461
|
+
title: "".concat(text, "\u5546\u54C1SKU\u540D\u79F0"),
|
|
13462
|
+
align: 'center',
|
|
13463
|
+
ellipsis: true,
|
|
13464
|
+
width: 250
|
|
13023
13465
|
}, {
|
|
13024
13466
|
dataIndex: 'num',
|
|
13025
|
-
title: "".concat(text, "\u6570\u91CF"),
|
|
13467
|
+
title: "".concat(text, "\u9000\u8D27\u6570\u91CF"),
|
|
13026
13468
|
align: 'center',
|
|
13027
13469
|
ellipsis: true,
|
|
13028
13470
|
width: 100,
|
|
13029
13471
|
render: function render(val, record, index) {
|
|
13030
|
-
return
|
|
13472
|
+
return !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13031
13473
|
style: {
|
|
13032
13474
|
width: 70
|
|
13033
13475
|
},
|
|
@@ -13044,7 +13486,25 @@ var getColumns$1 = function getColumns(_ref) {
|
|
|
13044
13486
|
title: "\u5206\u644A\u4EF7",
|
|
13045
13487
|
align: 'center',
|
|
13046
13488
|
ellipsis: true,
|
|
13047
|
-
width:
|
|
13489
|
+
width: 80,
|
|
13490
|
+
render: function render(val, record, index) {
|
|
13491
|
+
return !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13492
|
+
style: {
|
|
13493
|
+
width: 70
|
|
13494
|
+
},
|
|
13495
|
+
value: val,
|
|
13496
|
+
min: 0,
|
|
13497
|
+
onChange: function onChange(value) {
|
|
13498
|
+
return updateHandle(value, index, 'sharePrice');
|
|
13499
|
+
}
|
|
13500
|
+
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13501
|
+
}
|
|
13502
|
+
}, {
|
|
13503
|
+
dataIndex: 'returnPrice',
|
|
13504
|
+
title: "".concat(text, "\u9000\u8D27\u91D1\u989D"),
|
|
13505
|
+
align: 'center',
|
|
13506
|
+
ellipsis: true,
|
|
13507
|
+
width: 100
|
|
13048
13508
|
}, {
|
|
13049
13509
|
dataIndex: 'giftType',
|
|
13050
13510
|
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
@@ -13063,9 +13523,34 @@ var getColumns$1 = function getColumns(_ref) {
|
|
|
13063
13523
|
};
|
|
13064
13524
|
return /*#__PURE__*/React__default['default'].createElement("span", null, giftTypeMap[val]);
|
|
13065
13525
|
}
|
|
13526
|
+
}, {
|
|
13527
|
+
dataIndex: 'type',
|
|
13528
|
+
title: "".concat(text, "\u5546\u54C1\u7C7B\u578B"),
|
|
13529
|
+
align: 'center',
|
|
13530
|
+
ellipsis: true,
|
|
13531
|
+
width: 100,
|
|
13532
|
+
render: function render(val, record, index) {
|
|
13533
|
+
var options = [{
|
|
13534
|
+
label: '单品',
|
|
13535
|
+
value: '1'
|
|
13536
|
+
}, {
|
|
13537
|
+
label: '组合装',
|
|
13538
|
+
value: '2'
|
|
13539
|
+
}];
|
|
13540
|
+
return !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.Select, {
|
|
13541
|
+
style: {
|
|
13542
|
+
width: 70
|
|
13543
|
+
},
|
|
13544
|
+
options: options,
|
|
13545
|
+
value: val,
|
|
13546
|
+
onChange: function onChange(value) {
|
|
13547
|
+
return updateHandle(value, index, 'type');
|
|
13548
|
+
}
|
|
13549
|
+
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13550
|
+
}
|
|
13066
13551
|
}],
|
|
13067
|
-
|
|
13068
|
-
|
|
13552
|
+
//旺店通换出商品信息
|
|
13553
|
+
WDT_EXCHANGE_GOODS: [{
|
|
13069
13554
|
dataIndex: 'goodId',
|
|
13070
13555
|
title: "\u5546\u54C1ID",
|
|
13071
13556
|
align: 'center',
|
|
@@ -13103,7 +13588,7 @@ var getColumns$1 = function getColumns(_ref) {
|
|
|
13103
13588
|
width: 250
|
|
13104
13589
|
}, {
|
|
13105
13590
|
dataIndex: 'num',
|
|
13106
|
-
title: "".concat(text, "\
|
|
13591
|
+
title: "".concat(text, "\u6362\u51FA\u6570\u91CF"),
|
|
13107
13592
|
align: 'center',
|
|
13108
13593
|
ellipsis: true,
|
|
13109
13594
|
width: 100,
|
|
@@ -13121,11 +13606,11 @@ var getColumns$1 = function getColumns(_ref) {
|
|
|
13121
13606
|
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13122
13607
|
}
|
|
13123
13608
|
}, {
|
|
13124
|
-
dataIndex: '
|
|
13125
|
-
title: "\
|
|
13609
|
+
dataIndex: 'price',
|
|
13610
|
+
title: "".concat(text, "\u5546\u54C1\u5355\u4EF7"),
|
|
13126
13611
|
align: 'center',
|
|
13127
13612
|
ellipsis: true,
|
|
13128
|
-
width:
|
|
13613
|
+
width: 100,
|
|
13129
13614
|
render: function render(val, record, index) {
|
|
13130
13615
|
return !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13131
13616
|
style: {
|
|
@@ -13134,13 +13619,13 @@ var getColumns$1 = function getColumns(_ref) {
|
|
|
13134
13619
|
value: val,
|
|
13135
13620
|
min: 0,
|
|
13136
13621
|
onChange: function onChange(value) {
|
|
13137
|
-
return updateHandle(value, index, '
|
|
13622
|
+
return updateHandle(value, index, 'price');
|
|
13138
13623
|
}
|
|
13139
13624
|
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13140
13625
|
}
|
|
13141
13626
|
}, {
|
|
13142
|
-
dataIndex: '
|
|
13143
|
-
title: "".concat(text, "\
|
|
13627
|
+
dataIndex: 'exchangePrice',
|
|
13628
|
+
title: "".concat(text, "\u6362\u51FA\u91D1\u989D"),
|
|
13144
13629
|
align: 'center',
|
|
13145
13630
|
ellipsis: true,
|
|
13146
13631
|
width: 100
|
|
@@ -13187,52 +13672,262 @@ var getColumns$1 = function getColumns(_ref) {
|
|
|
13187
13672
|
}
|
|
13188
13673
|
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13189
13674
|
}
|
|
13190
|
-
}]
|
|
13191
|
-
|
|
13192
|
-
|
|
13193
|
-
|
|
13194
|
-
|
|
13675
|
+
}]
|
|
13676
|
+
};
|
|
13677
|
+
};
|
|
13678
|
+
|
|
13679
|
+
var getColumns$3 = function getColumns(_ref) {
|
|
13680
|
+
var _ref$text = _ref.text,
|
|
13681
|
+
text = _ref$text === void 0 ? '' : _ref$text,
|
|
13682
|
+
disabled = _ref.disabled,
|
|
13683
|
+
updateHandle = _ref.updateHandle;
|
|
13684
|
+
return {
|
|
13685
|
+
//万里牛商品信息
|
|
13686
|
+
WLN_GOODS: [{
|
|
13687
|
+
dataIndex: 'skuName',
|
|
13688
|
+
title: "".concat(text, "sku\u540D\u79F0"),
|
|
13195
13689
|
align: 'center',
|
|
13196
13690
|
ellipsis: true,
|
|
13197
|
-
width:
|
|
13691
|
+
width: 250
|
|
13198
13692
|
}, {
|
|
13199
|
-
dataIndex: '
|
|
13200
|
-
title: "\
|
|
13693
|
+
dataIndex: 'sku',
|
|
13694
|
+
title: "".concat(text, "sku\u7F16\u7801"),
|
|
13201
13695
|
align: 'center',
|
|
13202
13696
|
ellipsis: true,
|
|
13203
|
-
width:
|
|
13697
|
+
width: 100
|
|
13204
13698
|
}, {
|
|
13205
|
-
dataIndex: '
|
|
13206
|
-
title: "".concat(text, "\
|
|
13699
|
+
dataIndex: 'name',
|
|
13700
|
+
title: "".concat(text, "\u540D\u79F0"),
|
|
13207
13701
|
align: 'center',
|
|
13208
13702
|
ellipsis: true,
|
|
13209
13703
|
width: 250
|
|
13210
13704
|
}, {
|
|
13211
|
-
dataIndex: '
|
|
13212
|
-
title: ""
|
|
13705
|
+
dataIndex: 'pic',
|
|
13706
|
+
title: "\u56FE\u7247",
|
|
13707
|
+
align: 'center',
|
|
13708
|
+
ellipsis: true,
|
|
13709
|
+
width: 100,
|
|
13710
|
+
render: function render(val) {
|
|
13711
|
+
return /*#__PURE__*/React__default['default'].createElement(antd.Image, {
|
|
13712
|
+
width: 60,
|
|
13713
|
+
src: val
|
|
13714
|
+
});
|
|
13715
|
+
}
|
|
13716
|
+
}, {
|
|
13717
|
+
dataIndex: 'code',
|
|
13718
|
+
title: "".concat(text, "\u7F16\u7801"),
|
|
13719
|
+
align: 'center',
|
|
13720
|
+
ellipsis: true,
|
|
13721
|
+
width: 100
|
|
13722
|
+
}, {
|
|
13723
|
+
dataIndex: 'money',
|
|
13724
|
+
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
13725
|
+
align: 'center',
|
|
13726
|
+
ellipsis: true,
|
|
13727
|
+
width: 100
|
|
13728
|
+
}, {
|
|
13729
|
+
dataIndex: 'number',
|
|
13730
|
+
title: "".concat(text, "\u6570\u91CF"),
|
|
13731
|
+
align: 'center',
|
|
13732
|
+
ellipsis: true,
|
|
13733
|
+
width: 100,
|
|
13734
|
+
render: function render(val, record, index) {
|
|
13735
|
+
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13736
|
+
style: {
|
|
13737
|
+
width: 70
|
|
13738
|
+
},
|
|
13739
|
+
value: val,
|
|
13740
|
+
min: 1,
|
|
13741
|
+
precision: 0,
|
|
13742
|
+
onChange: function onChange(num) {
|
|
13743
|
+
return updateHandle(num, index, 'number');
|
|
13744
|
+
}
|
|
13745
|
+
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13746
|
+
}
|
|
13747
|
+
}, {
|
|
13748
|
+
dataIndex: 'share',
|
|
13749
|
+
title: "\u5206\u644A\u4EF7",
|
|
13750
|
+
align: 'center',
|
|
13751
|
+
ellipsis: true,
|
|
13752
|
+
width: 70
|
|
13753
|
+
}, {
|
|
13754
|
+
dataIndex: 'type',
|
|
13755
|
+
title: "\u8D60\u54C1\u7C7B\u578B",
|
|
13213
13756
|
align: 'center',
|
|
13214
13757
|
ellipsis: true,
|
|
13215
13758
|
width: 100
|
|
13759
|
+
}]
|
|
13760
|
+
};
|
|
13761
|
+
};
|
|
13762
|
+
|
|
13763
|
+
var isNumberOrNumberString = function isNumberOrNumberString(value) {
|
|
13764
|
+
if (typeof value === 'number') return true;
|
|
13765
|
+
if (typeof value === 'string' && !isNaN(Number(value)) && value.trim() !== '') return true;
|
|
13766
|
+
return false;
|
|
13767
|
+
};
|
|
13768
|
+
var getYesOrNo = function getYesOrNo(val) {
|
|
13769
|
+
if (kmkfUtils.isNull(val)) return null;
|
|
13770
|
+
return val ? '是' : '否';
|
|
13771
|
+
};
|
|
13772
|
+
var getColumns$4 = function getColumns(_ref) {
|
|
13773
|
+
var _ref$text = _ref.text,
|
|
13774
|
+
disabled = _ref.disabled,
|
|
13775
|
+
updateHandle = _ref.updateHandle,
|
|
13776
|
+
updateDataHandle = _ref.updateDataHandle;
|
|
13777
|
+
return {
|
|
13778
|
+
//管易商品信息
|
|
13779
|
+
GY_GOODS: [{
|
|
13780
|
+
dataIndex: 'goodName',
|
|
13781
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
13782
|
+
width: 150
|
|
13783
|
+
}, {
|
|
13784
|
+
dataIndex: 'goodShortName',
|
|
13785
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
13786
|
+
width: 150
|
|
13787
|
+
}, {
|
|
13788
|
+
dataIndex: 'goodNo',
|
|
13789
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13790
|
+
width: 200
|
|
13791
|
+
}, {
|
|
13792
|
+
dataIndex: 'specName',
|
|
13793
|
+
title: "SKU\u540D\u79F0",
|
|
13794
|
+
align: 'center',
|
|
13795
|
+
ellipsis: true,
|
|
13796
|
+
width: 250
|
|
13216
13797
|
}, {
|
|
13217
13798
|
dataIndex: 'specNo',
|
|
13218
|
-
title: "
|
|
13799
|
+
title: "SKU\u7F16\u7801",
|
|
13219
13800
|
align: 'center',
|
|
13220
13801
|
ellipsis: true,
|
|
13221
|
-
width:
|
|
13802
|
+
width: 150
|
|
13803
|
+
}, {
|
|
13804
|
+
dataIndex: 'qty',
|
|
13805
|
+
title: "\u6570\u91CF",
|
|
13806
|
+
width: 100,
|
|
13807
|
+
render: function render(val, record, index) {
|
|
13808
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13809
|
+
style: {
|
|
13810
|
+
width: 70
|
|
13811
|
+
},
|
|
13812
|
+
value: val,
|
|
13813
|
+
min: 1,
|
|
13814
|
+
precision: 0,
|
|
13815
|
+
onChange: function onChange(num) {
|
|
13816
|
+
updateDataHandle({
|
|
13817
|
+
qty: num,
|
|
13818
|
+
amount: num && isNumberOrNumberString(record.price) ? num * record.price : null,
|
|
13819
|
+
originAmount: num && isNumberOrNumberString(record.originPrice) ? num * record.originPrice : null
|
|
13820
|
+
}, index);
|
|
13821
|
+
}
|
|
13822
|
+
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13823
|
+
}
|
|
13824
|
+
}, {
|
|
13825
|
+
dataIndex: 'price',
|
|
13826
|
+
title: "\u5B9E\u9645\u5355\u4EF7",
|
|
13827
|
+
width: 150,
|
|
13828
|
+
render: function render(val, record, index) {
|
|
13829
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13830
|
+
style: {
|
|
13831
|
+
width: 130
|
|
13832
|
+
},
|
|
13833
|
+
value: val,
|
|
13834
|
+
min: 0,
|
|
13835
|
+
precision: 2,
|
|
13836
|
+
onChange: function onChange(num) {
|
|
13837
|
+
updateDataHandle({
|
|
13838
|
+
price: num,
|
|
13839
|
+
amount: num && isNumberOrNumberString(record.qty) ? num * record.qty : null
|
|
13840
|
+
}, index);
|
|
13841
|
+
}
|
|
13842
|
+
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13843
|
+
}
|
|
13844
|
+
}, {
|
|
13845
|
+
dataIndex: 'amount',
|
|
13846
|
+
title: "\u5B9E\u9645\u91D1\u989D",
|
|
13847
|
+
width: 150
|
|
13848
|
+
}, {
|
|
13849
|
+
dataIndex: 'originPrice',
|
|
13850
|
+
title: "\u6807\u51C6\u5355\u4EF7",
|
|
13851
|
+
width: 150
|
|
13852
|
+
}, {
|
|
13853
|
+
dataIndex: 'originAmount',
|
|
13854
|
+
title: "\u6807\u51C6\u91D1\u989D",
|
|
13855
|
+
width: 150
|
|
13856
|
+
}, {
|
|
13857
|
+
dataIndex: 'discountFee',
|
|
13858
|
+
title: "\u8BA9\u5229\u91D1\u989D",
|
|
13859
|
+
width: 150
|
|
13860
|
+
}, {
|
|
13861
|
+
dataIndex: 'amountAfter',
|
|
13862
|
+
title: "\u8BA9\u5229\u540E\u91D1\u989D",
|
|
13863
|
+
width: 150
|
|
13864
|
+
}, {
|
|
13865
|
+
dataIndex: 'cancel',
|
|
13866
|
+
title: "\u662F\u5426\u53D6\u6D88",
|
|
13867
|
+
width: 150,
|
|
13868
|
+
render: function render(val) {
|
|
13869
|
+
return /*#__PURE__*/React__default['default'].createElement("span", null, getYesOrNo(val));
|
|
13870
|
+
}
|
|
13871
|
+
}, {
|
|
13872
|
+
dataIndex: 'isGift',
|
|
13873
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
13874
|
+
width: 150,
|
|
13875
|
+
render: function render(val, record, index) {
|
|
13876
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.Select, {
|
|
13877
|
+
value: val,
|
|
13878
|
+
onChange: function onChange(value) {
|
|
13879
|
+
updateHandle(value, index, 'isGift');
|
|
13880
|
+
},
|
|
13881
|
+
options: [{
|
|
13882
|
+
label: '是',
|
|
13883
|
+
value: 1
|
|
13884
|
+
}, {
|
|
13885
|
+
label: '否',
|
|
13886
|
+
value: 0
|
|
13887
|
+
}]
|
|
13888
|
+
}) : /*#__PURE__*/React__default['default'].createElement("span", null, getYesOrNo(val));
|
|
13889
|
+
}
|
|
13890
|
+
}, {
|
|
13891
|
+
dataIndex: 'skuNote',
|
|
13892
|
+
title: "\u5546\u54C1\u5907\u6CE8",
|
|
13893
|
+
width: 150
|
|
13894
|
+
}].map(function (item) {
|
|
13895
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
13896
|
+
align: 'center',
|
|
13897
|
+
ellipsis: true
|
|
13898
|
+
});
|
|
13899
|
+
}),
|
|
13900
|
+
//管易补发商品信息
|
|
13901
|
+
GY_REISSUE_GOODS: [{
|
|
13902
|
+
dataIndex: 'goodName',
|
|
13903
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
13904
|
+
width: 150
|
|
13905
|
+
}, {
|
|
13906
|
+
dataIndex: 'goodShortName',
|
|
13907
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
13908
|
+
width: 150
|
|
13909
|
+
}, {
|
|
13910
|
+
dataIndex: 'goodNo',
|
|
13911
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13912
|
+
width: 200
|
|
13222
13913
|
}, {
|
|
13223
13914
|
dataIndex: 'specName',
|
|
13224
|
-
title: "
|
|
13915
|
+
title: "SKU\u540D\u79F0",
|
|
13225
13916
|
align: 'center',
|
|
13226
13917
|
ellipsis: true,
|
|
13227
13918
|
width: 250
|
|
13228
13919
|
}, {
|
|
13229
|
-
dataIndex: '
|
|
13230
|
-
title: "
|
|
13920
|
+
dataIndex: 'specNo',
|
|
13921
|
+
title: "SKU\u7F16\u7801",
|
|
13231
13922
|
align: 'center',
|
|
13232
13923
|
ellipsis: true,
|
|
13924
|
+
width: 150
|
|
13925
|
+
}, {
|
|
13926
|
+
dataIndex: 'qty',
|
|
13927
|
+
title: "\u6570\u91CF",
|
|
13233
13928
|
width: 100,
|
|
13234
13929
|
render: function render(val, record, index) {
|
|
13235
|
-
return !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13930
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13236
13931
|
style: {
|
|
13237
13932
|
width: 70
|
|
13238
13933
|
},
|
|
@@ -13240,184 +13935,81 @@ var getColumns$1 = function getColumns(_ref) {
|
|
|
13240
13935
|
min: 1,
|
|
13241
13936
|
precision: 0,
|
|
13242
13937
|
onChange: function onChange(num) {
|
|
13243
|
-
|
|
13938
|
+
updateDataHandle({
|
|
13939
|
+
qty: num,
|
|
13940
|
+
amount: num && isNumberOrNumberString(record.price) ? num * record.price : null,
|
|
13941
|
+
originAmount: num && isNumberOrNumberString(record.originPrice) ? num * record.originPrice : null
|
|
13942
|
+
}, index);
|
|
13244
13943
|
}
|
|
13245
13944
|
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13246
13945
|
}
|
|
13247
13946
|
}, {
|
|
13248
13947
|
dataIndex: 'price',
|
|
13249
|
-
title: "
|
|
13250
|
-
|
|
13251
|
-
ellipsis: true,
|
|
13252
|
-
width: 100,
|
|
13948
|
+
title: "\u5B9E\u9645\u5355\u4EF7",
|
|
13949
|
+
width: 150,
|
|
13253
13950
|
render: function render(val, record, index) {
|
|
13254
|
-
return !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13951
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13255
13952
|
style: {
|
|
13256
|
-
width:
|
|
13953
|
+
width: 130
|
|
13257
13954
|
},
|
|
13258
13955
|
value: val,
|
|
13259
13956
|
min: 0,
|
|
13260
|
-
|
|
13261
|
-
|
|
13957
|
+
precision: 2,
|
|
13958
|
+
onChange: function onChange(num) {
|
|
13959
|
+
updateDataHandle({
|
|
13960
|
+
price: num,
|
|
13961
|
+
amount: num && isNumberOrNumberString(record.qty) ? num * record.qty : null
|
|
13962
|
+
}, index);
|
|
13262
13963
|
}
|
|
13263
13964
|
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13264
13965
|
}
|
|
13265
13966
|
}, {
|
|
13266
|
-
dataIndex: '
|
|
13267
|
-
title: "
|
|
13268
|
-
|
|
13269
|
-
ellipsis: true,
|
|
13270
|
-
width: 100
|
|
13967
|
+
dataIndex: 'amount',
|
|
13968
|
+
title: "\u5B9E\u9645\u91D1\u989D",
|
|
13969
|
+
width: 150
|
|
13271
13970
|
}, {
|
|
13272
|
-
dataIndex: '
|
|
13273
|
-
title: "\
|
|
13274
|
-
|
|
13275
|
-
ellipsis: true,
|
|
13276
|
-
width: 100,
|
|
13277
|
-
render: function render(val) {
|
|
13278
|
-
var giftTypeMap = {
|
|
13279
|
-
0: '非赠品',
|
|
13280
|
-
1: '自动赠送',
|
|
13281
|
-
2: '手工赠送',
|
|
13282
|
-
3: '回购自动送赠品',
|
|
13283
|
-
4: '前N有礼送赠品',
|
|
13284
|
-
6: '天猫优仓赠品',
|
|
13285
|
-
7: '淘宝CRM会员送赠'
|
|
13286
|
-
};
|
|
13287
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, giftTypeMap[val]);
|
|
13288
|
-
}
|
|
13971
|
+
dataIndex: 'originPrice',
|
|
13972
|
+
title: "\u6807\u51C6\u5355\u4EF7",
|
|
13973
|
+
width: 150
|
|
13289
13974
|
}, {
|
|
13290
|
-
dataIndex: '
|
|
13291
|
-
title: "
|
|
13292
|
-
|
|
13293
|
-
|
|
13294
|
-
|
|
13975
|
+
dataIndex: 'originAmount',
|
|
13976
|
+
title: "\u6807\u51C6\u91D1\u989D",
|
|
13977
|
+
width: 150
|
|
13978
|
+
}, {
|
|
13979
|
+
dataIndex: 'isGift',
|
|
13980
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
13981
|
+
width: 150,
|
|
13295
13982
|
render: function render(val, record, index) {
|
|
13296
|
-
|
|
13297
|
-
label: '单品',
|
|
13298
|
-
value: '1'
|
|
13299
|
-
}, {
|
|
13300
|
-
label: '组合装',
|
|
13301
|
-
value: '2'
|
|
13302
|
-
}];
|
|
13303
|
-
return !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.Select, {
|
|
13304
|
-
style: {
|
|
13305
|
-
width: 70
|
|
13306
|
-
},
|
|
13307
|
-
options: options,
|
|
13983
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.Select, {
|
|
13308
13984
|
value: val,
|
|
13309
13985
|
onChange: function onChange(value) {
|
|
13310
|
-
|
|
13311
|
-
}
|
|
13312
|
-
|
|
13986
|
+
updateHandle(value, index, 'isGift');
|
|
13987
|
+
},
|
|
13988
|
+
options: [{
|
|
13989
|
+
label: '是',
|
|
13990
|
+
value: 1
|
|
13991
|
+
}, {
|
|
13992
|
+
label: '否',
|
|
13993
|
+
value: 0
|
|
13994
|
+
}]
|
|
13995
|
+
}) : /*#__PURE__*/React__default['default'].createElement("span", null, getYesOrNo(val));
|
|
13313
13996
|
}
|
|
13314
|
-
}]
|
|
13997
|
+
}].map(function (item) {
|
|
13998
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
13999
|
+
align: 'center',
|
|
14000
|
+
ellipsis: true
|
|
14001
|
+
});
|
|
14002
|
+
})
|
|
13315
14003
|
};
|
|
13316
14004
|
};
|
|
13317
14005
|
|
|
13318
|
-
var getColumns$
|
|
14006
|
+
var getColumns$5 = function getColumns(_ref) {
|
|
13319
14007
|
var _ref$text = _ref.text,
|
|
13320
14008
|
text = _ref$text === void 0 ? '' : _ref$text,
|
|
13321
14009
|
disabled = _ref.disabled,
|
|
13322
14010
|
updateHandle = _ref.updateHandle;
|
|
13323
14011
|
return {
|
|
13324
|
-
|
|
13325
|
-
WLN_GOODS: [{
|
|
13326
|
-
dataIndex: 'skuName',
|
|
13327
|
-
title: "".concat(text, "sku\u540D\u79F0"),
|
|
13328
|
-
align: 'center',
|
|
13329
|
-
ellipsis: true,
|
|
13330
|
-
width: 250
|
|
13331
|
-
}, {
|
|
13332
|
-
dataIndex: 'sku',
|
|
13333
|
-
title: "".concat(text, "sku\u7F16\u7801"),
|
|
13334
|
-
align: 'center',
|
|
13335
|
-
ellipsis: true,
|
|
13336
|
-
width: 100
|
|
13337
|
-
}, {
|
|
13338
|
-
dataIndex: 'name',
|
|
13339
|
-
title: "".concat(text, "\u540D\u79F0"),
|
|
13340
|
-
align: 'center',
|
|
13341
|
-
ellipsis: true,
|
|
13342
|
-
width: 250
|
|
13343
|
-
}, {
|
|
13344
|
-
dataIndex: 'pic',
|
|
13345
|
-
title: "\u56FE\u7247",
|
|
13346
|
-
align: 'center',
|
|
13347
|
-
ellipsis: true,
|
|
13348
|
-
width: 100,
|
|
13349
|
-
render: function render(val) {
|
|
13350
|
-
return /*#__PURE__*/React__default['default'].createElement(antd.Image, {
|
|
13351
|
-
width: 60,
|
|
13352
|
-
src: val
|
|
13353
|
-
});
|
|
13354
|
-
}
|
|
13355
|
-
}, {
|
|
13356
|
-
dataIndex: 'code',
|
|
13357
|
-
title: "".concat(text, "\u7F16\u7801"),
|
|
13358
|
-
align: 'center',
|
|
13359
|
-
ellipsis: true,
|
|
13360
|
-
width: 100
|
|
13361
|
-
}, {
|
|
13362
|
-
dataIndex: 'money',
|
|
13363
|
-
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
13364
|
-
align: 'center',
|
|
13365
|
-
ellipsis: true,
|
|
13366
|
-
width: 100
|
|
13367
|
-
}, {
|
|
13368
|
-
dataIndex: 'number',
|
|
13369
|
-
title: "".concat(text, "\u6570\u91CF"),
|
|
13370
|
-
align: 'center',
|
|
13371
|
-
ellipsis: true,
|
|
13372
|
-
width: 100,
|
|
13373
|
-
render: function render(val, record, index) {
|
|
13374
|
-
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, {
|
|
13375
|
-
style: {
|
|
13376
|
-
width: 70
|
|
13377
|
-
},
|
|
13378
|
-
value: val,
|
|
13379
|
-
min: 1,
|
|
13380
|
-
precision: 0,
|
|
13381
|
-
onChange: function onChange(num) {
|
|
13382
|
-
return updateHandle(num, index, 'number');
|
|
13383
|
-
}
|
|
13384
|
-
}) : /*#__PURE__*/React__default['default'].createElement("span", null, val);
|
|
13385
|
-
}
|
|
13386
|
-
}, {
|
|
13387
|
-
dataIndex: 'share',
|
|
13388
|
-
title: "\u5206\u644A\u4EF7",
|
|
13389
|
-
align: 'center',
|
|
13390
|
-
ellipsis: true,
|
|
13391
|
-
width: 70
|
|
13392
|
-
}, {
|
|
13393
|
-
dataIndex: 'type',
|
|
13394
|
-
title: "\u8D60\u54C1\u7C7B\u578B",
|
|
13395
|
-
align: 'center',
|
|
13396
|
-
ellipsis: true,
|
|
13397
|
-
width: 100
|
|
13398
|
-
}]
|
|
13399
|
-
};
|
|
13400
|
-
};
|
|
13401
|
-
|
|
13402
|
-
var getColumnsMap = function getColumnsMap(args) {
|
|
13403
|
-
var _ref = args || {},
|
|
13404
|
-
_ref$text = _ref.text,
|
|
13405
|
-
text = _ref$text === void 0 ? '' : _ref$text,
|
|
13406
|
-
disabled = _ref.disabled,
|
|
13407
|
-
updateHandle = _ref.updateHandle;
|
|
13408
|
-
return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({}, getColumns({
|
|
13409
|
-
text: text,
|
|
13410
|
-
disabled: disabled,
|
|
13411
|
-
updateHandle: updateHandle
|
|
13412
|
-
})), getColumns$1({
|
|
13413
|
-
text: text,
|
|
13414
|
-
disabled: disabled,
|
|
13415
|
-
updateHandle: updateHandle
|
|
13416
|
-
})), getColumns$2({
|
|
13417
|
-
text: text,
|
|
13418
|
-
disabled: disabled,
|
|
13419
|
-
updateHandle: updateHandle
|
|
13420
|
-
})), {}, {
|
|
14012
|
+
//bs商品信息
|
|
13421
14013
|
default: [{
|
|
13422
14014
|
dataIndex: 'mark',
|
|
13423
14015
|
title: "\u5546\u54C1\u6807\u8BB0",
|
|
@@ -13514,6 +14106,43 @@ var getColumnsMap = function getColumnsMap(args) {
|
|
|
13514
14106
|
ellipsis: true,
|
|
13515
14107
|
width: 100
|
|
13516
14108
|
}]
|
|
14109
|
+
};
|
|
14110
|
+
};
|
|
14111
|
+
|
|
14112
|
+
var getColumnsMap = function getColumnsMap(args) {
|
|
14113
|
+
var _ref = args || {},
|
|
14114
|
+
_ref$text = _ref.text,
|
|
14115
|
+
text = _ref$text === void 0 ? '' : _ref$text,
|
|
14116
|
+
disabled = _ref.disabled,
|
|
14117
|
+
updateHandle = _ref.updateHandle,
|
|
14118
|
+
updateDataHandle = _ref.updateDataHandle;
|
|
14119
|
+
return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({}, getColumns$1({
|
|
14120
|
+
text: text,
|
|
14121
|
+
disabled: disabled,
|
|
14122
|
+
updateHandle: updateHandle
|
|
14123
|
+
})), getColumns({
|
|
14124
|
+
text: text,
|
|
14125
|
+
disabled: disabled,
|
|
14126
|
+
updateHandle: updateHandle
|
|
14127
|
+
})), getColumns$2({
|
|
14128
|
+
text: text,
|
|
14129
|
+
disabled: disabled,
|
|
14130
|
+
updateHandle: updateHandle
|
|
14131
|
+
})), getColumns$3({
|
|
14132
|
+
text: text,
|
|
14133
|
+
disabled: disabled,
|
|
14134
|
+
updateHandle: updateHandle
|
|
14135
|
+
})), getColumns$4({
|
|
14136
|
+
text: text,
|
|
14137
|
+
disabled: disabled,
|
|
14138
|
+
updateHandle: updateHandle,
|
|
14139
|
+
updateDataHandle: updateDataHandle
|
|
14140
|
+
})), {}, {
|
|
14141
|
+
default: getColumns$5({
|
|
14142
|
+
text: text,
|
|
14143
|
+
disabled: disabled,
|
|
14144
|
+
updateHandle: updateHandle
|
|
14145
|
+
})['default']
|
|
13517
14146
|
});
|
|
13518
14147
|
};
|
|
13519
14148
|
var getColumnsBaseInfo = function getColumnsBaseInfo() {
|
|
@@ -13671,6 +14300,9 @@ var getButtonText = function getButtonText() {
|
|
|
13671
14300
|
if (['WDT_REISSUE_GOODS'].includes(type)) {
|
|
13672
14301
|
return '选择旺店通商品';
|
|
13673
14302
|
}
|
|
14303
|
+
if (['GY_GOODS', 'GY_REISSUE_GOODS'].includes(type)) {
|
|
14304
|
+
return '选择管易ERP商品';
|
|
14305
|
+
}
|
|
13674
14306
|
return '选择商品';
|
|
13675
14307
|
};
|
|
13676
14308
|
var GoodItem$1 = function GoodItem(props) {
|
|
@@ -13762,6 +14394,12 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13762
14394
|
onChange === null || onChange === void 0 ? void 0 : onChange(_toConsumableArray(value));
|
|
13763
14395
|
}
|
|
13764
14396
|
};
|
|
14397
|
+
var updateDataHandle = function updateDataHandle(data, index) {
|
|
14398
|
+
if (value === null || value === void 0 ? void 0 : value.length) {
|
|
14399
|
+
value[index] = _objectSpread2(_objectSpread2({}, value[index]), data);
|
|
14400
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_toConsumableArray(value));
|
|
14401
|
+
}
|
|
14402
|
+
};
|
|
13765
14403
|
var COLUMNS_MAP = function COLUMNS_MAP() {
|
|
13766
14404
|
var text = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
|
|
13767
14405
|
var operate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
@@ -13774,11 +14412,14 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13774
14412
|
case 'BS_E3_GOODS':
|
|
13775
14413
|
case 'BS_GOODS':
|
|
13776
14414
|
case 'WLN_GOODS':
|
|
14415
|
+
case 'GY_GOODS':
|
|
14416
|
+
case 'GY_REISSUE_GOODS':
|
|
13777
14417
|
{
|
|
13778
14418
|
columns = getColumnsMap({
|
|
13779
14419
|
text: text,
|
|
13780
14420
|
disabled: disabled,
|
|
13781
|
-
updateHandle: updateHandle
|
|
14421
|
+
updateHandle: updateHandle,
|
|
14422
|
+
updateDataHandle: updateDataHandle
|
|
13782
14423
|
})[type];
|
|
13783
14424
|
}
|
|
13784
14425
|
break;
|
|
@@ -13804,7 +14445,8 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13804
14445
|
columns = getColumnsMap({
|
|
13805
14446
|
text: text,
|
|
13806
14447
|
disabled: disabled,
|
|
13807
|
-
updateHandle: updateHandle
|
|
14448
|
+
updateHandle: updateHandle,
|
|
14449
|
+
updateDataHandle: updateDataHandle
|
|
13808
14450
|
})['default'];
|
|
13809
14451
|
}
|
|
13810
14452
|
return columns;
|
|
@@ -13927,6 +14569,28 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13927
14569
|
canUpdateNumber: canUpdateNumber
|
|
13928
14570
|
});
|
|
13929
14571
|
});
|
|
14572
|
+
} else if (['GY_GOODS', 'GY_REISSUE_GOODS'].includes(type)) {
|
|
14573
|
+
newList = list.map(function (item) {
|
|
14574
|
+
var goodName = item.goodName,
|
|
14575
|
+
goodShortName = item.goodShortName,
|
|
14576
|
+
goodNo = item.goodNo,
|
|
14577
|
+
specName = item.specName,
|
|
14578
|
+
specNo = item.specNo,
|
|
14579
|
+
retailPrice = item.retailPrice;
|
|
14580
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
14581
|
+
uuid: kmkfUtils.uuid(),
|
|
14582
|
+
canDelete: true,
|
|
14583
|
+
canEdit: true,
|
|
14584
|
+
qty: 1,
|
|
14585
|
+
goodName: goodName,
|
|
14586
|
+
goodShortName: goodShortName,
|
|
14587
|
+
goodNo: goodNo,
|
|
14588
|
+
specName: specName,
|
|
14589
|
+
specNo: specNo,
|
|
14590
|
+
originPrice: !kmkfUtils.isNull(retailPrice) ? Number(retailPrice) : null,
|
|
14591
|
+
originAmount: !kmkfUtils.isNull(retailPrice) ? Number(retailPrice) : null
|
|
14592
|
+
});
|
|
14593
|
+
});
|
|
13930
14594
|
} else {
|
|
13931
14595
|
newList = list.map(function (item) {
|
|
13932
14596
|
var goodsId = item.goodsId,
|
|
@@ -14022,6 +14686,14 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
14022
14686
|
shopId: shopId,
|
|
14023
14687
|
maxLength: maxLength,
|
|
14024
14688
|
companyKey: companyKey
|
|
14689
|
+
}) : ['GY_GOODS', 'GY_REISSUE_GOODS'].includes(type) ? /*#__PURE__*/React__default['default'].createElement(GyGoodsModal$1, {
|
|
14690
|
+
ref: refModal,
|
|
14691
|
+
onSubmit: onSubmit,
|
|
14692
|
+
width: width,
|
|
14693
|
+
shopList: shopList,
|
|
14694
|
+
shopId: shopId,
|
|
14695
|
+
maxLength: maxLength,
|
|
14696
|
+
companyKey: companyKey
|
|
14025
14697
|
}) : /*#__PURE__*/React__default['default'].createElement(GoodsModal$2, {
|
|
14026
14698
|
ref: refModal,
|
|
14027
14699
|
onSubmit: onSubmit,
|
|
@@ -14713,19 +15385,66 @@ var getBsE3OrderListSingleton = function getBsE3OrderListSingleton(orderNo) {
|
|
|
14713
15385
|
});
|
|
14714
15386
|
singletonMap$1.set(orderNo, p);
|
|
14715
15387
|
}
|
|
14716
|
-
return singletonMap$1.get(orderNo);
|
|
15388
|
+
return singletonMap$1.get(orderNo);
|
|
15389
|
+
};
|
|
15390
|
+
var bsE3Utils = {
|
|
15391
|
+
getBsE3OrderListSingleton: getBsE3OrderListSingleton
|
|
15392
|
+
};
|
|
15393
|
+
|
|
15394
|
+
var singletonMap$2 = new Map();
|
|
15395
|
+
var getGyOrderListSingleton = function getGyOrderListSingleton(orderNo) {
|
|
15396
|
+
if (!singletonMap$2.has(orderNo)) {
|
|
15397
|
+
var p = new Promise(function (resolve, reject) {
|
|
15398
|
+
var doReject = function doReject(err) {
|
|
15399
|
+
// 清空掉错误的请求记录
|
|
15400
|
+
singletonMap$2.delete(orderNo);
|
|
15401
|
+
reject(err);
|
|
15402
|
+
};
|
|
15403
|
+
extendRequest('/qy/gdfw/oms/gyOrderDetail', {
|
|
15404
|
+
method: 'post',
|
|
15405
|
+
data: {
|
|
15406
|
+
tid: orderNo
|
|
15407
|
+
}
|
|
15408
|
+
}).then(function (res) {
|
|
15409
|
+
if (res === null || res === void 0 ? void 0 : res.success) {
|
|
15410
|
+
var _res$data;
|
|
15411
|
+
if (res === null || res === void 0 ? void 0 : (_res$data = res.data) === null || _res$data === void 0 ? void 0 : _res$data.length) {
|
|
15412
|
+
res.data.trades = kmkfUtils.filterGyOrders(res === null || res === void 0 ? void 0 : res.data, orderNo).map(function (item) {
|
|
15413
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
15414
|
+
billNo: item.code,
|
|
15415
|
+
billType: item.orderTypeName,
|
|
15416
|
+
billTag: item.tagName,
|
|
15417
|
+
tradeTagName: item.tradeTagName,
|
|
15418
|
+
deliveryState: item.deliveryState,
|
|
15419
|
+
deliveryStateName: kmkfUtils.GY_DELIVERY_STATE_MAPPING[item.deliveryState]
|
|
15420
|
+
});
|
|
15421
|
+
});
|
|
15422
|
+
}
|
|
15423
|
+
resolve(res.data);
|
|
15424
|
+
// 延迟10秒清除,保证订单的时效性
|
|
15425
|
+
setTimeout(function () {
|
|
15426
|
+
singletonMap$2.delete(orderNo);
|
|
15427
|
+
}, 1000 * 10);
|
|
15428
|
+
} else {
|
|
15429
|
+
doReject(res);
|
|
15430
|
+
}
|
|
15431
|
+
}).catch(doReject);
|
|
15432
|
+
});
|
|
15433
|
+
singletonMap$2.set(orderNo, p);
|
|
15434
|
+
}
|
|
15435
|
+
return singletonMap$2.get(orderNo);
|
|
14717
15436
|
};
|
|
14718
|
-
var
|
|
14719
|
-
|
|
15437
|
+
var gyUtils = {
|
|
15438
|
+
getGyOrderListSingleton: getGyOrderListSingleton
|
|
14720
15439
|
};
|
|
14721
15440
|
|
|
14722
|
-
var singletonMap$
|
|
15441
|
+
var singletonMap$3 = new Map();
|
|
14723
15442
|
var getOrderListSingleton = function getOrderListSingleton(orderNo) {
|
|
14724
|
-
if (!singletonMap$
|
|
15443
|
+
if (!singletonMap$3.has(orderNo)) {
|
|
14725
15444
|
var p = new Promise(function (resolve, reject) {
|
|
14726
15445
|
var doReject = function doReject(err) {
|
|
14727
15446
|
// 清空掉错误的请求记录
|
|
14728
|
-
singletonMap$
|
|
15447
|
+
singletonMap$3.delete(orderNo);
|
|
14729
15448
|
reject(err);
|
|
14730
15449
|
};
|
|
14731
15450
|
extendRequest('/qy/gdfw/order/kmErpOrderDetail', {
|
|
@@ -14751,151 +15470,36 @@ var getOrderListSingleton = function getOrderListSingleton(orderNo) {
|
|
|
14751
15470
|
}
|
|
14752
15471
|
// 延迟10秒清除,保证订单的时效性
|
|
14753
15472
|
setTimeout(function () {
|
|
14754
|
-
singletonMap$
|
|
15473
|
+
singletonMap$3.delete(orderNo);
|
|
14755
15474
|
}, 1000 * 10);
|
|
14756
15475
|
} else {
|
|
14757
15476
|
doReject(data);
|
|
14758
15477
|
}
|
|
14759
15478
|
}).catch(doReject);
|
|
14760
15479
|
});
|
|
14761
|
-
singletonMap$
|
|
15480
|
+
singletonMap$3.set(orderNo, p);
|
|
14762
15481
|
}
|
|
14763
|
-
return singletonMap$
|
|
15482
|
+
return singletonMap$3.get(orderNo);
|
|
14764
15483
|
};
|
|
14765
15484
|
var kmUtils = {
|
|
14766
15485
|
getOrderListSingleton: getOrderListSingleton
|
|
14767
15486
|
};
|
|
14768
15487
|
|
|
14769
15488
|
var columnsMap = {
|
|
14770
|
-
BS_SYSTEM_ORDER:
|
|
14771
|
-
title: '单据类型',
|
|
14772
|
-
dataIndex: 'billType',
|
|
14773
|
-
width: 150
|
|
14774
|
-
}, {
|
|
14775
|
-
title: '系统订单号',
|
|
14776
|
-
dataIndex: 'billNo',
|
|
14777
|
-
width: 150
|
|
14778
|
-
}, {
|
|
14779
|
-
title: '标签',
|
|
14780
|
-
dataIndex: 'billTag',
|
|
14781
|
-
width: 150
|
|
14782
|
-
}, {
|
|
14783
|
-
title: '主播名称',
|
|
14784
|
-
dataIndex: 'authorName',
|
|
14785
|
-
width: 150
|
|
14786
|
-
}, {
|
|
14787
|
-
title: '主播ID',
|
|
14788
|
-
dataIndex: 'authorId',
|
|
14789
|
-
width: 150
|
|
14790
|
-
}
|
|
14791
|
-
// {
|
|
14792
|
-
// title: '直播活动',
|
|
14793
|
-
// dataIndex: 'liveActivites',
|
|
14794
|
-
// width: 150,
|
|
14795
|
-
// },
|
|
14796
|
-
],
|
|
14797
|
-
|
|
15489
|
+
BS_SYSTEM_ORDER: kmkfUtils.BS_SYSTEM_ORDER_CONFIG.columns,
|
|
14798
15490
|
KM_SYSTEM_ORDER: kmkfUtils.KM_SYSTEM_ORDER_CONFIG.columns,
|
|
14799
|
-
WLN_SYSTEM_ORDER:
|
|
14800
|
-
|
|
14801
|
-
|
|
14802
|
-
|
|
14803
|
-
}, {
|
|
14804
|
-
title: '系统订单号',
|
|
14805
|
-
dataIndex: 'billNo',
|
|
14806
|
-
width: 150
|
|
14807
|
-
}, {
|
|
14808
|
-
title: '标记',
|
|
14809
|
-
dataIndex: 'billTag',
|
|
14810
|
-
width: 150
|
|
14811
|
-
}],
|
|
14812
|
-
WDT_SYSTEM_ORDER: [{
|
|
14813
|
-
title: '订单类型',
|
|
14814
|
-
dataIndex: 'billType',
|
|
14815
|
-
width: 150
|
|
14816
|
-
}, {
|
|
14817
|
-
title: '系统订单号',
|
|
14818
|
-
dataIndex: 'billNo',
|
|
14819
|
-
width: 150
|
|
14820
|
-
}, {
|
|
14821
|
-
title: '订单标签',
|
|
14822
|
-
dataIndex: 'billTag',
|
|
14823
|
-
width: 150
|
|
14824
|
-
}],
|
|
14825
|
-
BS_E3_SYSTEM_ORDER: [{
|
|
14826
|
-
title: '系统订单号',
|
|
14827
|
-
dataIndex: 'orderSn',
|
|
14828
|
-
width: 150,
|
|
14829
|
-
ellipsis: true
|
|
14830
|
-
}, {
|
|
14831
|
-
title: '订单状态',
|
|
14832
|
-
dataIndex: 'orderStatus',
|
|
14833
|
-
width: 100,
|
|
14834
|
-
ellipsis: true,
|
|
14835
|
-
render: function render(val) {
|
|
14836
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, kmkfUtils.BS_E3_ORDER_STATUS_MAP[val] || val);
|
|
14837
|
-
}
|
|
14838
|
-
}, {
|
|
14839
|
-
title: '是否被拆分',
|
|
14840
|
-
dataIndex: 'isSplit',
|
|
14841
|
-
width: 100,
|
|
14842
|
-
ellipsis: true,
|
|
14843
|
-
render: function render(val) {
|
|
14844
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, kmkfUtils.BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14845
|
-
}
|
|
14846
|
-
}, {
|
|
14847
|
-
title: '是否拆分子单',
|
|
14848
|
-
dataIndex: 'isSplitNew',
|
|
14849
|
-
width: 100,
|
|
14850
|
-
ellipsis: true,
|
|
14851
|
-
render: function render(val) {
|
|
14852
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, kmkfUtils.BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14853
|
-
}
|
|
14854
|
-
}, {
|
|
14855
|
-
title: '是否被合并',
|
|
14856
|
-
dataIndex: 'isCombine',
|
|
14857
|
-
width: 100,
|
|
14858
|
-
ellipsis: true,
|
|
14859
|
-
render: function render(val) {
|
|
14860
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, kmkfUtils.BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14861
|
-
}
|
|
14862
|
-
}, {
|
|
14863
|
-
title: '是否合并新单',
|
|
14864
|
-
dataIndex: 'isCombineNew',
|
|
14865
|
-
width: 100,
|
|
14866
|
-
ellipsis: true,
|
|
14867
|
-
render: function render(val) {
|
|
14868
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, kmkfUtils.BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14869
|
-
}
|
|
14870
|
-
}, {
|
|
14871
|
-
title: '是否复制单',
|
|
14872
|
-
dataIndex: 'isCopy',
|
|
14873
|
-
width: 100,
|
|
14874
|
-
ellipsis: true,
|
|
14875
|
-
render: function render(val) {
|
|
14876
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, kmkfUtils.BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14877
|
-
}
|
|
14878
|
-
}, {
|
|
14879
|
-
title: '是否换货单',
|
|
14880
|
-
dataIndex: 'isExchangeOrder',
|
|
14881
|
-
width: 100,
|
|
14882
|
-
ellipsis: true,
|
|
14883
|
-
render: function render(val) {
|
|
14884
|
-
return /*#__PURE__*/React__default['default'].createElement("span", null, kmkfUtils.BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14885
|
-
}
|
|
14886
|
-
}, {
|
|
14887
|
-
title: '订单备注',
|
|
14888
|
-
dataIndex: 'orderMsg',
|
|
14889
|
-
width: 150,
|
|
14890
|
-
ellipsis: true
|
|
14891
|
-
}]
|
|
15491
|
+
WLN_SYSTEM_ORDER: kmkfUtils.WLN_SYSTEM_ORDER_CONFIG.columns,
|
|
15492
|
+
WDT_SYSTEM_ORDER: kmkfUtils.WDT_SYSTEM_ORDER_CONFIG.columns,
|
|
15493
|
+
BS_E3_SYSTEM_ORDER: kmkfUtils.BS_E3_SYSTEM_ORDER_CONFIG.columns,
|
|
15494
|
+
GY_SYSTEM_ORDER: kmkfUtils.GY_SYSTEM_ORDER_CONFIG.columns
|
|
14892
15495
|
};
|
|
14893
15496
|
var rowKeyMap = {
|
|
14894
15497
|
BS_SYSTEM_ORDER: 'billNo',
|
|
14895
15498
|
KM_SYSTEM_ORDER: 'billNo',
|
|
14896
15499
|
WLN_SYSTEM_ORDER: 'billNo',
|
|
14897
15500
|
WDT_SYSTEM_ORDER: 'billNo',
|
|
14898
|
-
BS_E3_SYSTEM_ORDER: 'orderSn'
|
|
15501
|
+
BS_E3_SYSTEM_ORDER: 'orderSn',
|
|
15502
|
+
GY_SYSTEM_ORDER: 'billNo'
|
|
14899
15503
|
};
|
|
14900
15504
|
var index$1 = (function (props) {
|
|
14901
15505
|
var value = props.value,
|
|
@@ -14917,6 +15521,9 @@ var index$1 = (function (props) {
|
|
|
14917
15521
|
getWdtOrderList(value.orderNo);
|
|
14918
15522
|
} else if (type === 'BS_E3_SYSTEM_ORDER') {
|
|
14919
15523
|
getBsE3OrderList(value.orderNo);
|
|
15524
|
+
} else if (type === 'GY_SYSTEM_ORDER') {
|
|
15525
|
+
console.log('触发gy--getGyOrderList--1');
|
|
15526
|
+
getGyOrderList(value.orderNo);
|
|
14920
15527
|
}
|
|
14921
15528
|
}
|
|
14922
15529
|
}, [value, type]);
|
|
@@ -15103,6 +15710,45 @@ var index$1 = (function (props) {
|
|
|
15103
15710
|
return _ref6.apply(this, arguments);
|
|
15104
15711
|
};
|
|
15105
15712
|
}();
|
|
15713
|
+
var getGyOrderList = /*#__PURE__*/function () {
|
|
15714
|
+
var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(orderNo) {
|
|
15715
|
+
return _regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
15716
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
15717
|
+
case 0:
|
|
15718
|
+
gyUtils.getGyOrderListSingleton(orderNo).then(function (data) {
|
|
15719
|
+
var trades = ((data === null || data === void 0 ? void 0 : data.trades) || []).filter(function (item) {
|
|
15720
|
+
return kmkfUtils.getIsPlatformCodesIncludeOrderNos(item.platformCode, orderNo);
|
|
15721
|
+
});
|
|
15722
|
+
_onChange === null || _onChange === void 0 ? void 0 : _onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
15723
|
+
orders: trades,
|
|
15724
|
+
showOrderInfo: trades.map(function (_ref9) {
|
|
15725
|
+
var billNo = _ref9.billNo,
|
|
15726
|
+
billType = _ref9.billType,
|
|
15727
|
+
billTag = _ref9.billTag,
|
|
15728
|
+
tradeTagName = _ref9.tradeTagName,
|
|
15729
|
+
deliveryState = _ref9.deliveryState;
|
|
15730
|
+
return {
|
|
15731
|
+
billNo: billNo,
|
|
15732
|
+
billType: billType,
|
|
15733
|
+
billTag: billTag,
|
|
15734
|
+
tradeTagName: tradeTagName,
|
|
15735
|
+
deliveryState: deliveryState,
|
|
15736
|
+
deliveryStateName: kmkfUtils.GY_DELIVERY_STATE_MAPPING[deliveryState]
|
|
15737
|
+
};
|
|
15738
|
+
})
|
|
15739
|
+
}));
|
|
15740
|
+
});
|
|
15741
|
+
onceRef.current = false;
|
|
15742
|
+
case 2:
|
|
15743
|
+
case "end":
|
|
15744
|
+
return _context6.stop();
|
|
15745
|
+
}
|
|
15746
|
+
}, _callee6);
|
|
15747
|
+
}));
|
|
15748
|
+
return function getGyOrderList(_x6) {
|
|
15749
|
+
return _ref8.apply(this, arguments);
|
|
15750
|
+
};
|
|
15751
|
+
}();
|
|
15106
15752
|
var rowSelection = {
|
|
15107
15753
|
selectedRowKeys: (value === null || value === void 0 ? void 0 : value.selectIds) || [],
|
|
15108
15754
|
fixed: true,
|
|
@@ -15119,7 +15765,24 @@ var index$1 = (function (props) {
|
|
|
15119
15765
|
};
|
|
15120
15766
|
}
|
|
15121
15767
|
};
|
|
15122
|
-
|
|
15768
|
+
// useEffect(() => {
|
|
15769
|
+
// const dom = document.querySelector(
|
|
15770
|
+
// `.${type}_SYSTEM_ORDER_COMPONENT .ant-table-content`,
|
|
15771
|
+
// );
|
|
15772
|
+
// //解决列表出现横向滚动条时选择数据造成行内闪烁问题
|
|
15773
|
+
// if (
|
|
15774
|
+
// (value?.selectIds || []).length > 0 &&
|
|
15775
|
+
// dom &&
|
|
15776
|
+
// dom.scrollWidth > dom.clientWidth &&
|
|
15777
|
+
// dom.scrollLeft === 0
|
|
15778
|
+
// ) {
|
|
15779
|
+
// console.log(dom.scrollWidth > dom.clientWidth, dom.scrollLeft === 0);
|
|
15780
|
+
// dom.scrollLeft = 1;
|
|
15781
|
+
// }
|
|
15782
|
+
// }, [JSON.stringify(value?.selectIds || [])]);
|
|
15783
|
+
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
15784
|
+
className: "".concat(type, "_SYSTEM_ORDER_COMPONENT")
|
|
15785
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Table, {
|
|
15123
15786
|
dataSource: (value === null || value === void 0 ? void 0 : value.orders) || [],
|
|
15124
15787
|
columns: columns,
|
|
15125
15788
|
rowSelection: rowSelection,
|
|
@@ -15127,12 +15790,12 @@ var index$1 = (function (props) {
|
|
|
15127
15790
|
size: "small",
|
|
15128
15791
|
pagination: false,
|
|
15129
15792
|
scroll: {
|
|
15130
|
-
x: '
|
|
15793
|
+
x: 'max-content'
|
|
15131
15794
|
},
|
|
15132
15795
|
locale: {
|
|
15133
15796
|
emptyText: '暂无数据'
|
|
15134
15797
|
}
|
|
15135
|
-
});
|
|
15798
|
+
}));
|
|
15136
15799
|
});
|
|
15137
15800
|
|
|
15138
15801
|
var WlnGoods = function WlnGoods(props) {
|
|
@@ -15158,13 +15821,14 @@ var WlnGoods = function WlnGoods(props) {
|
|
|
15158
15821
|
};
|
|
15159
15822
|
|
|
15160
15823
|
var componentMap$1 = {
|
|
15161
|
-
|
|
15824
|
+
WDT_GOODS: {
|
|
15162
15825
|
type: 'wdt',
|
|
15163
15826
|
key: 'wdtGoods',
|
|
15164
15827
|
name: '旺店通',
|
|
15165
15828
|
orderNo: 'srcTid',
|
|
15166
15829
|
goodDetailOrderNo: 'srcTid',
|
|
15167
15830
|
eventNameMap: {
|
|
15831
|
+
// pubsub 事件
|
|
15168
15832
|
type: 'wdtType',
|
|
15169
15833
|
updateGoodsHandle: kmkfUtils.updateWdtGoodsHandle,
|
|
15170
15834
|
selectListReturn: 'wdtSelectListReturn',
|
|
@@ -15182,13 +15846,14 @@ var componentMap$1 = {
|
|
|
15182
15846
|
exchangeDeleteGood: 'wdtExchangeDeleteGood'
|
|
15183
15847
|
}
|
|
15184
15848
|
},
|
|
15185
|
-
|
|
15849
|
+
BS_E3_GOODS: {
|
|
15186
15850
|
type: 'e3',
|
|
15187
15851
|
key: 'bsE3Goods',
|
|
15188
15852
|
name: '百胜E3',
|
|
15189
15853
|
orderNo: 'dealCode',
|
|
15190
15854
|
goodDetailOrderNo: 'originalDealCode',
|
|
15191
15855
|
eventNameMap: {
|
|
15856
|
+
// pubsub 事件
|
|
15192
15857
|
type: 'bsE3Type',
|
|
15193
15858
|
updateGoodsHandle: kmkfUtils.updateBsE3GoodsHandle,
|
|
15194
15859
|
selectListReturn: 'bsE3SelectListReturn',
|
|
@@ -15205,6 +15870,31 @@ var componentMap$1 = {
|
|
|
15205
15870
|
returnDeleteGood: 'bsE3ReturnDeleteGood',
|
|
15206
15871
|
exchangeDeleteGood: 'bsE3ExchangeDeleteGood'
|
|
15207
15872
|
}
|
|
15873
|
+
},
|
|
15874
|
+
GY_GOODS: {
|
|
15875
|
+
type: 'gy',
|
|
15876
|
+
key: 'gyGoods',
|
|
15877
|
+
name: '管易',
|
|
15878
|
+
orderNo: 'dealCode',
|
|
15879
|
+
goodDetailOrderNo: 'originalDealCode',
|
|
15880
|
+
eventNameMap: {
|
|
15881
|
+
// pubsub 事件
|
|
15882
|
+
type: 'gyType',
|
|
15883
|
+
updateGoodsHandle: kmkfUtils.updateGyGoodsHandle,
|
|
15884
|
+
selectListReturn: 'gySelectListReturn',
|
|
15885
|
+
selectList: 'gySelectList',
|
|
15886
|
+
reissueSelectList: 'gyReissueSelectList',
|
|
15887
|
+
reissueSelectListReturn: 'gyReissueSelectListReturn',
|
|
15888
|
+
reissueDeleteGood: 'gyReissueDeleteGood',
|
|
15889
|
+
changeShopCode: 'gyChangeShopCode',
|
|
15890
|
+
reissueType: 'gyReissueType',
|
|
15891
|
+
returnType: 'gyReturnType',
|
|
15892
|
+
returnSelectListReturn: 'gyReturnSelectListReturn',
|
|
15893
|
+
returnSelectList: 'gyReturnSelectList',
|
|
15894
|
+
deleteGood: 'gyDeleteGood',
|
|
15895
|
+
returnDeleteGood: 'gyReturnDeleteGood',
|
|
15896
|
+
exchangeDeleteGood: 'gyExchangeDeleteGood'
|
|
15897
|
+
}
|
|
15208
15898
|
}
|
|
15209
15899
|
};
|
|
15210
15900
|
var CommonGoods = function CommonGoods(props) {
|
|
@@ -16919,6 +17609,255 @@ var bsE3Reissue = function bsE3Reissue(props) {
|
|
|
16919
17609
|
})));
|
|
16920
17610
|
};
|
|
16921
17611
|
|
|
17612
|
+
var _excluded$l = ["value", "onChange", "reasonList", "disabled", "type"],
|
|
17613
|
+
_excluded2 = ["billNo", "billType", "billTag", "tradeTagName", "deliveryState"];
|
|
17614
|
+
var typeMap$3 = {
|
|
17615
|
+
GY_REISSUE_GOODS: {
|
|
17616
|
+
key: 'gyReissueGoods',
|
|
17617
|
+
name: '管易',
|
|
17618
|
+
typeName: 'gyReissueType',
|
|
17619
|
+
systemOrder: 'gySystemOrder',
|
|
17620
|
+
systemOrderNo: 'gySystemOrderNo',
|
|
17621
|
+
reissueSelectList: 'gyReissueSelectList',
|
|
17622
|
+
reissueSelectListReturn: 'gyReissueSelectListReturn',
|
|
17623
|
+
reissueDeleteGood: 'gyReissueDeleteGood',
|
|
17624
|
+
changeShopCode: 'gyChangeShopCode',
|
|
17625
|
+
reissueType: 'gyReissueType',
|
|
17626
|
+
formatDefaultField: {
|
|
17627
|
+
money: 'orderPrice',
|
|
17628
|
+
share: 'sharePrice'
|
|
17629
|
+
},
|
|
17630
|
+
getOrderList: gyUtils.getGyOrderListSingleton
|
|
17631
|
+
}
|
|
17632
|
+
};
|
|
17633
|
+
var GyReissue = function GyReissue(props) {
|
|
17634
|
+
var _value$gySystemOrder, _typeMap$type26, _typeMap$type28, _typeMap$type29, _value$typeMap$type$s5, _typeMap$type30, _typeMap$type31, _typeMap$type32;
|
|
17635
|
+
var value = props.value,
|
|
17636
|
+
onChange = props.onChange,
|
|
17637
|
+
_props$reasonList = props.reasonList,
|
|
17638
|
+
reasonList = _props$reasonList === void 0 ? [] : _props$reasonList,
|
|
17639
|
+
disabled = props.disabled,
|
|
17640
|
+
type = props.type,
|
|
17641
|
+
other = _objectWithoutProperties(props, _excluded$l);
|
|
17642
|
+
var showModeBtn = ((value === null || value === void 0 ? void 0 : (_value$gySystemOrder = value.gySystemOrder) === null || _value$gySystemOrder === void 0 ? void 0 : _value$gySystemOrder.orders) || []).some(function (order) {
|
|
17643
|
+
var _order$platformCode;
|
|
17644
|
+
return order === null || order === void 0 ? void 0 : (_order$platformCode = order.platformCode) === null || _order$platformCode === void 0 ? void 0 : _order$platformCode.includes(';');
|
|
17645
|
+
});
|
|
17646
|
+
var getOrderFlag = React.useRef(false);
|
|
17647
|
+
var _useState = React.useState(false),
|
|
17648
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
17649
|
+
isStrict = _useState2[0],
|
|
17650
|
+
setIsStrict = _useState2[1];
|
|
17651
|
+
React.useEffect(function () {
|
|
17652
|
+
var _value$typeMap$type$s, _value$typeMap$type$s2, _typeMap$type, _value$typeMap$type$s3, _typeMap$type2;
|
|
17653
|
+
if (!getOrderFlag.current && !(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s = value[(_typeMap$type = typeMap$3[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$3[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)) {
|
|
17654
|
+
var _value$typeMap$type$s4, _typeMap$type3;
|
|
17655
|
+
getOrderFlag.current = true;
|
|
17656
|
+
getOrderList(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s4 = value[(_typeMap$type3 = typeMap$3[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);
|
|
17657
|
+
}
|
|
17658
|
+
return;
|
|
17659
|
+
}, [value]);
|
|
17660
|
+
var getOrderList = /*#__PURE__*/function () {
|
|
17661
|
+
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderNo) {
|
|
17662
|
+
var _typeMap$type4;
|
|
17663
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
17664
|
+
while (1) switch (_context.prev = _context.next) {
|
|
17665
|
+
case 0:
|
|
17666
|
+
(_typeMap$type4 = typeMap$3[type]) === null || _typeMap$type4 === void 0 ? void 0 : _typeMap$type4.getOrderList(orderNo).then(function (data) {
|
|
17667
|
+
var _typeMap$type5, _typeMap$type6;
|
|
17668
|
+
var orders = (data === null || data === void 0 ? void 0 : data.trades) || [];
|
|
17669
|
+
var showOrderInfo = orders.map(function (_ref2) {
|
|
17670
|
+
var billNo = _ref2.billNo,
|
|
17671
|
+
billType = _ref2.billType,
|
|
17672
|
+
billTag = _ref2.billTag,
|
|
17673
|
+
tradeTagName = _ref2.tradeTagName,
|
|
17674
|
+
deliveryState = _ref2.deliveryState,
|
|
17675
|
+
rest = _objectWithoutProperties(_ref2, _excluded2);
|
|
17676
|
+
return _objectSpread2(_objectSpread2({}, rest), {}, {
|
|
17677
|
+
billNo: billNo,
|
|
17678
|
+
billType: billType,
|
|
17679
|
+
billTag: billTag,
|
|
17680
|
+
tradeTagName: tradeTagName,
|
|
17681
|
+
deliveryState: deliveryState,
|
|
17682
|
+
deliveryStateName: kmkfUtils.GY_DELIVERY_STATE_MAPPING[deliveryState]
|
|
17683
|
+
});
|
|
17684
|
+
});
|
|
17685
|
+
onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type5 = typeMap$3[type]) === null || _typeMap$type5 === void 0 ? void 0 : _typeMap$type5.systemOrder, _objectSpread2(_objectSpread2({}, value[(_typeMap$type6 = typeMap$3[type]) === null || _typeMap$type6 === void 0 ? void 0 : _typeMap$type6.systemOrder]), {}, {
|
|
17686
|
+
showOrderInfo: showOrderInfo,
|
|
17687
|
+
orders: orders
|
|
17688
|
+
}))));
|
|
17689
|
+
});
|
|
17690
|
+
case 1:
|
|
17691
|
+
case "end":
|
|
17692
|
+
return _context.stop();
|
|
17693
|
+
}
|
|
17694
|
+
}, _callee);
|
|
17695
|
+
}));
|
|
17696
|
+
return function getOrderList(_x) {
|
|
17697
|
+
return _ref.apply(this, arguments);
|
|
17698
|
+
};
|
|
17699
|
+
}();
|
|
17700
|
+
var changeTypeHandle = function changeTypeHandle(val) {
|
|
17701
|
+
var _value$typeMap$type$t, _typeMap$type7, _typeMap$type8;
|
|
17702
|
+
var typeName = val === null || val === void 0 ? void 0 : val[0];
|
|
17703
|
+
if (typeName === (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t = value[(_typeMap$type7 = typeMap$3[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;
|
|
17704
|
+
// const systemOrderNo = value?.[typeMap[type]?.systemOrderNo];
|
|
17705
|
+
var newValue = _objectSpread2({}, value);
|
|
17706
|
+
newValue[(_typeMap$type8 = typeMap$3[type]) === null || _typeMap$type8 === void 0 ? void 0 : _typeMap$type8.typeName] = val;
|
|
17707
|
+
if (typeName === '1') {
|
|
17708
|
+
var _typeMap$type9;
|
|
17709
|
+
newValue[(_typeMap$type9 = typeMap$3[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.key] = getGoodDetails({
|
|
17710
|
+
mode: isStrict
|
|
17711
|
+
});
|
|
17712
|
+
} else if (typeName === '2') {
|
|
17713
|
+
var _typeMap$type10;
|
|
17714
|
+
// 切换到非原单,清空列表
|
|
17715
|
+
newValue[(_typeMap$type10 = typeMap$3[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.key] = [];
|
|
17716
|
+
}
|
|
17717
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
17718
|
+
};
|
|
17719
|
+
var handleModeChange = function handleModeChange(mode) {
|
|
17720
|
+
var _value$typeMap$type$t2, _typeMap$type11, _typeMap$type12;
|
|
17721
|
+
var isOriginalOrder = (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t2 = value[(_typeMap$type11 = typeMap$3[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';
|
|
17722
|
+
setIsStrict(mode);
|
|
17723
|
+
if (!isOriginalOrder) return;
|
|
17724
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type12 = typeMap$3[type]) === null || _typeMap$type12 === void 0 ? void 0 : _typeMap$type12.key, getGoodDetails({
|
|
17725
|
+
mode: mode
|
|
17726
|
+
}))));
|
|
17727
|
+
};
|
|
17728
|
+
var getGoodDetails = function getGoodDetails(_ref3) {
|
|
17729
|
+
var _typeMap$type13, _typeMap$type14, _order$details;
|
|
17730
|
+
var mode = _ref3.mode,
|
|
17731
|
+
sysOrderNo = _ref3.sysOrderNo;
|
|
17732
|
+
var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type13 = typeMap$3[type]) === null || _typeMap$type13 === void 0 ? void 0 : _typeMap$type13.systemOrder];
|
|
17733
|
+
var systemOrderNo = sysOrderNo !== null && sysOrderNo !== void 0 ? sysOrderNo : value === null || value === void 0 ? void 0 : value[(_typeMap$type14 = typeMap$3[type]) === null || _typeMap$type14 === void 0 ? void 0 : _typeMap$type14.systemOrderNo];
|
|
17734
|
+
var order = systemOrderNo && ((systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orders) || []).find(function (order) {
|
|
17735
|
+
return order.code === systemOrderNo;
|
|
17736
|
+
});
|
|
17737
|
+
var goodDetails = (order === null || order === void 0 ? void 0 : (_order$details = order.details) === null || _order$details === void 0 ? void 0 : _order$details.length) ? kmkfUtils.updateGyGoodsHandle([order]) : [];
|
|
17738
|
+
var orderNo = systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orderNo;
|
|
17739
|
+
return mode ? goodDetails.filter(function (goodItem) {
|
|
17740
|
+
return !orderNo || (orderNo || '').includes(goodItem.oid);
|
|
17741
|
+
}) : goodDetails;
|
|
17742
|
+
};
|
|
17743
|
+
var changeGoodHandle = function changeGoodHandle(val) {
|
|
17744
|
+
var _typeMap$type15;
|
|
17745
|
+
var newValue = _objectSpread2({}, value);
|
|
17746
|
+
newValue["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type15 = typeMap$3[type]) === null || _typeMap$type15 === void 0 ? void 0 : _typeMap$type15.key)] = (val || []).map(function (item) {
|
|
17747
|
+
var _typeMap$type16, _typeMap$type17;
|
|
17748
|
+
item["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type16 = typeMap$3[type]) === null || _typeMap$type16 === void 0 ? void 0 : _typeMap$type16.formatDefaultField.money)] = 0;
|
|
17749
|
+
item["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type17 = typeMap$3[type]) === null || _typeMap$type17 === void 0 ? void 0 : _typeMap$type17.formatDefaultField.share)] = 0;
|
|
17750
|
+
return item;
|
|
17751
|
+
});
|
|
17752
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
17753
|
+
};
|
|
17754
|
+
var changeSystemOrderHandle = function changeSystemOrderHandle(val) {
|
|
17755
|
+
var _typeMap$type18, _value$typeMap$type$t3, _typeMap$type19, _value$typeMap$type$t4, _typeMap$type21;
|
|
17756
|
+
var newValue = _objectSpread2({}, value);
|
|
17757
|
+
newValue["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type18 = typeMap$3[type]) === null || _typeMap$type18 === void 0 ? void 0 : _typeMap$type18.systemOrderNo)] = val;
|
|
17758
|
+
if (['2'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t3 = value[(_typeMap$type19 = typeMap$3[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])) {
|
|
17759
|
+
var _typeMap$type20;
|
|
17760
|
+
newValue["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type20 = typeMap$3[type]) === null || _typeMap$type20 === void 0 ? void 0 : _typeMap$type20.key)] = [];
|
|
17761
|
+
} else if (['1'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t4 = value[(_typeMap$type21 = typeMap$3[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])) {
|
|
17762
|
+
var _typeMap$type22;
|
|
17763
|
+
newValue["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type22 = typeMap$3[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.key)] = getGoodDetails({
|
|
17764
|
+
mode: isStrict,
|
|
17765
|
+
sysOrderNo: val
|
|
17766
|
+
});
|
|
17767
|
+
}
|
|
17768
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
17769
|
+
};
|
|
17770
|
+
var selectedGoodsChange = React.useCallback(function (skuList) {
|
|
17771
|
+
var _typeMap$type23, _typeMap$type24, _uniqBy, _typeMap$type25;
|
|
17772
|
+
var newValue = _objectSpread2({}, value);
|
|
17773
|
+
// 原订单商品
|
|
17774
|
+
var originTradeGoodList = getGoodDetails({
|
|
17775
|
+
mode: isStrict
|
|
17776
|
+
}) || [];
|
|
17777
|
+
// 当前选中的所有商品【包含了原订单+商品库】
|
|
17778
|
+
var currentSelectGoodList = (value === null || value === void 0 ? void 0 : value["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type23 = typeMap$3[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.key)]) || [];
|
|
17779
|
+
newValue["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type24 = typeMap$3[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.key)] = (_uniqBy = lodash.uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
|
|
17780
|
+
return skuList.includes(item.uuid);
|
|
17781
|
+
});
|
|
17782
|
+
console.log('商品发生变化', newValue["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type25 = typeMap$3[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.key)]);
|
|
17783
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
17784
|
+
}, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type26 = typeMap$3[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.key)], isStrict]);
|
|
17785
|
+
//显示选择商品按钮 原单换不显示选择商品
|
|
17786
|
+
var showChangeBtn = React.useMemo(function () {
|
|
17787
|
+
var _typeMap$type27;
|
|
17788
|
+
return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type27 = typeMap$3[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrderNo]);
|
|
17789
|
+
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$type28 = typeMap$3[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.systemOrderNo]]);
|
|
17790
|
+
return /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement(antd.Row, {
|
|
17791
|
+
gutter: 8,
|
|
17792
|
+
wrap: true
|
|
17793
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Col, {
|
|
17794
|
+
className: "gutter-row",
|
|
17795
|
+
xs: {
|
|
17796
|
+
span: 11
|
|
17797
|
+
},
|
|
17798
|
+
sm: {
|
|
17799
|
+
span: 6
|
|
17800
|
+
}
|
|
17801
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Select, {
|
|
17802
|
+
style: {
|
|
17803
|
+
marginBottom: '8px'
|
|
17804
|
+
},
|
|
17805
|
+
disabled: disabled,
|
|
17806
|
+
allowClear: false,
|
|
17807
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type29 = typeMap$3[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.systemOrderNo)],
|
|
17808
|
+
onChange: function onChange(val) {
|
|
17809
|
+
return changeSystemOrderHandle(val);
|
|
17810
|
+
},
|
|
17811
|
+
placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
|
|
17812
|
+
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type30 = typeMap$3[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) {
|
|
17813
|
+
return /*#__PURE__*/React__default['default'].createElement(antd.Select.Option, {
|
|
17814
|
+
key: item.billNo,
|
|
17815
|
+
value: item.billNo,
|
|
17816
|
+
label: item.billNo
|
|
17817
|
+
}, item.billNo);
|
|
17818
|
+
}))), /*#__PURE__*/React__default['default'].createElement(antd.Col, {
|
|
17819
|
+
className: "gutter-row",
|
|
17820
|
+
xs: {
|
|
17821
|
+
span: 11
|
|
17822
|
+
},
|
|
17823
|
+
sm: {
|
|
17824
|
+
span: 6
|
|
17825
|
+
}
|
|
17826
|
+
}, /*#__PURE__*/React__default['default'].createElement(antd.Cascader, {
|
|
17827
|
+
style: {
|
|
17828
|
+
marginBottom: '8px'
|
|
17829
|
+
},
|
|
17830
|
+
disabled: disabled,
|
|
17831
|
+
allowClear: false,
|
|
17832
|
+
options: reasonList,
|
|
17833
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type31 = typeMap$3[type]) === null || _typeMap$type31 === void 0 ? void 0 : _typeMap$type31.typeName)],
|
|
17834
|
+
onChange: function onChange(val) {
|
|
17835
|
+
return changeTypeHandle(val);
|
|
17836
|
+
}
|
|
17837
|
+
}))), /*#__PURE__*/React__default['default'].createElement(GoodItem$1, _objectSpread2(_objectSpread2({
|
|
17838
|
+
key: 'reissueGoods'
|
|
17839
|
+
}, other), {}, {
|
|
17840
|
+
type: type,
|
|
17841
|
+
disabled: disabled,
|
|
17842
|
+
canUpdateNumber: showChangeBtn,
|
|
17843
|
+
showChangeBtn: showChangeBtn,
|
|
17844
|
+
shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
|
|
17845
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$3 === null || typeMap$3 === void 0 ? void 0 : (_typeMap$type32 = typeMap$3[type]) === null || _typeMap$type32 === void 0 ? void 0 : _typeMap$type32.key)],
|
|
17846
|
+
onChange: function onChange(val) {
|
|
17847
|
+
return changeGoodHandle(val);
|
|
17848
|
+
},
|
|
17849
|
+
onModeChange: handleModeChange,
|
|
17850
|
+
showModeBtn: showModeBtn,
|
|
17851
|
+
isStrict: isStrict,
|
|
17852
|
+
tradeGoods: {
|
|
17853
|
+
originDataSource: getGoodDetails({
|
|
17854
|
+
mode: isStrict
|
|
17855
|
+
}),
|
|
17856
|
+
selectedGoodsChange: selectedGoodsChange
|
|
17857
|
+
}
|
|
17858
|
+
})));
|
|
17859
|
+
};
|
|
17860
|
+
|
|
16922
17861
|
exports.Address = ApaasAddress;
|
|
16923
17862
|
exports.AliPay = AliPay;
|
|
16924
17863
|
exports.ApaasAddress = Province;
|
|
@@ -16957,6 +17896,7 @@ exports.CommonSystemOrder = CommonSystemOrder;
|
|
|
16957
17896
|
exports.ExpressLogistics = ExpressLogistics;
|
|
16958
17897
|
exports.Goods = Goods;
|
|
16959
17898
|
exports.GoodsTable = index$2;
|
|
17899
|
+
exports.GyReissue = GyReissue;
|
|
16960
17900
|
exports.IdentifyAddress = IdentifyAddress;
|
|
16961
17901
|
exports.Invoice = Invoice;
|
|
16962
17902
|
exports.JstGoods = jstGoods;
|