@kmkf-fe-packages/basic-components 1.22.1-beta.7 → 1.22.1-beta.74
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/README.md +3 -1
- package/dist/index.esm.js +2583 -1275
- package/dist/index.js +2583 -1273
- package/dist/src/apaas/ApaasLogistics/index.d.ts +1 -0
- package/dist/src/bs/component/GoodItem/constants/bsE3ReissueGoodsColumns.d.ts +7 -0
- package/dist/src/bs/component/GoodItem/constants/wdtReissueGoodsColumns.d.ts +9 -0
- package/dist/src/bs/component/GoodItem/index.d.ts +5 -1
- 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/common/Goods/RichItem.d.ts +6 -1
- package/dist/src/constants/bs.d.ts +3 -0
- package/dist/src/constants/bs_e3.d.ts +3 -0
- package/dist/src/constants/columnsBaseInfoMap.d.ts +7 -0
- package/dist/src/constants/defaultColumns.d.ts +3 -0
- package/dist/src/constants/gy.d.ts +3 -0
- package/dist/src/constants/wdt.d.ts +3 -0
- package/dist/src/constants/wln.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 +2 -0
- package/package.json +3 -3
- package/dist/src/bs/component/GoodItem/bsE3ReissueGoodsColumns.d.ts +0 -29
- package/dist/src/bs/component/GoodItem/wdtReissueGoodsColumns.d.ts +0 -21
package/dist/index.esm.js
CHANGED
|
@@ -3,384 +3,370 @@ import { Cascader, DatePicker, InputNumber, Input, Select, Upload, Image, messag
|
|
|
3
3
|
import { EyeOutlined, DeleteOutlined, CloseCircleOutlined, CaretUpOutlined } from '@ant-design/icons';
|
|
4
4
|
import request, { extend as extend$1 } from 'umi-request';
|
|
5
5
|
import { CopyToClipboard } from 'react-copy-to-clipboard';
|
|
6
|
-
import { AddressData, BsAddressData, WdtAddressData, request as request$1, ExpressData, uuid, LogisticsAddressData, SendDataCenter, BS_E3_BOOLEAN_STATUS_MAP, filterWdtOrders, WDT_ORDER_TYPE_MAP, filterBsE3Orders, filterKmOrders, KM_SYSTEM_ORDER_CONFIG,
|
|
7
|
-
import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, cloneDeep, difference, differenceWith, takeRight, reject, isEmpty, intersection } from 'lodash';
|
|
6
|
+
import { AddressData, BsAddressData, WdtAddressData, GyAddressData, request as request$1, ExpressData, uuid, columnsGoodsList, LogisticsAddressData, SendDataCenter, BS_E3_BOOLEAN_STATUS_MAP, isNull, filterWdtOrders, WDT_ORDER_TYPE_MAP, filterBsE3Orders, filterGyOrders, GY_DELIVERY_STATE_MAPPING, filterKmOrders, getIsPlatformCodesIncludeOrderNos, BS_SYSTEM_ORDER_CONFIG, KM_SYSTEM_ORDER_CONFIG, WLN_SYSTEM_ORDER_CONFIG, WDT_SYSTEM_ORDER_CONFIG, BS_E3_SYSTEM_ORDER_CONFIG, GY_SYSTEM_ORDER_CONFIG, updateWdtGoodsHandle, updateBsE3GoodsHandle, updateGyGoodsHandle, msgTypeCh } from '@kmkf-fe-packages/kmkf-utils';
|
|
7
|
+
import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, cloneDeep, difference, differenceWith, takeRight, reject, isEmpty, intersection, uniqBy } from 'lodash';
|
|
8
8
|
import { useUpdateEffect, useDebounceEffect, useAntdTable } from 'ahooks';
|
|
9
9
|
import zhCN from 'antd/lib/locale/zh_CN';
|
|
10
10
|
import pubsub from 'pubsub-js';
|
|
11
11
|
import BigNumber from 'bignumber.js';
|
|
12
12
|
|
|
13
|
-
function _iterableToArrayLimit(
|
|
14
|
-
var
|
|
15
|
-
if (null !=
|
|
16
|
-
var
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
13
|
+
function _iterableToArrayLimit(arr, i) {
|
|
14
|
+
var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"];
|
|
15
|
+
if (null != _i) {
|
|
16
|
+
var _s,
|
|
17
|
+
_e,
|
|
18
|
+
_x,
|
|
19
|
+
_r,
|
|
20
|
+
_arr = [],
|
|
21
|
+
_n = !0,
|
|
22
|
+
_d = !1;
|
|
23
23
|
try {
|
|
24
|
-
if (
|
|
25
|
-
if (Object(
|
|
26
|
-
|
|
27
|
-
} else for (; !(
|
|
28
|
-
} catch (
|
|
29
|
-
|
|
24
|
+
if (_x = (_i = _i.call(arr)).next, 0 === i) {
|
|
25
|
+
if (Object(_i) !== _i) return;
|
|
26
|
+
_n = !1;
|
|
27
|
+
} else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0);
|
|
28
|
+
} catch (err) {
|
|
29
|
+
_d = !0, _e = err;
|
|
30
30
|
} finally {
|
|
31
31
|
try {
|
|
32
|
-
if (!
|
|
32
|
+
if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return;
|
|
33
33
|
} finally {
|
|
34
|
-
if (
|
|
34
|
+
if (_d) throw _e;
|
|
35
35
|
}
|
|
36
36
|
}
|
|
37
|
-
return
|
|
37
|
+
return _arr;
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
|
-
function ownKeys(
|
|
41
|
-
var
|
|
40
|
+
function ownKeys(object, enumerableOnly) {
|
|
41
|
+
var keys = Object.keys(object);
|
|
42
42
|
if (Object.getOwnPropertySymbols) {
|
|
43
|
-
var
|
|
44
|
-
|
|
45
|
-
return Object.getOwnPropertyDescriptor(
|
|
46
|
-
})),
|
|
43
|
+
var symbols = Object.getOwnPropertySymbols(object);
|
|
44
|
+
enumerableOnly && (symbols = symbols.filter(function (sym) {
|
|
45
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
46
|
+
})), keys.push.apply(keys, symbols);
|
|
47
47
|
}
|
|
48
|
-
return
|
|
49
|
-
}
|
|
50
|
-
function _objectSpread2(
|
|
51
|
-
for (var
|
|
52
|
-
var
|
|
53
|
-
|
|
54
|
-
_defineProperty(
|
|
55
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(
|
|
56
|
-
Object.defineProperty(
|
|
48
|
+
return keys;
|
|
49
|
+
}
|
|
50
|
+
function _objectSpread2(target) {
|
|
51
|
+
for (var i = 1; i < arguments.length; i++) {
|
|
52
|
+
var source = null != arguments[i] ? arguments[i] : {};
|
|
53
|
+
i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
|
|
54
|
+
_defineProperty(target, key, source[key]);
|
|
55
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {
|
|
56
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
57
57
|
});
|
|
58
58
|
}
|
|
59
|
-
return
|
|
59
|
+
return target;
|
|
60
60
|
}
|
|
61
61
|
function _regeneratorRuntime() {
|
|
62
62
|
_regeneratorRuntime = function () {
|
|
63
|
-
return
|
|
63
|
+
return exports;
|
|
64
64
|
};
|
|
65
|
-
var
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
t[e] = r.value;
|
|
65
|
+
var exports = {},
|
|
66
|
+
Op = Object.prototype,
|
|
67
|
+
hasOwn = Op.hasOwnProperty,
|
|
68
|
+
defineProperty = Object.defineProperty || function (obj, key, desc) {
|
|
69
|
+
obj[key] = desc.value;
|
|
71
70
|
},
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
function define(
|
|
77
|
-
return Object.defineProperty(
|
|
78
|
-
value:
|
|
71
|
+
$Symbol = "function" == typeof Symbol ? Symbol : {},
|
|
72
|
+
iteratorSymbol = $Symbol.iterator || "@@iterator",
|
|
73
|
+
asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator",
|
|
74
|
+
toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
|
|
75
|
+
function define(obj, key, value) {
|
|
76
|
+
return Object.defineProperty(obj, key, {
|
|
77
|
+
value: value,
|
|
79
78
|
enumerable: !0,
|
|
80
79
|
configurable: !0,
|
|
81
80
|
writable: !0
|
|
82
|
-
}),
|
|
81
|
+
}), obj[key];
|
|
83
82
|
}
|
|
84
83
|
try {
|
|
85
84
|
define({}, "");
|
|
86
|
-
} catch (
|
|
87
|
-
define = function (
|
|
88
|
-
return
|
|
85
|
+
} catch (err) {
|
|
86
|
+
define = function (obj, key, value) {
|
|
87
|
+
return obj[key] = value;
|
|
89
88
|
};
|
|
90
89
|
}
|
|
91
|
-
function wrap(
|
|
92
|
-
var
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
return
|
|
96
|
-
value: makeInvokeMethod(
|
|
97
|
-
}),
|
|
90
|
+
function wrap(innerFn, outerFn, self, tryLocsList) {
|
|
91
|
+
var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator,
|
|
92
|
+
generator = Object.create(protoGenerator.prototype),
|
|
93
|
+
context = new Context(tryLocsList || []);
|
|
94
|
+
return defineProperty(generator, "_invoke", {
|
|
95
|
+
value: makeInvokeMethod(innerFn, self, context)
|
|
96
|
+
}), generator;
|
|
98
97
|
}
|
|
99
|
-
function tryCatch(
|
|
98
|
+
function tryCatch(fn, obj, arg) {
|
|
100
99
|
try {
|
|
101
100
|
return {
|
|
102
101
|
type: "normal",
|
|
103
|
-
arg:
|
|
102
|
+
arg: fn.call(obj, arg)
|
|
104
103
|
};
|
|
105
|
-
} catch (
|
|
104
|
+
} catch (err) {
|
|
106
105
|
return {
|
|
107
106
|
type: "throw",
|
|
108
|
-
arg:
|
|
107
|
+
arg: err
|
|
109
108
|
};
|
|
110
109
|
}
|
|
111
110
|
}
|
|
112
|
-
|
|
113
|
-
var
|
|
114
|
-
l = "suspendedYield",
|
|
115
|
-
f = "executing",
|
|
116
|
-
s = "completed",
|
|
117
|
-
y = {};
|
|
111
|
+
exports.wrap = wrap;
|
|
112
|
+
var ContinueSentinel = {};
|
|
118
113
|
function Generator() {}
|
|
119
114
|
function GeneratorFunction() {}
|
|
120
115
|
function GeneratorFunctionPrototype() {}
|
|
121
|
-
var
|
|
122
|
-
define(
|
|
116
|
+
var IteratorPrototype = {};
|
|
117
|
+
define(IteratorPrototype, iteratorSymbol, function () {
|
|
123
118
|
return this;
|
|
124
119
|
});
|
|
125
|
-
var
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
var
|
|
129
|
-
function defineIteratorMethods(
|
|
130
|
-
["next", "throw", "return"].forEach(function (
|
|
131
|
-
define(
|
|
132
|
-
return this._invoke(
|
|
120
|
+
var getProto = Object.getPrototypeOf,
|
|
121
|
+
NativeIteratorPrototype = getProto && getProto(getProto(values([])));
|
|
122
|
+
NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype);
|
|
123
|
+
var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype);
|
|
124
|
+
function defineIteratorMethods(prototype) {
|
|
125
|
+
["next", "throw", "return"].forEach(function (method) {
|
|
126
|
+
define(prototype, method, function (arg) {
|
|
127
|
+
return this._invoke(method, arg);
|
|
133
128
|
});
|
|
134
129
|
});
|
|
135
130
|
}
|
|
136
|
-
function AsyncIterator(
|
|
137
|
-
function invoke(
|
|
138
|
-
var
|
|
139
|
-
if ("throw" !==
|
|
140
|
-
var
|
|
141
|
-
|
|
142
|
-
return
|
|
143
|
-
invoke("next",
|
|
144
|
-
}, function (
|
|
145
|
-
invoke("throw",
|
|
146
|
-
}) :
|
|
147
|
-
|
|
148
|
-
}, function (
|
|
149
|
-
return invoke("throw",
|
|
131
|
+
function AsyncIterator(generator, PromiseImpl) {
|
|
132
|
+
function invoke(method, arg, resolve, reject) {
|
|
133
|
+
var record = tryCatch(generator[method], generator, arg);
|
|
134
|
+
if ("throw" !== record.type) {
|
|
135
|
+
var result = record.arg,
|
|
136
|
+
value = result.value;
|
|
137
|
+
return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) {
|
|
138
|
+
invoke("next", value, resolve, reject);
|
|
139
|
+
}, function (err) {
|
|
140
|
+
invoke("throw", err, resolve, reject);
|
|
141
|
+
}) : PromiseImpl.resolve(value).then(function (unwrapped) {
|
|
142
|
+
result.value = unwrapped, resolve(result);
|
|
143
|
+
}, function (error) {
|
|
144
|
+
return invoke("throw", error, resolve, reject);
|
|
150
145
|
});
|
|
151
146
|
}
|
|
152
|
-
|
|
147
|
+
reject(record.arg);
|
|
153
148
|
}
|
|
154
|
-
var
|
|
155
|
-
|
|
156
|
-
value: function (
|
|
149
|
+
var previousPromise;
|
|
150
|
+
defineProperty(this, "_invoke", {
|
|
151
|
+
value: function (method, arg) {
|
|
157
152
|
function callInvokeWithMethodAndArg() {
|
|
158
|
-
return new
|
|
159
|
-
invoke(
|
|
153
|
+
return new PromiseImpl(function (resolve, reject) {
|
|
154
|
+
invoke(method, arg, resolve, reject);
|
|
160
155
|
});
|
|
161
156
|
}
|
|
162
|
-
return
|
|
157
|
+
return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
|
|
163
158
|
}
|
|
164
159
|
});
|
|
165
160
|
}
|
|
166
|
-
function makeInvokeMethod(
|
|
167
|
-
var
|
|
168
|
-
return function (
|
|
169
|
-
if (
|
|
170
|
-
if (
|
|
171
|
-
if ("throw" ===
|
|
172
|
-
return
|
|
173
|
-
value: t,
|
|
174
|
-
done: !0
|
|
175
|
-
};
|
|
161
|
+
function makeInvokeMethod(innerFn, self, context) {
|
|
162
|
+
var state = "suspendedStart";
|
|
163
|
+
return function (method, arg) {
|
|
164
|
+
if ("executing" === state) throw new Error("Generator is already running");
|
|
165
|
+
if ("completed" === state) {
|
|
166
|
+
if ("throw" === method) throw arg;
|
|
167
|
+
return doneResult();
|
|
176
168
|
}
|
|
177
|
-
for (
|
|
178
|
-
var
|
|
179
|
-
if (
|
|
180
|
-
var
|
|
181
|
-
if (
|
|
182
|
-
if (
|
|
183
|
-
return
|
|
169
|
+
for (context.method = method, context.arg = arg;;) {
|
|
170
|
+
var delegate = context.delegate;
|
|
171
|
+
if (delegate) {
|
|
172
|
+
var delegateResult = maybeInvokeDelegate(delegate, context);
|
|
173
|
+
if (delegateResult) {
|
|
174
|
+
if (delegateResult === ContinueSentinel) continue;
|
|
175
|
+
return delegateResult;
|
|
184
176
|
}
|
|
185
177
|
}
|
|
186
|
-
if ("next" ===
|
|
187
|
-
if (
|
|
188
|
-
|
|
189
|
-
} else "return" ===
|
|
190
|
-
|
|
191
|
-
var
|
|
192
|
-
if ("normal" ===
|
|
193
|
-
if (
|
|
178
|
+
if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) {
|
|
179
|
+
if ("suspendedStart" === state) throw state = "completed", context.arg;
|
|
180
|
+
context.dispatchException(context.arg);
|
|
181
|
+
} else "return" === context.method && context.abrupt("return", context.arg);
|
|
182
|
+
state = "executing";
|
|
183
|
+
var record = tryCatch(innerFn, self, context);
|
|
184
|
+
if ("normal" === record.type) {
|
|
185
|
+
if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue;
|
|
194
186
|
return {
|
|
195
|
-
value:
|
|
196
|
-
done:
|
|
187
|
+
value: record.arg,
|
|
188
|
+
done: context.done
|
|
197
189
|
};
|
|
198
190
|
}
|
|
199
|
-
"throw" ===
|
|
191
|
+
"throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg);
|
|
200
192
|
}
|
|
201
193
|
};
|
|
202
194
|
}
|
|
203
|
-
function maybeInvokeDelegate(
|
|
204
|
-
var
|
|
205
|
-
|
|
206
|
-
if (
|
|
207
|
-
var
|
|
208
|
-
if ("throw" ===
|
|
209
|
-
var
|
|
210
|
-
return
|
|
195
|
+
function maybeInvokeDelegate(delegate, context) {
|
|
196
|
+
var methodName = context.method,
|
|
197
|
+
method = delegate.iterator[methodName];
|
|
198
|
+
if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel;
|
|
199
|
+
var record = tryCatch(method, delegate.iterator, context.arg);
|
|
200
|
+
if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel;
|
|
201
|
+
var info = record.arg;
|
|
202
|
+
return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel);
|
|
211
203
|
}
|
|
212
|
-
function pushTryEntry(
|
|
213
|
-
var
|
|
214
|
-
tryLoc:
|
|
204
|
+
function pushTryEntry(locs) {
|
|
205
|
+
var entry = {
|
|
206
|
+
tryLoc: locs[0]
|
|
215
207
|
};
|
|
216
|
-
1 in
|
|
208
|
+
1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry);
|
|
217
209
|
}
|
|
218
|
-
function resetTryEntry(
|
|
219
|
-
var
|
|
220
|
-
|
|
210
|
+
function resetTryEntry(entry) {
|
|
211
|
+
var record = entry.completion || {};
|
|
212
|
+
record.type = "normal", delete record.arg, entry.completion = record;
|
|
221
213
|
}
|
|
222
|
-
function Context(
|
|
214
|
+
function Context(tryLocsList) {
|
|
223
215
|
this.tryEntries = [{
|
|
224
216
|
tryLoc: "root"
|
|
225
|
-
}],
|
|
217
|
+
}], tryLocsList.forEach(pushTryEntry, this), this.reset(!0);
|
|
226
218
|
}
|
|
227
|
-
function values(
|
|
228
|
-
if (
|
|
229
|
-
var
|
|
230
|
-
if (
|
|
231
|
-
if ("function" == typeof
|
|
232
|
-
if (!isNaN(
|
|
233
|
-
var
|
|
234
|
-
|
|
235
|
-
for (; ++
|
|
236
|
-
return next.value =
|
|
219
|
+
function values(iterable) {
|
|
220
|
+
if (iterable) {
|
|
221
|
+
var iteratorMethod = iterable[iteratorSymbol];
|
|
222
|
+
if (iteratorMethod) return iteratorMethod.call(iterable);
|
|
223
|
+
if ("function" == typeof iterable.next) return iterable;
|
|
224
|
+
if (!isNaN(iterable.length)) {
|
|
225
|
+
var i = -1,
|
|
226
|
+
next = function next() {
|
|
227
|
+
for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next;
|
|
228
|
+
return next.value = undefined, next.done = !0, next;
|
|
237
229
|
};
|
|
238
|
-
return
|
|
230
|
+
return next.next = next;
|
|
239
231
|
}
|
|
240
232
|
}
|
|
241
|
-
|
|
233
|
+
return {
|
|
234
|
+
next: doneResult
|
|
235
|
+
};
|
|
236
|
+
}
|
|
237
|
+
function doneResult() {
|
|
238
|
+
return {
|
|
239
|
+
value: undefined,
|
|
240
|
+
done: !0
|
|
241
|
+
};
|
|
242
242
|
}
|
|
243
|
-
return GeneratorFunction.prototype = GeneratorFunctionPrototype,
|
|
243
|
+
return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", {
|
|
244
244
|
value: GeneratorFunctionPrototype,
|
|
245
245
|
configurable: !0
|
|
246
|
-
}),
|
|
246
|
+
}), defineProperty(GeneratorFunctionPrototype, "constructor", {
|
|
247
247
|
value: GeneratorFunction,
|
|
248
248
|
configurable: !0
|
|
249
|
-
}), GeneratorFunction.displayName = define(GeneratorFunctionPrototype,
|
|
250
|
-
var
|
|
251
|
-
return !!
|
|
252
|
-
},
|
|
253
|
-
return Object.setPrototypeOf ? Object.setPrototypeOf(
|
|
254
|
-
},
|
|
249
|
+
}), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) {
|
|
250
|
+
var ctor = "function" == typeof genFun && genFun.constructor;
|
|
251
|
+
return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name));
|
|
252
|
+
}, exports.mark = function (genFun) {
|
|
253
|
+
return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun;
|
|
254
|
+
}, exports.awrap = function (arg) {
|
|
255
255
|
return {
|
|
256
|
-
__await:
|
|
256
|
+
__await: arg
|
|
257
257
|
};
|
|
258
|
-
}, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype,
|
|
258
|
+
}, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
|
|
259
259
|
return this;
|
|
260
|
-
}),
|
|
261
|
-
void 0 ===
|
|
262
|
-
var
|
|
263
|
-
return
|
|
264
|
-
return
|
|
260
|
+
}), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) {
|
|
261
|
+
void 0 === PromiseImpl && (PromiseImpl = Promise);
|
|
262
|
+
var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl);
|
|
263
|
+
return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) {
|
|
264
|
+
return result.done ? result.value : iter.next();
|
|
265
265
|
});
|
|
266
|
-
}, defineIteratorMethods(
|
|
266
|
+
}, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () {
|
|
267
267
|
return this;
|
|
268
|
-
}), define(
|
|
268
|
+
}), define(Gp, "toString", function () {
|
|
269
269
|
return "[object Generator]";
|
|
270
|
-
}),
|
|
271
|
-
var
|
|
272
|
-
|
|
273
|
-
for (var
|
|
274
|
-
return
|
|
275
|
-
for (;
|
|
276
|
-
var
|
|
277
|
-
if (
|
|
270
|
+
}), exports.keys = function (val) {
|
|
271
|
+
var object = Object(val),
|
|
272
|
+
keys = [];
|
|
273
|
+
for (var key in object) keys.push(key);
|
|
274
|
+
return keys.reverse(), function next() {
|
|
275
|
+
for (; keys.length;) {
|
|
276
|
+
var key = keys.pop();
|
|
277
|
+
if (key in object) return next.value = key, next.done = !1, next;
|
|
278
278
|
}
|
|
279
279
|
return next.done = !0, next;
|
|
280
280
|
};
|
|
281
|
-
},
|
|
281
|
+
}, exports.values = values, Context.prototype = {
|
|
282
282
|
constructor: Context,
|
|
283
|
-
reset: function (
|
|
284
|
-
if (this.prev = 0, this.next = 0, this.sent = this._sent =
|
|
283
|
+
reset: function (skipTempReset) {
|
|
284
|
+
if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined);
|
|
285
285
|
},
|
|
286
286
|
stop: function () {
|
|
287
287
|
this.done = !0;
|
|
288
|
-
var
|
|
289
|
-
if ("throw" ===
|
|
288
|
+
var rootRecord = this.tryEntries[0].completion;
|
|
289
|
+
if ("throw" === rootRecord.type) throw rootRecord.arg;
|
|
290
290
|
return this.rval;
|
|
291
291
|
},
|
|
292
|
-
dispatchException: function (
|
|
293
|
-
if (this.done) throw
|
|
294
|
-
var
|
|
295
|
-
function handle(
|
|
296
|
-
return
|
|
292
|
+
dispatchException: function (exception) {
|
|
293
|
+
if (this.done) throw exception;
|
|
294
|
+
var context = this;
|
|
295
|
+
function handle(loc, caught) {
|
|
296
|
+
return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught;
|
|
297
297
|
}
|
|
298
|
-
for (var
|
|
299
|
-
var
|
|
300
|
-
|
|
301
|
-
if ("root" ===
|
|
302
|
-
if (
|
|
303
|
-
var
|
|
304
|
-
|
|
305
|
-
if (
|
|
306
|
-
if (this.prev <
|
|
307
|
-
if (this.prev <
|
|
308
|
-
} else if (
|
|
309
|
-
if (this.prev <
|
|
298
|
+
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
|
|
299
|
+
var entry = this.tryEntries[i],
|
|
300
|
+
record = entry.completion;
|
|
301
|
+
if ("root" === entry.tryLoc) return handle("end");
|
|
302
|
+
if (entry.tryLoc <= this.prev) {
|
|
303
|
+
var hasCatch = hasOwn.call(entry, "catchLoc"),
|
|
304
|
+
hasFinally = hasOwn.call(entry, "finallyLoc");
|
|
305
|
+
if (hasCatch && hasFinally) {
|
|
306
|
+
if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
|
|
307
|
+
if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
|
|
308
|
+
} else if (hasCatch) {
|
|
309
|
+
if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
|
|
310
310
|
} else {
|
|
311
|
-
if (!
|
|
312
|
-
if (this.prev <
|
|
311
|
+
if (!hasFinally) throw new Error("try statement without catch or finally");
|
|
312
|
+
if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
|
|
313
313
|
}
|
|
314
314
|
}
|
|
315
315
|
}
|
|
316
316
|
},
|
|
317
|
-
abrupt: function (
|
|
318
|
-
for (var
|
|
319
|
-
var
|
|
320
|
-
if (
|
|
321
|
-
var
|
|
317
|
+
abrupt: function (type, arg) {
|
|
318
|
+
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
|
|
319
|
+
var entry = this.tryEntries[i];
|
|
320
|
+
if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) {
|
|
321
|
+
var finallyEntry = entry;
|
|
322
322
|
break;
|
|
323
323
|
}
|
|
324
324
|
}
|
|
325
|
-
|
|
326
|
-
var
|
|
327
|
-
return
|
|
325
|
+
finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null);
|
|
326
|
+
var record = finallyEntry ? finallyEntry.completion : {};
|
|
327
|
+
return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record);
|
|
328
328
|
},
|
|
329
|
-
complete: function (
|
|
330
|
-
if ("throw" ===
|
|
331
|
-
return "break" ===
|
|
329
|
+
complete: function (record, afterLoc) {
|
|
330
|
+
if ("throw" === record.type) throw record.arg;
|
|
331
|
+
return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel;
|
|
332
332
|
},
|
|
333
|
-
finish: function (
|
|
334
|
-
for (var
|
|
335
|
-
var
|
|
336
|
-
if (
|
|
333
|
+
finish: function (finallyLoc) {
|
|
334
|
+
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
|
|
335
|
+
var entry = this.tryEntries[i];
|
|
336
|
+
if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel;
|
|
337
337
|
}
|
|
338
338
|
},
|
|
339
|
-
catch: function (
|
|
340
|
-
for (var
|
|
341
|
-
var
|
|
342
|
-
if (
|
|
343
|
-
var
|
|
344
|
-
if ("throw" ===
|
|
345
|
-
var
|
|
346
|
-
resetTryEntry(
|
|
339
|
+
catch: function (tryLoc) {
|
|
340
|
+
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
|
|
341
|
+
var entry = this.tryEntries[i];
|
|
342
|
+
if (entry.tryLoc === tryLoc) {
|
|
343
|
+
var record = entry.completion;
|
|
344
|
+
if ("throw" === record.type) {
|
|
345
|
+
var thrown = record.arg;
|
|
346
|
+
resetTryEntry(entry);
|
|
347
347
|
}
|
|
348
|
-
return
|
|
348
|
+
return thrown;
|
|
349
349
|
}
|
|
350
350
|
}
|
|
351
351
|
throw new Error("illegal catch attempt");
|
|
352
352
|
},
|
|
353
|
-
delegateYield: function (
|
|
353
|
+
delegateYield: function (iterable, resultName, nextLoc) {
|
|
354
354
|
return this.delegate = {
|
|
355
|
-
iterator: values(
|
|
356
|
-
resultName:
|
|
357
|
-
nextLoc:
|
|
358
|
-
}, "next" === this.method && (this.arg =
|
|
359
|
-
}
|
|
360
|
-
},
|
|
361
|
-
}
|
|
362
|
-
function _toPrimitive(t, r) {
|
|
363
|
-
if ("object" != typeof t || !t) return t;
|
|
364
|
-
var e = t[Symbol.toPrimitive];
|
|
365
|
-
if (void 0 !== e) {
|
|
366
|
-
var i = e.call(t, r || "default");
|
|
367
|
-
if ("object" != typeof i) return i;
|
|
368
|
-
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
369
|
-
}
|
|
370
|
-
return ("string" === r ? String : Number)(t);
|
|
371
|
-
}
|
|
372
|
-
function _toPropertyKey(t) {
|
|
373
|
-
var i = _toPrimitive(t, "string");
|
|
374
|
-
return "symbol" == typeof i ? i : String(i);
|
|
355
|
+
iterator: values(iterable),
|
|
356
|
+
resultName: resultName,
|
|
357
|
+
nextLoc: nextLoc
|
|
358
|
+
}, "next" === this.method && (this.arg = undefined), ContinueSentinel;
|
|
359
|
+
}
|
|
360
|
+
}, exports;
|
|
375
361
|
}
|
|
376
|
-
function _typeof(
|
|
362
|
+
function _typeof(obj) {
|
|
377
363
|
"@babel/helpers - typeof";
|
|
378
364
|
|
|
379
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (
|
|
380
|
-
return typeof
|
|
381
|
-
} : function (
|
|
382
|
-
return
|
|
383
|
-
}, _typeof(
|
|
365
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
366
|
+
return typeof obj;
|
|
367
|
+
} : function (obj) {
|
|
368
|
+
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
369
|
+
}, _typeof(obj);
|
|
384
370
|
}
|
|
385
371
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
|
386
372
|
try {
|
|
@@ -487,6 +473,20 @@ function _nonIterableSpread() {
|
|
|
487
473
|
function _nonIterableRest() {
|
|
488
474
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
489
475
|
}
|
|
476
|
+
function _toPrimitive(input, hint) {
|
|
477
|
+
if (typeof input !== "object" || input === null) return input;
|
|
478
|
+
var prim = input[Symbol.toPrimitive];
|
|
479
|
+
if (prim !== undefined) {
|
|
480
|
+
var res = prim.call(input, hint || "default");
|
|
481
|
+
if (typeof res !== "object") return res;
|
|
482
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
483
|
+
}
|
|
484
|
+
return (hint === "string" ? String : Number)(input);
|
|
485
|
+
}
|
|
486
|
+
function _toPropertyKey(arg) {
|
|
487
|
+
var key = _toPrimitive(arg, "string");
|
|
488
|
+
return typeof key === "symbol" ? key : String(key);
|
|
489
|
+
}
|
|
490
490
|
|
|
491
491
|
function ApaasCascader(props) {
|
|
492
492
|
return /*#__PURE__*/React.createElement(Cascader, _objectSpread2({
|
|
@@ -928,7 +928,7 @@ var fn$1 = function fn() {
|
|
|
928
928
|
var ApaasUploadAsync = function ApaasUploadAsync(_ref, ref) {
|
|
929
929
|
var _document;
|
|
930
930
|
var _ref$maxCount = _ref.maxCount,
|
|
931
|
-
maxCount = _ref$maxCount === void 0 ?
|
|
931
|
+
maxCount = _ref$maxCount === void 0 ? 20 : _ref$maxCount,
|
|
932
932
|
_ref$maxSize = _ref.maxSize,
|
|
933
933
|
maxSize = _ref$maxSize === void 0 ? 10 : _ref$maxSize,
|
|
934
934
|
_ref$uploadText = _ref.uploadText,
|
|
@@ -6863,7 +6863,7 @@ var fn$2 = function fn() {
|
|
|
6863
6863
|
};
|
|
6864
6864
|
var ApaasUploadFile = function ApaasUploadFile(_ref) {
|
|
6865
6865
|
var _ref$maxCount = _ref.maxCount,
|
|
6866
|
-
maxCount = _ref$maxCount === void 0 ?
|
|
6866
|
+
maxCount = _ref$maxCount === void 0 ? 20 : _ref$maxCount,
|
|
6867
6867
|
_ref$maxSize = _ref.maxSize,
|
|
6868
6868
|
maxSize = _ref$maxSize === void 0 ? 100 : _ref$maxSize,
|
|
6869
6869
|
_ref$onChange = _ref.onChange,
|
|
@@ -7361,7 +7361,8 @@ var Province = function Province(props) {
|
|
|
7361
7361
|
var mapping = {
|
|
7362
7362
|
workOrder: AddressData.getInstance(),
|
|
7363
7363
|
bs: BsAddressData.getInstance(),
|
|
7364
|
-
wdt: WdtAddressData.getInstance()
|
|
7364
|
+
wdt: WdtAddressData.getInstance(),
|
|
7365
|
+
gy: GyAddressData.getInstance()
|
|
7365
7366
|
};
|
|
7366
7367
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Cascader, _objectSpread2(_objectSpread2({}, props), {}, {
|
|
7367
7368
|
options: ((_mapping$type = mapping[type]) === null || _mapping$type === void 0 ? void 0 : _mapping$type.addressOptions) || [],
|
|
@@ -7466,10 +7467,16 @@ var IdentifyAddress = function IdentifyAddress(props) {
|
|
|
7466
7467
|
var addressData = (type && {
|
|
7467
7468
|
bs: BsAddressData,
|
|
7468
7469
|
wdt: WdtAddressData,
|
|
7470
|
+
gy: GyAddressData,
|
|
7469
7471
|
workOrder: AddressData
|
|
7470
7472
|
}[type] || AddressData).getInstance();
|
|
7471
7473
|
if ((val === null || val === void 0 ? void 0 : val.province) && addressData.getProCodeByName(val === null || val === void 0 ? void 0 : val.province)) {
|
|
7472
|
-
params.address = [
|
|
7474
|
+
// params.address = [
|
|
7475
|
+
// addressData.getProCodeByName(val?.province),
|
|
7476
|
+
// addressData.getProCodeByName(val?.city),
|
|
7477
|
+
// addressData.getProCodeByName(val?.district),
|
|
7478
|
+
// ];
|
|
7479
|
+
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]);
|
|
7473
7480
|
}
|
|
7474
7481
|
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2({}, params));
|
|
7475
7482
|
};
|
|
@@ -7542,11 +7549,13 @@ function ApaasPosting(props) {
|
|
|
7542
7549
|
});
|
|
7543
7550
|
}
|
|
7544
7551
|
|
|
7545
|
-
var _excluded$a = ["value", "onChange", "platformType"];
|
|
7552
|
+
var _excluded$a = ["value", "onChange", "platformType", "type"];
|
|
7546
7553
|
function ApaasLogistics(props) {
|
|
7547
7554
|
var value = props.value,
|
|
7548
7555
|
onChange = props.onChange,
|
|
7549
7556
|
platformType = props.platformType,
|
|
7557
|
+
_props$type = props.type,
|
|
7558
|
+
type = _props$type === void 0 ? 'select' : _props$type,
|
|
7550
7559
|
other = _objectWithoutProperties(props, _excluded$a);
|
|
7551
7560
|
var _useState = useState([]),
|
|
7552
7561
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -7577,10 +7586,18 @@ function ApaasLogistics(props) {
|
|
|
7577
7586
|
isFirst.current = true;
|
|
7578
7587
|
}
|
|
7579
7588
|
}, []);
|
|
7580
|
-
|
|
7589
|
+
var handleInputChange = function handleInputChange(e) {
|
|
7590
|
+
var val = e.target.value;
|
|
7591
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(val);
|
|
7592
|
+
};
|
|
7593
|
+
return type === 'input' ? /*#__PURE__*/React.createElement(Input, _objectSpread2(_objectSpread2({}, other), {}, {
|
|
7594
|
+
value: value,
|
|
7595
|
+
onChange: handleInputChange
|
|
7596
|
+
})) : /*#__PURE__*/React.createElement(Select, _objectSpread2(_objectSpread2({}, other), {}, {
|
|
7581
7597
|
value: value,
|
|
7582
7598
|
onChange: onChange,
|
|
7583
|
-
options: option
|
|
7599
|
+
options: option,
|
|
7600
|
+
virtual: true
|
|
7584
7601
|
}));
|
|
7585
7602
|
}
|
|
7586
7603
|
|
|
@@ -8110,7 +8127,7 @@ function ApaasAddress(props) {
|
|
|
8110
8127
|
};
|
|
8111
8128
|
var addressData = type === 'bs' ? BsAddressData.getInstance() : AddressData.getInstance();
|
|
8112
8129
|
if ((val === null || val === void 0 ? void 0 : val.province) && addressData.getProCodeByName(val === null || val === void 0 ? void 0 : val.province)) {
|
|
8113
|
-
params.address =
|
|
8130
|
+
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]);
|
|
8114
8131
|
}
|
|
8115
8132
|
onChange === null || onChange === void 0 ? void 0 : onChange(params);
|
|
8116
8133
|
};
|
|
@@ -9474,7 +9491,8 @@ var GoodItem = function GoodItem(props) {
|
|
|
9474
9491
|
picUrl: item.picUrl,
|
|
9475
9492
|
numIid: item.numIid,
|
|
9476
9493
|
skuId: item.skuId,
|
|
9477
|
-
outerSkuId: item.outerSkuId
|
|
9494
|
+
outerSkuId: item.outerSkuId,
|
|
9495
|
+
num: 1 //手动选择商品默认数量
|
|
9478
9496
|
};
|
|
9479
9497
|
// if (type === 1) {
|
|
9480
9498
|
// params.outerId = item.outerId; //编码
|
|
@@ -9563,16 +9581,34 @@ var GoodItem = function GoodItem(props) {
|
|
|
9563
9581
|
return _ref5.apply(this, arguments);
|
|
9564
9582
|
};
|
|
9565
9583
|
}();
|
|
9566
|
-
var headerList =
|
|
9567
|
-
|
|
9568
|
-
|
|
9569
|
-
|
|
9584
|
+
var headerList = useMemo(function () {
|
|
9585
|
+
if (!Array.isArray(showHeader)) return columnsGoodsList.map(function (item) {
|
|
9586
|
+
return item.dataIndex;
|
|
9587
|
+
});
|
|
9588
|
+
var isStringArray = Array.isArray(showHeader) && typeof showHeader[0] === 'string';
|
|
9589
|
+
var isObjectArray = Array.isArray(showHeader) && Object.prototype.toString.call(showHeader[0]) === '[object Object]';
|
|
9590
|
+
var dataIndexList = [];
|
|
9591
|
+
if (isStringArray) {
|
|
9592
|
+
dataIndexList = showHeader;
|
|
9593
|
+
} else if (isObjectArray) {
|
|
9594
|
+
dataIndexList = showHeader.filter(function (item) {
|
|
9595
|
+
return item.show !== false;
|
|
9596
|
+
}).map(function (item) {
|
|
9597
|
+
return item.dataIndex;
|
|
9598
|
+
});
|
|
9599
|
+
}
|
|
9600
|
+
return dataIndexList || {
|
|
9601
|
+
1: columnsGoodsList.map(function (item) {
|
|
9602
|
+
return item.dataIndex;
|
|
9603
|
+
})
|
|
9604
|
+
}[type] || [];
|
|
9605
|
+
}, [showHeader]);
|
|
9570
9606
|
//修改参数
|
|
9571
|
-
var handleChangeValue = function handleChangeValue(key, index) {
|
|
9607
|
+
var handleChangeValue = function handleChangeValue(key, index, replaceFn) {
|
|
9572
9608
|
return function (e) {
|
|
9573
|
-
var _e$target;
|
|
9609
|
+
var _e$target, _e$target2;
|
|
9574
9610
|
var newImgList = _toConsumableArray(imgList);
|
|
9575
|
-
newImgList[index][key] = e === null || e === void 0 ? void 0 : (_e$target = e.target) === null || _e$target === void 0 ? void 0 : _e$target.value;
|
|
9611
|
+
newImgList[index][key] = replaceFn ? replaceFn(e === null || e === void 0 ? void 0 : (_e$target = e.target) === null || _e$target === void 0 ? void 0 : _e$target.value) : e === null || e === void 0 ? void 0 : (_e$target2 = e.target) === null || _e$target2 === void 0 ? void 0 : _e$target2.value;
|
|
9576
9612
|
var newValue = {
|
|
9577
9613
|
shopId: shopId,
|
|
9578
9614
|
imgList: newImgList
|
|
@@ -9581,35 +9617,67 @@ var GoodItem = function GoodItem(props) {
|
|
|
9581
9617
|
};
|
|
9582
9618
|
};
|
|
9583
9619
|
// TODO: 目前只做了type 1的处理,其他的还是走老的文件 ./index.tsx
|
|
9584
|
-
var goodItemAttrs =
|
|
9585
|
-
|
|
9586
|
-
|
|
9587
|
-
|
|
9588
|
-
|
|
9589
|
-
|
|
9590
|
-
|
|
9591
|
-
|
|
9592
|
-
|
|
9593
|
-
|
|
9594
|
-
|
|
9595
|
-
|
|
9596
|
-
|
|
9597
|
-
|
|
9598
|
-
|
|
9599
|
-
|
|
9600
|
-
|
|
9601
|
-
|
|
9602
|
-
|
|
9603
|
-
|
|
9604
|
-
|
|
9605
|
-
|
|
9606
|
-
|
|
9607
|
-
|
|
9608
|
-
|
|
9609
|
-
|
|
9610
|
-
|
|
9611
|
-
|
|
9612
|
-
|
|
9620
|
+
var goodItemAttrs = useMemo(function () {
|
|
9621
|
+
var initList = [{
|
|
9622
|
+
isShow: headerList.includes('title'),
|
|
9623
|
+
key: 'title',
|
|
9624
|
+
label: '商品名称'
|
|
9625
|
+
}, {
|
|
9626
|
+
isShow: headerList.includes('outerId'),
|
|
9627
|
+
key: 'outerId',
|
|
9628
|
+
label: '商品编码'
|
|
9629
|
+
},
|
|
9630
|
+
// { isShow: headerList.includes('picUrl'), key: 'picUrl', label: '图片' },
|
|
9631
|
+
{
|
|
9632
|
+
isShow: headerList.includes('numIid'),
|
|
9633
|
+
key: 'numIid',
|
|
9634
|
+
label: '商品id'
|
|
9635
|
+
}, {
|
|
9636
|
+
isShow: headerList.includes('num'),
|
|
9637
|
+
key: 'num',
|
|
9638
|
+
label: '商品数量',
|
|
9639
|
+
replaceFn: function replaceFn(value) {
|
|
9640
|
+
// 使用正则表达式匹配所有数字字符
|
|
9641
|
+
var numbers = String(value || '').match(/\d+/g);
|
|
9642
|
+
// 如果没有匹配到任何数字字符,返回null
|
|
9643
|
+
if (!numbers) {
|
|
9644
|
+
return null;
|
|
9645
|
+
}
|
|
9646
|
+
// 将匹配到的数字字符拼接成一个新的数字
|
|
9647
|
+
return Number(numbers.join('')) ? Number(numbers.join('')) : null;
|
|
9648
|
+
}
|
|
9649
|
+
}, {
|
|
9650
|
+
isShow: changeSku && headerList.includes('skuId'),
|
|
9651
|
+
key: 'skuId',
|
|
9652
|
+
label: 'SKU ID'
|
|
9653
|
+
}, {
|
|
9654
|
+
isShow: changeSku && headerList.includes('outerSkuId'),
|
|
9655
|
+
key: 'outerSkuId',
|
|
9656
|
+
label: 'SKU 编码'
|
|
9657
|
+
}, {
|
|
9658
|
+
isShow: changeSku && headerList.includes('propertiesName'),
|
|
9659
|
+
key: 'propertiesName',
|
|
9660
|
+
label: 'SKU 信息'
|
|
9661
|
+
}];
|
|
9662
|
+
if (!Array.isArray(showHeader)) return initList;
|
|
9663
|
+
var newList = [];
|
|
9664
|
+
headerList.forEach(function (dataIndex) {
|
|
9665
|
+
if (initList.find(function (item) {
|
|
9666
|
+
return item.key === dataIndex;
|
|
9667
|
+
})) {
|
|
9668
|
+
newList.push(initList.find(function (item) {
|
|
9669
|
+
return item.key === dataIndex;
|
|
9670
|
+
}));
|
|
9671
|
+
}
|
|
9672
|
+
});
|
|
9673
|
+
return newList;
|
|
9674
|
+
}, [headerList, showHeader]);
|
|
9675
|
+
var hasPic = useMemo(function () {
|
|
9676
|
+
return headerList.includes('picUrl');
|
|
9677
|
+
}, [headerList]);
|
|
9678
|
+
var hasAttr = useMemo(function () {
|
|
9679
|
+
return hasPic ? headerList.length > 1 : headerList.length > 0;
|
|
9680
|
+
}, [hasPic, headerList]);
|
|
9613
9681
|
return /*#__PURE__*/React.createElement("div", null, imgList.length === 0 ? /*#__PURE__*/React.createElement("p", {
|
|
9614
9682
|
className: "goods-title"
|
|
9615
9683
|
}, "\u6700\u591A\u6DFB\u52A0", maxLength, "\u4E2A\u5B9D\u8D1D") : /*#__PURE__*/React.createElement("p", {
|
|
@@ -9667,7 +9735,7 @@ var GoodItem = function GoodItem(props) {
|
|
|
9667
9735
|
title: String(img[item.key] || ''),
|
|
9668
9736
|
value: img[item.key],
|
|
9669
9737
|
disabled: item.disabled || disabled,
|
|
9670
|
-
onChange: handleChangeValue(item.key, index)
|
|
9738
|
+
onChange: handleChangeValue(item.key, index, item.replaceFn)
|
|
9671
9739
|
}));
|
|
9672
9740
|
}), !disabled && !hasPic && type !== 4 && changeSku ? /*#__PURE__*/React.createElement(Button, {
|
|
9673
9741
|
style: {
|
|
@@ -10956,13 +11024,19 @@ var jstGoods = function jstGoods(props) {
|
|
|
10956
11024
|
changeIndex = _useState2[0],
|
|
10957
11025
|
setChangeIndex = _useState2[1]; //选中的包裹
|
|
10958
11026
|
var sendOptions = SendDataCenter.getInstance(platformType).getSendData();
|
|
10959
|
-
var isSelectName = ['wdt', 'bsE3', 'km'].includes(platformType);
|
|
11027
|
+
var isSelectName = ['wdt', 'bsE3', 'km', 'gy'].includes(platformType);
|
|
11028
|
+
var logisticsType = type === 1 && platformType === 'gy' ? 'input' : 'select';
|
|
10960
11029
|
useEffect(function () {
|
|
10961
11030
|
//没有值塞个默认值
|
|
10962
11031
|
if (!(value === null || value === void 0 ? void 0 : value.length) && type !== 1) {
|
|
10963
11032
|
onChange === null || onChange === void 0 ? void 0 : onChange(typeInitValueMap[type]);
|
|
10964
11033
|
}
|
|
10965
11034
|
}, [value, type]);
|
|
11035
|
+
useEffect(function () {
|
|
11036
|
+
if (changeIndex > (value === null || value === void 0 ? void 0 : value.length) - 1) {
|
|
11037
|
+
setChangeIndex(0);
|
|
11038
|
+
}
|
|
11039
|
+
}, value);
|
|
10966
11040
|
var content = function content(item, index) {
|
|
10967
11041
|
return /*#__PURE__*/React.createElement("div", {
|
|
10968
11042
|
style: {
|
|
@@ -10973,7 +11047,7 @@ var jstGoods = function jstGoods(props) {
|
|
|
10973
11047
|
style: {
|
|
10974
11048
|
textAlign: 'center'
|
|
10975
11049
|
}
|
|
10976
|
-
}, "\u5305\u88F9".concat(index + 1, "\u5546\u54C1\u4FE1\u606F")), ((item === null || item === void 0 ? void 0 : item.items) || []).map(function (t, index) {
|
|
11050
|
+
}, "\u5305\u88F9".concat(index + 1, "\u5546\u54C1\u4FE1\u606F"), item.sid && /*#__PURE__*/React.createElement("span", null, "(\u7CFB\u7EDF\u5355\u53F7:", item.sid, ")")), ((item === null || item === void 0 ? void 0 : item.items) || []).map(function (t, index) {
|
|
10977
11051
|
return /*#__PURE__*/React.createElement("div", {
|
|
10978
11052
|
key: index
|
|
10979
11053
|
}, /*#__PURE__*/React.createElement(Space, null, /*#__PURE__*/React.createElement(Image, {
|
|
@@ -11025,24 +11099,32 @@ var jstGoods = function jstGoods(props) {
|
|
|
11025
11099
|
return setChangeIndex(index);
|
|
11026
11100
|
}
|
|
11027
11101
|
}, "\u5305\u88F9".concat(index + 1)));
|
|
11028
|
-
}))) : null, value.length || type === 1 ? /*#__PURE__*/React.createElement(React.Fragment, null, type === 1 ? /*#__PURE__*/React.createElement(Space, null, !showField || showField === 'logisticsCompany' ? /*#__PURE__*/React.createElement(ApaasLogistics, {
|
|
11102
|
+
}))) : null, value.length || type === 1 ? /*#__PURE__*/React.createElement(React.Fragment, null, type === 1 ? /*#__PURE__*/React.createElement(Space, null, !showField || showField === 'logisticsCompany' ? /*#__PURE__*/React.createElement(ApaasLogistics, _objectSpread2(_objectSpread2({
|
|
11103
|
+
type: logisticsType,
|
|
11029
11104
|
disabled: disabled,
|
|
11030
11105
|
placeholder: "\u7269\u6D41\u516C\u53F8",
|
|
11031
11106
|
onChange: function onChange(val) {
|
|
11032
|
-
|
|
11107
|
+
if (logisticsType === 'input') {
|
|
11108
|
+
changeInputHandle(null, 'logisticsCompany');
|
|
11109
|
+
changeInputHandle(val, 'logisticsCompanyName');
|
|
11110
|
+
} else {
|
|
11111
|
+
changeInputHandle(val, 'logisticsCompany');
|
|
11112
|
+
}
|
|
11033
11113
|
},
|
|
11034
|
-
value: (_value$changeIndex = value[changeIndex]) === null || _value$changeIndex === void 0 ? void 0 : _value$changeIndex
|
|
11114
|
+
value: (_value$changeIndex = value[changeIndex]) === null || _value$changeIndex === void 0 ? void 0 : _value$changeIndex[logisticsType === 'input' ? 'logisticsCompanyName' : 'logisticsCompany']
|
|
11115
|
+
}, logisticsType === 'input' ? {} : {
|
|
11035
11116
|
showSearch: true,
|
|
11117
|
+
dropdownMatchSelectWidth: false,
|
|
11036
11118
|
filterOption: function filterOption(input, option) {
|
|
11037
11119
|
return option.label.includes(input);
|
|
11038
|
-
}
|
|
11039
|
-
|
|
11120
|
+
}
|
|
11121
|
+
}), {}, {
|
|
11040
11122
|
style: {
|
|
11041
11123
|
minWidth: '100px',
|
|
11042
11124
|
maxWidth: '180px'
|
|
11043
11125
|
},
|
|
11044
11126
|
platformType: platformType
|
|
11045
|
-
}) : null, !showField || showField === 'logisticsCode' ? /*#__PURE__*/React.createElement(Input, {
|
|
11127
|
+
})) : null, !showField || showField === 'logisticsCode' ? /*#__PURE__*/React.createElement(Input, {
|
|
11046
11128
|
disabled: disabled,
|
|
11047
11129
|
placeholder: "\u7269\u6D41\u5355\u53F7",
|
|
11048
11130
|
onChange: function onChange(e) {
|
|
@@ -12426,199 +12508,1645 @@ var GoodsModal$4 = function GoodsModal(props, ref) {
|
|
|
12426
12508
|
};
|
|
12427
12509
|
var BsE3GoodsModal = /*#__PURE__*/forwardRef(GoodsModal$4);
|
|
12428
12510
|
|
|
12511
|
+
var getTableData$2 = function getTableData(_ref, formData) {
|
|
12512
|
+
var current = _ref.current,
|
|
12513
|
+
pageSize = _ref.pageSize;
|
|
12514
|
+
var data = {
|
|
12515
|
+
skuName: formData.skuName || null,
|
|
12516
|
+
skuCode: formData.skuCode || null,
|
|
12517
|
+
goodName: formData.goodName || null,
|
|
12518
|
+
goodNo: formData.goodNo || null
|
|
12519
|
+
};
|
|
12520
|
+
return extendRequest('/qy/gdfw/product/product/page', {
|
|
12521
|
+
method: 'post',
|
|
12522
|
+
data: _objectSpread2({
|
|
12523
|
+
pageSize: pageSize,
|
|
12524
|
+
pageNo: current,
|
|
12525
|
+
platform: 'GY_ERP'
|
|
12526
|
+
}, data)
|
|
12527
|
+
}).then(function (res) {
|
|
12528
|
+
var _res$data = res.data,
|
|
12529
|
+
_res$data$productSkuL = _res$data.productSkuList,
|
|
12530
|
+
productSkuList = _res$data$productSkuL === void 0 ? [] : _res$data$productSkuL,
|
|
12531
|
+
_res$data$total = _res$data.total,
|
|
12532
|
+
total = _res$data$total === void 0 ? 0 : _res$data$total;
|
|
12533
|
+
var newProducts = productSkuList.map(function (item, index) {
|
|
12534
|
+
return _objectSpread2({}, item);
|
|
12535
|
+
});
|
|
12536
|
+
return {
|
|
12537
|
+
total: total,
|
|
12538
|
+
list: newProducts
|
|
12539
|
+
};
|
|
12540
|
+
});
|
|
12541
|
+
};
|
|
12429
12542
|
var columns$3 = [{
|
|
12430
|
-
dataIndex: '
|
|
12431
|
-
title:
|
|
12432
|
-
|
|
12433
|
-
|
|
12434
|
-
|
|
12435
|
-
|
|
12436
|
-
|
|
12437
|
-
},
|
|
12438
|
-
|
|
12439
|
-
|
|
12440
|
-
width: 150
|
|
12441
|
-
}, {
|
|
12442
|
-
dataIndex: 'goodsShortName',
|
|
12443
|
-
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12444
|
-
width: 150
|
|
12445
|
-
}, {
|
|
12446
|
-
dataIndex: 'picPath',
|
|
12447
|
-
title: "\u5546\u54C1\u56FE\u7247",
|
|
12448
|
-
width: 150
|
|
12543
|
+
dataIndex: 'index',
|
|
12544
|
+
title: 'NO',
|
|
12545
|
+
render: function render(val, record, index) {
|
|
12546
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
12547
|
+
style: {
|
|
12548
|
+
width: 25
|
|
12549
|
+
}
|
|
12550
|
+
}, index + 1);
|
|
12551
|
+
},
|
|
12552
|
+
width: 80
|
|
12449
12553
|
}, {
|
|
12450
|
-
dataIndex: '
|
|
12451
|
-
title:
|
|
12452
|
-
width:
|
|
12554
|
+
dataIndex: 'specName',
|
|
12555
|
+
title: 'SKU名称',
|
|
12556
|
+
width: 250,
|
|
12557
|
+
ellipsis: true
|
|
12453
12558
|
}, {
|
|
12454
|
-
dataIndex: '
|
|
12455
|
-
title:
|
|
12456
|
-
width:
|
|
12559
|
+
dataIndex: 'specNo',
|
|
12560
|
+
title: 'SKU编码',
|
|
12561
|
+
width: 200,
|
|
12562
|
+
ellipsis: true
|
|
12457
12563
|
}, {
|
|
12458
|
-
dataIndex: '
|
|
12459
|
-
title:
|
|
12460
|
-
width:
|
|
12564
|
+
dataIndex: 'goodName',
|
|
12565
|
+
title: '商品名称',
|
|
12566
|
+
width: 250,
|
|
12567
|
+
ellipsis: true
|
|
12461
12568
|
}, {
|
|
12462
|
-
dataIndex: '
|
|
12463
|
-
title: "\
|
|
12464
|
-
|
|
12569
|
+
dataIndex: 'goodShortName',
|
|
12570
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12571
|
+
ellipsis: true,
|
|
12572
|
+
width: 250
|
|
12465
12573
|
}, {
|
|
12466
|
-
dataIndex: '
|
|
12467
|
-
title:
|
|
12468
|
-
width:
|
|
12574
|
+
dataIndex: 'goodNo',
|
|
12575
|
+
title: '商品编码',
|
|
12576
|
+
width: 200,
|
|
12577
|
+
ellipsis: true
|
|
12469
12578
|
}, {
|
|
12470
|
-
dataIndex: '
|
|
12471
|
-
title:
|
|
12472
|
-
width:
|
|
12579
|
+
dataIndex: 'goodPicUrl',
|
|
12580
|
+
title: '商品图片',
|
|
12581
|
+
width: 100,
|
|
12582
|
+
render: function render(picUrl) {
|
|
12583
|
+
return /*#__PURE__*/React.createElement("img", {
|
|
12584
|
+
style: {
|
|
12585
|
+
width: '40px',
|
|
12586
|
+
height: '40px',
|
|
12587
|
+
objectFit: 'contain'
|
|
12588
|
+
},
|
|
12589
|
+
src: picUrl
|
|
12590
|
+
});
|
|
12591
|
+
}
|
|
12473
12592
|
}, {
|
|
12474
12593
|
dataIndex: 'brandName',
|
|
12475
|
-
title:
|
|
12476
|
-
width:
|
|
12477
|
-
|
|
12478
|
-
dataIndex: 'goodsNumber',
|
|
12479
|
-
title: "\u5546\u54C1\u6570\u91CF",
|
|
12480
|
-
width: 150
|
|
12481
|
-
}, {
|
|
12482
|
-
dataIndex: 'goodsPrice',
|
|
12483
|
-
title: "\u5546\u54C1\u5355\u4EF7",
|
|
12484
|
-
width: 150
|
|
12594
|
+
title: '品牌名称',
|
|
12595
|
+
width: 200,
|
|
12596
|
+
ellipsis: true
|
|
12485
12597
|
}, {
|
|
12486
|
-
dataIndex: '
|
|
12487
|
-
title: "\
|
|
12488
|
-
|
|
12598
|
+
dataIndex: 'retailPrice',
|
|
12599
|
+
title: "\u6807\u51C6\u552E\u4EF7",
|
|
12600
|
+
ellipsis: true,
|
|
12601
|
+
width: 100
|
|
12489
12602
|
}, {
|
|
12490
|
-
dataIndex: '
|
|
12491
|
-
title: "\
|
|
12492
|
-
|
|
12493
|
-
|
|
12494
|
-
return /*#__PURE__*/React.createElement("span", null, +val ? '是' : '否');
|
|
12495
|
-
}
|
|
12603
|
+
dataIndex: 'costPrice',
|
|
12604
|
+
title: "\u6210\u672C\u4EF7",
|
|
12605
|
+
ellipsis: true,
|
|
12606
|
+
width: 100
|
|
12496
12607
|
}];
|
|
12497
|
-
var
|
|
12498
|
-
|
|
12499
|
-
|
|
12500
|
-
|
|
12501
|
-
|
|
12502
|
-
|
|
12503
|
-
|
|
12504
|
-
|
|
12505
|
-
|
|
12506
|
-
|
|
12507
|
-
|
|
12508
|
-
|
|
12509
|
-
|
|
12510
|
-
|
|
12511
|
-
}
|
|
12512
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12513
|
-
};
|
|
12514
|
-
},
|
|
12515
|
-
goodsPrice: function goodsPrice(_ref2) {
|
|
12516
|
-
var disabled = _ref2.disabled,
|
|
12517
|
-
updateHandle = _ref2.updateHandle;
|
|
12518
|
-
return function (val, record, index) {
|
|
12519
|
-
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
12520
|
-
style: {
|
|
12521
|
-
width: 70
|
|
12522
|
-
},
|
|
12523
|
-
value: val,
|
|
12524
|
-
min: 0,
|
|
12525
|
-
onChange: function onChange(value) {
|
|
12526
|
-
return updateHandle(value, index, 'goodsPrice');
|
|
12527
|
-
}
|
|
12528
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12529
|
-
};
|
|
12530
|
-
},
|
|
12531
|
-
isGift: function isGift(_ref3) {
|
|
12532
|
-
var disabled = _ref3.disabled,
|
|
12533
|
-
updateHandle = _ref3.updateHandle;
|
|
12534
|
-
return function (val, record, index) {
|
|
12535
|
-
var options = [{
|
|
12536
|
-
label: '是',
|
|
12537
|
-
value: 1
|
|
12538
|
-
}, {
|
|
12539
|
-
label: '否',
|
|
12540
|
-
value: 0
|
|
12541
|
-
}];
|
|
12542
|
-
return !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
12543
|
-
style: {
|
|
12544
|
-
width: 70
|
|
12545
|
-
},
|
|
12546
|
-
options: options,
|
|
12547
|
-
value: val,
|
|
12548
|
-
onChange: function onChange(value) {
|
|
12549
|
-
return updateHandle(value, index, 'isGift');
|
|
12550
|
-
},
|
|
12551
|
-
getPopupContainer: function getPopupContainer() {
|
|
12552
|
-
return document.getElementById('bsE3ReissueGoods');
|
|
12553
|
-
}
|
|
12554
|
-
}) : /*#__PURE__*/React.createElement("span", null, +val ? '是' : '否');
|
|
12608
|
+
var GoodList$2 = function GoodList(props, ref) {
|
|
12609
|
+
var _useState = useState([]),
|
|
12610
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
12611
|
+
selectList = _useState2[0],
|
|
12612
|
+
setSelect = _useState2[1];
|
|
12613
|
+
var _useState3 = useState([]),
|
|
12614
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
12615
|
+
selectIds = _useState4[0],
|
|
12616
|
+
setSelectIds = _useState4[1];
|
|
12617
|
+
useImperativeHandle(ref, function () {
|
|
12618
|
+
return {
|
|
12619
|
+
getSelectGoodList: function getSelectGoodList() {
|
|
12620
|
+
return selectList;
|
|
12621
|
+
}
|
|
12555
12622
|
};
|
|
12556
|
-
}
|
|
12557
|
-
|
|
12558
|
-
|
|
12559
|
-
|
|
12560
|
-
|
|
12561
|
-
|
|
12562
|
-
|
|
12563
|
-
|
|
12623
|
+
});
|
|
12624
|
+
var _Form$useForm = Form.useForm(),
|
|
12625
|
+
_Form$useForm2 = _slicedToArray(_Form$useForm, 1),
|
|
12626
|
+
form = _Form$useForm2[0];
|
|
12627
|
+
var _useAntdTable = useAntdTable(getTableData$2, {
|
|
12628
|
+
defaultPageSize: 10,
|
|
12629
|
+
form: form
|
|
12630
|
+
}),
|
|
12631
|
+
tableProps = _useAntdTable.tableProps,
|
|
12632
|
+
search = _useAntdTable.search,
|
|
12633
|
+
params = _useAntdTable.params;
|
|
12634
|
+
var submit = search.submit,
|
|
12635
|
+
reset = search.reset;
|
|
12636
|
+
var advanceSearchForm = /*#__PURE__*/React.createElement(Form, {
|
|
12637
|
+
layout: "inline",
|
|
12638
|
+
form: form
|
|
12639
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
12640
|
+
name: "skuName",
|
|
12641
|
+
style: {
|
|
12642
|
+
marginBottom: '12px'
|
|
12643
|
+
}
|
|
12644
|
+
}, /*#__PURE__*/React.createElement(Input, {
|
|
12645
|
+
placeholder: "\u5546\u54C1sku\u540D\u79F0",
|
|
12646
|
+
allowClear: true,
|
|
12647
|
+
style: {
|
|
12648
|
+
width: 150
|
|
12649
|
+
}
|
|
12650
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
12651
|
+
name: "skuCode",
|
|
12652
|
+
style: {
|
|
12653
|
+
marginBottom: '12px'
|
|
12654
|
+
}
|
|
12655
|
+
}, /*#__PURE__*/React.createElement(Input, {
|
|
12656
|
+
placeholder: "\u5546\u54C1sku\u7F16\u7801",
|
|
12657
|
+
allowClear: true,
|
|
12658
|
+
style: {
|
|
12659
|
+
width: 150
|
|
12660
|
+
}
|
|
12661
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
12662
|
+
name: "goodName",
|
|
12663
|
+
style: {
|
|
12664
|
+
marginBottom: '12px'
|
|
12665
|
+
}
|
|
12666
|
+
}, /*#__PURE__*/React.createElement(Input, {
|
|
12667
|
+
placeholder: "\u5546\u54C1\u540D\u79F0",
|
|
12668
|
+
allowClear: true,
|
|
12669
|
+
style: {
|
|
12670
|
+
width: 150
|
|
12671
|
+
}
|
|
12672
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
12673
|
+
name: "goodNo",
|
|
12674
|
+
style: {
|
|
12675
|
+
marginBottom: '12px'
|
|
12676
|
+
}
|
|
12677
|
+
}, /*#__PURE__*/React.createElement(Input, {
|
|
12678
|
+
placeholder: "\u5546\u54C1\u7F16\u7801",
|
|
12679
|
+
allowClear: true,
|
|
12680
|
+
style: {
|
|
12681
|
+
width: 150
|
|
12682
|
+
}
|
|
12683
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
12684
|
+
style: {
|
|
12685
|
+
marginBottom: '12px'
|
|
12686
|
+
}
|
|
12687
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
12688
|
+
type: "primary",
|
|
12689
|
+
style: {
|
|
12690
|
+
marginRight: '8px'
|
|
12691
|
+
},
|
|
12692
|
+
onClick: submit
|
|
12693
|
+
}, "\u67E5\u8BE2"), /*#__PURE__*/React.createElement(Button, {
|
|
12694
|
+
onClick: reset
|
|
12695
|
+
}, "\u91CD\u7F6E")));
|
|
12696
|
+
var rowSelection = {
|
|
12697
|
+
selectedRowKeys: selectIds,
|
|
12698
|
+
fixed: true,
|
|
12699
|
+
onSelect: function onSelect(record, selected) {
|
|
12700
|
+
if (selected) {
|
|
12701
|
+
setSelectIds([].concat(_toConsumableArray(selectIds), [record.specNo]));
|
|
12702
|
+
setSelect([].concat(_toConsumableArray(selectList), [record]));
|
|
12703
|
+
} else {
|
|
12704
|
+
setSelectIds(selectIds.filter(function (t) {
|
|
12705
|
+
return t !== record.specNo;
|
|
12706
|
+
}));
|
|
12707
|
+
setSelect(selectList.filter(function (t) {
|
|
12708
|
+
return t.specNo !== record.specNo;
|
|
12709
|
+
}));
|
|
12710
|
+
}
|
|
12711
|
+
},
|
|
12712
|
+
onSelectAll: function onSelectAll(selected, selectedRows, changeRows) {
|
|
12713
|
+
if (selected) {
|
|
12714
|
+
setSelectIds([].concat(_toConsumableArray(selectIds), _toConsumableArray(changeRows.map(function (t) {
|
|
12715
|
+
return t.specNo;
|
|
12716
|
+
}))));
|
|
12717
|
+
setSelect([].concat(_toConsumableArray(selectList), _toConsumableArray(changeRows)));
|
|
12718
|
+
} else {
|
|
12719
|
+
setSelectIds(difference(selectIds, changeRows.map(function (t) {
|
|
12720
|
+
return t.specNo;
|
|
12721
|
+
})));
|
|
12722
|
+
var list = differenceWith(selectList, changeRows, function (arrVal, othVal) {
|
|
12723
|
+
return arrVal.specNo !== othVal.specNo;
|
|
12724
|
+
});
|
|
12725
|
+
setSelect(list);
|
|
12726
|
+
}
|
|
12727
|
+
}
|
|
12728
|
+
};
|
|
12729
|
+
var showTable = function showTable() {
|
|
12730
|
+
var handleDelete = function handleDelete(record) {
|
|
12731
|
+
setSelectIds(selectIds.filter(function (t) {
|
|
12732
|
+
return t !== record.specNo;
|
|
12733
|
+
}));
|
|
12734
|
+
setSelect(selectList.filter(function (t) {
|
|
12735
|
+
return t.specNo !== record.specNo;
|
|
12736
|
+
}));
|
|
12737
|
+
};
|
|
12738
|
+
var showColumns = [{
|
|
12739
|
+
dataIndex: '',
|
|
12740
|
+
title: "\u64CD\u4F5C",
|
|
12741
|
+
ellipsis: true,
|
|
12742
|
+
width: 100,
|
|
12743
|
+
render: function render(val, record) {
|
|
12744
|
+
return /*#__PURE__*/React.createElement(Button, {
|
|
12745
|
+
type: "link",
|
|
12746
|
+
onClick: function onClick() {
|
|
12747
|
+
return handleDelete(record);
|
|
12748
|
+
}
|
|
12749
|
+
}, "\u5220\u9664");
|
|
12750
|
+
}
|
|
12751
|
+
}].concat(takeRight(columns$3, columns$3.length - 1));
|
|
12752
|
+
return selectList.length ? /*#__PURE__*/React.createElement("div", {
|
|
12753
|
+
style: {
|
|
12754
|
+
width: '100%',
|
|
12755
|
+
maxWidth: '387px'
|
|
12756
|
+
}
|
|
12757
|
+
}, /*#__PURE__*/React.createElement(Table, {
|
|
12758
|
+
columns: showColumns,
|
|
12759
|
+
rowKey: 'specNo',
|
|
12760
|
+
dataSource: selectList,
|
|
12761
|
+
scroll: {
|
|
12762
|
+
x: '100%',
|
|
12763
|
+
y: 250
|
|
12764
|
+
},
|
|
12765
|
+
pagination: {
|
|
12766
|
+
size: 'small',
|
|
12767
|
+
total: selectIds.length,
|
|
12768
|
+
pageSize: 10,
|
|
12769
|
+
showSizeChanger: false
|
|
12770
|
+
}
|
|
12771
|
+
})) : null;
|
|
12772
|
+
};
|
|
12773
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, advanceSearchForm, /*#__PURE__*/React.createElement("div", {
|
|
12774
|
+
style: {
|
|
12775
|
+
marginTop: '4px'
|
|
12776
|
+
}
|
|
12777
|
+
}, /*#__PURE__*/React.createElement(Table, _objectSpread2({
|
|
12778
|
+
rowSelection: rowSelection,
|
|
12779
|
+
rowKey: "specNo",
|
|
12780
|
+
columns: columns$3,
|
|
12781
|
+
scroll: {
|
|
12782
|
+
x: '100%',
|
|
12783
|
+
y: 250
|
|
12784
|
+
}
|
|
12785
|
+
}, tableProps))), /*#__PURE__*/React.createElement(Popover, {
|
|
12786
|
+
getPopupContainer: function getPopupContainer(triggerNode) {
|
|
12787
|
+
return triggerNode.parentElement;
|
|
12788
|
+
},
|
|
12789
|
+
content: showTable(),
|
|
12790
|
+
title: "\u5DF2\u9009\u62E9".concat(selectList.length, "\u4E2A\u5546\u54C1")
|
|
12791
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
12792
|
+
danger: true,
|
|
12793
|
+
type: "text"
|
|
12794
|
+
}, "\u5DF2\u9009".concat(selectList.length > 99 ? '99+' : selectList.length, "\u4E2A\u5546\u54C1"), /*#__PURE__*/React.createElement(CaretUpOutlined, null))));
|
|
12795
|
+
};
|
|
12796
|
+
var GyGoodsList = /*#__PURE__*/forwardRef(GoodList$2);
|
|
12797
|
+
|
|
12798
|
+
var GyGoodsModal = function GyGoodsModal(props, ref) {
|
|
12799
|
+
useImperativeHandle(ref, function () {
|
|
12800
|
+
return {
|
|
12801
|
+
open: function open() {
|
|
12802
|
+
setVisible(true);
|
|
12803
|
+
}
|
|
12804
|
+
};
|
|
12805
|
+
});
|
|
12806
|
+
var onSubmit = props.onSubmit,
|
|
12807
|
+
width = props.width;
|
|
12808
|
+
var _useState = useState(false),
|
|
12809
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
12810
|
+
visible = _useState2[0],
|
|
12811
|
+
setVisible = _useState2[1];
|
|
12812
|
+
var gyGoodsListRef = useRef(null);
|
|
12813
|
+
var _onCancel = function onCancel() {
|
|
12814
|
+
setVisible(false);
|
|
12815
|
+
};
|
|
12816
|
+
var onOk = function onOk() {
|
|
12817
|
+
var _gyGoodsListRef$curre;
|
|
12818
|
+
var selectedList = ((_gyGoodsListRef$curre = gyGoodsListRef.current) === null || _gyGoodsListRef$curre === void 0 ? void 0 : _gyGoodsListRef$curre.getSelectGoodList()) || [];
|
|
12819
|
+
onSubmit(selectedList);
|
|
12820
|
+
_onCancel();
|
|
12821
|
+
};
|
|
12822
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, visible && /*#__PURE__*/React.createElement(Modal, {
|
|
12823
|
+
title: '选择商品',
|
|
12824
|
+
okText: '确认',
|
|
12825
|
+
cancelText: '取消',
|
|
12826
|
+
visible: visible,
|
|
12827
|
+
width: width || 850,
|
|
12828
|
+
onCancel: function onCancel() {
|
|
12829
|
+
_onCancel();
|
|
12830
|
+
},
|
|
12831
|
+
onOk: onOk,
|
|
12832
|
+
wrapClassName: "goodModal"
|
|
12833
|
+
}, /*#__PURE__*/React.createElement(GyGoodsList, {
|
|
12834
|
+
ref: gyGoodsListRef
|
|
12835
|
+
})));
|
|
12836
|
+
};
|
|
12837
|
+
var GyGoodsModal$1 = /*#__PURE__*/forwardRef(GyGoodsModal);
|
|
12838
|
+
|
|
12839
|
+
var getColumns = function getColumns(_ref) {
|
|
12840
|
+
var _ref$text = _ref.text,
|
|
12841
|
+
disabled = _ref.disabled,
|
|
12842
|
+
updateHandle = _ref.updateHandle;
|
|
12843
|
+
return {
|
|
12844
|
+
//百胜E3补发商品
|
|
12845
|
+
BS_E3_REISSUE_GOODS: [{
|
|
12846
|
+
dataIndex: 'sku',
|
|
12847
|
+
title: "SKU",
|
|
12848
|
+
width: 150
|
|
12849
|
+
}, {
|
|
12850
|
+
dataIndex: 'skuId',
|
|
12851
|
+
title: "SKU ID",
|
|
12852
|
+
width: 150
|
|
12853
|
+
}, {
|
|
12854
|
+
dataIndex: 'goodsName',
|
|
12855
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
12856
|
+
width: 150
|
|
12857
|
+
}, {
|
|
12858
|
+
dataIndex: 'goodsShortName',
|
|
12859
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12860
|
+
width: 150
|
|
12861
|
+
}, {
|
|
12862
|
+
dataIndex: 'picPath',
|
|
12863
|
+
title: "\u5546\u54C1\u56FE\u7247",
|
|
12864
|
+
width: 150,
|
|
12865
|
+
render: function render(val) {
|
|
12866
|
+
return /*#__PURE__*/React.createElement(Image, {
|
|
12867
|
+
width: 60,
|
|
12868
|
+
src: val
|
|
12869
|
+
});
|
|
12870
|
+
}
|
|
12871
|
+
}, {
|
|
12872
|
+
dataIndex: 'goodsSn',
|
|
12873
|
+
title: "\u8D27\u53F7",
|
|
12874
|
+
width: 150
|
|
12875
|
+
}, {
|
|
12876
|
+
dataIndex: 'goodsId',
|
|
12877
|
+
title: "\u8D27\u53F7ID",
|
|
12878
|
+
width: 150
|
|
12879
|
+
}, {
|
|
12880
|
+
dataIndex: 'colorName',
|
|
12881
|
+
title: "\u989C\u8272\u540D\u79F0",
|
|
12882
|
+
width: 150
|
|
12883
|
+
}, {
|
|
12884
|
+
dataIndex: 'colorCode',
|
|
12885
|
+
title: "\u989C\u8272\u4EE3\u7801",
|
|
12886
|
+
width: 150
|
|
12887
|
+
}, {
|
|
12888
|
+
dataIndex: 'sizeName',
|
|
12889
|
+
title: "\u5C3A\u7801\u540D\u79F0",
|
|
12890
|
+
width: 150
|
|
12891
|
+
}, {
|
|
12892
|
+
dataIndex: 'sizeCode',
|
|
12893
|
+
title: "\u5C3A\u7801\u4EE3\u7801",
|
|
12894
|
+
width: 150
|
|
12895
|
+
}, {
|
|
12896
|
+
dataIndex: 'brandName',
|
|
12897
|
+
title: "\u54C1\u724C\u540D\u79F0",
|
|
12898
|
+
width: 150
|
|
12899
|
+
}, {
|
|
12900
|
+
dataIndex: 'goodsNumber',
|
|
12901
|
+
title: "\u5546\u54C1\u6570\u91CF",
|
|
12902
|
+
width: 150
|
|
12903
|
+
}, {
|
|
12904
|
+
dataIndex: 'goodsPrice',
|
|
12905
|
+
title: "\u5546\u54C1\u5355\u4EF7",
|
|
12906
|
+
width: 150
|
|
12907
|
+
}, {
|
|
12908
|
+
dataIndex: 'shopPrice',
|
|
12909
|
+
title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
|
|
12910
|
+
width: 150
|
|
12911
|
+
}, {
|
|
12912
|
+
dataIndex: 'isGift',
|
|
12913
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
12914
|
+
width: 150,
|
|
12915
|
+
render: function render(val) {
|
|
12916
|
+
return /*#__PURE__*/React.createElement("span", null, +val ? '是' : '否');
|
|
12917
|
+
}
|
|
12918
|
+
}],
|
|
12919
|
+
//百胜E3商品信息
|
|
12920
|
+
BS_E3_GOODS: [{
|
|
12921
|
+
dataIndex: 'sku',
|
|
12922
|
+
title: "SKU",
|
|
12923
|
+
align: 'center',
|
|
12924
|
+
ellipsis: true,
|
|
12925
|
+
width: 150
|
|
12926
|
+
}, {
|
|
12927
|
+
dataIndex: 'skuId',
|
|
12928
|
+
title: "SKU ID",
|
|
12929
|
+
align: 'center',
|
|
12930
|
+
ellipsis: true,
|
|
12931
|
+
width: 150
|
|
12932
|
+
}, {
|
|
12933
|
+
dataIndex: 'goodsName',
|
|
12934
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
12935
|
+
align: 'center',
|
|
12936
|
+
ellipsis: true,
|
|
12937
|
+
width: 150
|
|
12938
|
+
}, {
|
|
12939
|
+
dataIndex: 'goodsShortName',
|
|
12940
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12941
|
+
align: 'center',
|
|
12942
|
+
ellipsis: true,
|
|
12943
|
+
width: 100
|
|
12944
|
+
}, {
|
|
12945
|
+
dataIndex: 'picPath',
|
|
12946
|
+
title: "\u5546\u54C1\u56FE\u7247",
|
|
12947
|
+
align: 'center',
|
|
12948
|
+
ellipsis: true,
|
|
12949
|
+
width: 100,
|
|
12950
|
+
render: function render(val) {
|
|
12951
|
+
return /*#__PURE__*/React.createElement(Image, {
|
|
12952
|
+
width: 60,
|
|
12953
|
+
src: val
|
|
12954
|
+
});
|
|
12955
|
+
}
|
|
12956
|
+
}, {
|
|
12957
|
+
dataIndex: 'goodsSn',
|
|
12958
|
+
title: "\u8D27\u53F7",
|
|
12959
|
+
align: 'center',
|
|
12960
|
+
ellipsis: true,
|
|
12961
|
+
width: 150
|
|
12962
|
+
}, {
|
|
12963
|
+
dataIndex: 'goodsId',
|
|
12964
|
+
title: "\u8D27\u53F7ID",
|
|
12965
|
+
align: 'center',
|
|
12966
|
+
ellipsis: true,
|
|
12967
|
+
width: 150
|
|
12968
|
+
}, {
|
|
12969
|
+
dataIndex: 'colorName',
|
|
12970
|
+
title: "\u989C\u8272\u540D\u79F0",
|
|
12971
|
+
align: 'center',
|
|
12972
|
+
ellipsis: true,
|
|
12973
|
+
width: 100
|
|
12974
|
+
}, {
|
|
12975
|
+
dataIndex: 'colorCode',
|
|
12976
|
+
title: "\u989C\u8272\u4EE3\u7801",
|
|
12977
|
+
align: 'center',
|
|
12978
|
+
ellipsis: true,
|
|
12979
|
+
width: 150
|
|
12980
|
+
}, {
|
|
12981
|
+
dataIndex: 'sizeName',
|
|
12982
|
+
title: "\u5C3A\u7801\u540D\u79F0",
|
|
12983
|
+
align: 'center',
|
|
12984
|
+
ellipsis: true,
|
|
12985
|
+
width: 100
|
|
12986
|
+
}, {
|
|
12987
|
+
dataIndex: 'sizeCode',
|
|
12988
|
+
title: "\u5C3A\u7801\u4EE3\u7801",
|
|
12989
|
+
align: 'center',
|
|
12990
|
+
ellipsis: true,
|
|
12991
|
+
width: 100
|
|
12992
|
+
}, {
|
|
12993
|
+
dataIndex: 'brandName',
|
|
12994
|
+
title: "\u54C1\u724C\u540D\u79F0",
|
|
12995
|
+
align: 'center',
|
|
12996
|
+
ellipsis: true,
|
|
12997
|
+
width: 150
|
|
12998
|
+
}, {
|
|
12999
|
+
dataIndex: 'goodsNumber',
|
|
13000
|
+
title: "\u5546\u54C1\u6570\u91CF",
|
|
13001
|
+
align: 'center',
|
|
13002
|
+
ellipsis: true,
|
|
13003
|
+
width: 100,
|
|
13004
|
+
render: function render(val, record, index) {
|
|
13005
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13006
|
+
style: {
|
|
13007
|
+
width: 70
|
|
13008
|
+
},
|
|
13009
|
+
value: val,
|
|
13010
|
+
min: 1,
|
|
13011
|
+
precision: 0,
|
|
13012
|
+
onChange: function onChange(num) {
|
|
13013
|
+
return updateHandle(num, index, 'goodsNumber');
|
|
13014
|
+
}
|
|
13015
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13016
|
+
}
|
|
13017
|
+
}, {
|
|
13018
|
+
dataIndex: 'goodsPrice',
|
|
13019
|
+
title: "\u5546\u54C1\u5355\u4EF7",
|
|
13020
|
+
align: 'center',
|
|
13021
|
+
ellipsis: true,
|
|
13022
|
+
width: 120,
|
|
13023
|
+
render: function render(val, record, index) {
|
|
13024
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13025
|
+
style: {
|
|
13026
|
+
width: 70
|
|
13027
|
+
},
|
|
13028
|
+
value: val,
|
|
13029
|
+
min: 0,
|
|
13030
|
+
precision: 2,
|
|
13031
|
+
onChange: function onChange(num) {
|
|
13032
|
+
return updateHandle(num, index, 'goodsPrice');
|
|
13033
|
+
}
|
|
13034
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13035
|
+
}
|
|
13036
|
+
}, {
|
|
13037
|
+
dataIndex: 'shopPrice',
|
|
13038
|
+
title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
|
|
13039
|
+
align: 'center',
|
|
13040
|
+
ellipsis: true,
|
|
13041
|
+
width: 120
|
|
13042
|
+
}, {
|
|
13043
|
+
dataIndex: 'sharePrice',
|
|
13044
|
+
title: "\u5206\u644A\u4EF7",
|
|
13045
|
+
align: 'center',
|
|
13046
|
+
ellipsis: true,
|
|
13047
|
+
width: 120
|
|
13048
|
+
}, {
|
|
13049
|
+
dataIndex: 'sharePayment',
|
|
13050
|
+
title: "\u5206\u644A\u5B9E\u4ED8\u91D1\u989D",
|
|
13051
|
+
align: 'center',
|
|
13052
|
+
ellipsis: true,
|
|
13053
|
+
width: 120
|
|
13054
|
+
}, {
|
|
13055
|
+
dataIndex: 'payment',
|
|
13056
|
+
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
13057
|
+
align: 'center',
|
|
13058
|
+
ellipsis: true,
|
|
13059
|
+
width: 120,
|
|
13060
|
+
render: function render(val, record, index) {
|
|
13061
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13062
|
+
style: {
|
|
13063
|
+
width: 70
|
|
13064
|
+
},
|
|
13065
|
+
value: val,
|
|
13066
|
+
min: 0,
|
|
13067
|
+
precision: 2,
|
|
13068
|
+
onChange: function onChange(num) {
|
|
13069
|
+
return updateHandle(num, index, 'payment');
|
|
13070
|
+
}
|
|
13071
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13072
|
+
}
|
|
13073
|
+
}, {
|
|
13074
|
+
dataIndex: 'tcSku',
|
|
13075
|
+
title: "\u5957\u9910SKU",
|
|
13076
|
+
align: 'center',
|
|
13077
|
+
ellipsis: true,
|
|
13078
|
+
width: 150
|
|
13079
|
+
}, {
|
|
13080
|
+
dataIndex: 'tcGoodsNumber',
|
|
13081
|
+
title: "\u5957\u9910\u5957\u6570",
|
|
13082
|
+
align: 'center',
|
|
13083
|
+
ellipsis: true,
|
|
13084
|
+
width: 100
|
|
13085
|
+
}, {
|
|
13086
|
+
dataIndex: 'taoCanSingleSl',
|
|
13087
|
+
title: "\u5355\u4E2A\u5957\u9910\u6570\u91CF",
|
|
13088
|
+
align: 'center',
|
|
13089
|
+
ellipsis: true,
|
|
13090
|
+
width: 100
|
|
13091
|
+
}, {
|
|
13092
|
+
dataIndex: 'isGift',
|
|
13093
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
13094
|
+
align: 'center',
|
|
13095
|
+
ellipsis: true,
|
|
13096
|
+
width: 100,
|
|
13097
|
+
render: function render(val) {
|
|
13098
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
13099
|
+
}
|
|
13100
|
+
}]
|
|
13101
|
+
};
|
|
13102
|
+
};
|
|
13103
|
+
|
|
13104
|
+
var getColumns$1 = function getColumns(_ref) {
|
|
13105
|
+
var _ref$text = _ref.text,
|
|
13106
|
+
text = _ref$text === void 0 ? '' : _ref$text,
|
|
13107
|
+
disabled = _ref.disabled,
|
|
13108
|
+
updateHandle = _ref.updateHandle;
|
|
13109
|
+
return {
|
|
13110
|
+
//bs商品信息
|
|
13111
|
+
BS_GOODS: [{
|
|
13112
|
+
dataIndex: 'mark',
|
|
13113
|
+
title: "\u5546\u54C1\u6807\u8BB0",
|
|
13114
|
+
align: 'center',
|
|
13115
|
+
ellipsis: true,
|
|
13116
|
+
width: 70,
|
|
13117
|
+
render: function render(val, record, index) {
|
|
13118
|
+
return /*#__PURE__*/React.createElement(Select, {
|
|
13119
|
+
options: [{
|
|
13120
|
+
label: '是',
|
|
13121
|
+
value: '是'
|
|
13122
|
+
}, {
|
|
13123
|
+
label: '否',
|
|
13124
|
+
value: '否'
|
|
13125
|
+
}],
|
|
13126
|
+
disabled: disabled,
|
|
13127
|
+
value: val,
|
|
13128
|
+
onChange: function onChange(val) {
|
|
13129
|
+
return updateHandle(val, index, 'mark');
|
|
13130
|
+
}
|
|
13131
|
+
});
|
|
13132
|
+
}
|
|
13133
|
+
}, {
|
|
13134
|
+
dataIndex: 'skuName',
|
|
13135
|
+
title: "".concat(text, "sku\u540D\u79F0"),
|
|
13136
|
+
align: 'center',
|
|
13137
|
+
ellipsis: true,
|
|
13138
|
+
width: 250
|
|
13139
|
+
}, {
|
|
13140
|
+
dataIndex: 'sku',
|
|
13141
|
+
title: "".concat(text, "sku\u7F16\u7801"),
|
|
13142
|
+
align: 'center',
|
|
13143
|
+
ellipsis: true,
|
|
13144
|
+
width: 100
|
|
13145
|
+
}, {
|
|
13146
|
+
dataIndex: 'name',
|
|
13147
|
+
title: "".concat(text, "\u540D\u79F0"),
|
|
13148
|
+
align: 'center',
|
|
13149
|
+
ellipsis: true,
|
|
13150
|
+
width: 250
|
|
13151
|
+
}, {
|
|
13152
|
+
dataIndex: 'pic',
|
|
13153
|
+
title: "\u56FE\u7247",
|
|
13154
|
+
align: 'center',
|
|
13155
|
+
ellipsis: true,
|
|
13156
|
+
width: 100,
|
|
13157
|
+
render: function render(val) {
|
|
13158
|
+
return /*#__PURE__*/React.createElement(Image, {
|
|
13159
|
+
width: 60,
|
|
13160
|
+
src: val
|
|
13161
|
+
});
|
|
13162
|
+
}
|
|
13163
|
+
}, {
|
|
13164
|
+
dataIndex: 'code',
|
|
13165
|
+
title: "".concat(text, "\u7F16\u7801"),
|
|
13166
|
+
align: 'center',
|
|
13167
|
+
ellipsis: true,
|
|
13168
|
+
width: 100
|
|
13169
|
+
}, {
|
|
13170
|
+
dataIndex: 'money',
|
|
13171
|
+
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
13172
|
+
align: 'center',
|
|
13173
|
+
ellipsis: true,
|
|
13174
|
+
width: 100
|
|
13175
|
+
}, {
|
|
13176
|
+
dataIndex: 'number',
|
|
13177
|
+
title: "".concat(text, "\u6570\u91CF"),
|
|
13178
|
+
align: 'center',
|
|
13179
|
+
ellipsis: true,
|
|
13180
|
+
width: 100,
|
|
13181
|
+
render: function render(val, record, index) {
|
|
13182
|
+
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13183
|
+
style: {
|
|
13184
|
+
width: 70
|
|
13185
|
+
},
|
|
13186
|
+
value: val,
|
|
13187
|
+
min: 1,
|
|
13188
|
+
precision: 0,
|
|
13189
|
+
onChange: function onChange(num) {
|
|
13190
|
+
return updateHandle(num, index, 'number');
|
|
13191
|
+
}
|
|
13192
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13193
|
+
}
|
|
13194
|
+
}, {
|
|
13195
|
+
dataIndex: 'share',
|
|
13196
|
+
title: "\u5206\u644A\u4EF7",
|
|
13197
|
+
align: 'center',
|
|
13198
|
+
ellipsis: true,
|
|
13199
|
+
width: 70
|
|
13200
|
+
}, {
|
|
13201
|
+
dataIndex: 'type',
|
|
13202
|
+
title: "\u8D60\u54C1\u7C7B\u578B",
|
|
13203
|
+
align: 'center',
|
|
13204
|
+
ellipsis: true,
|
|
13205
|
+
width: 100
|
|
13206
|
+
}, {
|
|
13207
|
+
dataIndex: 'batch',
|
|
13208
|
+
title: "\u6279\u6B21\u53F7",
|
|
13209
|
+
align: 'center',
|
|
13210
|
+
ellipsis: true,
|
|
13211
|
+
width: 100
|
|
13212
|
+
}, {
|
|
13213
|
+
dataIndex: 'expireDate',
|
|
13214
|
+
title: "\u6709\u6548\u671F",
|
|
13215
|
+
align: 'center',
|
|
13216
|
+
ellipsis: true,
|
|
13217
|
+
width: 100
|
|
13218
|
+
}]
|
|
13219
|
+
};
|
|
13220
|
+
};
|
|
13221
|
+
|
|
13222
|
+
var renderGiftType = function renderGiftType(val) {
|
|
13223
|
+
var giftTypeMap = {
|
|
13224
|
+
0: '非赠品',
|
|
13225
|
+
1: '自动赠送',
|
|
13226
|
+
2: '手工赠送',
|
|
13227
|
+
3: '回购自动送赠品',
|
|
13228
|
+
4: '前N有礼送赠品',
|
|
13229
|
+
6: '天猫优仓赠品',
|
|
13230
|
+
7: '淘宝CRM会员送赠'
|
|
13231
|
+
};
|
|
13232
|
+
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
13233
|
+
};
|
|
13234
|
+
var renderFieldMap = {
|
|
13235
|
+
num: function num(_ref) {
|
|
13236
|
+
var disabled = _ref.disabled,
|
|
13237
|
+
updateHandle = _ref.updateHandle;
|
|
13238
|
+
return function (val, record, index) {
|
|
13239
|
+
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13240
|
+
style: {
|
|
13241
|
+
width: 70
|
|
13242
|
+
},
|
|
13243
|
+
value: val,
|
|
13244
|
+
min: 1,
|
|
13245
|
+
precision: 0,
|
|
13246
|
+
onChange: function onChange(num) {
|
|
13247
|
+
return updateHandle(num, index, 'num');
|
|
13248
|
+
}
|
|
13249
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13250
|
+
};
|
|
13251
|
+
},
|
|
13252
|
+
giftType: function giftType() {
|
|
13253
|
+
return renderGiftType;
|
|
13254
|
+
}
|
|
13255
|
+
};
|
|
13256
|
+
var getWdtReissueGoodColumns = function getWdtReissueGoodColumns(_ref2) {
|
|
13257
|
+
var disabled = _ref2.disabled,
|
|
13258
|
+
updateHandle = _ref2.updateHandle,
|
|
13259
|
+
operate = _ref2.operate;
|
|
13260
|
+
return getColumnsMap()['WDT_REISSUE_GOODS'].map(function (item) {
|
|
13261
|
+
var newItem = _objectSpread2({
|
|
13262
|
+
align: 'center',
|
|
13263
|
+
ellipsis: true
|
|
13264
|
+
}, item);
|
|
13265
|
+
if (operate && (renderFieldMap === null || renderFieldMap === void 0 ? void 0 : renderFieldMap[item.dataIndex])) {
|
|
13266
|
+
return _objectSpread2(_objectSpread2({}, newItem), {}, {
|
|
13267
|
+
render: renderFieldMap === null || renderFieldMap === void 0 ? void 0 : renderFieldMap[item.dataIndex]({
|
|
13268
|
+
disabled: disabled,
|
|
13269
|
+
updateHandle: updateHandle
|
|
13270
|
+
})
|
|
13271
|
+
});
|
|
13272
|
+
}
|
|
13273
|
+
return newItem;
|
|
13274
|
+
});
|
|
13275
|
+
};
|
|
13276
|
+
|
|
13277
|
+
var getColumns$2 = function getColumns(_ref) {
|
|
13278
|
+
var _ref$text = _ref.text,
|
|
13279
|
+
text = _ref$text === void 0 ? '' : _ref$text,
|
|
13280
|
+
disabled = _ref.disabled,
|
|
13281
|
+
updateHandle = _ref.updateHandle;
|
|
13282
|
+
return {
|
|
13283
|
+
//旺店通补发商品信息
|
|
13284
|
+
WDT_REISSUE_GOODS: [{
|
|
13285
|
+
dataIndex: 'goodId',
|
|
13286
|
+
title: "\u5546\u54C1ID",
|
|
13287
|
+
width: 120
|
|
13288
|
+
}, {
|
|
13289
|
+
dataIndex: 'goodNo',
|
|
13290
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13291
|
+
width: 200
|
|
13292
|
+
}, {
|
|
13293
|
+
dataIndex: 'goodName',
|
|
13294
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
13295
|
+
width: 200
|
|
13296
|
+
}, {
|
|
13297
|
+
dataIndex: 'specId',
|
|
13298
|
+
title: "SKUID",
|
|
13299
|
+
width: 150
|
|
13300
|
+
}, {
|
|
13301
|
+
dataIndex: 'specNo',
|
|
13302
|
+
title: "\u5546\u54C1SKU\u7F16\u7801",
|
|
13303
|
+
width: 200
|
|
13304
|
+
}, {
|
|
13305
|
+
dataIndex: 'specName',
|
|
13306
|
+
title: "\u5546\u54C1SKU\u540D\u79F0",
|
|
13307
|
+
width: 250
|
|
13308
|
+
}, {
|
|
13309
|
+
dataIndex: 'orderPrice',
|
|
13310
|
+
title: "\u5B9E\u4ED8\u603B\u91D1\u989D",
|
|
13311
|
+
width: 200
|
|
13312
|
+
}, {
|
|
13313
|
+
dataIndex: 'num',
|
|
13314
|
+
title: "\u6570\u91CF",
|
|
13315
|
+
width: 100
|
|
13316
|
+
}, {
|
|
13317
|
+
dataIndex: 'sharePrice',
|
|
13318
|
+
title: "\u5206\u644A\u4EF7",
|
|
13319
|
+
width: 150
|
|
13320
|
+
}, {
|
|
13321
|
+
dataIndex: 'giftType',
|
|
13322
|
+
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
13323
|
+
width: 100,
|
|
13324
|
+
render: renderGiftType
|
|
13325
|
+
}],
|
|
13326
|
+
//旺店通商品信息
|
|
13327
|
+
WDT_GOODS: [{
|
|
13328
|
+
dataIndex: 'goodId',
|
|
13329
|
+
title: "\u5546\u54C1ID",
|
|
13330
|
+
align: 'center',
|
|
13331
|
+
ellipsis: true,
|
|
13332
|
+
width: 70
|
|
13333
|
+
}, {
|
|
13334
|
+
dataIndex: 'goodNo',
|
|
13335
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13336
|
+
align: 'center',
|
|
13337
|
+
ellipsis: true,
|
|
13338
|
+
width: 180
|
|
13339
|
+
}, {
|
|
13340
|
+
dataIndex: 'goodName',
|
|
13341
|
+
title: "".concat(text, "\u5546\u54C1\u540D\u79F0"),
|
|
13342
|
+
align: 'center',
|
|
13343
|
+
ellipsis: true,
|
|
13344
|
+
width: 250
|
|
13345
|
+
}, {
|
|
13346
|
+
dataIndex: 'specId',
|
|
13347
|
+
title: "".concat(text, "SKUID"),
|
|
13348
|
+
align: 'center',
|
|
13349
|
+
ellipsis: true,
|
|
13350
|
+
width: 100
|
|
13351
|
+
}, {
|
|
13352
|
+
dataIndex: 'specNo',
|
|
13353
|
+
title: "".concat(text, "\u5546\u54C1SKU\u7F16\u7801"),
|
|
13354
|
+
align: 'center',
|
|
13355
|
+
ellipsis: true,
|
|
13356
|
+
width: 180
|
|
13357
|
+
}, {
|
|
13358
|
+
dataIndex: 'specName',
|
|
13359
|
+
title: "".concat(text, "\u5546\u54C1SKU\u540D\u79F0"),
|
|
13360
|
+
align: 'center',
|
|
13361
|
+
ellipsis: true,
|
|
13362
|
+
width: 250
|
|
13363
|
+
}, {
|
|
13364
|
+
dataIndex: 'orderPrice',
|
|
13365
|
+
title: "\u5B9E\u4ED8\u603B\u91D1\u989D",
|
|
13366
|
+
align: 'center',
|
|
13367
|
+
ellipsis: true,
|
|
13368
|
+
width: 100
|
|
13369
|
+
}, {
|
|
13370
|
+
dataIndex: 'num',
|
|
13371
|
+
title: "".concat(text, "\u6570\u91CF"),
|
|
13372
|
+
align: 'center',
|
|
13373
|
+
ellipsis: true,
|
|
13374
|
+
width: 100,
|
|
13375
|
+
render: function render(val, record, index) {
|
|
13376
|
+
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13377
|
+
style: {
|
|
13378
|
+
width: 70
|
|
13379
|
+
},
|
|
13380
|
+
value: val,
|
|
13381
|
+
min: 1,
|
|
13382
|
+
precision: 0,
|
|
13383
|
+
onChange: function onChange(num) {
|
|
13384
|
+
return updateHandle(num, index, 'num');
|
|
13385
|
+
}
|
|
13386
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13387
|
+
}
|
|
13388
|
+
}, {
|
|
13389
|
+
dataIndex: 'sharePrice',
|
|
13390
|
+
title: "\u5206\u644A\u4EF7",
|
|
13391
|
+
align: 'center',
|
|
13392
|
+
ellipsis: true,
|
|
13393
|
+
width: 70
|
|
13394
|
+
}, {
|
|
13395
|
+
dataIndex: 'giftType',
|
|
13396
|
+
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
13397
|
+
align: 'center',
|
|
13398
|
+
ellipsis: true,
|
|
13399
|
+
width: 100,
|
|
13400
|
+
render: function render(val) {
|
|
13401
|
+
var giftTypeMap = {
|
|
13402
|
+
0: '非赠品',
|
|
13403
|
+
1: '自动赠送',
|
|
13404
|
+
2: '手工赠送',
|
|
13405
|
+
3: '回购自动送赠品',
|
|
13406
|
+
4: '前N有礼送赠品',
|
|
13407
|
+
6: '天猫优仓赠品',
|
|
13408
|
+
7: '淘宝CRM会员送赠'
|
|
13409
|
+
};
|
|
13410
|
+
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
13411
|
+
}
|
|
13412
|
+
}],
|
|
13413
|
+
//旺店通退货商品信息
|
|
13414
|
+
WDT_RETURN_GOODS: [{
|
|
13415
|
+
dataIndex: 'goodId',
|
|
13416
|
+
title: "\u5546\u54C1ID",
|
|
13417
|
+
align: 'center',
|
|
13418
|
+
ellipsis: true,
|
|
13419
|
+
width: 70
|
|
13420
|
+
}, {
|
|
13421
|
+
dataIndex: 'goodNo',
|
|
13422
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13423
|
+
align: 'center',
|
|
13424
|
+
ellipsis: true,
|
|
13425
|
+
width: 180
|
|
13426
|
+
}, {
|
|
13427
|
+
dataIndex: 'goodName',
|
|
13428
|
+
title: "".concat(text, "\u5546\u54C1\u540D\u79F0"),
|
|
13429
|
+
align: 'center',
|
|
13430
|
+
ellipsis: true,
|
|
13431
|
+
width: 250
|
|
13432
|
+
}, {
|
|
13433
|
+
dataIndex: 'specId',
|
|
13434
|
+
title: "".concat(text, "SKUID"),
|
|
13435
|
+
align: 'center',
|
|
13436
|
+
ellipsis: true,
|
|
13437
|
+
width: 100
|
|
13438
|
+
}, {
|
|
13439
|
+
dataIndex: 'specNo',
|
|
13440
|
+
title: "".concat(text, "\u5546\u54C1SKU\u7F16\u7801"),
|
|
13441
|
+
align: 'center',
|
|
13442
|
+
ellipsis: true,
|
|
13443
|
+
width: 180
|
|
13444
|
+
}, {
|
|
13445
|
+
dataIndex: 'specName',
|
|
13446
|
+
title: "".concat(text, "\u5546\u54C1SKU\u540D\u79F0"),
|
|
13447
|
+
align: 'center',
|
|
13448
|
+
ellipsis: true,
|
|
13449
|
+
width: 250
|
|
13450
|
+
}, {
|
|
13451
|
+
dataIndex: 'num',
|
|
13452
|
+
title: "".concat(text, "\u9000\u8D27\u6570\u91CF"),
|
|
13453
|
+
align: 'center',
|
|
13454
|
+
ellipsis: true,
|
|
13455
|
+
width: 100,
|
|
13456
|
+
render: function render(val, record, index) {
|
|
13457
|
+
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13458
|
+
style: {
|
|
13459
|
+
width: 70
|
|
13460
|
+
},
|
|
13461
|
+
value: val,
|
|
13462
|
+
min: 1,
|
|
13463
|
+
precision: 0,
|
|
13464
|
+
onChange: function onChange(num) {
|
|
13465
|
+
return updateHandle(num, index, 'num');
|
|
13466
|
+
}
|
|
13467
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13468
|
+
}
|
|
13469
|
+
}, {
|
|
13470
|
+
dataIndex: 'sharePrice',
|
|
13471
|
+
title: "\u5206\u644A\u4EF7",
|
|
13472
|
+
align: 'center',
|
|
13473
|
+
ellipsis: true,
|
|
13474
|
+
width: 80,
|
|
13475
|
+
render: function render(val, record, index) {
|
|
13476
|
+
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13477
|
+
style: {
|
|
13478
|
+
width: 70
|
|
13479
|
+
},
|
|
13480
|
+
value: val,
|
|
13481
|
+
min: 0,
|
|
13482
|
+
onChange: function onChange(value) {
|
|
13483
|
+
return updateHandle(value, index, 'sharePrice');
|
|
13484
|
+
}
|
|
13485
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13486
|
+
}
|
|
13487
|
+
}, {
|
|
13488
|
+
dataIndex: 'returnPrice',
|
|
13489
|
+
title: "".concat(text, "\u9000\u8D27\u91D1\u989D"),
|
|
13490
|
+
align: 'center',
|
|
13491
|
+
ellipsis: true,
|
|
13492
|
+
width: 100
|
|
13493
|
+
}, {
|
|
13494
|
+
dataIndex: 'giftType',
|
|
13495
|
+
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
13496
|
+
align: 'center',
|
|
13497
|
+
ellipsis: true,
|
|
13498
|
+
width: 100,
|
|
13499
|
+
render: function render(val) {
|
|
13500
|
+
var giftTypeMap = {
|
|
13501
|
+
0: '非赠品',
|
|
13502
|
+
1: '自动赠送',
|
|
13503
|
+
2: '手工赠送',
|
|
13504
|
+
3: '回购自动送赠品',
|
|
13505
|
+
4: '前N有礼送赠品',
|
|
13506
|
+
6: '天猫优仓赠品',
|
|
13507
|
+
7: '淘宝CRM会员送赠'
|
|
13508
|
+
};
|
|
13509
|
+
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
13510
|
+
}
|
|
13511
|
+
}, {
|
|
13512
|
+
dataIndex: 'type',
|
|
13513
|
+
title: "".concat(text, "\u5546\u54C1\u7C7B\u578B"),
|
|
13514
|
+
align: 'center',
|
|
13515
|
+
ellipsis: true,
|
|
13516
|
+
width: 100,
|
|
13517
|
+
render: function render(val, record, index) {
|
|
13518
|
+
var options = [{
|
|
13519
|
+
label: '单品',
|
|
13520
|
+
value: '1'
|
|
13521
|
+
}, {
|
|
13522
|
+
label: '组合装',
|
|
13523
|
+
value: '2'
|
|
13524
|
+
}];
|
|
13525
|
+
return !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
13526
|
+
style: {
|
|
13527
|
+
width: 70
|
|
13528
|
+
},
|
|
13529
|
+
options: options,
|
|
13530
|
+
value: val,
|
|
13531
|
+
onChange: function onChange(value) {
|
|
13532
|
+
return updateHandle(value, index, 'type');
|
|
13533
|
+
}
|
|
13534
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13535
|
+
}
|
|
13536
|
+
}],
|
|
13537
|
+
//旺店通换出商品信息
|
|
13538
|
+
WDT_EXCHANGE_GOODS: [{
|
|
13539
|
+
dataIndex: 'goodId',
|
|
13540
|
+
title: "\u5546\u54C1ID",
|
|
13541
|
+
align: 'center',
|
|
13542
|
+
ellipsis: true,
|
|
13543
|
+
width: 70
|
|
13544
|
+
}, {
|
|
13545
|
+
dataIndex: 'goodNo',
|
|
13546
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13547
|
+
align: 'center',
|
|
13548
|
+
ellipsis: true,
|
|
13549
|
+
width: 180
|
|
13550
|
+
}, {
|
|
13551
|
+
dataIndex: 'goodName',
|
|
13552
|
+
title: "".concat(text, "\u5546\u54C1\u540D\u79F0"),
|
|
13553
|
+
align: 'center',
|
|
13554
|
+
ellipsis: true,
|
|
13555
|
+
width: 250
|
|
13556
|
+
}, {
|
|
13557
|
+
dataIndex: 'specId',
|
|
13558
|
+
title: "".concat(text, "SKUID"),
|
|
13559
|
+
align: 'center',
|
|
13560
|
+
ellipsis: true,
|
|
13561
|
+
width: 100
|
|
13562
|
+
}, {
|
|
13563
|
+
dataIndex: 'specNo',
|
|
13564
|
+
title: "".concat(text, "\u5546\u54C1SKU\u7F16\u7801"),
|
|
13565
|
+
align: 'center',
|
|
13566
|
+
ellipsis: true,
|
|
13567
|
+
width: 180
|
|
13568
|
+
}, {
|
|
13569
|
+
dataIndex: 'specName',
|
|
13570
|
+
title: "".concat(text, "\u5546\u54C1SKU\u540D\u79F0"),
|
|
13571
|
+
align: 'center',
|
|
13572
|
+
ellipsis: true,
|
|
13573
|
+
width: 250
|
|
13574
|
+
}, {
|
|
13575
|
+
dataIndex: 'num',
|
|
13576
|
+
title: "".concat(text, "\u6362\u51FA\u6570\u91CF"),
|
|
13577
|
+
align: 'center',
|
|
13578
|
+
ellipsis: true,
|
|
13579
|
+
width: 100,
|
|
13580
|
+
render: function render(val, record, index) {
|
|
13581
|
+
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13582
|
+
style: {
|
|
13583
|
+
width: 70
|
|
13584
|
+
},
|
|
13585
|
+
value: val,
|
|
13586
|
+
min: 1,
|
|
13587
|
+
precision: 0,
|
|
13588
|
+
onChange: function onChange(num) {
|
|
13589
|
+
return updateHandle(num, index, 'num');
|
|
13590
|
+
}
|
|
13591
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13592
|
+
}
|
|
13593
|
+
}, {
|
|
13594
|
+
dataIndex: 'price',
|
|
13595
|
+
title: "".concat(text, "\u5546\u54C1\u5355\u4EF7"),
|
|
13596
|
+
align: 'center',
|
|
13597
|
+
ellipsis: true,
|
|
13598
|
+
width: 100,
|
|
13599
|
+
render: function render(val, record, index) {
|
|
13600
|
+
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13601
|
+
style: {
|
|
13602
|
+
width: 70
|
|
13603
|
+
},
|
|
13604
|
+
value: val,
|
|
13605
|
+
min: 0,
|
|
13606
|
+
onChange: function onChange(value) {
|
|
13607
|
+
return updateHandle(value, index, 'price');
|
|
13608
|
+
}
|
|
13609
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13610
|
+
}
|
|
13611
|
+
}, {
|
|
13612
|
+
dataIndex: 'exchangePrice',
|
|
13613
|
+
title: "".concat(text, "\u6362\u51FA\u91D1\u989D"),
|
|
13614
|
+
align: 'center',
|
|
13615
|
+
ellipsis: true,
|
|
13616
|
+
width: 100
|
|
13617
|
+
}, {
|
|
13618
|
+
dataIndex: 'giftType',
|
|
13619
|
+
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
13620
|
+
align: 'center',
|
|
13621
|
+
ellipsis: true,
|
|
13622
|
+
width: 100,
|
|
13623
|
+
render: function render(val) {
|
|
13624
|
+
var giftTypeMap = {
|
|
13625
|
+
0: '非赠品',
|
|
13626
|
+
1: '自动赠送',
|
|
13627
|
+
2: '手工赠送',
|
|
13628
|
+
3: '回购自动送赠品',
|
|
13629
|
+
4: '前N有礼送赠品',
|
|
13630
|
+
6: '天猫优仓赠品',
|
|
13631
|
+
7: '淘宝CRM会员送赠'
|
|
13632
|
+
};
|
|
13633
|
+
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
13634
|
+
}
|
|
13635
|
+
}, {
|
|
13636
|
+
dataIndex: 'type',
|
|
13637
|
+
title: "".concat(text, "\u5546\u54C1\u7C7B\u578B"),
|
|
13638
|
+
align: 'center',
|
|
13639
|
+
ellipsis: true,
|
|
13640
|
+
width: 100,
|
|
13641
|
+
render: function render(val, record, index) {
|
|
13642
|
+
var options = [{
|
|
13643
|
+
label: '单品',
|
|
13644
|
+
value: '1'
|
|
13645
|
+
}, {
|
|
13646
|
+
label: '组合装',
|
|
13647
|
+
value: '2'
|
|
13648
|
+
}];
|
|
13649
|
+
return !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
13650
|
+
style: {
|
|
13651
|
+
width: 70
|
|
13652
|
+
},
|
|
13653
|
+
options: options,
|
|
13654
|
+
value: val,
|
|
13655
|
+
onChange: function onChange(value) {
|
|
13656
|
+
return updateHandle(value, index, 'type');
|
|
13657
|
+
}
|
|
13658
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13659
|
+
}
|
|
13660
|
+
}]
|
|
13661
|
+
};
|
|
13662
|
+
};
|
|
13663
|
+
|
|
13664
|
+
var getColumns$3 = function getColumns(_ref) {
|
|
13665
|
+
var _ref$text = _ref.text,
|
|
13666
|
+
text = _ref$text === void 0 ? '' : _ref$text,
|
|
13667
|
+
disabled = _ref.disabled,
|
|
13668
|
+
updateHandle = _ref.updateHandle;
|
|
13669
|
+
return {
|
|
13670
|
+
//万里牛商品信息
|
|
13671
|
+
WLN_GOODS: [{
|
|
13672
|
+
dataIndex: 'skuName',
|
|
13673
|
+
title: "".concat(text, "sku\u540D\u79F0"),
|
|
13674
|
+
align: 'center',
|
|
13675
|
+
ellipsis: true,
|
|
13676
|
+
width: 250
|
|
13677
|
+
}, {
|
|
13678
|
+
dataIndex: 'sku',
|
|
13679
|
+
title: "".concat(text, "sku\u7F16\u7801"),
|
|
13680
|
+
align: 'center',
|
|
13681
|
+
ellipsis: true,
|
|
13682
|
+
width: 100
|
|
13683
|
+
}, {
|
|
13684
|
+
dataIndex: 'name',
|
|
13685
|
+
title: "".concat(text, "\u540D\u79F0"),
|
|
13686
|
+
align: 'center',
|
|
13687
|
+
ellipsis: true,
|
|
13688
|
+
width: 250
|
|
13689
|
+
}, {
|
|
13690
|
+
dataIndex: 'pic',
|
|
13691
|
+
title: "\u56FE\u7247",
|
|
13692
|
+
align: 'center',
|
|
13693
|
+
ellipsis: true,
|
|
13694
|
+
width: 100,
|
|
13695
|
+
render: function render(val) {
|
|
13696
|
+
return /*#__PURE__*/React.createElement(Image, {
|
|
13697
|
+
width: 60,
|
|
13698
|
+
src: val
|
|
13699
|
+
});
|
|
13700
|
+
}
|
|
13701
|
+
}, {
|
|
13702
|
+
dataIndex: 'code',
|
|
13703
|
+
title: "".concat(text, "\u7F16\u7801"),
|
|
13704
|
+
align: 'center',
|
|
13705
|
+
ellipsis: true,
|
|
13706
|
+
width: 100
|
|
13707
|
+
}, {
|
|
13708
|
+
dataIndex: 'money',
|
|
13709
|
+
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
13710
|
+
align: 'center',
|
|
13711
|
+
ellipsis: true,
|
|
13712
|
+
width: 100
|
|
13713
|
+
}, {
|
|
13714
|
+
dataIndex: 'number',
|
|
13715
|
+
title: "".concat(text, "\u6570\u91CF"),
|
|
13716
|
+
align: 'center',
|
|
13717
|
+
ellipsis: true,
|
|
13718
|
+
width: 100,
|
|
13719
|
+
render: function render(val, record, index) {
|
|
13720
|
+
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13721
|
+
style: {
|
|
13722
|
+
width: 70
|
|
13723
|
+
},
|
|
13724
|
+
value: val,
|
|
13725
|
+
min: 1,
|
|
13726
|
+
precision: 0,
|
|
13727
|
+
onChange: function onChange(num) {
|
|
13728
|
+
return updateHandle(num, index, 'number');
|
|
13729
|
+
}
|
|
13730
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13731
|
+
}
|
|
13732
|
+
}, {
|
|
13733
|
+
dataIndex: 'share',
|
|
13734
|
+
title: "\u5206\u644A\u4EF7",
|
|
13735
|
+
align: 'center',
|
|
13736
|
+
ellipsis: true,
|
|
13737
|
+
width: 70
|
|
13738
|
+
}, {
|
|
13739
|
+
dataIndex: 'type',
|
|
13740
|
+
title: "\u8D60\u54C1\u7C7B\u578B",
|
|
13741
|
+
align: 'center',
|
|
13742
|
+
ellipsis: true,
|
|
13743
|
+
width: 100
|
|
13744
|
+
}]
|
|
13745
|
+
};
|
|
13746
|
+
};
|
|
13747
|
+
|
|
13748
|
+
var isNumberOrNumberString = function isNumberOrNumberString(value) {
|
|
13749
|
+
if (typeof value === 'number') return true;
|
|
13750
|
+
if (typeof value === 'string' && !isNaN(Number(value)) && value.trim() !== '') return true;
|
|
13751
|
+
return false;
|
|
13752
|
+
};
|
|
13753
|
+
var getYesOrNo = function getYesOrNo(val) {
|
|
13754
|
+
if (isNull(val)) return null;
|
|
13755
|
+
return val ? '是' : '否';
|
|
13756
|
+
};
|
|
13757
|
+
var getColumns$4 = function getColumns(_ref) {
|
|
13758
|
+
var _ref$text = _ref.text,
|
|
13759
|
+
disabled = _ref.disabled,
|
|
13760
|
+
updateHandle = _ref.updateHandle,
|
|
13761
|
+
updateDataHandle = _ref.updateDataHandle;
|
|
13762
|
+
return {
|
|
13763
|
+
//管易商品信息
|
|
13764
|
+
GY_GOODS: [{
|
|
13765
|
+
dataIndex: 'goodName',
|
|
13766
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
13767
|
+
width: 150
|
|
13768
|
+
}, {
|
|
13769
|
+
dataIndex: 'goodShortName',
|
|
13770
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
13771
|
+
width: 150
|
|
13772
|
+
}, {
|
|
13773
|
+
dataIndex: 'goodNo',
|
|
13774
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13775
|
+
width: 200
|
|
13776
|
+
}, {
|
|
13777
|
+
dataIndex: 'specName',
|
|
13778
|
+
title: "SKU\u540D\u79F0",
|
|
13779
|
+
align: 'center',
|
|
13780
|
+
ellipsis: true,
|
|
13781
|
+
width: 250
|
|
13782
|
+
}, {
|
|
13783
|
+
dataIndex: 'specNo',
|
|
13784
|
+
title: "SKU\u7F16\u7801",
|
|
13785
|
+
align: 'center',
|
|
13786
|
+
ellipsis: true,
|
|
13787
|
+
width: 150
|
|
13788
|
+
}, {
|
|
13789
|
+
dataIndex: 'qty',
|
|
13790
|
+
title: "\u6570\u91CF",
|
|
13791
|
+
width: 100,
|
|
13792
|
+
render: function render(val, record, index) {
|
|
13793
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13794
|
+
style: {
|
|
13795
|
+
width: 70
|
|
13796
|
+
},
|
|
13797
|
+
value: val,
|
|
13798
|
+
min: 1,
|
|
13799
|
+
precision: 0,
|
|
13800
|
+
onChange: function onChange(num) {
|
|
13801
|
+
updateDataHandle({
|
|
13802
|
+
qty: num,
|
|
13803
|
+
amount: num && isNumberOrNumberString(record.price) ? num * record.price : null,
|
|
13804
|
+
originAmount: num && isNumberOrNumberString(record.originPrice) ? num * record.originPrice : null
|
|
13805
|
+
}, index);
|
|
13806
|
+
}
|
|
13807
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13808
|
+
}
|
|
13809
|
+
}, {
|
|
13810
|
+
dataIndex: 'price',
|
|
13811
|
+
title: "\u5B9E\u9645\u5355\u4EF7",
|
|
13812
|
+
width: 150,
|
|
13813
|
+
render: function render(val, record, index) {
|
|
13814
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13815
|
+
style: {
|
|
13816
|
+
width: 130
|
|
13817
|
+
},
|
|
13818
|
+
value: val,
|
|
13819
|
+
min: 0,
|
|
13820
|
+
precision: 2,
|
|
13821
|
+
onChange: function onChange(num) {
|
|
13822
|
+
updateDataHandle({
|
|
13823
|
+
price: num,
|
|
13824
|
+
amount: num && isNumberOrNumberString(record.qty) ? num * record.qty : null
|
|
13825
|
+
}, index);
|
|
13826
|
+
}
|
|
13827
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13828
|
+
}
|
|
13829
|
+
}, {
|
|
13830
|
+
dataIndex: 'amount',
|
|
13831
|
+
title: "\u5B9E\u9645\u91D1\u989D",
|
|
13832
|
+
width: 150
|
|
13833
|
+
}, {
|
|
13834
|
+
dataIndex: 'originPrice',
|
|
13835
|
+
title: "\u6807\u51C6\u5355\u4EF7",
|
|
13836
|
+
width: 150
|
|
13837
|
+
}, {
|
|
13838
|
+
dataIndex: 'originAmount',
|
|
13839
|
+
title: "\u6807\u51C6\u91D1\u989D",
|
|
13840
|
+
width: 150
|
|
13841
|
+
}, {
|
|
13842
|
+
dataIndex: 'discountFee',
|
|
13843
|
+
title: "\u8BA9\u5229\u91D1\u989D",
|
|
13844
|
+
width: 150
|
|
13845
|
+
}, {
|
|
13846
|
+
dataIndex: 'amountAfter',
|
|
13847
|
+
title: "\u8BA9\u5229\u540E\u91D1\u989D",
|
|
13848
|
+
width: 150
|
|
13849
|
+
}, {
|
|
13850
|
+
dataIndex: 'cancel',
|
|
13851
|
+
title: "\u662F\u5426\u53D6\u6D88",
|
|
13852
|
+
width: 150,
|
|
13853
|
+
render: function render(val) {
|
|
13854
|
+
return /*#__PURE__*/React.createElement("span", null, getYesOrNo(val));
|
|
13855
|
+
}
|
|
13856
|
+
}, {
|
|
13857
|
+
dataIndex: 'isGift',
|
|
13858
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
13859
|
+
width: 150,
|
|
13860
|
+
render: function render(val, record, index) {
|
|
13861
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
13862
|
+
value: val,
|
|
13863
|
+
onChange: function onChange(value) {
|
|
13864
|
+
updateHandle(value, index, 'isGift');
|
|
13865
|
+
},
|
|
13866
|
+
options: [{
|
|
13867
|
+
label: '是',
|
|
13868
|
+
value: 1
|
|
13869
|
+
}, {
|
|
13870
|
+
label: '否',
|
|
13871
|
+
value: 0
|
|
13872
|
+
}]
|
|
13873
|
+
}) : /*#__PURE__*/React.createElement("span", null, getYesOrNo(val));
|
|
13874
|
+
}
|
|
13875
|
+
}, {
|
|
13876
|
+
dataIndex: 'skuNote',
|
|
13877
|
+
title: "\u5546\u54C1\u5907\u6CE8",
|
|
13878
|
+
width: 150
|
|
13879
|
+
}].map(function (item) {
|
|
13880
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
13881
|
+
align: 'center',
|
|
13882
|
+
ellipsis: true
|
|
13883
|
+
});
|
|
13884
|
+
}),
|
|
13885
|
+
//管易补发商品信息
|
|
13886
|
+
GY_REISSUE_GOODS: [{
|
|
13887
|
+
dataIndex: 'goodName',
|
|
13888
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
13889
|
+
width: 150
|
|
13890
|
+
}, {
|
|
13891
|
+
dataIndex: 'goodShortName',
|
|
13892
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
13893
|
+
width: 150
|
|
13894
|
+
}, {
|
|
13895
|
+
dataIndex: 'goodNo',
|
|
13896
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
13897
|
+
width: 200
|
|
13898
|
+
}, {
|
|
13899
|
+
dataIndex: 'specName',
|
|
13900
|
+
title: "SKU\u540D\u79F0",
|
|
13901
|
+
align: 'center',
|
|
13902
|
+
ellipsis: true,
|
|
13903
|
+
width: 250
|
|
13904
|
+
}, {
|
|
13905
|
+
dataIndex: 'specNo',
|
|
13906
|
+
title: "SKU\u7F16\u7801",
|
|
13907
|
+
align: 'center',
|
|
13908
|
+
ellipsis: true,
|
|
13909
|
+
width: 150
|
|
13910
|
+
}, {
|
|
13911
|
+
dataIndex: 'qty',
|
|
13912
|
+
title: "\u6570\u91CF",
|
|
13913
|
+
width: 100,
|
|
13914
|
+
render: function render(val, record, index) {
|
|
13915
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13916
|
+
style: {
|
|
13917
|
+
width: 70
|
|
13918
|
+
},
|
|
13919
|
+
value: val,
|
|
13920
|
+
min: 1,
|
|
13921
|
+
precision: 0,
|
|
13922
|
+
onChange: function onChange(num) {
|
|
13923
|
+
updateDataHandle({
|
|
13924
|
+
qty: num,
|
|
13925
|
+
amount: num && isNumberOrNumberString(record.price) ? num * record.price : null,
|
|
13926
|
+
originAmount: num && isNumberOrNumberString(record.originPrice) ? num * record.originPrice : null
|
|
13927
|
+
}, index);
|
|
13928
|
+
}
|
|
13929
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13930
|
+
}
|
|
13931
|
+
}, {
|
|
13932
|
+
dataIndex: 'price',
|
|
13933
|
+
title: "\u5B9E\u9645\u5355\u4EF7",
|
|
13934
|
+
width: 150,
|
|
13935
|
+
render: function render(val, record, index) {
|
|
13936
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13937
|
+
style: {
|
|
13938
|
+
width: 130
|
|
13939
|
+
},
|
|
13940
|
+
value: val,
|
|
13941
|
+
min: 0,
|
|
13942
|
+
precision: 2,
|
|
13943
|
+
onChange: function onChange(num) {
|
|
13944
|
+
updateDataHandle({
|
|
13945
|
+
price: num,
|
|
13946
|
+
amount: num && isNumberOrNumberString(record.qty) ? num * record.qty : null
|
|
13947
|
+
}, index);
|
|
13948
|
+
}
|
|
13949
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13950
|
+
}
|
|
13951
|
+
}, {
|
|
13952
|
+
dataIndex: 'amount',
|
|
13953
|
+
title: "\u5B9E\u9645\u91D1\u989D",
|
|
13954
|
+
width: 150
|
|
13955
|
+
}, {
|
|
13956
|
+
dataIndex: 'originPrice',
|
|
13957
|
+
title: "\u6807\u51C6\u5355\u4EF7",
|
|
13958
|
+
width: 150
|
|
13959
|
+
}, {
|
|
13960
|
+
dataIndex: 'originAmount',
|
|
13961
|
+
title: "\u6807\u51C6\u91D1\u989D",
|
|
13962
|
+
width: 150
|
|
13963
|
+
}, {
|
|
13964
|
+
dataIndex: 'isGift',
|
|
13965
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
13966
|
+
width: 150,
|
|
13967
|
+
render: function render(val, record, index) {
|
|
13968
|
+
return record.canEdit && !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
13969
|
+
value: val,
|
|
13970
|
+
onChange: function onChange(value) {
|
|
13971
|
+
updateHandle(value, index, 'isGift');
|
|
13972
|
+
},
|
|
13973
|
+
options: [{
|
|
13974
|
+
label: '是',
|
|
13975
|
+
value: 1
|
|
13976
|
+
}, {
|
|
13977
|
+
label: '否',
|
|
13978
|
+
value: 0
|
|
13979
|
+
}]
|
|
13980
|
+
}) : /*#__PURE__*/React.createElement("span", null, getYesOrNo(val));
|
|
13981
|
+
}
|
|
13982
|
+
}].map(function (item) {
|
|
13983
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
13984
|
+
align: 'center',
|
|
13985
|
+
ellipsis: true
|
|
13986
|
+
});
|
|
13987
|
+
})
|
|
13988
|
+
};
|
|
13989
|
+
};
|
|
13990
|
+
|
|
13991
|
+
var getColumns$5 = function getColumns(_ref) {
|
|
13992
|
+
var _ref$text = _ref.text,
|
|
13993
|
+
text = _ref$text === void 0 ? '' : _ref$text,
|
|
13994
|
+
disabled = _ref.disabled,
|
|
13995
|
+
updateHandle = _ref.updateHandle;
|
|
13996
|
+
return {
|
|
13997
|
+
//bs商品信息
|
|
13998
|
+
default: [{
|
|
13999
|
+
dataIndex: 'mark',
|
|
14000
|
+
title: "\u5546\u54C1\u6807\u8BB0",
|
|
14001
|
+
align: 'center',
|
|
14002
|
+
ellipsis: true,
|
|
14003
|
+
width: 70,
|
|
14004
|
+
render: function render(val, record, index) {
|
|
14005
|
+
return /*#__PURE__*/React.createElement(Select, {
|
|
14006
|
+
options: [{
|
|
14007
|
+
label: '是',
|
|
14008
|
+
value: '是'
|
|
14009
|
+
}, {
|
|
14010
|
+
label: '否',
|
|
14011
|
+
value: '否'
|
|
14012
|
+
}],
|
|
14013
|
+
disabled: disabled,
|
|
14014
|
+
value: val,
|
|
14015
|
+
onChange: function onChange(val) {
|
|
14016
|
+
return updateHandle(val, index, 'mark');
|
|
14017
|
+
}
|
|
14018
|
+
});
|
|
14019
|
+
}
|
|
14020
|
+
}, {
|
|
14021
|
+
dataIndex: 'skuName',
|
|
14022
|
+
title: "".concat(text, "sku\u540D\u79F0"),
|
|
14023
|
+
align: 'center',
|
|
14024
|
+
ellipsis: true,
|
|
14025
|
+
width: 250
|
|
14026
|
+
}, {
|
|
14027
|
+
dataIndex: 'sku',
|
|
14028
|
+
title: "".concat(text, "sku\u7F16\u7801"),
|
|
14029
|
+
align: 'center',
|
|
14030
|
+
ellipsis: true,
|
|
14031
|
+
width: 100
|
|
14032
|
+
}, {
|
|
14033
|
+
dataIndex: 'name',
|
|
14034
|
+
title: "".concat(text, "\u540D\u79F0"),
|
|
14035
|
+
align: 'center',
|
|
14036
|
+
ellipsis: true,
|
|
14037
|
+
width: 250
|
|
14038
|
+
}, {
|
|
14039
|
+
dataIndex: 'pic',
|
|
14040
|
+
title: "\u56FE\u7247",
|
|
12564
14041
|
align: 'center',
|
|
12565
|
-
ellipsis: true
|
|
12566
|
-
|
|
12567
|
-
|
|
12568
|
-
|
|
12569
|
-
|
|
12570
|
-
|
|
12571
|
-
|
|
12572
|
-
|
|
12573
|
-
|
|
12574
|
-
|
|
12575
|
-
|
|
14042
|
+
ellipsis: true,
|
|
14043
|
+
width: 100,
|
|
14044
|
+
render: function render(val) {
|
|
14045
|
+
return /*#__PURE__*/React.createElement(Image, {
|
|
14046
|
+
width: 60,
|
|
14047
|
+
src: val
|
|
14048
|
+
});
|
|
14049
|
+
}
|
|
14050
|
+
}, {
|
|
14051
|
+
dataIndex: 'code',
|
|
14052
|
+
title: "".concat(text, "\u7F16\u7801"),
|
|
14053
|
+
align: 'center',
|
|
14054
|
+
ellipsis: true,
|
|
14055
|
+
width: 100
|
|
14056
|
+
}, {
|
|
14057
|
+
dataIndex: 'money',
|
|
14058
|
+
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
14059
|
+
align: 'center',
|
|
14060
|
+
ellipsis: true,
|
|
14061
|
+
width: 100
|
|
14062
|
+
}, {
|
|
14063
|
+
dataIndex: 'number',
|
|
14064
|
+
title: "".concat(text, "\u6570\u91CF"),
|
|
14065
|
+
align: 'center',
|
|
14066
|
+
ellipsis: true,
|
|
14067
|
+
width: 100,
|
|
14068
|
+
render: function render(val, record, index) {
|
|
14069
|
+
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
14070
|
+
style: {
|
|
14071
|
+
width: 70
|
|
14072
|
+
},
|
|
14073
|
+
value: val,
|
|
14074
|
+
min: 1,
|
|
14075
|
+
precision: 0,
|
|
14076
|
+
onChange: function onChange(num) {
|
|
14077
|
+
return updateHandle(num, index, 'number');
|
|
14078
|
+
}
|
|
14079
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
14080
|
+
}
|
|
14081
|
+
}, {
|
|
14082
|
+
dataIndex: 'share',
|
|
14083
|
+
title: "\u5206\u644A\u4EF7",
|
|
14084
|
+
align: 'center',
|
|
14085
|
+
ellipsis: true,
|
|
14086
|
+
width: 70
|
|
14087
|
+
}, {
|
|
14088
|
+
dataIndex: 'type',
|
|
14089
|
+
title: "\u8D60\u54C1\u7C7B\u578B",
|
|
14090
|
+
align: 'center',
|
|
14091
|
+
ellipsis: true,
|
|
14092
|
+
width: 100
|
|
14093
|
+
}]
|
|
14094
|
+
};
|
|
14095
|
+
};
|
|
14096
|
+
|
|
14097
|
+
var getColumnsMap = function getColumnsMap(args) {
|
|
14098
|
+
var _ref = args || {},
|
|
14099
|
+
_ref$text = _ref.text,
|
|
14100
|
+
text = _ref$text === void 0 ? '' : _ref$text,
|
|
14101
|
+
disabled = _ref.disabled,
|
|
14102
|
+
updateHandle = _ref.updateHandle,
|
|
14103
|
+
updateDataHandle = _ref.updateDataHandle;
|
|
14104
|
+
return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({}, getColumns$1({
|
|
14105
|
+
text: text,
|
|
14106
|
+
disabled: disabled,
|
|
14107
|
+
updateHandle: updateHandle
|
|
14108
|
+
})), getColumns({
|
|
14109
|
+
text: text,
|
|
14110
|
+
disabled: disabled,
|
|
14111
|
+
updateHandle: updateHandle
|
|
14112
|
+
})), getColumns$2({
|
|
14113
|
+
text: text,
|
|
14114
|
+
disabled: disabled,
|
|
14115
|
+
updateHandle: updateHandle
|
|
14116
|
+
})), getColumns$3({
|
|
14117
|
+
text: text,
|
|
14118
|
+
disabled: disabled,
|
|
14119
|
+
updateHandle: updateHandle
|
|
14120
|
+
})), getColumns$4({
|
|
14121
|
+
text: text,
|
|
14122
|
+
disabled: disabled,
|
|
14123
|
+
updateHandle: updateHandle,
|
|
14124
|
+
updateDataHandle: updateDataHandle
|
|
14125
|
+
})), {}, {
|
|
14126
|
+
default: getColumns$5({
|
|
14127
|
+
text: text,
|
|
14128
|
+
disabled: disabled,
|
|
14129
|
+
updateHandle: updateHandle
|
|
14130
|
+
})['default']
|
|
14131
|
+
});
|
|
14132
|
+
};
|
|
14133
|
+
var getColumnsBaseInfo = function getColumnsBaseInfo() {
|
|
14134
|
+
var clone_columnsMap = cloneDeep(getColumnsMap());
|
|
14135
|
+
var newColumns = {};
|
|
14136
|
+
Object.keys(clone_columnsMap).forEach(function (key) {
|
|
14137
|
+
newColumns[key] = clone_columnsMap[key].map(function (col) {
|
|
14138
|
+
return {
|
|
14139
|
+
title: col.title,
|
|
14140
|
+
dataIndex: col.dataIndex
|
|
14141
|
+
};
|
|
14142
|
+
});
|
|
12576
14143
|
});
|
|
14144
|
+
return newColumns;
|
|
12577
14145
|
};
|
|
14146
|
+
var columnsBaseInfoMap = getColumnsBaseInfo();
|
|
12578
14147
|
|
|
12579
|
-
var columns$4 = [{
|
|
12580
|
-
dataIndex: 'goodId',
|
|
12581
|
-
title: "\u5546\u54C1ID",
|
|
12582
|
-
width: 70
|
|
12583
|
-
}, {
|
|
12584
|
-
dataIndex: 'goodNo',
|
|
12585
|
-
title: "\u5546\u54C1\u7F16\u7801",
|
|
12586
|
-
width: 180
|
|
12587
|
-
}, {
|
|
12588
|
-
dataIndex: 'goodName',
|
|
12589
|
-
title: "\u5546\u54C1\u540D\u79F0",
|
|
12590
|
-
width: 250
|
|
12591
|
-
}, {
|
|
12592
|
-
dataIndex: 'specId',
|
|
12593
|
-
title: "SKUID",
|
|
12594
|
-
width: 100
|
|
12595
|
-
}, {
|
|
12596
|
-
dataIndex: 'specNo',
|
|
12597
|
-
title: "\u5546\u54C1SKU\u7F16\u7801",
|
|
12598
|
-
width: 180
|
|
12599
|
-
}, {
|
|
12600
|
-
dataIndex: 'specName',
|
|
12601
|
-
title: "\u5546\u54C1SKU\u540D\u79F0",
|
|
12602
|
-
width: 250
|
|
12603
|
-
}, {
|
|
12604
|
-
dataIndex: 'orderPrice',
|
|
12605
|
-
title: "\u5B9E\u4ED8\u603B\u91D1\u989D",
|
|
12606
|
-
width: 100
|
|
12607
|
-
}, {
|
|
12608
|
-
dataIndex: 'num',
|
|
12609
|
-
title: "\u6570\u91CF",
|
|
12610
|
-
width: 100
|
|
12611
|
-
}, {
|
|
12612
|
-
dataIndex: 'sharePrice',
|
|
12613
|
-
title: "\u5206\u644A\u4EF7",
|
|
12614
|
-
width: 70
|
|
12615
|
-
}, {
|
|
12616
|
-
dataIndex: 'giftType',
|
|
12617
|
-
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
12618
|
-
width: 100
|
|
12619
|
-
}];
|
|
12620
14148
|
var renderFieldMap$1 = {
|
|
12621
|
-
|
|
14149
|
+
goodsNumber: function goodsNumber(_ref) {
|
|
12622
14150
|
var disabled = _ref.disabled,
|
|
12623
14151
|
updateHandle = _ref.updateHandle;
|
|
12624
14152
|
return function (val, record, index) {
|
|
@@ -12630,33 +14158,59 @@ var renderFieldMap$1 = {
|
|
|
12630
14158
|
min: 1,
|
|
12631
14159
|
precision: 0,
|
|
12632
14160
|
onChange: function onChange(num) {
|
|
12633
|
-
return updateHandle(num, index, '
|
|
14161
|
+
return updateHandle(num, index, 'goodsNumber');
|
|
12634
14162
|
}
|
|
12635
14163
|
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12636
14164
|
};
|
|
12637
14165
|
},
|
|
12638
|
-
|
|
14166
|
+
goodsPrice: function goodsPrice(_ref2) {
|
|
12639
14167
|
var disabled = _ref2.disabled,
|
|
12640
14168
|
updateHandle = _ref2.updateHandle;
|
|
12641
|
-
return function (val) {
|
|
12642
|
-
|
|
12643
|
-
|
|
12644
|
-
|
|
12645
|
-
|
|
12646
|
-
|
|
12647
|
-
|
|
12648
|
-
|
|
12649
|
-
|
|
12650
|
-
|
|
12651
|
-
|
|
14169
|
+
return function (val, record, index) {
|
|
14170
|
+
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
14171
|
+
style: {
|
|
14172
|
+
width: 70
|
|
14173
|
+
},
|
|
14174
|
+
value: val,
|
|
14175
|
+
min: 0,
|
|
14176
|
+
onChange: function onChange(value) {
|
|
14177
|
+
return updateHandle(value, index, 'goodsPrice');
|
|
14178
|
+
}
|
|
14179
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
14180
|
+
};
|
|
14181
|
+
},
|
|
14182
|
+
isGift: function isGift(_ref3) {
|
|
14183
|
+
var disabled = _ref3.disabled,
|
|
14184
|
+
updateHandle = _ref3.updateHandle;
|
|
14185
|
+
return function (val, record, index) {
|
|
14186
|
+
var options = [{
|
|
14187
|
+
label: '是',
|
|
14188
|
+
value: 1
|
|
14189
|
+
}, {
|
|
14190
|
+
label: '否',
|
|
14191
|
+
value: 0
|
|
14192
|
+
}];
|
|
14193
|
+
return !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
14194
|
+
style: {
|
|
14195
|
+
width: 70
|
|
14196
|
+
},
|
|
14197
|
+
options: options,
|
|
14198
|
+
value: val,
|
|
14199
|
+
onChange: function onChange(value) {
|
|
14200
|
+
return updateHandle(value, index, 'isGift');
|
|
14201
|
+
},
|
|
14202
|
+
getPopupContainer: function getPopupContainer() {
|
|
14203
|
+
return document.getElementById('bsE3ReissueGoods');
|
|
14204
|
+
}
|
|
14205
|
+
}) : /*#__PURE__*/React.createElement("span", null, +val ? '是' : '否');
|
|
12652
14206
|
};
|
|
12653
14207
|
}
|
|
12654
14208
|
};
|
|
12655
|
-
var
|
|
12656
|
-
var disabled =
|
|
12657
|
-
updateHandle =
|
|
12658
|
-
operate =
|
|
12659
|
-
return
|
|
14209
|
+
var getBsE3ReissueGoodColumns = function getBsE3ReissueGoodColumns(_ref4) {
|
|
14210
|
+
var disabled = _ref4.disabled,
|
|
14211
|
+
updateHandle = _ref4.updateHandle,
|
|
14212
|
+
operate = _ref4.operate;
|
|
14213
|
+
return getColumnsMap()['BS_E3_REISSUE_GOODS'].map(function (item) {
|
|
12660
14214
|
var newItem = _objectSpread2({
|
|
12661
14215
|
align: 'center',
|
|
12662
14216
|
ellipsis: true
|
|
@@ -12673,7 +14227,7 @@ var getWdtReissueGoodColumns = function getWdtReissueGoodColumns(_ref3) {
|
|
|
12673
14227
|
});
|
|
12674
14228
|
};
|
|
12675
14229
|
|
|
12676
|
-
var MAIN_FIELD = '
|
|
14230
|
+
var MAIN_FIELD = 'uuid';
|
|
12677
14231
|
var SelectTradeGoods = function SelectTradeGoods(_ref) {
|
|
12678
14232
|
var columns = _ref.columns,
|
|
12679
14233
|
dataSource = _ref.dataSource,
|
|
@@ -12731,6 +14285,9 @@ var getButtonText = function getButtonText() {
|
|
|
12731
14285
|
if (['WDT_REISSUE_GOODS'].includes(type)) {
|
|
12732
14286
|
return '选择旺店通商品';
|
|
12733
14287
|
}
|
|
14288
|
+
if (['GY_GOODS', 'GY_REISSUE_GOODS'].includes(type)) {
|
|
14289
|
+
return '选择管易ERP商品';
|
|
14290
|
+
}
|
|
12734
14291
|
return '选择商品';
|
|
12735
14292
|
};
|
|
12736
14293
|
var GoodItem$1 = function GoodItem(props) {
|
|
@@ -12822,515 +14379,42 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
12822
14379
|
onChange === null || onChange === void 0 ? void 0 : onChange(_toConsumableArray(value));
|
|
12823
14380
|
}
|
|
12824
14381
|
};
|
|
14382
|
+
var updateDataHandle = function updateDataHandle(data, index) {
|
|
14383
|
+
if (value === null || value === void 0 ? void 0 : value.length) {
|
|
14384
|
+
value[index] = _objectSpread2(_objectSpread2({}, value[index]), data);
|
|
14385
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_toConsumableArray(value));
|
|
14386
|
+
}
|
|
14387
|
+
};
|
|
12825
14388
|
var COLUMNS_MAP = function COLUMNS_MAP() {
|
|
12826
14389
|
var text = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
|
|
12827
14390
|
var operate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
12828
14391
|
return function (type) {
|
|
12829
14392
|
var columns = [];
|
|
12830
14393
|
switch (type) {
|
|
12831
|
-
case 'WDT_REISSUE_GOODS':
|
|
12832
|
-
{
|
|
12833
|
-
columns = getWdtReissueGoodColumns({
|
|
12834
|
-
disabled: disabled,
|
|
12835
|
-
updateHandle: updateHandle,
|
|
12836
|
-
operate: operate
|
|
12837
|
-
});
|
|
12838
|
-
}
|
|
12839
|
-
break;
|
|
12840
14394
|
case 'WDT_GOODS':
|
|
12841
|
-
columns = [{
|
|
12842
|
-
dataIndex: 'goodId',
|
|
12843
|
-
title: "\u5546\u54C1ID",
|
|
12844
|
-
align: 'center',
|
|
12845
|
-
ellipsis: true,
|
|
12846
|
-
width: 70
|
|
12847
|
-
}, {
|
|
12848
|
-
dataIndex: 'goodNo',
|
|
12849
|
-
title: "\u5546\u54C1\u7F16\u7801",
|
|
12850
|
-
align: 'center',
|
|
12851
|
-
ellipsis: true,
|
|
12852
|
-
width: 180
|
|
12853
|
-
}, {
|
|
12854
|
-
dataIndex: 'goodName',
|
|
12855
|
-
title: "".concat(text, "\u5546\u54C1\u540D\u79F0"),
|
|
12856
|
-
align: 'center',
|
|
12857
|
-
ellipsis: true,
|
|
12858
|
-
width: 250
|
|
12859
|
-
}, {
|
|
12860
|
-
dataIndex: 'specId',
|
|
12861
|
-
title: "".concat(text, "SKUID"),
|
|
12862
|
-
align: 'center',
|
|
12863
|
-
ellipsis: true,
|
|
12864
|
-
width: 100
|
|
12865
|
-
}, {
|
|
12866
|
-
dataIndex: 'specNo',
|
|
12867
|
-
title: "".concat(text, "\u5546\u54C1SKU\u7F16\u7801"),
|
|
12868
|
-
align: 'center',
|
|
12869
|
-
ellipsis: true,
|
|
12870
|
-
width: 180
|
|
12871
|
-
}, {
|
|
12872
|
-
dataIndex: 'specName',
|
|
12873
|
-
title: "".concat(text, "\u5546\u54C1SKU\u540D\u79F0"),
|
|
12874
|
-
align: 'center',
|
|
12875
|
-
ellipsis: true,
|
|
12876
|
-
width: 250
|
|
12877
|
-
}, {
|
|
12878
|
-
dataIndex: 'orderPrice',
|
|
12879
|
-
title: "\u5B9E\u4ED8\u603B\u91D1\u989D",
|
|
12880
|
-
align: 'center',
|
|
12881
|
-
ellipsis: true,
|
|
12882
|
-
width: 100
|
|
12883
|
-
}, {
|
|
12884
|
-
dataIndex: 'num',
|
|
12885
|
-
title: "".concat(text, "\u6570\u91CF"),
|
|
12886
|
-
align: 'center',
|
|
12887
|
-
ellipsis: true,
|
|
12888
|
-
width: 100,
|
|
12889
|
-
render: function render(val, record, index) {
|
|
12890
|
-
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
12891
|
-
style: {
|
|
12892
|
-
width: 70
|
|
12893
|
-
},
|
|
12894
|
-
value: val,
|
|
12895
|
-
min: 1,
|
|
12896
|
-
precision: 0,
|
|
12897
|
-
onChange: function onChange(num) {
|
|
12898
|
-
return updateHandle(num, index, 'num');
|
|
12899
|
-
}
|
|
12900
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12901
|
-
}
|
|
12902
|
-
},
|
|
12903
|
-
// {
|
|
12904
|
-
// dataIndex: 'actualNum',
|
|
12905
|
-
// title: `${text}实发数量`,
|
|
12906
|
-
// align: 'center',
|
|
12907
|
-
// ellipsis: true,
|
|
12908
|
-
// width: 100,
|
|
12909
|
-
// },
|
|
12910
|
-
{
|
|
12911
|
-
dataIndex: 'sharePrice',
|
|
12912
|
-
title: "\u5206\u644A\u4EF7",
|
|
12913
|
-
align: 'center',
|
|
12914
|
-
ellipsis: true,
|
|
12915
|
-
width: 70
|
|
12916
|
-
}, {
|
|
12917
|
-
dataIndex: 'giftType',
|
|
12918
|
-
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
12919
|
-
align: 'center',
|
|
12920
|
-
ellipsis: true,
|
|
12921
|
-
width: 100,
|
|
12922
|
-
render: function render(val) {
|
|
12923
|
-
var giftTypeMap = {
|
|
12924
|
-
0: '非赠品',
|
|
12925
|
-
1: '自动赠送',
|
|
12926
|
-
2: '手工赠送',
|
|
12927
|
-
3: '回购自动送赠品',
|
|
12928
|
-
4: '前N有礼送赠品',
|
|
12929
|
-
6: '天猫优仓赠品',
|
|
12930
|
-
7: '淘宝CRM会员送赠'
|
|
12931
|
-
};
|
|
12932
|
-
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
12933
|
-
}
|
|
12934
|
-
}];
|
|
12935
|
-
break;
|
|
12936
14395
|
case 'WDT_RETURN_GOODS':
|
|
12937
|
-
{
|
|
12938
|
-
columns = [{
|
|
12939
|
-
dataIndex: 'goodId',
|
|
12940
|
-
title: "\u5546\u54C1ID",
|
|
12941
|
-
align: 'center',
|
|
12942
|
-
ellipsis: true,
|
|
12943
|
-
width: 70
|
|
12944
|
-
}, {
|
|
12945
|
-
dataIndex: 'goodNo',
|
|
12946
|
-
title: "\u5546\u54C1\u7F16\u7801",
|
|
12947
|
-
align: 'center',
|
|
12948
|
-
ellipsis: true,
|
|
12949
|
-
width: 180
|
|
12950
|
-
}, {
|
|
12951
|
-
dataIndex: 'goodName',
|
|
12952
|
-
title: "".concat(text, "\u5546\u54C1\u540D\u79F0"),
|
|
12953
|
-
align: 'center',
|
|
12954
|
-
ellipsis: true,
|
|
12955
|
-
width: 250
|
|
12956
|
-
}, {
|
|
12957
|
-
dataIndex: 'specId',
|
|
12958
|
-
title: "".concat(text, "SKUID"),
|
|
12959
|
-
align: 'center',
|
|
12960
|
-
ellipsis: true,
|
|
12961
|
-
width: 100
|
|
12962
|
-
}, {
|
|
12963
|
-
dataIndex: 'specNo',
|
|
12964
|
-
title: "".concat(text, "\u5546\u54C1SKU\u7F16\u7801"),
|
|
12965
|
-
align: 'center',
|
|
12966
|
-
ellipsis: true,
|
|
12967
|
-
width: 180
|
|
12968
|
-
}, {
|
|
12969
|
-
dataIndex: 'specName',
|
|
12970
|
-
title: "".concat(text, "\u5546\u54C1SKU\u540D\u79F0"),
|
|
12971
|
-
align: 'center',
|
|
12972
|
-
ellipsis: true,
|
|
12973
|
-
width: 250
|
|
12974
|
-
}, {
|
|
12975
|
-
dataIndex: 'num',
|
|
12976
|
-
title: "".concat(text, "\u9000\u8D27\u6570\u91CF"),
|
|
12977
|
-
align: 'center',
|
|
12978
|
-
ellipsis: true,
|
|
12979
|
-
width: 100,
|
|
12980
|
-
render: function render(val, record, index) {
|
|
12981
|
-
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
12982
|
-
style: {
|
|
12983
|
-
width: 70
|
|
12984
|
-
},
|
|
12985
|
-
value: val,
|
|
12986
|
-
min: 1,
|
|
12987
|
-
precision: 0,
|
|
12988
|
-
onChange: function onChange(num) {
|
|
12989
|
-
return updateHandle(num, index, 'num');
|
|
12990
|
-
}
|
|
12991
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12992
|
-
}
|
|
12993
|
-
}, {
|
|
12994
|
-
dataIndex: 'sharePrice',
|
|
12995
|
-
title: "\u5206\u644A\u4EF7",
|
|
12996
|
-
align: 'center',
|
|
12997
|
-
ellipsis: true,
|
|
12998
|
-
width: 80,
|
|
12999
|
-
render: function render(val, record, index) {
|
|
13000
|
-
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13001
|
-
style: {
|
|
13002
|
-
width: 70
|
|
13003
|
-
},
|
|
13004
|
-
value: val,
|
|
13005
|
-
min: 0,
|
|
13006
|
-
onChange: function onChange(value) {
|
|
13007
|
-
return updateHandle(value, index, 'sharePrice');
|
|
13008
|
-
}
|
|
13009
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13010
|
-
}
|
|
13011
|
-
}, {
|
|
13012
|
-
dataIndex: 'returnPrice',
|
|
13013
|
-
title: "".concat(text, "\u9000\u8D27\u91D1\u989D"),
|
|
13014
|
-
align: 'center',
|
|
13015
|
-
ellipsis: true,
|
|
13016
|
-
width: 100
|
|
13017
|
-
}, {
|
|
13018
|
-
dataIndex: 'giftType',
|
|
13019
|
-
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
13020
|
-
align: 'center',
|
|
13021
|
-
ellipsis: true,
|
|
13022
|
-
width: 100,
|
|
13023
|
-
render: function render(val) {
|
|
13024
|
-
var giftTypeMap = {
|
|
13025
|
-
0: '非赠品',
|
|
13026
|
-
1: '自动赠送',
|
|
13027
|
-
2: '手工赠送',
|
|
13028
|
-
3: '回购自动送赠品',
|
|
13029
|
-
4: '前N有礼送赠品',
|
|
13030
|
-
6: '天猫优仓赠品',
|
|
13031
|
-
7: '淘宝CRM会员送赠'
|
|
13032
|
-
};
|
|
13033
|
-
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
13034
|
-
}
|
|
13035
|
-
}, {
|
|
13036
|
-
dataIndex: 'type',
|
|
13037
|
-
title: "".concat(text, "\u5546\u54C1\u7C7B\u578B"),
|
|
13038
|
-
align: 'center',
|
|
13039
|
-
ellipsis: true,
|
|
13040
|
-
width: 100,
|
|
13041
|
-
render: function render(val, record, index) {
|
|
13042
|
-
var options = [{
|
|
13043
|
-
label: '单品',
|
|
13044
|
-
value: '1'
|
|
13045
|
-
}, {
|
|
13046
|
-
label: '组合装',
|
|
13047
|
-
value: '2'
|
|
13048
|
-
}];
|
|
13049
|
-
return !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
13050
|
-
style: {
|
|
13051
|
-
width: 70
|
|
13052
|
-
},
|
|
13053
|
-
options: options,
|
|
13054
|
-
value: val,
|
|
13055
|
-
onChange: function onChange(value) {
|
|
13056
|
-
return updateHandle(value, index, 'type');
|
|
13057
|
-
}
|
|
13058
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13059
|
-
}
|
|
13060
|
-
}];
|
|
13061
|
-
}
|
|
13062
|
-
break;
|
|
13063
14396
|
case 'WDT_EXCHANGE_GOODS':
|
|
14397
|
+
case 'BS_E3_GOODS':
|
|
14398
|
+
case 'BS_GOODS':
|
|
14399
|
+
case 'WLN_GOODS':
|
|
14400
|
+
case 'GY_GOODS':
|
|
14401
|
+
case 'GY_REISSUE_GOODS':
|
|
13064
14402
|
{
|
|
13065
|
-
columns =
|
|
13066
|
-
|
|
13067
|
-
|
|
13068
|
-
|
|
13069
|
-
|
|
13070
|
-
|
|
13071
|
-
}, {
|
|
13072
|
-
dataIndex: 'goodNo',
|
|
13073
|
-
title: "\u5546\u54C1\u7F16\u7801",
|
|
13074
|
-
align: 'center',
|
|
13075
|
-
ellipsis: true,
|
|
13076
|
-
width: 180
|
|
13077
|
-
}, {
|
|
13078
|
-
dataIndex: 'goodName',
|
|
13079
|
-
title: "".concat(text, "\u5546\u54C1\u540D\u79F0"),
|
|
13080
|
-
align: 'center',
|
|
13081
|
-
ellipsis: true,
|
|
13082
|
-
width: 250
|
|
13083
|
-
}, {
|
|
13084
|
-
dataIndex: 'specId',
|
|
13085
|
-
title: "".concat(text, "SKUID"),
|
|
13086
|
-
align: 'center',
|
|
13087
|
-
ellipsis: true,
|
|
13088
|
-
width: 100
|
|
13089
|
-
}, {
|
|
13090
|
-
dataIndex: 'specNo',
|
|
13091
|
-
title: "".concat(text, "\u5546\u54C1SKU\u7F16\u7801"),
|
|
13092
|
-
align: 'center',
|
|
13093
|
-
ellipsis: true,
|
|
13094
|
-
width: 180
|
|
13095
|
-
}, {
|
|
13096
|
-
dataIndex: 'specName',
|
|
13097
|
-
title: "".concat(text, "\u5546\u54C1SKU\u540D\u79F0"),
|
|
13098
|
-
align: 'center',
|
|
13099
|
-
ellipsis: true,
|
|
13100
|
-
width: 250
|
|
13101
|
-
}, {
|
|
13102
|
-
dataIndex: 'num',
|
|
13103
|
-
title: "".concat(text, "\u6362\u51FA\u6570\u91CF"),
|
|
13104
|
-
align: 'center',
|
|
13105
|
-
ellipsis: true,
|
|
13106
|
-
width: 100,
|
|
13107
|
-
render: function render(val, record, index) {
|
|
13108
|
-
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13109
|
-
style: {
|
|
13110
|
-
width: 70
|
|
13111
|
-
},
|
|
13112
|
-
value: val,
|
|
13113
|
-
min: 1,
|
|
13114
|
-
precision: 0,
|
|
13115
|
-
onChange: function onChange(num) {
|
|
13116
|
-
return updateHandle(num, index, 'num');
|
|
13117
|
-
}
|
|
13118
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13119
|
-
}
|
|
13120
|
-
}, {
|
|
13121
|
-
dataIndex: 'price',
|
|
13122
|
-
title: "".concat(text, "\u5546\u54C1\u5355\u4EF7"),
|
|
13123
|
-
align: 'center',
|
|
13124
|
-
ellipsis: true,
|
|
13125
|
-
width: 100,
|
|
13126
|
-
render: function render(val, record, index) {
|
|
13127
|
-
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13128
|
-
style: {
|
|
13129
|
-
width: 70
|
|
13130
|
-
},
|
|
13131
|
-
value: val,
|
|
13132
|
-
min: 0,
|
|
13133
|
-
onChange: function onChange(value) {
|
|
13134
|
-
return updateHandle(value, index, 'price');
|
|
13135
|
-
}
|
|
13136
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13137
|
-
}
|
|
13138
|
-
}, {
|
|
13139
|
-
dataIndex: 'exchangePrice',
|
|
13140
|
-
title: "".concat(text, "\u6362\u51FA\u91D1\u989D"),
|
|
13141
|
-
align: 'center',
|
|
13142
|
-
ellipsis: true,
|
|
13143
|
-
width: 100
|
|
13144
|
-
}, {
|
|
13145
|
-
dataIndex: 'giftType',
|
|
13146
|
-
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
13147
|
-
align: 'center',
|
|
13148
|
-
ellipsis: true,
|
|
13149
|
-
width: 100,
|
|
13150
|
-
render: function render(val) {
|
|
13151
|
-
var giftTypeMap = {
|
|
13152
|
-
0: '非赠品',
|
|
13153
|
-
1: '自动赠送',
|
|
13154
|
-
2: '手工赠送',
|
|
13155
|
-
3: '回购自动送赠品',
|
|
13156
|
-
4: '前N有礼送赠品',
|
|
13157
|
-
6: '天猫优仓赠品',
|
|
13158
|
-
7: '淘宝CRM会员送赠'
|
|
13159
|
-
};
|
|
13160
|
-
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
13161
|
-
}
|
|
13162
|
-
}, {
|
|
13163
|
-
dataIndex: 'type',
|
|
13164
|
-
title: "".concat(text, "\u5546\u54C1\u7C7B\u578B"),
|
|
13165
|
-
align: 'center',
|
|
13166
|
-
ellipsis: true,
|
|
13167
|
-
width: 100,
|
|
13168
|
-
render: function render(val, record, index) {
|
|
13169
|
-
var options = [{
|
|
13170
|
-
label: '单品',
|
|
13171
|
-
value: '1'
|
|
13172
|
-
}, {
|
|
13173
|
-
label: '组合装',
|
|
13174
|
-
value: '2'
|
|
13175
|
-
}];
|
|
13176
|
-
return !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
13177
|
-
style: {
|
|
13178
|
-
width: 70
|
|
13179
|
-
},
|
|
13180
|
-
options: options,
|
|
13181
|
-
value: val,
|
|
13182
|
-
onChange: function onChange(value) {
|
|
13183
|
-
return updateHandle(value, index, 'type');
|
|
13184
|
-
}
|
|
13185
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13186
|
-
}
|
|
13187
|
-
}];
|
|
14403
|
+
columns = getColumnsMap({
|
|
14404
|
+
text: text,
|
|
14405
|
+
disabled: disabled,
|
|
14406
|
+
updateHandle: updateHandle,
|
|
14407
|
+
updateDataHandle: updateDataHandle
|
|
14408
|
+
})[type];
|
|
13188
14409
|
}
|
|
13189
14410
|
break;
|
|
13190
|
-
case '
|
|
14411
|
+
case 'WDT_REISSUE_GOODS':
|
|
13191
14412
|
{
|
|
13192
|
-
columns =
|
|
13193
|
-
|
|
13194
|
-
|
|
13195
|
-
|
|
13196
|
-
|
|
13197
|
-
width: 150
|
|
13198
|
-
}, {
|
|
13199
|
-
dataIndex: 'skuId',
|
|
13200
|
-
title: "SKU ID",
|
|
13201
|
-
align: 'center',
|
|
13202
|
-
ellipsis: true,
|
|
13203
|
-
width: 150
|
|
13204
|
-
}, {
|
|
13205
|
-
dataIndex: 'goodsName',
|
|
13206
|
-
title: "\u5546\u54C1\u540D\u79F0",
|
|
13207
|
-
align: 'center',
|
|
13208
|
-
ellipsis: true,
|
|
13209
|
-
width: 150
|
|
13210
|
-
}, {
|
|
13211
|
-
dataIndex: 'goodsShortName',
|
|
13212
|
-
title: "\u5546\u54C1\u7B80\u79F0",
|
|
13213
|
-
align: 'center',
|
|
13214
|
-
ellipsis: true,
|
|
13215
|
-
width: 100
|
|
13216
|
-
}, {
|
|
13217
|
-
dataIndex: 'picPath',
|
|
13218
|
-
title: "\u5546\u54C1\u56FE\u7247",
|
|
13219
|
-
align: 'center',
|
|
13220
|
-
ellipsis: true,
|
|
13221
|
-
width: 100,
|
|
13222
|
-
render: function render(val) {
|
|
13223
|
-
return /*#__PURE__*/React.createElement(Image, {
|
|
13224
|
-
width: 60,
|
|
13225
|
-
src: val
|
|
13226
|
-
});
|
|
13227
|
-
}
|
|
13228
|
-
}, {
|
|
13229
|
-
dataIndex: 'goodsSn',
|
|
13230
|
-
title: "\u8D27\u53F7",
|
|
13231
|
-
align: 'center',
|
|
13232
|
-
ellipsis: true,
|
|
13233
|
-
width: 150
|
|
13234
|
-
}, {
|
|
13235
|
-
dataIndex: 'goodsId',
|
|
13236
|
-
title: "\u8D27\u53F7ID",
|
|
13237
|
-
align: 'center',
|
|
13238
|
-
ellipsis: true,
|
|
13239
|
-
width: 150
|
|
13240
|
-
}, {
|
|
13241
|
-
dataIndex: 'colorName',
|
|
13242
|
-
title: "\u989C\u8272\u540D\u79F0",
|
|
13243
|
-
align: 'center',
|
|
13244
|
-
ellipsis: true,
|
|
13245
|
-
width: 100
|
|
13246
|
-
}, {
|
|
13247
|
-
dataIndex: 'colorCode',
|
|
13248
|
-
title: "\u989C\u8272\u4EE3\u7801",
|
|
13249
|
-
align: 'center',
|
|
13250
|
-
ellipsis: true,
|
|
13251
|
-
width: 150
|
|
13252
|
-
}, {
|
|
13253
|
-
dataIndex: 'sizeName',
|
|
13254
|
-
title: "\u5C3A\u7801\u540D\u79F0",
|
|
13255
|
-
align: 'center',
|
|
13256
|
-
ellipsis: true,
|
|
13257
|
-
width: 100
|
|
13258
|
-
}, {
|
|
13259
|
-
dataIndex: 'sizeCode',
|
|
13260
|
-
title: "\u5C3A\u7801\u4EE3\u7801",
|
|
13261
|
-
align: 'center',
|
|
13262
|
-
ellipsis: true,
|
|
13263
|
-
width: 100
|
|
13264
|
-
}, {
|
|
13265
|
-
dataIndex: 'brandName',
|
|
13266
|
-
title: "\u54C1\u724C\u540D\u79F0",
|
|
13267
|
-
align: 'center',
|
|
13268
|
-
ellipsis: true,
|
|
13269
|
-
width: 150
|
|
13270
|
-
}, {
|
|
13271
|
-
dataIndex: 'goodsNumber',
|
|
13272
|
-
title: "\u5546\u54C1\u6570\u91CF",
|
|
13273
|
-
align: 'center',
|
|
13274
|
-
ellipsis: true,
|
|
13275
|
-
width: 100
|
|
13276
|
-
}, {
|
|
13277
|
-
dataIndex: 'goodsPrice',
|
|
13278
|
-
title: "\u5546\u54C1\u5355\u4EF7",
|
|
13279
|
-
align: 'center',
|
|
13280
|
-
ellipsis: true,
|
|
13281
|
-
width: 120
|
|
13282
|
-
}, {
|
|
13283
|
-
dataIndex: 'shopPrice',
|
|
13284
|
-
title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
|
|
13285
|
-
align: 'center',
|
|
13286
|
-
ellipsis: true,
|
|
13287
|
-
width: 120
|
|
13288
|
-
}, {
|
|
13289
|
-
dataIndex: 'sharePrice',
|
|
13290
|
-
title: "\u5206\u644A\u4EF7",
|
|
13291
|
-
align: 'center',
|
|
13292
|
-
ellipsis: true,
|
|
13293
|
-
width: 120
|
|
13294
|
-
}, {
|
|
13295
|
-
dataIndex: 'sharePayment',
|
|
13296
|
-
title: "\u5206\u644A\u5B9E\u4ED8\u91D1\u989D",
|
|
13297
|
-
align: 'center',
|
|
13298
|
-
ellipsis: true,
|
|
13299
|
-
width: 120
|
|
13300
|
-
}, {
|
|
13301
|
-
dataIndex: 'payment',
|
|
13302
|
-
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
13303
|
-
align: 'center',
|
|
13304
|
-
ellipsis: true,
|
|
13305
|
-
width: 120
|
|
13306
|
-
}, {
|
|
13307
|
-
dataIndex: 'tcSku',
|
|
13308
|
-
title: "\u5957\u9910SKU",
|
|
13309
|
-
align: 'center',
|
|
13310
|
-
ellipsis: true,
|
|
13311
|
-
width: 150
|
|
13312
|
-
}, {
|
|
13313
|
-
dataIndex: 'tcGoodsNumber',
|
|
13314
|
-
title: "\u5957\u9910\u5957\u6570",
|
|
13315
|
-
align: 'center',
|
|
13316
|
-
ellipsis: true,
|
|
13317
|
-
width: 100
|
|
13318
|
-
}, {
|
|
13319
|
-
dataIndex: 'taoCanSingleSl',
|
|
13320
|
-
title: "\u5355\u4E2A\u5957\u9910\u6570\u91CF",
|
|
13321
|
-
align: 'center',
|
|
13322
|
-
ellipsis: true,
|
|
13323
|
-
width: 100
|
|
13324
|
-
}, {
|
|
13325
|
-
dataIndex: 'isGift',
|
|
13326
|
-
title: "\u662F\u5426\u8D60\u54C1",
|
|
13327
|
-
align: 'center',
|
|
13328
|
-
ellipsis: true,
|
|
13329
|
-
width: 100,
|
|
13330
|
-
render: function render(val) {
|
|
13331
|
-
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
13332
|
-
}
|
|
13333
|
-
}];
|
|
14413
|
+
columns = getWdtReissueGoodColumns({
|
|
14414
|
+
disabled: disabled,
|
|
14415
|
+
updateHandle: updateHandle,
|
|
14416
|
+
operate: operate
|
|
14417
|
+
});
|
|
13334
14418
|
}
|
|
13335
14419
|
break;
|
|
13336
14420
|
case 'BS_E3_REISSUE_GOODS':
|
|
@@ -13343,102 +14427,12 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13343
14427
|
}
|
|
13344
14428
|
break;
|
|
13345
14429
|
default:
|
|
13346
|
-
columns =
|
|
13347
|
-
|
|
13348
|
-
|
|
13349
|
-
|
|
13350
|
-
|
|
13351
|
-
|
|
13352
|
-
render: function render(val, record, index) {
|
|
13353
|
-
return /*#__PURE__*/React.createElement(Select, {
|
|
13354
|
-
options: [{
|
|
13355
|
-
label: '是',
|
|
13356
|
-
value: '是'
|
|
13357
|
-
}, {
|
|
13358
|
-
label: '否',
|
|
13359
|
-
value: '否'
|
|
13360
|
-
}],
|
|
13361
|
-
disabled: disabled,
|
|
13362
|
-
value: val,
|
|
13363
|
-
onChange: function onChange(val) {
|
|
13364
|
-
return updateHandle(val, index, 'mark');
|
|
13365
|
-
}
|
|
13366
|
-
});
|
|
13367
|
-
}
|
|
13368
|
-
}, {
|
|
13369
|
-
dataIndex: 'skuName',
|
|
13370
|
-
title: "".concat(text, "sku\u540D\u79F0"),
|
|
13371
|
-
align: 'center',
|
|
13372
|
-
ellipsis: true,
|
|
13373
|
-
width: 250
|
|
13374
|
-
}, {
|
|
13375
|
-
dataIndex: 'sku',
|
|
13376
|
-
title: "".concat(text, "sku\u7F16\u7801"),
|
|
13377
|
-
align: 'center',
|
|
13378
|
-
ellipsis: true,
|
|
13379
|
-
width: 100
|
|
13380
|
-
}, {
|
|
13381
|
-
dataIndex: 'name',
|
|
13382
|
-
title: "".concat(text, "\u540D\u79F0"),
|
|
13383
|
-
align: 'center',
|
|
13384
|
-
ellipsis: true,
|
|
13385
|
-
width: 250
|
|
13386
|
-
}, {
|
|
13387
|
-
dataIndex: 'pic',
|
|
13388
|
-
title: "\u56FE\u7247",
|
|
13389
|
-
align: 'center',
|
|
13390
|
-
ellipsis: true,
|
|
13391
|
-
width: 100,
|
|
13392
|
-
render: function render(val) {
|
|
13393
|
-
return /*#__PURE__*/React.createElement(Image, {
|
|
13394
|
-
width: 60,
|
|
13395
|
-
src: val
|
|
13396
|
-
});
|
|
13397
|
-
}
|
|
13398
|
-
}, {
|
|
13399
|
-
dataIndex: 'code',
|
|
13400
|
-
title: "".concat(text, "\u7F16\u7801"),
|
|
13401
|
-
align: 'center',
|
|
13402
|
-
ellipsis: true,
|
|
13403
|
-
width: 100
|
|
13404
|
-
}, {
|
|
13405
|
-
dataIndex: 'money',
|
|
13406
|
-
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
13407
|
-
align: 'center',
|
|
13408
|
-
ellipsis: true,
|
|
13409
|
-
width: 100
|
|
13410
|
-
}, {
|
|
13411
|
-
dataIndex: 'number',
|
|
13412
|
-
title: "".concat(text, "\u6570\u91CF"),
|
|
13413
|
-
align: 'center',
|
|
13414
|
-
ellipsis: true,
|
|
13415
|
-
width: 100,
|
|
13416
|
-
render: function render(val, record, index) {
|
|
13417
|
-
return record.canUpdateNumber && !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
13418
|
-
style: {
|
|
13419
|
-
width: 70
|
|
13420
|
-
},
|
|
13421
|
-
value: val,
|
|
13422
|
-
min: 1,
|
|
13423
|
-
precision: 0,
|
|
13424
|
-
onChange: function onChange(num) {
|
|
13425
|
-
return updateHandle(num, index, 'number');
|
|
13426
|
-
}
|
|
13427
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
13428
|
-
}
|
|
13429
|
-
}, {
|
|
13430
|
-
dataIndex: 'share',
|
|
13431
|
-
title: "\u5206\u644A\u4EF7",
|
|
13432
|
-
align: 'center',
|
|
13433
|
-
ellipsis: true,
|
|
13434
|
-
width: 70
|
|
13435
|
-
}, {
|
|
13436
|
-
dataIndex: 'type',
|
|
13437
|
-
title: "\u8D60\u54C1\u7C7B\u578B",
|
|
13438
|
-
align: 'center',
|
|
13439
|
-
ellipsis: true,
|
|
13440
|
-
width: 100
|
|
13441
|
-
}];
|
|
14430
|
+
columns = getColumnsMap({
|
|
14431
|
+
text: text,
|
|
14432
|
+
disabled: disabled,
|
|
14433
|
+
updateHandle: updateHandle,
|
|
14434
|
+
updateDataHandle: updateDataHandle
|
|
14435
|
+
})['default'];
|
|
13442
14436
|
}
|
|
13443
14437
|
return columns;
|
|
13444
14438
|
};
|
|
@@ -13450,6 +14444,24 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13450
14444
|
return COLUMNS_INFO(type);
|
|
13451
14445
|
};
|
|
13452
14446
|
var newColumns = useMemo(function () {
|
|
14447
|
+
var initBaseInfoColumns = GOODS_INFO_COLUMNS();
|
|
14448
|
+
var baseInfoColumns = [];
|
|
14449
|
+
var isStringArray = Array.isArray(showHeader) && typeof showHeader[0] === 'string';
|
|
14450
|
+
var isObjectArray = Array.isArray(showHeader) && Object.prototype.toString.call(showHeader[0]) === '[object Object]';
|
|
14451
|
+
if (isStringArray) {
|
|
14452
|
+
baseInfoColumns = initBaseInfoColumns.filter(function (col) {
|
|
14453
|
+
return showHeader.includes(col.dataIndex);
|
|
14454
|
+
});
|
|
14455
|
+
} else if (isObjectArray) {
|
|
14456
|
+
baseInfoColumns = showHeader.filter(function (col) {
|
|
14457
|
+
return col.show !== false;
|
|
14458
|
+
}).map(function (col) {
|
|
14459
|
+
var currentCol = initBaseInfoColumns.find(function (item) {
|
|
14460
|
+
return item.dataIndex === col.dataIndex;
|
|
14461
|
+
});
|
|
14462
|
+
return currentCol ? currentCol : undefined;
|
|
14463
|
+
}).filter(Boolean);
|
|
14464
|
+
}
|
|
13453
14465
|
var columnList = [{
|
|
13454
14466
|
dataIndex: '',
|
|
13455
14467
|
title: '序号',
|
|
@@ -13459,9 +14471,7 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13459
14471
|
render: function render(val, record, index) {
|
|
13460
14472
|
return /*#__PURE__*/React.createElement("span", null, index + 1);
|
|
13461
14473
|
}
|
|
13462
|
-
}].concat(_toConsumableArray(
|
|
13463
|
-
return showHeader.includes(t === null || t === void 0 ? void 0 : t.dataIndex);
|
|
13464
|
-
})));
|
|
14474
|
+
}].concat(_toConsumableArray(baseInfoColumns));
|
|
13465
14475
|
if (!disabled) {
|
|
13466
14476
|
columnList.push({
|
|
13467
14477
|
dataIndex: '',
|
|
@@ -13539,10 +14549,33 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13539
14549
|
isGift: '',
|
|
13540
14550
|
uuid: uuid(),
|
|
13541
14551
|
canDelete: true,
|
|
14552
|
+
canEdit: true,
|
|
13542
14553
|
goodsNumber: 1,
|
|
13543
14554
|
canUpdateNumber: canUpdateNumber
|
|
13544
14555
|
});
|
|
13545
14556
|
});
|
|
14557
|
+
} else if (['GY_GOODS', 'GY_REISSUE_GOODS'].includes(type)) {
|
|
14558
|
+
newList = list.map(function (item) {
|
|
14559
|
+
var goodName = item.goodName,
|
|
14560
|
+
goodShortName = item.goodShortName,
|
|
14561
|
+
goodNo = item.goodNo,
|
|
14562
|
+
specName = item.specName,
|
|
14563
|
+
specNo = item.specNo,
|
|
14564
|
+
retailPrice = item.retailPrice;
|
|
14565
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
14566
|
+
uuid: uuid(),
|
|
14567
|
+
canDelete: true,
|
|
14568
|
+
canEdit: true,
|
|
14569
|
+
qty: 1,
|
|
14570
|
+
goodName: goodName,
|
|
14571
|
+
goodShortName: goodShortName,
|
|
14572
|
+
goodNo: goodNo,
|
|
14573
|
+
specName: specName,
|
|
14574
|
+
specNo: specNo,
|
|
14575
|
+
originPrice: !isNull(retailPrice) ? Number(retailPrice) : null,
|
|
14576
|
+
originAmount: !isNull(retailPrice) ? Number(retailPrice) : null
|
|
14577
|
+
});
|
|
14578
|
+
});
|
|
13546
14579
|
} else {
|
|
13547
14580
|
newList = list.map(function (item) {
|
|
13548
14581
|
var goodsId = item.goodsId,
|
|
@@ -13638,6 +14671,14 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
13638
14671
|
shopId: shopId,
|
|
13639
14672
|
maxLength: maxLength,
|
|
13640
14673
|
companyKey: companyKey
|
|
14674
|
+
}) : ['GY_GOODS', 'GY_REISSUE_GOODS'].includes(type) ? /*#__PURE__*/React.createElement(GyGoodsModal$1, {
|
|
14675
|
+
ref: refModal,
|
|
14676
|
+
onSubmit: onSubmit,
|
|
14677
|
+
width: width,
|
|
14678
|
+
shopList: shopList,
|
|
14679
|
+
shopId: shopId,
|
|
14680
|
+
maxLength: maxLength,
|
|
14681
|
+
companyKey: companyKey
|
|
13641
14682
|
}) : /*#__PURE__*/React.createElement(GoodsModal$2, {
|
|
13642
14683
|
ref: refModal,
|
|
13643
14684
|
onSubmit: onSubmit,
|
|
@@ -14323,25 +15364,72 @@ var getBsE3OrderListSingleton = function getBsE3OrderListSingleton(orderNo) {
|
|
|
14323
15364
|
}
|
|
14324
15365
|
resolve(data.data);
|
|
14325
15366
|
} else {
|
|
14326
|
-
doReject(data);
|
|
15367
|
+
doReject(data);
|
|
15368
|
+
}
|
|
15369
|
+
}).catch(doReject);
|
|
15370
|
+
});
|
|
15371
|
+
singletonMap$1.set(orderNo, p);
|
|
15372
|
+
}
|
|
15373
|
+
return singletonMap$1.get(orderNo);
|
|
15374
|
+
};
|
|
15375
|
+
var bsE3Utils = {
|
|
15376
|
+
getBsE3OrderListSingleton: getBsE3OrderListSingleton
|
|
15377
|
+
};
|
|
15378
|
+
|
|
15379
|
+
var singletonMap$2 = new Map();
|
|
15380
|
+
var getGyOrderListSingleton = function getGyOrderListSingleton(orderNo) {
|
|
15381
|
+
if (!singletonMap$2.has(orderNo)) {
|
|
15382
|
+
var p = new Promise(function (resolve, reject) {
|
|
15383
|
+
var doReject = function doReject(err) {
|
|
15384
|
+
// 清空掉错误的请求记录
|
|
15385
|
+
singletonMap$2.delete(orderNo);
|
|
15386
|
+
reject(err);
|
|
15387
|
+
};
|
|
15388
|
+
extendRequest('/qy/gdfw/oms/gyOrderDetail', {
|
|
15389
|
+
method: 'post',
|
|
15390
|
+
data: {
|
|
15391
|
+
tid: orderNo
|
|
15392
|
+
}
|
|
15393
|
+
}).then(function (res) {
|
|
15394
|
+
if (res === null || res === void 0 ? void 0 : res.success) {
|
|
15395
|
+
var _res$data;
|
|
15396
|
+
if (res === null || res === void 0 ? void 0 : (_res$data = res.data) === null || _res$data === void 0 ? void 0 : _res$data.length) {
|
|
15397
|
+
res.data.trades = filterGyOrders(res === null || res === void 0 ? void 0 : res.data, orderNo).map(function (item) {
|
|
15398
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
15399
|
+
billNo: item.code,
|
|
15400
|
+
billType: item.orderTypeName,
|
|
15401
|
+
billTag: item.tagName,
|
|
15402
|
+
tradeTagName: item.tradeTagName,
|
|
15403
|
+
deliveryState: item.deliveryState,
|
|
15404
|
+
deliveryStateName: GY_DELIVERY_STATE_MAPPING[item.deliveryState]
|
|
15405
|
+
});
|
|
15406
|
+
});
|
|
15407
|
+
}
|
|
15408
|
+
resolve(res.data);
|
|
15409
|
+
// 延迟10秒清除,保证订单的时效性
|
|
15410
|
+
setTimeout(function () {
|
|
15411
|
+
singletonMap$2.delete(orderNo);
|
|
15412
|
+
}, 1000 * 10);
|
|
15413
|
+
} else {
|
|
15414
|
+
doReject(res);
|
|
14327
15415
|
}
|
|
14328
15416
|
}).catch(doReject);
|
|
14329
15417
|
});
|
|
14330
|
-
singletonMap$
|
|
15418
|
+
singletonMap$2.set(orderNo, p);
|
|
14331
15419
|
}
|
|
14332
|
-
return singletonMap$
|
|
15420
|
+
return singletonMap$2.get(orderNo);
|
|
14333
15421
|
};
|
|
14334
|
-
var
|
|
14335
|
-
|
|
15422
|
+
var gyUtils = {
|
|
15423
|
+
getGyOrderListSingleton: getGyOrderListSingleton
|
|
14336
15424
|
};
|
|
14337
15425
|
|
|
14338
|
-
var singletonMap$
|
|
15426
|
+
var singletonMap$3 = new Map();
|
|
14339
15427
|
var getOrderListSingleton = function getOrderListSingleton(orderNo) {
|
|
14340
|
-
if (!singletonMap$
|
|
15428
|
+
if (!singletonMap$3.has(orderNo)) {
|
|
14341
15429
|
var p = new Promise(function (resolve, reject) {
|
|
14342
15430
|
var doReject = function doReject(err) {
|
|
14343
15431
|
// 清空掉错误的请求记录
|
|
14344
|
-
singletonMap$
|
|
15432
|
+
singletonMap$3.delete(orderNo);
|
|
14345
15433
|
reject(err);
|
|
14346
15434
|
};
|
|
14347
15435
|
extendRequest('/qy/gdfw/order/kmErpOrderDetail', {
|
|
@@ -14367,151 +15455,36 @@ var getOrderListSingleton = function getOrderListSingleton(orderNo) {
|
|
|
14367
15455
|
}
|
|
14368
15456
|
// 延迟10秒清除,保证订单的时效性
|
|
14369
15457
|
setTimeout(function () {
|
|
14370
|
-
singletonMap$
|
|
15458
|
+
singletonMap$3.delete(orderNo);
|
|
14371
15459
|
}, 1000 * 10);
|
|
14372
15460
|
} else {
|
|
14373
15461
|
doReject(data);
|
|
14374
15462
|
}
|
|
14375
15463
|
}).catch(doReject);
|
|
14376
15464
|
});
|
|
14377
|
-
singletonMap$
|
|
15465
|
+
singletonMap$3.set(orderNo, p);
|
|
14378
15466
|
}
|
|
14379
|
-
return singletonMap$
|
|
15467
|
+
return singletonMap$3.get(orderNo);
|
|
14380
15468
|
};
|
|
14381
15469
|
var kmUtils = {
|
|
14382
15470
|
getOrderListSingleton: getOrderListSingleton
|
|
14383
15471
|
};
|
|
14384
15472
|
|
|
14385
15473
|
var columnsMap = {
|
|
14386
|
-
BS_SYSTEM_ORDER:
|
|
14387
|
-
title: '单据类型',
|
|
14388
|
-
dataIndex: 'billType',
|
|
14389
|
-
width: 150
|
|
14390
|
-
}, {
|
|
14391
|
-
title: '系统订单号',
|
|
14392
|
-
dataIndex: 'billNo',
|
|
14393
|
-
width: 150
|
|
14394
|
-
}, {
|
|
14395
|
-
title: '标签',
|
|
14396
|
-
dataIndex: 'billTag',
|
|
14397
|
-
width: 150
|
|
14398
|
-
}, {
|
|
14399
|
-
title: '主播名称',
|
|
14400
|
-
dataIndex: 'authorName',
|
|
14401
|
-
width: 150
|
|
14402
|
-
}, {
|
|
14403
|
-
title: '主播ID',
|
|
14404
|
-
dataIndex: 'authorId',
|
|
14405
|
-
width: 150
|
|
14406
|
-
}
|
|
14407
|
-
// {
|
|
14408
|
-
// title: '直播活动',
|
|
14409
|
-
// dataIndex: 'liveActivites',
|
|
14410
|
-
// width: 150,
|
|
14411
|
-
// },
|
|
14412
|
-
],
|
|
14413
|
-
|
|
15474
|
+
BS_SYSTEM_ORDER: BS_SYSTEM_ORDER_CONFIG.columns,
|
|
14414
15475
|
KM_SYSTEM_ORDER: KM_SYSTEM_ORDER_CONFIG.columns,
|
|
14415
|
-
WLN_SYSTEM_ORDER:
|
|
14416
|
-
|
|
14417
|
-
|
|
14418
|
-
|
|
14419
|
-
}, {
|
|
14420
|
-
title: '系统订单号',
|
|
14421
|
-
dataIndex: 'billNo',
|
|
14422
|
-
width: 150
|
|
14423
|
-
}, {
|
|
14424
|
-
title: '标记',
|
|
14425
|
-
dataIndex: 'billTag',
|
|
14426
|
-
width: 150
|
|
14427
|
-
}],
|
|
14428
|
-
WDT_SYSTEM_ORDER: [{
|
|
14429
|
-
title: '订单类型',
|
|
14430
|
-
dataIndex: 'billType',
|
|
14431
|
-
width: 150
|
|
14432
|
-
}, {
|
|
14433
|
-
title: '系统订单号',
|
|
14434
|
-
dataIndex: 'billNo',
|
|
14435
|
-
width: 150
|
|
14436
|
-
}, {
|
|
14437
|
-
title: '订单标签',
|
|
14438
|
-
dataIndex: 'billTag',
|
|
14439
|
-
width: 150
|
|
14440
|
-
}],
|
|
14441
|
-
BS_E3_SYSTEM_ORDER: [{
|
|
14442
|
-
title: '系统订单号',
|
|
14443
|
-
dataIndex: 'orderSn',
|
|
14444
|
-
width: 150,
|
|
14445
|
-
ellipsis: true
|
|
14446
|
-
}, {
|
|
14447
|
-
title: '订单状态',
|
|
14448
|
-
dataIndex: 'orderStatus',
|
|
14449
|
-
width: 100,
|
|
14450
|
-
ellipsis: true,
|
|
14451
|
-
render: function render(val) {
|
|
14452
|
-
return /*#__PURE__*/React.createElement("span", null, BS_E3_ORDER_STATUS_MAP[val] || val);
|
|
14453
|
-
}
|
|
14454
|
-
}, {
|
|
14455
|
-
title: '是否被拆分',
|
|
14456
|
-
dataIndex: 'isSplit',
|
|
14457
|
-
width: 100,
|
|
14458
|
-
ellipsis: true,
|
|
14459
|
-
render: function render(val) {
|
|
14460
|
-
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14461
|
-
}
|
|
14462
|
-
}, {
|
|
14463
|
-
title: '是否拆分子单',
|
|
14464
|
-
dataIndex: 'isSplitNew',
|
|
14465
|
-
width: 100,
|
|
14466
|
-
ellipsis: true,
|
|
14467
|
-
render: function render(val) {
|
|
14468
|
-
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14469
|
-
}
|
|
14470
|
-
}, {
|
|
14471
|
-
title: '是否被合并',
|
|
14472
|
-
dataIndex: 'isCombine',
|
|
14473
|
-
width: 100,
|
|
14474
|
-
ellipsis: true,
|
|
14475
|
-
render: function render(val) {
|
|
14476
|
-
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14477
|
-
}
|
|
14478
|
-
}, {
|
|
14479
|
-
title: '是否合并新单',
|
|
14480
|
-
dataIndex: 'isCombineNew',
|
|
14481
|
-
width: 100,
|
|
14482
|
-
ellipsis: true,
|
|
14483
|
-
render: function render(val) {
|
|
14484
|
-
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14485
|
-
}
|
|
14486
|
-
}, {
|
|
14487
|
-
title: '是否复制单',
|
|
14488
|
-
dataIndex: 'isCopy',
|
|
14489
|
-
width: 100,
|
|
14490
|
-
ellipsis: true,
|
|
14491
|
-
render: function render(val) {
|
|
14492
|
-
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14493
|
-
}
|
|
14494
|
-
}, {
|
|
14495
|
-
title: '是否换货单',
|
|
14496
|
-
dataIndex: 'isExchangeOrder',
|
|
14497
|
-
width: 100,
|
|
14498
|
-
ellipsis: true,
|
|
14499
|
-
render: function render(val) {
|
|
14500
|
-
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
14501
|
-
}
|
|
14502
|
-
}, {
|
|
14503
|
-
title: '订单备注',
|
|
14504
|
-
dataIndex: 'orderMsg',
|
|
14505
|
-
width: 150,
|
|
14506
|
-
ellipsis: true
|
|
14507
|
-
}]
|
|
15476
|
+
WLN_SYSTEM_ORDER: WLN_SYSTEM_ORDER_CONFIG.columns,
|
|
15477
|
+
WDT_SYSTEM_ORDER: WDT_SYSTEM_ORDER_CONFIG.columns,
|
|
15478
|
+
BS_E3_SYSTEM_ORDER: BS_E3_SYSTEM_ORDER_CONFIG.columns,
|
|
15479
|
+
GY_SYSTEM_ORDER: GY_SYSTEM_ORDER_CONFIG.columns
|
|
14508
15480
|
};
|
|
14509
15481
|
var rowKeyMap = {
|
|
14510
15482
|
BS_SYSTEM_ORDER: 'billNo',
|
|
14511
15483
|
KM_SYSTEM_ORDER: 'billNo',
|
|
14512
15484
|
WLN_SYSTEM_ORDER: 'billNo',
|
|
14513
15485
|
WDT_SYSTEM_ORDER: 'billNo',
|
|
14514
|
-
BS_E3_SYSTEM_ORDER: 'orderSn'
|
|
15486
|
+
BS_E3_SYSTEM_ORDER: 'orderSn',
|
|
15487
|
+
GY_SYSTEM_ORDER: 'billNo'
|
|
14515
15488
|
};
|
|
14516
15489
|
var index$1 = (function (props) {
|
|
14517
15490
|
var value = props.value,
|
|
@@ -14533,6 +15506,9 @@ var index$1 = (function (props) {
|
|
|
14533
15506
|
getWdtOrderList(value.orderNo);
|
|
14534
15507
|
} else if (type === 'BS_E3_SYSTEM_ORDER') {
|
|
14535
15508
|
getBsE3OrderList(value.orderNo);
|
|
15509
|
+
} else if (type === 'GY_SYSTEM_ORDER') {
|
|
15510
|
+
console.log('触发gy--getGyOrderList--1');
|
|
15511
|
+
getGyOrderList(value.orderNo);
|
|
14536
15512
|
}
|
|
14537
15513
|
}
|
|
14538
15514
|
}, [value, type]);
|
|
@@ -14719,6 +15695,45 @@ var index$1 = (function (props) {
|
|
|
14719
15695
|
return _ref6.apply(this, arguments);
|
|
14720
15696
|
};
|
|
14721
15697
|
}();
|
|
15698
|
+
var getGyOrderList = /*#__PURE__*/function () {
|
|
15699
|
+
var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(orderNo) {
|
|
15700
|
+
return _regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
15701
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
15702
|
+
case 0:
|
|
15703
|
+
gyUtils.getGyOrderListSingleton(orderNo).then(function (data) {
|
|
15704
|
+
var trades = ((data === null || data === void 0 ? void 0 : data.trades) || []).filter(function (item) {
|
|
15705
|
+
return getIsPlatformCodesIncludeOrderNos(item.platformCode, orderNo);
|
|
15706
|
+
});
|
|
15707
|
+
_onChange === null || _onChange === void 0 ? void 0 : _onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
15708
|
+
orders: trades,
|
|
15709
|
+
showOrderInfo: trades.map(function (_ref9) {
|
|
15710
|
+
var billNo = _ref9.billNo,
|
|
15711
|
+
billType = _ref9.billType,
|
|
15712
|
+
billTag = _ref9.billTag,
|
|
15713
|
+
tradeTagName = _ref9.tradeTagName,
|
|
15714
|
+
deliveryState = _ref9.deliveryState;
|
|
15715
|
+
return {
|
|
15716
|
+
billNo: billNo,
|
|
15717
|
+
billType: billType,
|
|
15718
|
+
billTag: billTag,
|
|
15719
|
+
tradeTagName: tradeTagName,
|
|
15720
|
+
deliveryState: deliveryState,
|
|
15721
|
+
deliveryStateName: GY_DELIVERY_STATE_MAPPING[deliveryState]
|
|
15722
|
+
};
|
|
15723
|
+
})
|
|
15724
|
+
}));
|
|
15725
|
+
});
|
|
15726
|
+
onceRef.current = false;
|
|
15727
|
+
case 2:
|
|
15728
|
+
case "end":
|
|
15729
|
+
return _context6.stop();
|
|
15730
|
+
}
|
|
15731
|
+
}, _callee6);
|
|
15732
|
+
}));
|
|
15733
|
+
return function getGyOrderList(_x6) {
|
|
15734
|
+
return _ref8.apply(this, arguments);
|
|
15735
|
+
};
|
|
15736
|
+
}();
|
|
14722
15737
|
var rowSelection = {
|
|
14723
15738
|
selectedRowKeys: (value === null || value === void 0 ? void 0 : value.selectIds) || [],
|
|
14724
15739
|
fixed: true,
|
|
@@ -14735,7 +15750,24 @@ var index$1 = (function (props) {
|
|
|
14735
15750
|
};
|
|
14736
15751
|
}
|
|
14737
15752
|
};
|
|
14738
|
-
|
|
15753
|
+
// useEffect(() => {
|
|
15754
|
+
// const dom = document.querySelector(
|
|
15755
|
+
// `.${type}_SYSTEM_ORDER_COMPONENT .ant-table-content`,
|
|
15756
|
+
// );
|
|
15757
|
+
// //解决列表出现横向滚动条时选择数据造成行内闪烁问题
|
|
15758
|
+
// if (
|
|
15759
|
+
// (value?.selectIds || []).length > 0 &&
|
|
15760
|
+
// dom &&
|
|
15761
|
+
// dom.scrollWidth > dom.clientWidth &&
|
|
15762
|
+
// dom.scrollLeft === 0
|
|
15763
|
+
// ) {
|
|
15764
|
+
// console.log(dom.scrollWidth > dom.clientWidth, dom.scrollLeft === 0);
|
|
15765
|
+
// dom.scrollLeft = 1;
|
|
15766
|
+
// }
|
|
15767
|
+
// }, [JSON.stringify(value?.selectIds || [])]);
|
|
15768
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
15769
|
+
className: "".concat(type, "_SYSTEM_ORDER_COMPONENT")
|
|
15770
|
+
}, /*#__PURE__*/React.createElement(Table, {
|
|
14739
15771
|
dataSource: (value === null || value === void 0 ? void 0 : value.orders) || [],
|
|
14740
15772
|
columns: columns,
|
|
14741
15773
|
rowSelection: rowSelection,
|
|
@@ -14743,12 +15775,12 @@ var index$1 = (function (props) {
|
|
|
14743
15775
|
size: "small",
|
|
14744
15776
|
pagination: false,
|
|
14745
15777
|
scroll: {
|
|
14746
|
-
x: '
|
|
15778
|
+
x: 'max-content'
|
|
14747
15779
|
},
|
|
14748
15780
|
locale: {
|
|
14749
15781
|
emptyText: '暂无数据'
|
|
14750
15782
|
}
|
|
14751
|
-
});
|
|
15783
|
+
}));
|
|
14752
15784
|
});
|
|
14753
15785
|
|
|
14754
15786
|
var WlnGoods = function WlnGoods(props) {
|
|
@@ -14774,13 +15806,14 @@ var WlnGoods = function WlnGoods(props) {
|
|
|
14774
15806
|
};
|
|
14775
15807
|
|
|
14776
15808
|
var componentMap$1 = {
|
|
14777
|
-
|
|
15809
|
+
WDT_GOODS: {
|
|
14778
15810
|
type: 'wdt',
|
|
14779
15811
|
key: 'wdtGoods',
|
|
14780
15812
|
name: '旺店通',
|
|
14781
15813
|
orderNo: 'srcTid',
|
|
14782
15814
|
goodDetailOrderNo: 'srcTid',
|
|
14783
15815
|
eventNameMap: {
|
|
15816
|
+
// pubsub 事件
|
|
14784
15817
|
type: 'wdtType',
|
|
14785
15818
|
updateGoodsHandle: updateWdtGoodsHandle,
|
|
14786
15819
|
selectListReturn: 'wdtSelectListReturn',
|
|
@@ -14798,13 +15831,14 @@ var componentMap$1 = {
|
|
|
14798
15831
|
exchangeDeleteGood: 'wdtExchangeDeleteGood'
|
|
14799
15832
|
}
|
|
14800
15833
|
},
|
|
14801
|
-
|
|
15834
|
+
BS_E3_GOODS: {
|
|
14802
15835
|
type: 'e3',
|
|
14803
15836
|
key: 'bsE3Goods',
|
|
14804
15837
|
name: '百胜E3',
|
|
14805
15838
|
orderNo: 'dealCode',
|
|
14806
15839
|
goodDetailOrderNo: 'originalDealCode',
|
|
14807
15840
|
eventNameMap: {
|
|
15841
|
+
// pubsub 事件
|
|
14808
15842
|
type: 'bsE3Type',
|
|
14809
15843
|
updateGoodsHandle: updateBsE3GoodsHandle,
|
|
14810
15844
|
selectListReturn: 'bsE3SelectListReturn',
|
|
@@ -14821,6 +15855,31 @@ var componentMap$1 = {
|
|
|
14821
15855
|
returnDeleteGood: 'bsE3ReturnDeleteGood',
|
|
14822
15856
|
exchangeDeleteGood: 'bsE3ExchangeDeleteGood'
|
|
14823
15857
|
}
|
|
15858
|
+
},
|
|
15859
|
+
GY_GOODS: {
|
|
15860
|
+
type: 'gy',
|
|
15861
|
+
key: 'gyGoods',
|
|
15862
|
+
name: '管易',
|
|
15863
|
+
orderNo: 'dealCode',
|
|
15864
|
+
goodDetailOrderNo: 'originalDealCode',
|
|
15865
|
+
eventNameMap: {
|
|
15866
|
+
// pubsub 事件
|
|
15867
|
+
type: 'gyType',
|
|
15868
|
+
updateGoodsHandle: updateGyGoodsHandle,
|
|
15869
|
+
selectListReturn: 'gySelectListReturn',
|
|
15870
|
+
selectList: 'gySelectList',
|
|
15871
|
+
reissueSelectList: 'gyReissueSelectList',
|
|
15872
|
+
reissueSelectListReturn: 'gyReissueSelectListReturn',
|
|
15873
|
+
reissueDeleteGood: 'gyReissueDeleteGood',
|
|
15874
|
+
changeShopCode: 'gyChangeShopCode',
|
|
15875
|
+
reissueType: 'gyReissueType',
|
|
15876
|
+
returnType: 'gyReturnType',
|
|
15877
|
+
returnSelectListReturn: 'gyReturnSelectListReturn',
|
|
15878
|
+
returnSelectList: 'gyReturnSelectList',
|
|
15879
|
+
deleteGood: 'gyDeleteGood',
|
|
15880
|
+
returnDeleteGood: 'gyReturnDeleteGood',
|
|
15881
|
+
exchangeDeleteGood: 'gyExchangeDeleteGood'
|
|
15882
|
+
}
|
|
14824
15883
|
}
|
|
14825
15884
|
};
|
|
14826
15885
|
var CommonGoods = function CommonGoods(props) {
|
|
@@ -15289,7 +16348,7 @@ var typeMap$1 = {
|
|
|
15289
16348
|
}
|
|
15290
16349
|
};
|
|
15291
16350
|
var wdtReissue = function wdtReissue(props) {
|
|
15292
|
-
var _value$wdtSystemOrder, _typeMap$
|
|
16351
|
+
var _value$wdtSystemOrder, _typeMap$type26, _typeMap$type28, _typeMap$type29, _value$typeMap$type$s5, _typeMap$type30, _typeMap$type31, _typeMap$type32;
|
|
15293
16352
|
var value = props.value,
|
|
15294
16353
|
onChange = props.onChange,
|
|
15295
16354
|
_props$reasonList = props.reasonList,
|
|
@@ -15450,19 +16509,25 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
15450
16509
|
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
15451
16510
|
};
|
|
15452
16511
|
var selectedGoodsChange = useCallback(function (skuList) {
|
|
15453
|
-
var _typeMap$type23,
|
|
16512
|
+
var _typeMap$type23, _typeMap$type24, _uniqBy, _typeMap$type25;
|
|
15454
16513
|
var newValue = _objectSpread2({}, value);
|
|
15455
|
-
|
|
15456
|
-
|
|
16514
|
+
// 原订单商品
|
|
16515
|
+
var originTradeGoodList = getGoodDetails({
|
|
16516
|
+
mode: isStrict
|
|
16517
|
+
}) || [];
|
|
16518
|
+
// 当前选中的所有商品【包含了原订单+商品库】
|
|
16519
|
+
var currentSelectGoodList = (value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type23 = typeMap$1[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.key)]) || [];
|
|
16520
|
+
newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type24 = typeMap$1[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.key)] = (_uniqBy = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
|
|
16521
|
+
return skuList.includes(item.uuid);
|
|
15457
16522
|
});
|
|
15458
|
-
console.log('
|
|
16523
|
+
console.log('商品发生变化', newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type25 = typeMap$1[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.key)]);
|
|
15459
16524
|
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
15460
|
-
}, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
16525
|
+
}, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type26 = typeMap$1[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.key)], isStrict]);
|
|
15461
16526
|
//显示选择商品按钮 原单换不显示选择商品
|
|
15462
16527
|
var showChangeBtn = useMemo(function () {
|
|
15463
|
-
var _typeMap$
|
|
15464
|
-
return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$
|
|
15465
|
-
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$
|
|
16528
|
+
var _typeMap$type27;
|
|
16529
|
+
return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type27 = typeMap$1[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrderNo]);
|
|
16530
|
+
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$type28 = typeMap$1[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.systemOrderNo]]);
|
|
15466
16531
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
|
|
15467
16532
|
gutter: 8,
|
|
15468
16533
|
wrap: true
|
|
@@ -15480,12 +16545,12 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
15480
16545
|
},
|
|
15481
16546
|
disabled: disabled,
|
|
15482
16547
|
allowClear: false,
|
|
15483
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
16548
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type29 = typeMap$1[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.systemOrderNo)],
|
|
15484
16549
|
onChange: function onChange(val) {
|
|
15485
16550
|
return changeSystemOrderHandle(val);
|
|
15486
16551
|
},
|
|
15487
16552
|
placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
|
|
15488
|
-
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$
|
|
16553
|
+
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type30 = typeMap$1[type]) === null || _typeMap$type30 === void 0 ? void 0 : _typeMap$type30.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
|
|
15489
16554
|
return /*#__PURE__*/React.createElement(Select.Option, {
|
|
15490
16555
|
key: item.billNo,
|
|
15491
16556
|
value: item.billNo,
|
|
@@ -15506,7 +16571,7 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
15506
16571
|
disabled: disabled,
|
|
15507
16572
|
allowClear: false,
|
|
15508
16573
|
options: reasonList,
|
|
15509
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
16574
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type31 = typeMap$1[type]) === null || _typeMap$type31 === void 0 ? void 0 : _typeMap$type31.typeName)],
|
|
15510
16575
|
onChange: function onChange(val) {
|
|
15511
16576
|
return changeTypeHandle(val);
|
|
15512
16577
|
}
|
|
@@ -15518,7 +16583,7 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
15518
16583
|
canUpdateNumber: showChangeBtn,
|
|
15519
16584
|
showChangeBtn: showChangeBtn,
|
|
15520
16585
|
shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
|
|
15521
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
16586
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type32 = typeMap$1[type]) === null || _typeMap$type32 === void 0 ? void 0 : _typeMap$type32.key)],
|
|
15522
16587
|
onChange: function onChange(val) {
|
|
15523
16588
|
return changeGoodHandle(val);
|
|
15524
16589
|
},
|
|
@@ -16217,16 +17282,6 @@ var CommonSystemOrder$1 = function CommonSystemOrder(props) {
|
|
|
16217
17282
|
};
|
|
16218
17283
|
|
|
16219
17284
|
var _excluded$j = ["value", "onChange", "disabled", "failValue", "type"];
|
|
16220
|
-
var msgTypeCh = {
|
|
16221
|
-
pdd: '拼多多',
|
|
16222
|
-
ding: '钉钉',
|
|
16223
|
-
wechat: '微信',
|
|
16224
|
-
qq: 'QQ',
|
|
16225
|
-
qywx: '企业微信',
|
|
16226
|
-
YZDKH: '邮政拦截',
|
|
16227
|
-
YT: '圆通拦截',
|
|
16228
|
-
feishu: '飞书'
|
|
16229
|
-
};
|
|
16230
17285
|
var MsgStatus = function MsgStatus(props) {
|
|
16231
17286
|
var _value$changeIndex, _value$changeIndex2, _value$changeIndex3;
|
|
16232
17287
|
var _props$value = props.value,
|
|
@@ -16316,7 +17371,7 @@ var typeMap$2 = {
|
|
|
16316
17371
|
}
|
|
16317
17372
|
};
|
|
16318
17373
|
var bsE3Reissue = function bsE3Reissue(props) {
|
|
16319
|
-
var _typeMap$type21, _typeMap$
|
|
17374
|
+
var _typeMap$type21, _typeMap$type24, _typeMap$type25, _value$typeMap$type$s5, _typeMap$type26, _typeMap$type27, _typeMap$type28;
|
|
16320
17375
|
var value = props.value,
|
|
16321
17376
|
onChange = props.onChange,
|
|
16322
17377
|
_props$reasonList = props.reasonList,
|
|
@@ -16454,15 +17509,19 @@ var bsE3Reissue = function bsE3Reissue(props) {
|
|
|
16454
17509
|
return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type20 = typeMap$2[type]) === null || _typeMap$type20 === void 0 ? void 0 : _typeMap$type20.systemOrderNo]);
|
|
16455
17510
|
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$type21 = typeMap$2[type]) === null || _typeMap$type21 === void 0 ? void 0 : _typeMap$type21.systemOrderNo]]);
|
|
16456
17511
|
var selectedGoodsChange = useCallback(function (skuList) {
|
|
16457
|
-
var _typeMap$type22,
|
|
17512
|
+
var _typeMap$type22, _typeMap$type23, _uniqBy;
|
|
16458
17513
|
var newValue = _objectSpread2({}, value);
|
|
16459
|
-
|
|
17514
|
+
// 原订单商品
|
|
17515
|
+
var originTradeGoodList = getGoodDetails({
|
|
16460
17516
|
mode: isStrict
|
|
16461
|
-
})
|
|
16462
|
-
|
|
17517
|
+
}) || [];
|
|
17518
|
+
// 当前选中的所有商品【包含了原订单+商品库】
|
|
17519
|
+
var currentSelectGoodList = (value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type22 = typeMap$2[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.key)]) || [];
|
|
17520
|
+
newValue["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type23 = typeMap$2[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.key)] = (_uniqBy = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
|
|
17521
|
+
return skuList.includes(item.uuid);
|
|
16463
17522
|
});
|
|
16464
17523
|
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
16465
|
-
}, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$
|
|
17524
|
+
}, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type24 = typeMap$2[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.key)], isStrict]);
|
|
16466
17525
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
|
|
16467
17526
|
gutter: 8,
|
|
16468
17527
|
wrap: true,
|
|
@@ -16481,12 +17540,12 @@ var bsE3Reissue = function bsE3Reissue(props) {
|
|
|
16481
17540
|
},
|
|
16482
17541
|
disabled: disabled,
|
|
16483
17542
|
allowClear: false,
|
|
16484
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$
|
|
17543
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type25 = typeMap$2[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.systemOrderNo)],
|
|
16485
17544
|
onChange: function onChange(val) {
|
|
16486
17545
|
return changeSystemOrderHandle(val);
|
|
16487
17546
|
},
|
|
16488
17547
|
placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
|
|
16489
|
-
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$
|
|
17548
|
+
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type26 = typeMap$2[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
|
|
16490
17549
|
return /*#__PURE__*/React.createElement(Select.Option, {
|
|
16491
17550
|
key: item.billNo,
|
|
16492
17551
|
value: item.billNo,
|
|
@@ -16507,7 +17566,7 @@ var bsE3Reissue = function bsE3Reissue(props) {
|
|
|
16507
17566
|
disabled: disabled,
|
|
16508
17567
|
allowClear: false,
|
|
16509
17568
|
options: reasonList,
|
|
16510
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$
|
|
17569
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type27 = typeMap$2[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.typeName)],
|
|
16511
17570
|
onChange: function onChange(val) {
|
|
16512
17571
|
return changeTypeHandle(val);
|
|
16513
17572
|
}
|
|
@@ -16519,7 +17578,7 @@ var bsE3Reissue = function bsE3Reissue(props) {
|
|
|
16519
17578
|
canUpdateNumber: showChangeBtn,
|
|
16520
17579
|
showChangeBtn: showChangeBtn,
|
|
16521
17580
|
shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
|
|
16522
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$
|
|
17581
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$2 === null || typeMap$2 === void 0 ? void 0 : (_typeMap$type28 = typeMap$2[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.key)],
|
|
16523
17582
|
onChange: function onChange(val) {
|
|
16524
17583
|
return changeGoodHandle(val);
|
|
16525
17584
|
},
|
|
@@ -16535,4 +17594,253 @@ var bsE3Reissue = function bsE3Reissue(props) {
|
|
|
16535
17594
|
})));
|
|
16536
17595
|
};
|
|
16537
17596
|
|
|
16538
|
-
|
|
17597
|
+
var _excluded$l = ["value", "onChange", "reasonList", "disabled", "type"],
|
|
17598
|
+
_excluded2 = ["billNo", "billType", "billTag", "tradeTagName", "deliveryState"];
|
|
17599
|
+
var typeMap$3 = {
|
|
17600
|
+
GY_REISSUE_GOODS: {
|
|
17601
|
+
key: 'gyReissueGoods',
|
|
17602
|
+
name: '管易',
|
|
17603
|
+
typeName: 'gyReissueType',
|
|
17604
|
+
systemOrder: 'gySystemOrder',
|
|
17605
|
+
systemOrderNo: 'gySystemOrderNo',
|
|
17606
|
+
reissueSelectList: 'gyReissueSelectList',
|
|
17607
|
+
reissueSelectListReturn: 'gyReissueSelectListReturn',
|
|
17608
|
+
reissueDeleteGood: 'gyReissueDeleteGood',
|
|
17609
|
+
changeShopCode: 'gyChangeShopCode',
|
|
17610
|
+
reissueType: 'gyReissueType',
|
|
17611
|
+
formatDefaultField: {
|
|
17612
|
+
money: 'orderPrice',
|
|
17613
|
+
share: 'sharePrice'
|
|
17614
|
+
},
|
|
17615
|
+
getOrderList: gyUtils.getGyOrderListSingleton
|
|
17616
|
+
}
|
|
17617
|
+
};
|
|
17618
|
+
var GyReissue = function GyReissue(props) {
|
|
17619
|
+
var _value$gySystemOrder, _typeMap$type26, _typeMap$type28, _typeMap$type29, _value$typeMap$type$s5, _typeMap$type30, _typeMap$type31, _typeMap$type32;
|
|
17620
|
+
var value = props.value,
|
|
17621
|
+
onChange = props.onChange,
|
|
17622
|
+
_props$reasonList = props.reasonList,
|
|
17623
|
+
reasonList = _props$reasonList === void 0 ? [] : _props$reasonList,
|
|
17624
|
+
disabled = props.disabled,
|
|
17625
|
+
type = props.type,
|
|
17626
|
+
other = _objectWithoutProperties(props, _excluded$l);
|
|
17627
|
+
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) {
|
|
17628
|
+
var _order$platformCode;
|
|
17629
|
+
return order === null || order === void 0 ? void 0 : (_order$platformCode = order.platformCode) === null || _order$platformCode === void 0 ? void 0 : _order$platformCode.includes(';');
|
|
17630
|
+
});
|
|
17631
|
+
var getOrderFlag = useRef(false);
|
|
17632
|
+
var _useState = useState(false),
|
|
17633
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
17634
|
+
isStrict = _useState2[0],
|
|
17635
|
+
setIsStrict = _useState2[1];
|
|
17636
|
+
useEffect(function () {
|
|
17637
|
+
var _value$typeMap$type$s, _value$typeMap$type$s2, _typeMap$type, _value$typeMap$type$s3, _typeMap$type2;
|
|
17638
|
+
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)) {
|
|
17639
|
+
var _value$typeMap$type$s4, _typeMap$type3;
|
|
17640
|
+
getOrderFlag.current = true;
|
|
17641
|
+
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);
|
|
17642
|
+
}
|
|
17643
|
+
return;
|
|
17644
|
+
}, [value]);
|
|
17645
|
+
var getOrderList = /*#__PURE__*/function () {
|
|
17646
|
+
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderNo) {
|
|
17647
|
+
var _typeMap$type4;
|
|
17648
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
17649
|
+
while (1) switch (_context.prev = _context.next) {
|
|
17650
|
+
case 0:
|
|
17651
|
+
(_typeMap$type4 = typeMap$3[type]) === null || _typeMap$type4 === void 0 ? void 0 : _typeMap$type4.getOrderList(orderNo).then(function (data) {
|
|
17652
|
+
var _typeMap$type5, _typeMap$type6;
|
|
17653
|
+
var orders = (data === null || data === void 0 ? void 0 : data.trades) || [];
|
|
17654
|
+
var showOrderInfo = orders.map(function (_ref2) {
|
|
17655
|
+
var billNo = _ref2.billNo,
|
|
17656
|
+
billType = _ref2.billType,
|
|
17657
|
+
billTag = _ref2.billTag,
|
|
17658
|
+
tradeTagName = _ref2.tradeTagName,
|
|
17659
|
+
deliveryState = _ref2.deliveryState,
|
|
17660
|
+
rest = _objectWithoutProperties(_ref2, _excluded2);
|
|
17661
|
+
return _objectSpread2(_objectSpread2({}, rest), {}, {
|
|
17662
|
+
billNo: billNo,
|
|
17663
|
+
billType: billType,
|
|
17664
|
+
billTag: billTag,
|
|
17665
|
+
tradeTagName: tradeTagName,
|
|
17666
|
+
deliveryState: deliveryState,
|
|
17667
|
+
deliveryStateName: GY_DELIVERY_STATE_MAPPING[deliveryState]
|
|
17668
|
+
});
|
|
17669
|
+
});
|
|
17670
|
+
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]), {}, {
|
|
17671
|
+
showOrderInfo: showOrderInfo,
|
|
17672
|
+
orders: orders
|
|
17673
|
+
}))));
|
|
17674
|
+
});
|
|
17675
|
+
case 1:
|
|
17676
|
+
case "end":
|
|
17677
|
+
return _context.stop();
|
|
17678
|
+
}
|
|
17679
|
+
}, _callee);
|
|
17680
|
+
}));
|
|
17681
|
+
return function getOrderList(_x) {
|
|
17682
|
+
return _ref.apply(this, arguments);
|
|
17683
|
+
};
|
|
17684
|
+
}();
|
|
17685
|
+
var changeTypeHandle = function changeTypeHandle(val) {
|
|
17686
|
+
var _value$typeMap$type$t, _typeMap$type7, _typeMap$type8;
|
|
17687
|
+
var typeName = val === null || val === void 0 ? void 0 : val[0];
|
|
17688
|
+
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;
|
|
17689
|
+
// const systemOrderNo = value?.[typeMap[type]?.systemOrderNo];
|
|
17690
|
+
var newValue = _objectSpread2({}, value);
|
|
17691
|
+
newValue[(_typeMap$type8 = typeMap$3[type]) === null || _typeMap$type8 === void 0 ? void 0 : _typeMap$type8.typeName] = val;
|
|
17692
|
+
if (typeName === '1') {
|
|
17693
|
+
var _typeMap$type9;
|
|
17694
|
+
newValue[(_typeMap$type9 = typeMap$3[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.key] = getGoodDetails({
|
|
17695
|
+
mode: isStrict
|
|
17696
|
+
});
|
|
17697
|
+
} else if (typeName === '2') {
|
|
17698
|
+
var _typeMap$type10;
|
|
17699
|
+
// 切换到非原单,清空列表
|
|
17700
|
+
newValue[(_typeMap$type10 = typeMap$3[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.key] = [];
|
|
17701
|
+
}
|
|
17702
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
17703
|
+
};
|
|
17704
|
+
var handleModeChange = function handleModeChange(mode) {
|
|
17705
|
+
var _value$typeMap$type$t2, _typeMap$type11, _typeMap$type12;
|
|
17706
|
+
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';
|
|
17707
|
+
setIsStrict(mode);
|
|
17708
|
+
if (!isOriginalOrder) return;
|
|
17709
|
+
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({
|
|
17710
|
+
mode: mode
|
|
17711
|
+
}))));
|
|
17712
|
+
};
|
|
17713
|
+
var getGoodDetails = function getGoodDetails(_ref3) {
|
|
17714
|
+
var _typeMap$type13, _typeMap$type14, _order$details;
|
|
17715
|
+
var mode = _ref3.mode,
|
|
17716
|
+
sysOrderNo = _ref3.sysOrderNo;
|
|
17717
|
+
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];
|
|
17718
|
+
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];
|
|
17719
|
+
var order = systemOrderNo && ((systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orders) || []).find(function (order) {
|
|
17720
|
+
return order.code === systemOrderNo;
|
|
17721
|
+
});
|
|
17722
|
+
var goodDetails = (order === null || order === void 0 ? void 0 : (_order$details = order.details) === null || _order$details === void 0 ? void 0 : _order$details.length) ? updateGyGoodsHandle([order]) : [];
|
|
17723
|
+
var orderNo = systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orderNo;
|
|
17724
|
+
return mode ? goodDetails.filter(function (goodItem) {
|
|
17725
|
+
return !orderNo || (orderNo || '').includes(goodItem.oid);
|
|
17726
|
+
}) : goodDetails;
|
|
17727
|
+
};
|
|
17728
|
+
var changeGoodHandle = function changeGoodHandle(val) {
|
|
17729
|
+
var _typeMap$type15;
|
|
17730
|
+
var newValue = _objectSpread2({}, value);
|
|
17731
|
+
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) {
|
|
17732
|
+
var _typeMap$type16, _typeMap$type17;
|
|
17733
|
+
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;
|
|
17734
|
+
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;
|
|
17735
|
+
return item;
|
|
17736
|
+
});
|
|
17737
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
17738
|
+
};
|
|
17739
|
+
var changeSystemOrderHandle = function changeSystemOrderHandle(val) {
|
|
17740
|
+
var _typeMap$type18, _value$typeMap$type$t3, _typeMap$type19, _value$typeMap$type$t4, _typeMap$type21;
|
|
17741
|
+
var newValue = _objectSpread2({}, value);
|
|
17742
|
+
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;
|
|
17743
|
+
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])) {
|
|
17744
|
+
var _typeMap$type20;
|
|
17745
|
+
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)] = [];
|
|
17746
|
+
} 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])) {
|
|
17747
|
+
var _typeMap$type22;
|
|
17748
|
+
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({
|
|
17749
|
+
mode: isStrict,
|
|
17750
|
+
sysOrderNo: val
|
|
17751
|
+
});
|
|
17752
|
+
}
|
|
17753
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
17754
|
+
};
|
|
17755
|
+
var selectedGoodsChange = useCallback(function (skuList) {
|
|
17756
|
+
var _typeMap$type23, _typeMap$type24, _uniqBy, _typeMap$type25;
|
|
17757
|
+
var newValue = _objectSpread2({}, value);
|
|
17758
|
+
// 原订单商品
|
|
17759
|
+
var originTradeGoodList = getGoodDetails({
|
|
17760
|
+
mode: isStrict
|
|
17761
|
+
}) || [];
|
|
17762
|
+
// 当前选中的所有商品【包含了原订单+商品库】
|
|
17763
|
+
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)]) || [];
|
|
17764
|
+
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 = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
|
|
17765
|
+
return skuList.includes(item.uuid);
|
|
17766
|
+
});
|
|
17767
|
+
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)]);
|
|
17768
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
17769
|
+
}, [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]);
|
|
17770
|
+
//显示选择商品按钮 原单换不显示选择商品
|
|
17771
|
+
var showChangeBtn = useMemo(function () {
|
|
17772
|
+
var _typeMap$type27;
|
|
17773
|
+
return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type27 = typeMap$3[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrderNo]);
|
|
17774
|
+
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$type28 = typeMap$3[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.systemOrderNo]]);
|
|
17775
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
|
|
17776
|
+
gutter: 8,
|
|
17777
|
+
wrap: true
|
|
17778
|
+
}, /*#__PURE__*/React.createElement(Col, {
|
|
17779
|
+
className: "gutter-row",
|
|
17780
|
+
xs: {
|
|
17781
|
+
span: 11
|
|
17782
|
+
},
|
|
17783
|
+
sm: {
|
|
17784
|
+
span: 6
|
|
17785
|
+
}
|
|
17786
|
+
}, /*#__PURE__*/React.createElement(Select, {
|
|
17787
|
+
style: {
|
|
17788
|
+
marginBottom: '8px'
|
|
17789
|
+
},
|
|
17790
|
+
disabled: disabled,
|
|
17791
|
+
allowClear: false,
|
|
17792
|
+
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)],
|
|
17793
|
+
onChange: function onChange(val) {
|
|
17794
|
+
return changeSystemOrderHandle(val);
|
|
17795
|
+
},
|
|
17796
|
+
placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
|
|
17797
|
+
}, ((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) {
|
|
17798
|
+
return /*#__PURE__*/React.createElement(Select.Option, {
|
|
17799
|
+
key: item.billNo,
|
|
17800
|
+
value: item.billNo,
|
|
17801
|
+
label: item.billNo
|
|
17802
|
+
}, item.billNo);
|
|
17803
|
+
}))), /*#__PURE__*/React.createElement(Col, {
|
|
17804
|
+
className: "gutter-row",
|
|
17805
|
+
xs: {
|
|
17806
|
+
span: 11
|
|
17807
|
+
},
|
|
17808
|
+
sm: {
|
|
17809
|
+
span: 6
|
|
17810
|
+
}
|
|
17811
|
+
}, /*#__PURE__*/React.createElement(Cascader, {
|
|
17812
|
+
style: {
|
|
17813
|
+
marginBottom: '8px'
|
|
17814
|
+
},
|
|
17815
|
+
disabled: disabled,
|
|
17816
|
+
allowClear: false,
|
|
17817
|
+
options: reasonList,
|
|
17818
|
+
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)],
|
|
17819
|
+
onChange: function onChange(val) {
|
|
17820
|
+
return changeTypeHandle(val);
|
|
17821
|
+
}
|
|
17822
|
+
}))), /*#__PURE__*/React.createElement(GoodItem$1, _objectSpread2(_objectSpread2({
|
|
17823
|
+
key: 'reissueGoods'
|
|
17824
|
+
}, other), {}, {
|
|
17825
|
+
type: type,
|
|
17826
|
+
disabled: disabled,
|
|
17827
|
+
canUpdateNumber: showChangeBtn,
|
|
17828
|
+
showChangeBtn: showChangeBtn,
|
|
17829
|
+
shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
|
|
17830
|
+
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)],
|
|
17831
|
+
onChange: function onChange(val) {
|
|
17832
|
+
return changeGoodHandle(val);
|
|
17833
|
+
},
|
|
17834
|
+
onModeChange: handleModeChange,
|
|
17835
|
+
showModeBtn: showModeBtn,
|
|
17836
|
+
isStrict: isStrict,
|
|
17837
|
+
tradeGoods: {
|
|
17838
|
+
originDataSource: getGoodDetails({
|
|
17839
|
+
mode: isStrict
|
|
17840
|
+
}),
|
|
17841
|
+
selectedGoodsChange: selectedGoodsChange
|
|
17842
|
+
}
|
|
17843
|
+
})));
|
|
17844
|
+
};
|
|
17845
|
+
|
|
17846
|
+
export { ApaasAddress as Address, AliPay, Province as ApaasAddress, ApaasCascader, ApaasCheckbox, ApaasDate, withFormItem as ApaasHoc, ApaasInput, ApaasInputNumber, ApaasLogistics, ApaasMultipleSelect, ApaasPosting, ApaasRadio, ApaasRate, ApaasSelect, ApaasSlider, ApaasTextArea, ApaasUpload, index as ApaasUploadAsync, ApaasUploadFile, bsE3Reissue as BsE3Reissue, BsExchange, BsGoods, BsReissue, BsReturnGoods as BsReturn, index$1 as BsSystemOrder, BuyerNick, CalculationInput, ChooseBaby, CommonExchangeGoods, CommonGoods, CommonSystemOrder$1 as CommonMultiStatus, CommonReturnGoods, CommonStatus, CommonSystemOrder, ExpressLogistics, Goods, index$2 as GoodsTable, GyReissue, IdentifyAddress, Invoice, jstGoods as JstGoods, ItemList as JstItemList, LogisticsInterception, LogisticsMoreInterception, LogisticsMoreTrajectory, LogisticsTrajectory, MsgStatus, ParseLogistics, Payment, RemarkInput as Remark, ExpressLogistics as ReturnLogistics, ShopNameSelect as ShopName, Status, SubForm, Supplier, TBGoodId, TBGoodSerial, TradeId, WdtGoodList, wdtReissue as WdtReissue, WlnGoods, columnsBaseInfoMap };
|