@kmkf-fe-packages/basic-components 1.17.8-beta.3 → 1.17.8-beta.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +1402 -643
- package/dist/index.js +1400 -641
- package/dist/src/bs/component/GoodItem/index.d.ts +3 -0
- package/dist/src/bs/component/model/BsE3GoodList.d.ts +32 -0
- package/dist/src/bs/component/model/BsE3GoodsModal.d.ts +12 -0
- package/dist/src/wdt/common/index.d.ts +3 -0
- package/package.json +3 -3
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, WdtSendData, WDT_ORDER_TYPE_MAP } from '@kmkf-fe-packages/kmkf-utils';
|
|
7
|
-
import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, cloneDeep, difference, differenceWith, takeRight } from 'lodash';
|
|
6
|
+
import { AddressData, BsAddressData, WdtAddressData, request as request$1, ExpressData, uuid, LogisticsAddressData, WdtSendData, filterWdtOrders, WDT_ORDER_TYPE_MAP, updateWdtGoodsHandle } from '@kmkf-fe-packages/kmkf-utils';
|
|
7
|
+
import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, cloneDeep, difference, differenceWith, takeRight, reject } 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
|
|
64
|
-
};
|
|
65
|
-
var
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
t[e] = r.value;
|
|
63
|
+
return exports;
|
|
64
|
+
};
|
|
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({
|
|
@@ -7520,7 +7520,9 @@ var IdentifyAddress = function IdentifyAddress(props) {
|
|
|
7520
7520
|
onChange: function onChange(e) {
|
|
7521
7521
|
return changeHandle(e.target.value, 'receiverMobile');
|
|
7522
7522
|
}
|
|
7523
|
-
})), /*#__PURE__*/React.createElement(Space,
|
|
7523
|
+
})), /*#__PURE__*/React.createElement(Space, {
|
|
7524
|
+
wrap: true
|
|
7525
|
+
}, /*#__PURE__*/React.createElement(Province, {
|
|
7524
7526
|
value: value.address,
|
|
7525
7527
|
onChange: function onChange(val) {
|
|
7526
7528
|
return changeHandle(val, 'address');
|
|
@@ -11682,9 +11684,11 @@ var GoodsModal$1 = function GoodsModal(props, ref) {
|
|
|
11682
11684
|
var GoodsModal$2 = /*#__PURE__*/forwardRef(GoodsModal$1);
|
|
11683
11685
|
|
|
11684
11686
|
var getTableData = function getTableData(_ref, formData) {
|
|
11687
|
+
var _formData$brandIds;
|
|
11685
11688
|
var current = _ref.current,
|
|
11686
11689
|
pageSize = _ref.pageSize;
|
|
11687
11690
|
var data = {
|
|
11691
|
+
brandIds: ((_formData$brandIds = formData.brandIds) === null || _formData$brandIds === void 0 ? void 0 : _formData$brandIds.length) ? formData.brandIds : null,
|
|
11688
11692
|
skuCode: formData.skuCode || null,
|
|
11689
11693
|
skuName: formData.skuName || null,
|
|
11690
11694
|
goodName: formData.goodName || null,
|
|
@@ -11769,6 +11773,11 @@ var columns$1 = [{
|
|
|
11769
11773
|
title: '商品ID',
|
|
11770
11774
|
width: 200,
|
|
11771
11775
|
ellipsis: true
|
|
11776
|
+
}, {
|
|
11777
|
+
dataIndex: 'brandName',
|
|
11778
|
+
title: '品牌名称',
|
|
11779
|
+
width: 200,
|
|
11780
|
+
ellipsis: true
|
|
11772
11781
|
}, {
|
|
11773
11782
|
dataIndex: 'marketPrice',
|
|
11774
11783
|
title: '市场价',
|
|
@@ -11800,6 +11809,10 @@ var GoodList = function GoodList(props, ref) {
|
|
|
11800
11809
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
11801
11810
|
selectIds = _useState4[0],
|
|
11802
11811
|
setSelectIds = _useState4[1];
|
|
11812
|
+
var _useState5 = useState([]),
|
|
11813
|
+
_useState6 = _slicedToArray(_useState5, 2),
|
|
11814
|
+
brandList = _useState6[0],
|
|
11815
|
+
setBrandList = _useState6[1];
|
|
11803
11816
|
useImperativeHandle(ref, function () {
|
|
11804
11817
|
return {
|
|
11805
11818
|
getSelectGoodList: function getSelectGoodList() {
|
|
@@ -11819,6 +11832,38 @@ var GoodList = function GoodList(props, ref) {
|
|
|
11819
11832
|
params = _useAntdTable.params;
|
|
11820
11833
|
var submit = search.submit,
|
|
11821
11834
|
reset = search.reset;
|
|
11835
|
+
var setGoodBrandList = function setGoodBrandList() {
|
|
11836
|
+
var list = [];
|
|
11837
|
+
var pageNo = 0;
|
|
11838
|
+
var pageSize = 100;
|
|
11839
|
+
var getMore = function getMore() {
|
|
11840
|
+
extendRequest('/qy/gdfw/wdt/erp/goodBrand/list', {
|
|
11841
|
+
method: 'post',
|
|
11842
|
+
data: {
|
|
11843
|
+
pageSize: pageSize,
|
|
11844
|
+
pageNo: pageNo
|
|
11845
|
+
}
|
|
11846
|
+
}).then(function (res) {
|
|
11847
|
+
var _res$data2;
|
|
11848
|
+
if (res.success && (res === null || res === void 0 ? void 0 : (_res$data2 = res.data) === null || _res$data2 === void 0 ? void 0 : _res$data2.detailList)) {
|
|
11849
|
+
var _res$data3, _res$data4;
|
|
11850
|
+
list.push.apply(list, _toConsumableArray((res === null || res === void 0 ? void 0 : (_res$data3 = res.data) === null || _res$data3 === void 0 ? void 0 : _res$data3.detailList) || []));
|
|
11851
|
+
if ((res === null || res === void 0 ? void 0 : (_res$data4 = res.data) === null || _res$data4 === void 0 ? void 0 : _res$data4.detailList.length) === pageSize) {
|
|
11852
|
+
pageNo += 1;
|
|
11853
|
+
getMore();
|
|
11854
|
+
} else {
|
|
11855
|
+
setBrandList(list);
|
|
11856
|
+
}
|
|
11857
|
+
} else {
|
|
11858
|
+
reject(res);
|
|
11859
|
+
}
|
|
11860
|
+
}).catch(console.error);
|
|
11861
|
+
};
|
|
11862
|
+
getMore();
|
|
11863
|
+
};
|
|
11864
|
+
React.useEffect(function () {
|
|
11865
|
+
setGoodBrandList();
|
|
11866
|
+
}, []);
|
|
11822
11867
|
var advanceSearchForm = /*#__PURE__*/React.createElement(Form, {
|
|
11823
11868
|
layout: "inline",
|
|
11824
11869
|
form: form
|
|
@@ -11866,6 +11911,29 @@ var GoodList = function GoodList(props, ref) {
|
|
|
11866
11911
|
style: {
|
|
11867
11912
|
width: 150
|
|
11868
11913
|
}
|
|
11914
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
11915
|
+
name: "brandIds",
|
|
11916
|
+
style: {
|
|
11917
|
+
marginBottom: '12px'
|
|
11918
|
+
}
|
|
11919
|
+
}, /*#__PURE__*/React.createElement(Select, {
|
|
11920
|
+
mode: "multiple",
|
|
11921
|
+
showSearch: true,
|
|
11922
|
+
allowClear: true,
|
|
11923
|
+
style: {
|
|
11924
|
+
width: 150
|
|
11925
|
+
},
|
|
11926
|
+
placeholder: "\u54C1\u724C",
|
|
11927
|
+
options: brandList.filter(function (item) {
|
|
11928
|
+
return !item.isDisabled;
|
|
11929
|
+
}).map(function (_ref2) {
|
|
11930
|
+
var value = _ref2.brandId,
|
|
11931
|
+
label = _ref2.brandName;
|
|
11932
|
+
return {
|
|
11933
|
+
value: value,
|
|
11934
|
+
label: label
|
|
11935
|
+
};
|
|
11936
|
+
})
|
|
11869
11937
|
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
11870
11938
|
style: {
|
|
11871
11939
|
marginBottom: '12px'
|
|
@@ -12022,115 +12090,516 @@ var GoodsModal$3 = function GoodsModal(props, ref) {
|
|
|
12022
12090
|
};
|
|
12023
12091
|
var WdtGoodsModal = /*#__PURE__*/forwardRef(GoodsModal$3);
|
|
12024
12092
|
|
|
12025
|
-
|
|
12026
|
-
|
|
12027
|
-
|
|
12028
|
-
|
|
12029
|
-
|
|
12030
|
-
|
|
12031
|
-
|
|
12032
|
-
|
|
12033
|
-
var _props$value = props.value,
|
|
12034
|
-
value = _props$value === void 0 ? [] : _props$value,
|
|
12035
|
-
type = props.type,
|
|
12036
|
-
onChange = props.onChange,
|
|
12037
|
-
disabled = props.disabled,
|
|
12038
|
-
_props$showHeader = props.showHeader,
|
|
12039
|
-
showHeader = _props$showHeader === void 0 ? [] : _props$showHeader,
|
|
12040
|
-
width = props.width,
|
|
12041
|
-
_props$shopList = props.shopList,
|
|
12042
|
-
shopList = _props$shopList === void 0 ? [] : _props$shopList,
|
|
12043
|
-
_props$shopId = props.shopId,
|
|
12044
|
-
shopId = _props$shopId === void 0 ? '' : _props$shopId,
|
|
12045
|
-
_props$maxLength = props.maxLength,
|
|
12046
|
-
maxLength = _props$maxLength === void 0 ? 20 : _props$maxLength,
|
|
12047
|
-
_props$showChangeBtn = props.showChangeBtn,
|
|
12048
|
-
showChangeBtn = _props$showChangeBtn === void 0 ? true : _props$showChangeBtn,
|
|
12049
|
-
_props$tableSelect = props.tableSelect,
|
|
12050
|
-
tableSelect = _props$tableSelect === void 0 ? false : _props$tableSelect,
|
|
12051
|
-
_props$selectType = props.selectType,
|
|
12052
|
-
selectType = _props$selectType === void 0 ? '' : _props$selectType,
|
|
12053
|
-
_props$otherOperation = props.otherOperations,
|
|
12054
|
-
otherOperations = _props$otherOperation === void 0 ? null : _props$otherOperation,
|
|
12055
|
-
_props$canUpdateNumbe = props.canUpdateNumber,
|
|
12056
|
-
canUpdateNumber = _props$canUpdateNumbe === void 0 ? false : _props$canUpdateNumbe,
|
|
12057
|
-
shopCode = props.shopCode,
|
|
12058
|
-
_props$companyKey = props.companyKey,
|
|
12059
|
-
companyKey = _props$companyKey === void 0 ? '' : _props$companyKey,
|
|
12060
|
-
onSelect = props.onSelect,
|
|
12061
|
-
onDelete = props.onDelete;
|
|
12062
|
-
var refModal = useRef();
|
|
12063
|
-
var handleDelete = function handleDelete(record, index) {
|
|
12064
|
-
onDelete === null || onDelete === void 0 ? void 0 : onDelete(value[index]);
|
|
12065
|
-
var newList = _toConsumableArray(value).filter(function (item, i) {
|
|
12066
|
-
return index !== i;
|
|
12067
|
-
});
|
|
12068
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(_toConsumableArray(newList));
|
|
12093
|
+
var getTableData$1 = function getTableData(_ref, formData) {
|
|
12094
|
+
var current = _ref.current,
|
|
12095
|
+
pageSize = _ref.pageSize;
|
|
12096
|
+
var data = {
|
|
12097
|
+
goodsSn: formData.goodsSn || null,
|
|
12098
|
+
goodsName: formData.goodsName || null,
|
|
12099
|
+
sku: formData.sku || null,
|
|
12100
|
+
skuId: formData.skuId || null
|
|
12069
12101
|
};
|
|
12102
|
+
return extendRequest('/qy/gdfw/product/product/page', {
|
|
12103
|
+
method: 'post',
|
|
12104
|
+
data: _objectSpread2({
|
|
12105
|
+
pageSize: pageSize,
|
|
12106
|
+
pageNo: current,
|
|
12107
|
+
platform: 'WDT_ERP'
|
|
12108
|
+
}, data)
|
|
12109
|
+
}).then(function (res) {
|
|
12110
|
+
var _res$data = res.data,
|
|
12111
|
+
_res$data$productSkuL = _res$data.productSkuList,
|
|
12112
|
+
productSkuList = _res$data$productSkuL === void 0 ? [] : _res$data$productSkuL,
|
|
12113
|
+
_res$data$total = _res$data.total,
|
|
12114
|
+
total = _res$data$total === void 0 ? 0 : _res$data$total;
|
|
12115
|
+
var newProducts = productSkuList.map(function (item, index) {
|
|
12116
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
12117
|
+
index: index + 1
|
|
12118
|
+
});
|
|
12119
|
+
});
|
|
12120
|
+
return {
|
|
12121
|
+
total: total,
|
|
12122
|
+
list: newProducts
|
|
12123
|
+
};
|
|
12124
|
+
});
|
|
12125
|
+
};
|
|
12126
|
+
var columns$2 = [{
|
|
12127
|
+
dataIndex: 'index',
|
|
12128
|
+
title: 'NO',
|
|
12129
|
+
render: function render(val, record, index) {
|
|
12130
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
12131
|
+
style: {
|
|
12132
|
+
width: 25
|
|
12133
|
+
}
|
|
12134
|
+
}, index + 1);
|
|
12135
|
+
},
|
|
12136
|
+
width: 100
|
|
12137
|
+
}, {
|
|
12138
|
+
dataIndex: 'sku',
|
|
12139
|
+
title: "SKU",
|
|
12140
|
+
ellipsis: true,
|
|
12141
|
+
width: 70
|
|
12142
|
+
}, {
|
|
12143
|
+
dataIndex: 'skuId',
|
|
12144
|
+
title: "SKU ID",
|
|
12145
|
+
ellipsis: true,
|
|
12146
|
+
width: 70
|
|
12147
|
+
}, {
|
|
12148
|
+
dataIndex: 'goodsName',
|
|
12149
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
12150
|
+
ellipsis: true,
|
|
12151
|
+
width: 70
|
|
12152
|
+
}, {
|
|
12153
|
+
dataIndex: 'goodsSname',
|
|
12154
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12155
|
+
ellipsis: true,
|
|
12156
|
+
width: 70
|
|
12157
|
+
}, {
|
|
12158
|
+
dataIndex: 'picPath',
|
|
12159
|
+
title: "\u5546\u54C1\u56FE\u7247",
|
|
12160
|
+
ellipsis: true,
|
|
12161
|
+
width: 100,
|
|
12162
|
+
render: function render(picUrl) {
|
|
12163
|
+
return /*#__PURE__*/React.createElement("img", {
|
|
12164
|
+
style: {
|
|
12165
|
+
width: '40px',
|
|
12166
|
+
height: '40px',
|
|
12167
|
+
objectFit: 'contain'
|
|
12168
|
+
},
|
|
12169
|
+
src: picUrl
|
|
12170
|
+
});
|
|
12171
|
+
}
|
|
12172
|
+
}, {
|
|
12173
|
+
dataIndex: 'goodsSn',
|
|
12174
|
+
title: "\u8D27\u53F7",
|
|
12175
|
+
ellipsis: true,
|
|
12176
|
+
width: 70
|
|
12177
|
+
}, {
|
|
12178
|
+
dataIndex: 'goodsId',
|
|
12179
|
+
title: "\u8D27\u53F7ID",
|
|
12180
|
+
ellipsis: true,
|
|
12181
|
+
width: 70
|
|
12182
|
+
}, {
|
|
12183
|
+
dataIndex: 'colorName',
|
|
12184
|
+
title: "\u989C\u8272\u540D\u79F0",
|
|
12185
|
+
ellipsis: true,
|
|
12186
|
+
width: 70
|
|
12187
|
+
}, {
|
|
12188
|
+
dataIndex: 'colorCode',
|
|
12189
|
+
title: "\u989C\u8272\u4EE3\u7801",
|
|
12190
|
+
ellipsis: true,
|
|
12191
|
+
width: 70
|
|
12192
|
+
}, {
|
|
12193
|
+
dataIndex: 'sizeName',
|
|
12194
|
+
title: "\u5C3A\u7801\u540D\u79F0",
|
|
12195
|
+
ellipsis: true,
|
|
12196
|
+
width: 70
|
|
12197
|
+
}, {
|
|
12198
|
+
dataIndex: 'sizeCode',
|
|
12199
|
+
title: "\u5C3A\u7801\u4EE3\u7801",
|
|
12200
|
+
ellipsis: true,
|
|
12201
|
+
width: 70
|
|
12202
|
+
}, {
|
|
12203
|
+
dataIndex: 'brandName',
|
|
12204
|
+
title: "\u54C1\u724C\u540D\u79F0",
|
|
12205
|
+
ellipsis: true,
|
|
12206
|
+
width: 70
|
|
12207
|
+
}, {
|
|
12208
|
+
dataIndex: 'goodsNumber',
|
|
12209
|
+
title: "\u5546\u54C1\u6570\u91CF",
|
|
12210
|
+
ellipsis: true,
|
|
12211
|
+
width: 70
|
|
12212
|
+
}, {
|
|
12213
|
+
dataIndex: 'goodsPrice',
|
|
12214
|
+
title: "\u5546\u54C1\u5355\u4EF7",
|
|
12215
|
+
ellipsis: true,
|
|
12216
|
+
width: 70
|
|
12217
|
+
}, {
|
|
12218
|
+
dataIndex: 'shopPrice',
|
|
12219
|
+
title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
|
|
12220
|
+
ellipsis: true,
|
|
12221
|
+
width: 70
|
|
12222
|
+
}, {
|
|
12223
|
+
dataIndex: 'sharePrice',
|
|
12224
|
+
title: "\u5206\u644A\u4EF7",
|
|
12225
|
+
ellipsis: true,
|
|
12226
|
+
width: 70
|
|
12227
|
+
}, {
|
|
12228
|
+
dataIndex: 'sharePayment',
|
|
12229
|
+
title: "\u5206\u644A\u5B9E\u4ED8\u91D1\u989D",
|
|
12230
|
+
ellipsis: true,
|
|
12231
|
+
width: 70
|
|
12232
|
+
}, {
|
|
12233
|
+
dataIndex: 'payment',
|
|
12234
|
+
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
12235
|
+
ellipsis: true,
|
|
12236
|
+
width: 70
|
|
12237
|
+
}, {
|
|
12238
|
+
dataIndex: 'tcSku',
|
|
12239
|
+
title: "\u5957\u9910SKU",
|
|
12240
|
+
ellipsis: true,
|
|
12241
|
+
width: 70
|
|
12242
|
+
}, {
|
|
12243
|
+
dataIndex: 'tcGoodsNumber',
|
|
12244
|
+
title: "\u5957\u9910\u5957\u6570",
|
|
12245
|
+
ellipsis: true,
|
|
12246
|
+
width: 70
|
|
12247
|
+
}, {
|
|
12248
|
+
dataIndex: 'taocanSingleSl',
|
|
12249
|
+
title: "\u5355\u4E2A\u5957\u9910\u6570\u91CF",
|
|
12250
|
+
ellipsis: true,
|
|
12251
|
+
width: 70
|
|
12252
|
+
}, {
|
|
12253
|
+
dataIndex: 'isGift',
|
|
12254
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
12255
|
+
ellipsis: true,
|
|
12256
|
+
width: 70
|
|
12257
|
+
}];
|
|
12258
|
+
var GoodList$1 = function GoodList(props, ref) {
|
|
12070
12259
|
var _useState = useState([]),
|
|
12071
12260
|
_useState2 = _slicedToArray(_useState, 2),
|
|
12072
|
-
|
|
12073
|
-
|
|
12074
|
-
|
|
12075
|
-
|
|
12076
|
-
|
|
12077
|
-
|
|
12078
|
-
|
|
12079
|
-
|
|
12080
|
-
|
|
12081
|
-
|
|
12082
|
-
var totalMoney = null;
|
|
12083
|
-
if (columnType === 'num') {
|
|
12084
|
-
totalMoney = new BigNumber(value[index][columnType]).multipliedBy(new BigNumber(value[index].sharePrice));
|
|
12085
|
-
} else {
|
|
12086
|
-
totalMoney = new BigNumber(value[index][columnType]).multipliedBy(new BigNumber(value[index].num));
|
|
12087
|
-
}
|
|
12088
|
-
if (totalMoney !== null) {
|
|
12089
|
-
value[index]['returnPrice'] = totalMoney.toString();
|
|
12090
|
-
}
|
|
12091
|
-
}
|
|
12092
|
-
} else if (type === 'WDT_EXCHANGE_GOODS') {
|
|
12093
|
-
if (['price', 'num'].includes(columnType)) {
|
|
12094
|
-
var _totalMoney = null;
|
|
12095
|
-
if (columnType === 'num') {
|
|
12096
|
-
_totalMoney = new BigNumber(value[index][columnType]).multipliedBy(new BigNumber(value[index].price));
|
|
12097
|
-
} else {
|
|
12098
|
-
_totalMoney = new BigNumber(value[index][columnType]).multipliedBy(new BigNumber(value[index].num));
|
|
12099
|
-
}
|
|
12100
|
-
if (_totalMoney !== null) {
|
|
12101
|
-
value[index]['exchangePrice'] = _totalMoney.toString();
|
|
12102
|
-
}
|
|
12103
|
-
}
|
|
12261
|
+
selectList = _useState2[0],
|
|
12262
|
+
setSelect = _useState2[1];
|
|
12263
|
+
var _useState3 = useState([]),
|
|
12264
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
12265
|
+
selectIds = _useState4[0],
|
|
12266
|
+
setSelectIds = _useState4[1];
|
|
12267
|
+
useImperativeHandle(ref, function () {
|
|
12268
|
+
return {
|
|
12269
|
+
getSelectGoodList: function getSelectGoodList() {
|
|
12270
|
+
return selectList;
|
|
12104
12271
|
}
|
|
12105
|
-
|
|
12272
|
+
};
|
|
12273
|
+
});
|
|
12274
|
+
var _Form$useForm = Form.useForm(),
|
|
12275
|
+
_Form$useForm2 = _slicedToArray(_Form$useForm, 1),
|
|
12276
|
+
form = _Form$useForm2[0];
|
|
12277
|
+
var _useAntdTable = useAntdTable(getTableData$1, {
|
|
12278
|
+
defaultPageSize: 10,
|
|
12279
|
+
form: form
|
|
12280
|
+
}),
|
|
12281
|
+
tableProps = _useAntdTable.tableProps,
|
|
12282
|
+
search = _useAntdTable.search,
|
|
12283
|
+
params = _useAntdTable.params;
|
|
12284
|
+
var submit = search.submit,
|
|
12285
|
+
reset = search.reset;
|
|
12286
|
+
var advanceSearchForm = /*#__PURE__*/React.createElement(Form, {
|
|
12287
|
+
layout: "inline",
|
|
12288
|
+
form: form
|
|
12289
|
+
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
12290
|
+
name: "goodsSn",
|
|
12291
|
+
style: {
|
|
12292
|
+
marginBottom: '12px'
|
|
12106
12293
|
}
|
|
12107
|
-
}
|
|
12108
|
-
|
|
12109
|
-
|
|
12110
|
-
|
|
12111
|
-
|
|
12112
|
-
|
|
12113
|
-
|
|
12114
|
-
|
|
12115
|
-
|
|
12116
|
-
|
|
12117
|
-
|
|
12118
|
-
|
|
12119
|
-
|
|
12120
|
-
|
|
12121
|
-
|
|
12122
|
-
|
|
12123
|
-
|
|
12124
|
-
|
|
12125
|
-
|
|
12126
|
-
|
|
12127
|
-
|
|
12128
|
-
|
|
12129
|
-
|
|
12130
|
-
|
|
12131
|
-
|
|
12132
|
-
|
|
12133
|
-
|
|
12294
|
+
}, /*#__PURE__*/React.createElement(Input, {
|
|
12295
|
+
placeholder: "\u5546\u54C1\u8D27\u53F7",
|
|
12296
|
+
allowClear: true,
|
|
12297
|
+
style: {
|
|
12298
|
+
width: 150
|
|
12299
|
+
}
|
|
12300
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
12301
|
+
name: "goodsName",
|
|
12302
|
+
style: {
|
|
12303
|
+
marginBottom: '12px'
|
|
12304
|
+
}
|
|
12305
|
+
}, /*#__PURE__*/React.createElement(Input, {
|
|
12306
|
+
placeholder: "\u5546\u54C1\u540D\u79F0",
|
|
12307
|
+
allowClear: true,
|
|
12308
|
+
style: {
|
|
12309
|
+
width: 150
|
|
12310
|
+
}
|
|
12311
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
12312
|
+
name: "sku",
|
|
12313
|
+
style: {
|
|
12314
|
+
marginBottom: '12px'
|
|
12315
|
+
}
|
|
12316
|
+
}, /*#__PURE__*/React.createElement(Input, {
|
|
12317
|
+
placeholder: "SKU",
|
|
12318
|
+
allowClear: true,
|
|
12319
|
+
style: {
|
|
12320
|
+
width: 150
|
|
12321
|
+
}
|
|
12322
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
12323
|
+
name: "skuId",
|
|
12324
|
+
style: {
|
|
12325
|
+
marginBottom: '12px'
|
|
12326
|
+
}
|
|
12327
|
+
}, /*#__PURE__*/React.createElement(Input, {
|
|
12328
|
+
placeholder: "SKU ID",
|
|
12329
|
+
allowClear: true,
|
|
12330
|
+
style: {
|
|
12331
|
+
width: 150
|
|
12332
|
+
}
|
|
12333
|
+
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
12334
|
+
style: {
|
|
12335
|
+
marginBottom: '12px'
|
|
12336
|
+
}
|
|
12337
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
12338
|
+
type: "primary",
|
|
12339
|
+
style: {
|
|
12340
|
+
marginRight: '8px'
|
|
12341
|
+
},
|
|
12342
|
+
onClick: submit
|
|
12343
|
+
}, "\u67E5\u8BE2"), /*#__PURE__*/React.createElement(Button, {
|
|
12344
|
+
onClick: reset
|
|
12345
|
+
}, "\u91CD\u7F6E")));
|
|
12346
|
+
var rowSelection = {
|
|
12347
|
+
selectedRowKeys: selectIds,
|
|
12348
|
+
fixed: true,
|
|
12349
|
+
onSelect: function onSelect(record, selected) {
|
|
12350
|
+
if (selected) {
|
|
12351
|
+
setSelectIds([].concat(_toConsumableArray(selectIds), [record.specNo]));
|
|
12352
|
+
setSelect([].concat(_toConsumableArray(selectList), [record]));
|
|
12353
|
+
} else {
|
|
12354
|
+
setSelectIds(selectIds.filter(function (t) {
|
|
12355
|
+
return t !== record.specNo;
|
|
12356
|
+
}));
|
|
12357
|
+
setSelect(selectList.filter(function (t) {
|
|
12358
|
+
return t.specNo !== record.specNo;
|
|
12359
|
+
}));
|
|
12360
|
+
}
|
|
12361
|
+
},
|
|
12362
|
+
onSelectAll: function onSelectAll(selected, selectedRows, changeRows) {
|
|
12363
|
+
if (selected) {
|
|
12364
|
+
setSelectIds([].concat(_toConsumableArray(selectIds), _toConsumableArray(changeRows.map(function (t) {
|
|
12365
|
+
return t.specNo;
|
|
12366
|
+
}))));
|
|
12367
|
+
setSelect([].concat(_toConsumableArray(selectList), _toConsumableArray(changeRows)));
|
|
12368
|
+
} else {
|
|
12369
|
+
setSelectIds(difference(selectIds, changeRows.map(function (t) {
|
|
12370
|
+
return t.specNo;
|
|
12371
|
+
})));
|
|
12372
|
+
var list = differenceWith(selectList, changeRows, function (arrVal, othVal) {
|
|
12373
|
+
return arrVal.specNo !== othVal.specNo;
|
|
12374
|
+
});
|
|
12375
|
+
setSelect(list);
|
|
12376
|
+
}
|
|
12377
|
+
}
|
|
12378
|
+
};
|
|
12379
|
+
var showTable = function showTable() {
|
|
12380
|
+
var handleDelete = function handleDelete(record) {
|
|
12381
|
+
setSelectIds(selectIds.filter(function (t) {
|
|
12382
|
+
return t !== record.specNo;
|
|
12383
|
+
}));
|
|
12384
|
+
setSelect(selectList.filter(function (t) {
|
|
12385
|
+
return t.specNo !== record.specNo;
|
|
12386
|
+
}));
|
|
12387
|
+
};
|
|
12388
|
+
var showColumns = [{
|
|
12389
|
+
dataIndex: '',
|
|
12390
|
+
title: "\u64CD\u4F5C",
|
|
12391
|
+
ellipsis: true,
|
|
12392
|
+
width: 100,
|
|
12393
|
+
render: function render(val, record) {
|
|
12394
|
+
return /*#__PURE__*/React.createElement(Button, {
|
|
12395
|
+
type: "link",
|
|
12396
|
+
onClick: function onClick() {
|
|
12397
|
+
return handleDelete(record);
|
|
12398
|
+
}
|
|
12399
|
+
}, "\u5220\u9664");
|
|
12400
|
+
}
|
|
12401
|
+
}].concat(takeRight(columns$2, columns$2.length - 1));
|
|
12402
|
+
return selectList.length ? /*#__PURE__*/React.createElement("div", {
|
|
12403
|
+
style: {
|
|
12404
|
+
width: '100%',
|
|
12405
|
+
maxWidth: '387px'
|
|
12406
|
+
}
|
|
12407
|
+
}, /*#__PURE__*/React.createElement(Table, {
|
|
12408
|
+
columns: showColumns,
|
|
12409
|
+
rowKey: 'specNo',
|
|
12410
|
+
dataSource: selectList,
|
|
12411
|
+
scroll: {
|
|
12412
|
+
x: '100%',
|
|
12413
|
+
y: 250
|
|
12414
|
+
},
|
|
12415
|
+
pagination: {
|
|
12416
|
+
size: 'small',
|
|
12417
|
+
total: selectIds.length,
|
|
12418
|
+
pageSize: 10,
|
|
12419
|
+
showSizeChanger: false
|
|
12420
|
+
}
|
|
12421
|
+
})) : null;
|
|
12422
|
+
};
|
|
12423
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, advanceSearchForm, /*#__PURE__*/React.createElement("div", {
|
|
12424
|
+
style: {
|
|
12425
|
+
marginTop: '4px'
|
|
12426
|
+
}
|
|
12427
|
+
}, /*#__PURE__*/React.createElement(Table, _objectSpread2({
|
|
12428
|
+
rowSelection: rowSelection,
|
|
12429
|
+
rowKey: "goodsId",
|
|
12430
|
+
columns: columns$2,
|
|
12431
|
+
scroll: {
|
|
12432
|
+
x: '100%',
|
|
12433
|
+
y: 250
|
|
12434
|
+
}
|
|
12435
|
+
}, tableProps))), /*#__PURE__*/React.createElement(Popover, {
|
|
12436
|
+
getPopupContainer: function getPopupContainer(triggerNode) {
|
|
12437
|
+
return triggerNode.parentElement;
|
|
12438
|
+
},
|
|
12439
|
+
content: showTable(),
|
|
12440
|
+
title: "\u5DF2\u9009\u62E9".concat(selectList.length, "\u4E2A\u5546\u54C1")
|
|
12441
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
12442
|
+
danger: true,
|
|
12443
|
+
type: "text"
|
|
12444
|
+
}, "\u5DF2\u9009".concat(selectList.length > 99 ? '99+' : selectList.length, "\u4E2A\u5546\u54C1"), /*#__PURE__*/React.createElement(CaretUpOutlined, null))));
|
|
12445
|
+
};
|
|
12446
|
+
var BsE3GoodList = /*#__PURE__*/forwardRef(GoodList$1);
|
|
12447
|
+
|
|
12448
|
+
var GoodsModal$4 = function GoodsModal(props, ref) {
|
|
12449
|
+
useImperativeHandle(ref, function () {
|
|
12450
|
+
return {
|
|
12451
|
+
open: function open() {
|
|
12452
|
+
setVisible(true);
|
|
12453
|
+
}
|
|
12454
|
+
};
|
|
12455
|
+
});
|
|
12456
|
+
var onSubmit = props.onSubmit,
|
|
12457
|
+
width = props.width;
|
|
12458
|
+
var _useState = useState(false),
|
|
12459
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
12460
|
+
visible = _useState2[0],
|
|
12461
|
+
setVisible = _useState2[1];
|
|
12462
|
+
var bsE3GoodListRef = useRef(null);
|
|
12463
|
+
var _onCancel = function onCancel() {
|
|
12464
|
+
setVisible(false);
|
|
12465
|
+
};
|
|
12466
|
+
var onOk = function onOk() {
|
|
12467
|
+
var _bsE3GoodListRef$curr;
|
|
12468
|
+
var selectedList = ((_bsE3GoodListRef$curr = bsE3GoodListRef.current) === null || _bsE3GoodListRef$curr === void 0 ? void 0 : _bsE3GoodListRef$curr.getSelectGoodList()) || [];
|
|
12469
|
+
onSubmit(selectedList);
|
|
12470
|
+
_onCancel();
|
|
12471
|
+
};
|
|
12472
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, visible && /*#__PURE__*/React.createElement(Modal, {
|
|
12473
|
+
title: '选择商品',
|
|
12474
|
+
okText: '确认',
|
|
12475
|
+
cancelText: '取消',
|
|
12476
|
+
visible: visible,
|
|
12477
|
+
width: width || 850,
|
|
12478
|
+
onCancel: function onCancel() {
|
|
12479
|
+
_onCancel();
|
|
12480
|
+
},
|
|
12481
|
+
onOk: onOk,
|
|
12482
|
+
wrapClassName: "goodModal"
|
|
12483
|
+
}, /*#__PURE__*/React.createElement(BsE3GoodList, {
|
|
12484
|
+
ref: bsE3GoodListRef
|
|
12485
|
+
})));
|
|
12486
|
+
};
|
|
12487
|
+
var BsE3GoodsModal = /*#__PURE__*/forwardRef(GoodsModal$4);
|
|
12488
|
+
|
|
12489
|
+
// interface GoodsItem {
|
|
12490
|
+
// title: string;
|
|
12491
|
+
// pic: string;
|
|
12492
|
+
// platform: string;
|
|
12493
|
+
// skuId: string;
|
|
12494
|
+
// styleId: string;
|
|
12495
|
+
// }
|
|
12496
|
+
var GoodItem$1 = function GoodItem(props) {
|
|
12497
|
+
var _props$value = props.value,
|
|
12498
|
+
value = _props$value === void 0 ? [] : _props$value,
|
|
12499
|
+
type = props.type,
|
|
12500
|
+
onChange = props.onChange,
|
|
12501
|
+
disabled = props.disabled,
|
|
12502
|
+
_props$showHeader = props.showHeader,
|
|
12503
|
+
showHeader = _props$showHeader === void 0 ? [] : _props$showHeader,
|
|
12504
|
+
width = props.width,
|
|
12505
|
+
_props$shopList = props.shopList,
|
|
12506
|
+
shopList = _props$shopList === void 0 ? [] : _props$shopList,
|
|
12507
|
+
_props$shopId = props.shopId,
|
|
12508
|
+
shopId = _props$shopId === void 0 ? '' : _props$shopId,
|
|
12509
|
+
_props$maxLength = props.maxLength,
|
|
12510
|
+
maxLength = _props$maxLength === void 0 ? 20 : _props$maxLength,
|
|
12511
|
+
_props$showChangeBtn = props.showChangeBtn,
|
|
12512
|
+
showChangeBtn = _props$showChangeBtn === void 0 ? true : _props$showChangeBtn,
|
|
12513
|
+
_props$showModeBtn = props.showModeBtn,
|
|
12514
|
+
showModeBtn = _props$showModeBtn === void 0 ? false : _props$showModeBtn,
|
|
12515
|
+
_props$isStrict = props.isStrict,
|
|
12516
|
+
isStrict = _props$isStrict === void 0 ? false : _props$isStrict,
|
|
12517
|
+
_props$tableSelect = props.tableSelect,
|
|
12518
|
+
tableSelect = _props$tableSelect === void 0 ? false : _props$tableSelect,
|
|
12519
|
+
_props$selectType = props.selectType,
|
|
12520
|
+
selectType = _props$selectType === void 0 ? '' : _props$selectType,
|
|
12521
|
+
_props$otherOperation = props.otherOperations,
|
|
12522
|
+
otherOperations = _props$otherOperation === void 0 ? null : _props$otherOperation,
|
|
12523
|
+
_props$canUpdateNumbe = props.canUpdateNumber,
|
|
12524
|
+
canUpdateNumber = _props$canUpdateNumbe === void 0 ? false : _props$canUpdateNumbe,
|
|
12525
|
+
shopCode = props.shopCode,
|
|
12526
|
+
_props$companyKey = props.companyKey,
|
|
12527
|
+
companyKey = _props$companyKey === void 0 ? '' : _props$companyKey,
|
|
12528
|
+
onSelect = props.onSelect,
|
|
12529
|
+
onDelete = props.onDelete,
|
|
12530
|
+
onModeChange = props.onModeChange;
|
|
12531
|
+
var refModal = useRef();
|
|
12532
|
+
var handleDelete = function handleDelete(record, index) {
|
|
12533
|
+
onDelete === null || onDelete === void 0 ? void 0 : onDelete(value[index]);
|
|
12534
|
+
var newList = _toConsumableArray(value).filter(function (item, i) {
|
|
12535
|
+
return index !== i;
|
|
12536
|
+
});
|
|
12537
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_toConsumableArray(newList));
|
|
12538
|
+
};
|
|
12539
|
+
var _useState = useState([]),
|
|
12540
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
12541
|
+
selectedRowKeys = _useState2[0],
|
|
12542
|
+
setSelectedRowKeys = _useState2[1];
|
|
12543
|
+
useEffect(function () {
|
|
12544
|
+
setSelectedRowKeys([]);
|
|
12545
|
+
}, [tableSelect, selectType]);
|
|
12546
|
+
var updateHandle = function updateHandle(val, index, columnType) {
|
|
12547
|
+
if (value === null || value === void 0 ? void 0 : value.length) {
|
|
12548
|
+
value[index][columnType] = val;
|
|
12549
|
+
if (type === 'WDT_RETURN_GOODS') {
|
|
12550
|
+
if (['sharePrice', 'num'].includes(columnType)) {
|
|
12551
|
+
var totalMoney = null;
|
|
12552
|
+
if (columnType === 'num') {
|
|
12553
|
+
totalMoney = new BigNumber(value[index][columnType]).multipliedBy(new BigNumber(value[index].sharePrice));
|
|
12554
|
+
} else {
|
|
12555
|
+
totalMoney = new BigNumber(value[index][columnType]).multipliedBy(new BigNumber(value[index].num));
|
|
12556
|
+
}
|
|
12557
|
+
if (totalMoney !== null) {
|
|
12558
|
+
value[index]['returnPrice'] = totalMoney.toString();
|
|
12559
|
+
}
|
|
12560
|
+
}
|
|
12561
|
+
} else if (type === 'WDT_EXCHANGE_GOODS') {
|
|
12562
|
+
if (['price', 'num'].includes(columnType)) {
|
|
12563
|
+
var _totalMoney = null;
|
|
12564
|
+
if (columnType === 'num') {
|
|
12565
|
+
_totalMoney = new BigNumber(value[index][columnType]).multipliedBy(new BigNumber(value[index].price));
|
|
12566
|
+
} else {
|
|
12567
|
+
_totalMoney = new BigNumber(value[index][columnType]).multipliedBy(new BigNumber(value[index].num));
|
|
12568
|
+
}
|
|
12569
|
+
if (_totalMoney !== null) {
|
|
12570
|
+
value[index]['exchangePrice'] = _totalMoney.toString();
|
|
12571
|
+
}
|
|
12572
|
+
}
|
|
12573
|
+
}
|
|
12574
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_toConsumableArray(value));
|
|
12575
|
+
}
|
|
12576
|
+
};
|
|
12577
|
+
var COLUMNS_MAP = function COLUMNS_MAP() {
|
|
12578
|
+
var text = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
|
|
12579
|
+
return function (type) {
|
|
12580
|
+
var columns = [];
|
|
12581
|
+
switch (type) {
|
|
12582
|
+
case 'WDT_REISSUE_GOODS':
|
|
12583
|
+
case 'WDT_GOODS':
|
|
12584
|
+
columns = [{
|
|
12585
|
+
dataIndex: 'goodId',
|
|
12586
|
+
title: "\u5546\u54C1ID",
|
|
12587
|
+
align: 'center',
|
|
12588
|
+
ellipsis: true,
|
|
12589
|
+
width: 70
|
|
12590
|
+
}, {
|
|
12591
|
+
dataIndex: 'goodNo',
|
|
12592
|
+
title: "\u5546\u54C1\u7F16\u7801",
|
|
12593
|
+
align: 'center',
|
|
12594
|
+
ellipsis: true,
|
|
12595
|
+
width: 180
|
|
12596
|
+
}, {
|
|
12597
|
+
dataIndex: 'goodName',
|
|
12598
|
+
title: "".concat(text, "\u5546\u54C1\u540D\u79F0"),
|
|
12599
|
+
align: 'center',
|
|
12600
|
+
ellipsis: true,
|
|
12601
|
+
width: 250
|
|
12602
|
+
}, {
|
|
12134
12603
|
dataIndex: 'specId',
|
|
12135
12604
|
title: "".concat(text, "SKUID"),
|
|
12136
12605
|
align: 'center',
|
|
@@ -12355,109 +12824,246 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
12355
12824
|
ellipsis: true,
|
|
12356
12825
|
width: 250
|
|
12357
12826
|
}, {
|
|
12358
|
-
dataIndex: 'specId',
|
|
12359
|
-
title: "".concat(text, "SKUID"),
|
|
12827
|
+
dataIndex: 'specId',
|
|
12828
|
+
title: "".concat(text, "SKUID"),
|
|
12829
|
+
align: 'center',
|
|
12830
|
+
ellipsis: true,
|
|
12831
|
+
width: 100
|
|
12832
|
+
}, {
|
|
12833
|
+
dataIndex: 'specNo',
|
|
12834
|
+
title: "".concat(text, "\u5546\u54C1SKU\u7F16\u7801"),
|
|
12835
|
+
align: 'center',
|
|
12836
|
+
ellipsis: true,
|
|
12837
|
+
width: 180
|
|
12838
|
+
}, {
|
|
12839
|
+
dataIndex: 'specName',
|
|
12840
|
+
title: "".concat(text, "\u5546\u54C1SKU\u540D\u79F0"),
|
|
12841
|
+
align: 'center',
|
|
12842
|
+
ellipsis: true,
|
|
12843
|
+
width: 250
|
|
12844
|
+
}, {
|
|
12845
|
+
dataIndex: 'num',
|
|
12846
|
+
title: "".concat(text, "\u6362\u51FA\u6570\u91CF"),
|
|
12847
|
+
align: 'center',
|
|
12848
|
+
ellipsis: true,
|
|
12849
|
+
width: 100,
|
|
12850
|
+
render: function render(val, record, index) {
|
|
12851
|
+
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
12852
|
+
style: {
|
|
12853
|
+
width: 70
|
|
12854
|
+
},
|
|
12855
|
+
value: val,
|
|
12856
|
+
min: 1,
|
|
12857
|
+
precision: 0,
|
|
12858
|
+
onChange: function onChange(num) {
|
|
12859
|
+
return updateHandle(num, index, 'num');
|
|
12860
|
+
}
|
|
12861
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12862
|
+
}
|
|
12863
|
+
}, {
|
|
12864
|
+
dataIndex: 'price',
|
|
12865
|
+
title: "".concat(text, "\u5546\u54C1\u5355\u4EF7"),
|
|
12866
|
+
align: 'center',
|
|
12867
|
+
ellipsis: true,
|
|
12868
|
+
width: 100,
|
|
12869
|
+
render: function render(val, record, index) {
|
|
12870
|
+
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
12871
|
+
style: {
|
|
12872
|
+
width: 70
|
|
12873
|
+
},
|
|
12874
|
+
value: val,
|
|
12875
|
+
min: 0,
|
|
12876
|
+
onChange: function onChange(value) {
|
|
12877
|
+
return updateHandle(value, index, 'price');
|
|
12878
|
+
}
|
|
12879
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12880
|
+
}
|
|
12881
|
+
}, {
|
|
12882
|
+
dataIndex: 'exchangePrice',
|
|
12883
|
+
title: "".concat(text, "\u6362\u51FA\u91D1\u989D"),
|
|
12884
|
+
align: 'center',
|
|
12885
|
+
ellipsis: true,
|
|
12886
|
+
width: 100
|
|
12887
|
+
}, {
|
|
12888
|
+
dataIndex: 'giftType',
|
|
12889
|
+
title: "\u8D60\u54C1\u65B9\u5F0F",
|
|
12890
|
+
align: 'center',
|
|
12891
|
+
ellipsis: true,
|
|
12892
|
+
width: 100,
|
|
12893
|
+
render: function render(val) {
|
|
12894
|
+
var giftTypeMap = {
|
|
12895
|
+
0: '非赠品',
|
|
12896
|
+
1: '自动赠送',
|
|
12897
|
+
2: '手工赠送',
|
|
12898
|
+
3: '回购自动送赠品',
|
|
12899
|
+
4: '前N有礼送赠品',
|
|
12900
|
+
6: '天猫优仓赠品',
|
|
12901
|
+
7: '淘宝CRM会员送赠'
|
|
12902
|
+
};
|
|
12903
|
+
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
12904
|
+
}
|
|
12905
|
+
}, {
|
|
12906
|
+
dataIndex: 'type',
|
|
12907
|
+
title: "".concat(text, "\u5546\u54C1\u7C7B\u578B"),
|
|
12908
|
+
align: 'center',
|
|
12909
|
+
ellipsis: true,
|
|
12910
|
+
width: 100,
|
|
12911
|
+
render: function render(val, record, index) {
|
|
12912
|
+
var options = [{
|
|
12913
|
+
label: '单品',
|
|
12914
|
+
value: '1'
|
|
12915
|
+
}, {
|
|
12916
|
+
label: '组合装',
|
|
12917
|
+
value: '2'
|
|
12918
|
+
}];
|
|
12919
|
+
return !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
12920
|
+
style: {
|
|
12921
|
+
width: 70
|
|
12922
|
+
},
|
|
12923
|
+
options: options,
|
|
12924
|
+
value: val,
|
|
12925
|
+
onChange: function onChange(value) {
|
|
12926
|
+
return updateHandle(value, index, 'type');
|
|
12927
|
+
}
|
|
12928
|
+
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12929
|
+
}
|
|
12930
|
+
}];
|
|
12931
|
+
}
|
|
12932
|
+
break;
|
|
12933
|
+
case 'BS_E3_GOODS':
|
|
12934
|
+
{
|
|
12935
|
+
columns = [{
|
|
12936
|
+
dataIndex: 'sku',
|
|
12937
|
+
title: "SKU",
|
|
12938
|
+
align: 'center',
|
|
12939
|
+
ellipsis: true,
|
|
12940
|
+
width: 70
|
|
12941
|
+
}, {
|
|
12942
|
+
dataIndex: 'skuId',
|
|
12943
|
+
title: "SKU ID",
|
|
12944
|
+
align: 'center',
|
|
12945
|
+
ellipsis: true,
|
|
12946
|
+
width: 70
|
|
12947
|
+
}, {
|
|
12948
|
+
dataIndex: 'goodsName',
|
|
12949
|
+
title: "\u5546\u54C1\u540D\u79F0",
|
|
12950
|
+
align: 'center',
|
|
12951
|
+
ellipsis: true,
|
|
12952
|
+
width: 70
|
|
12953
|
+
}, {
|
|
12954
|
+
dataIndex: 'goodsSname',
|
|
12955
|
+
title: "\u5546\u54C1\u7B80\u79F0",
|
|
12956
|
+
align: 'center',
|
|
12957
|
+
ellipsis: true,
|
|
12958
|
+
width: 70
|
|
12959
|
+
}, {
|
|
12960
|
+
dataIndex: 'picPath',
|
|
12961
|
+
title: "\u5546\u54C1\u56FE\u7247",
|
|
12962
|
+
align: 'center',
|
|
12963
|
+
ellipsis: true,
|
|
12964
|
+
width: 70
|
|
12965
|
+
}, {
|
|
12966
|
+
dataIndex: 'goodsSn',
|
|
12967
|
+
title: "\u8D27\u53F7",
|
|
12968
|
+
align: 'center',
|
|
12969
|
+
ellipsis: true,
|
|
12970
|
+
width: 70
|
|
12971
|
+
}, {
|
|
12972
|
+
dataIndex: 'goodsId',
|
|
12973
|
+
title: "\u8D27\u53F7ID",
|
|
12974
|
+
align: 'center',
|
|
12975
|
+
ellipsis: true,
|
|
12976
|
+
width: 70
|
|
12977
|
+
}, {
|
|
12978
|
+
dataIndex: 'colorName',
|
|
12979
|
+
title: "\u989C\u8272\u540D\u79F0",
|
|
12980
|
+
align: 'center',
|
|
12981
|
+
ellipsis: true,
|
|
12982
|
+
width: 70
|
|
12983
|
+
}, {
|
|
12984
|
+
dataIndex: 'colorCode',
|
|
12985
|
+
title: "\u989C\u8272\u4EE3\u7801",
|
|
12986
|
+
align: 'center',
|
|
12987
|
+
ellipsis: true,
|
|
12988
|
+
width: 70
|
|
12989
|
+
}, {
|
|
12990
|
+
dataIndex: 'sizeName',
|
|
12991
|
+
title: "\u5C3A\u7801\u540D\u79F0",
|
|
12992
|
+
align: 'center',
|
|
12993
|
+
ellipsis: true,
|
|
12994
|
+
width: 70
|
|
12995
|
+
}, {
|
|
12996
|
+
dataIndex: 'sizeCode',
|
|
12997
|
+
title: "\u5C3A\u7801\u4EE3\u7801",
|
|
12998
|
+
align: 'center',
|
|
12999
|
+
ellipsis: true,
|
|
13000
|
+
width: 70
|
|
13001
|
+
}, {
|
|
13002
|
+
dataIndex: 'brandName',
|
|
13003
|
+
title: "\u54C1\u724C\u540D\u79F0",
|
|
13004
|
+
align: 'center',
|
|
13005
|
+
ellipsis: true,
|
|
13006
|
+
width: 70
|
|
13007
|
+
}, {
|
|
13008
|
+
dataIndex: 'goodsNumber',
|
|
13009
|
+
title: "\u5546\u54C1\u6570\u91CF",
|
|
13010
|
+
align: 'center',
|
|
13011
|
+
ellipsis: true,
|
|
13012
|
+
width: 70
|
|
13013
|
+
}, {
|
|
13014
|
+
dataIndex: 'goodsPrice',
|
|
13015
|
+
title: "\u5546\u54C1\u5355\u4EF7",
|
|
13016
|
+
align: 'center',
|
|
13017
|
+
ellipsis: true,
|
|
13018
|
+
width: 70
|
|
13019
|
+
}, {
|
|
13020
|
+
dataIndex: 'shopPrice',
|
|
13021
|
+
title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
|
|
12360
13022
|
align: 'center',
|
|
12361
13023
|
ellipsis: true,
|
|
12362
|
-
width:
|
|
13024
|
+
width: 70
|
|
12363
13025
|
}, {
|
|
12364
|
-
dataIndex: '
|
|
12365
|
-
title: "
|
|
13026
|
+
dataIndex: 'sharePrice',
|
|
13027
|
+
title: "\u5206\u644A\u4EF7",
|
|
12366
13028
|
align: 'center',
|
|
12367
13029
|
ellipsis: true,
|
|
12368
|
-
width:
|
|
13030
|
+
width: 70
|
|
12369
13031
|
}, {
|
|
12370
|
-
dataIndex: '
|
|
12371
|
-
title: "
|
|
13032
|
+
dataIndex: 'sharePayment',
|
|
13033
|
+
title: "\u5206\u644A\u5B9E\u4ED8\u91D1\u989D",
|
|
12372
13034
|
align: 'center',
|
|
12373
13035
|
ellipsis: true,
|
|
12374
|
-
width:
|
|
13036
|
+
width: 70
|
|
12375
13037
|
}, {
|
|
12376
|
-
dataIndex: '
|
|
12377
|
-
title: "
|
|
13038
|
+
dataIndex: 'payment',
|
|
13039
|
+
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
12378
13040
|
align: 'center',
|
|
12379
13041
|
ellipsis: true,
|
|
12380
|
-
width:
|
|
12381
|
-
render: function render(val, record, index) {
|
|
12382
|
-
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
12383
|
-
style: {
|
|
12384
|
-
width: 70
|
|
12385
|
-
},
|
|
12386
|
-
value: val,
|
|
12387
|
-
min: 1,
|
|
12388
|
-
precision: 0,
|
|
12389
|
-
onChange: function onChange(num) {
|
|
12390
|
-
return updateHandle(num, index, 'num');
|
|
12391
|
-
}
|
|
12392
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12393
|
-
}
|
|
13042
|
+
width: 70
|
|
12394
13043
|
}, {
|
|
12395
|
-
dataIndex: '
|
|
12396
|
-
title: "
|
|
13044
|
+
dataIndex: 'tcSku',
|
|
13045
|
+
title: "\u5957\u9910SKU",
|
|
12397
13046
|
align: 'center',
|
|
12398
13047
|
ellipsis: true,
|
|
12399
|
-
width:
|
|
12400
|
-
render: function render(val, record, index) {
|
|
12401
|
-
return !disabled ? /*#__PURE__*/React.createElement(InputNumber, {
|
|
12402
|
-
style: {
|
|
12403
|
-
width: 70
|
|
12404
|
-
},
|
|
12405
|
-
value: val,
|
|
12406
|
-
min: 0,
|
|
12407
|
-
onChange: function onChange(value) {
|
|
12408
|
-
return updateHandle(value, index, 'price');
|
|
12409
|
-
}
|
|
12410
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12411
|
-
}
|
|
13048
|
+
width: 70
|
|
12412
13049
|
}, {
|
|
12413
|
-
dataIndex: '
|
|
12414
|
-
title: "
|
|
13050
|
+
dataIndex: 'tcGoodsNumber',
|
|
13051
|
+
title: "\u5957\u9910\u5957\u6570",
|
|
12415
13052
|
align: 'center',
|
|
12416
13053
|
ellipsis: true,
|
|
12417
|
-
width:
|
|
13054
|
+
width: 70
|
|
12418
13055
|
}, {
|
|
12419
|
-
dataIndex: '
|
|
12420
|
-
title: "\
|
|
13056
|
+
dataIndex: 'taocanSingleSl',
|
|
13057
|
+
title: "\u5355\u4E2A\u5957\u9910\u6570\u91CF",
|
|
12421
13058
|
align: 'center',
|
|
12422
13059
|
ellipsis: true,
|
|
12423
|
-
width:
|
|
12424
|
-
render: function render(val) {
|
|
12425
|
-
var giftTypeMap = {
|
|
12426
|
-
0: '非赠品',
|
|
12427
|
-
1: '自动赠送',
|
|
12428
|
-
2: '手工赠送',
|
|
12429
|
-
3: '回购自动送赠品',
|
|
12430
|
-
4: '前N有礼送赠品',
|
|
12431
|
-
6: '天猫优仓赠品',
|
|
12432
|
-
7: '淘宝CRM会员送赠'
|
|
12433
|
-
};
|
|
12434
|
-
return /*#__PURE__*/React.createElement("span", null, giftTypeMap[val]);
|
|
12435
|
-
}
|
|
13060
|
+
width: 70
|
|
12436
13061
|
}, {
|
|
12437
|
-
dataIndex: '
|
|
12438
|
-
title: "
|
|
13062
|
+
dataIndex: 'isGift',
|
|
13063
|
+
title: "\u662F\u5426\u8D60\u54C1",
|
|
12439
13064
|
align: 'center',
|
|
12440
13065
|
ellipsis: true,
|
|
12441
|
-
width:
|
|
12442
|
-
render: function render(val, record, index) {
|
|
12443
|
-
var options = [{
|
|
12444
|
-
label: '单品',
|
|
12445
|
-
value: '1'
|
|
12446
|
-
}, {
|
|
12447
|
-
label: '组合装',
|
|
12448
|
-
value: '2'
|
|
12449
|
-
}];
|
|
12450
|
-
return !disabled ? /*#__PURE__*/React.createElement(Select, {
|
|
12451
|
-
style: {
|
|
12452
|
-
width: 70
|
|
12453
|
-
},
|
|
12454
|
-
options: options,
|
|
12455
|
-
value: val,
|
|
12456
|
-
onChange: function onChange(value) {
|
|
12457
|
-
return updateHandle(value, index, 'type');
|
|
12458
|
-
}
|
|
12459
|
-
}) : /*#__PURE__*/React.createElement("span", null, val);
|
|
12460
|
-
}
|
|
13066
|
+
width: 70
|
|
12461
13067
|
}];
|
|
12462
13068
|
}
|
|
12463
13069
|
break;
|
|
@@ -12616,6 +13222,15 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
12616
13222
|
}
|
|
12617
13223
|
return item;
|
|
12618
13224
|
});
|
|
13225
|
+
} else if (['BS_E3_GOODS', 'BS_E3_REISSUE_GOODS', 'BS_E3_EXCHANGE_GOODS'].includes(type)) {
|
|
13226
|
+
newList = list.map(function (item) {
|
|
13227
|
+
item.uuid = uuid();
|
|
13228
|
+
item.canDelete = true;
|
|
13229
|
+
item.goodsNumber = 1;
|
|
13230
|
+
item.goodsPrice = 0;
|
|
13231
|
+
item.canUpdateNumber = canUpdateNumber;
|
|
13232
|
+
return item;
|
|
13233
|
+
});
|
|
12619
13234
|
} else {
|
|
12620
13235
|
newList = list.map(function (item) {
|
|
12621
13236
|
var goodsId = item.goodsId,
|
|
@@ -12658,6 +13273,9 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
12658
13273
|
fixed: true,
|
|
12659
13274
|
onChange: onSelectChange
|
|
12660
13275
|
};
|
|
13276
|
+
var handleCheckboxChange = function handleCheckboxChange(e) {
|
|
13277
|
+
onModeChange === null || onModeChange === void 0 ? void 0 : onModeChange(e.target.checked);
|
|
13278
|
+
};
|
|
12661
13279
|
var tableConfig = useMemo(function () {
|
|
12662
13280
|
var params = {};
|
|
12663
13281
|
if (tableSelect) {
|
|
@@ -12669,7 +13287,10 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
12669
13287
|
style: {
|
|
12670
13288
|
float: 'right'
|
|
12671
13289
|
}
|
|
12672
|
-
}, /*#__PURE__*/React.createElement(
|
|
13290
|
+
}, showModeBtn && /*#__PURE__*/React.createElement(Checkbox, {
|
|
13291
|
+
value: isStrict,
|
|
13292
|
+
onChange: handleCheckboxChange
|
|
13293
|
+
}, "\u5408\u5E76\u5355\uFF0C\u52FE\u9009\u540E\u53EA\u5C55\u793A\u5F53\u524D\u5E73\u53F0\u8BA2\u5355\u5546\u54C1"), /*#__PURE__*/React.createElement(Button, {
|
|
12673
13294
|
type: "link",
|
|
12674
13295
|
onClick: handleChangeGoods
|
|
12675
13296
|
}, "\u9009\u62E9\u5546\u54C1"), otherOperations), /*#__PURE__*/React.createElement(Table, _objectSpread2(_objectSpread2({}, tableConfig), {}, {
|
|
@@ -12692,6 +13313,14 @@ var GoodItem$1 = function GoodItem(props) {
|
|
|
12692
13313
|
shopId: shopId,
|
|
12693
13314
|
maxLength: maxLength,
|
|
12694
13315
|
companyKey: companyKey
|
|
13316
|
+
}) : ['BS_E3_REISSUE_GOODS', 'BS_E3_GOODS', 'BS_E3_EXCHANGE_GOODS'].includes(type) ? /*#__PURE__*/React.createElement(BsE3GoodsModal, {
|
|
13317
|
+
ref: refModal,
|
|
13318
|
+
onSubmit: onSubmit,
|
|
13319
|
+
width: width,
|
|
13320
|
+
shopList: shopList,
|
|
13321
|
+
shopId: shopId,
|
|
13322
|
+
maxLength: maxLength,
|
|
13323
|
+
companyKey: companyKey
|
|
12695
13324
|
}) : /*#__PURE__*/React.createElement(GoodsModal$2, {
|
|
12696
13325
|
ref: refModal,
|
|
12697
13326
|
onSubmit: onSubmit,
|
|
@@ -13311,19 +13940,133 @@ var BsReturnGoods = function BsReturnGoods(props) {
|
|
|
13311
13940
|
})));
|
|
13312
13941
|
};
|
|
13313
13942
|
|
|
13314
|
-
var
|
|
13315
|
-
|
|
13316
|
-
|
|
13317
|
-
|
|
13318
|
-
|
|
13319
|
-
|
|
13320
|
-
|
|
13321
|
-
|
|
13322
|
-
|
|
13323
|
-
|
|
13324
|
-
|
|
13325
|
-
|
|
13943
|
+
var singletonMap = new Map();
|
|
13944
|
+
var getWdtOrderListSingleton = function getWdtOrderListSingleton(orderNo) {
|
|
13945
|
+
if (!singletonMap.has(orderNo)) {
|
|
13946
|
+
var p = new Promise(function (resolve, reject) {
|
|
13947
|
+
var doReject = function doReject(err) {
|
|
13948
|
+
// 清空掉错误的请求记录
|
|
13949
|
+
singletonMap.delete(orderNo);
|
|
13950
|
+
reject(err);
|
|
13951
|
+
};
|
|
13952
|
+
extendRequest('/qy/gdfw/order/wdtOrderDetail', {
|
|
13953
|
+
method: 'post',
|
|
13954
|
+
data: {
|
|
13955
|
+
billNo: orderNo
|
|
13956
|
+
}
|
|
13957
|
+
}).then(function (data) {
|
|
13958
|
+
if (data === null || data === void 0 ? void 0 : data.success) {
|
|
13959
|
+
var _data$data, _data$data$trades;
|
|
13960
|
+
if (data === null || data === void 0 ? void 0 : (_data$data = data.data) === null || _data$data === void 0 ? void 0 : (_data$data$trades = _data$data.trades) === null || _data$data$trades === void 0 ? void 0 : _data$data$trades.length) {
|
|
13961
|
+
data.data.trades = filterWdtOrders(data === null || data === void 0 ? void 0 : data.data, orderNo).map(function (item) {
|
|
13962
|
+
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
13963
|
+
billNo: item.tradeNo,
|
|
13964
|
+
billType: WDT_ORDER_TYPE_MAP[item.tradeType],
|
|
13965
|
+
billTag: item.tagName
|
|
13966
|
+
});
|
|
13967
|
+
});
|
|
13968
|
+
}
|
|
13969
|
+
resolve(data.data);
|
|
13970
|
+
// 延迟10秒清除,保证订单的时效性
|
|
13971
|
+
setTimeout(function () {
|
|
13972
|
+
singletonMap.delete(orderNo);
|
|
13973
|
+
}, 1000 * 10);
|
|
13974
|
+
} else {
|
|
13975
|
+
doReject(data);
|
|
13976
|
+
}
|
|
13977
|
+
}).catch(doReject);
|
|
13978
|
+
});
|
|
13979
|
+
singletonMap.set(orderNo, p);
|
|
13326
13980
|
}
|
|
13981
|
+
return singletonMap.get(orderNo);
|
|
13982
|
+
};
|
|
13983
|
+
var wdtUtils = {
|
|
13984
|
+
getWdtOrderListSingleton: getWdtOrderListSingleton
|
|
13985
|
+
};
|
|
13986
|
+
|
|
13987
|
+
var columnsMap = {
|
|
13988
|
+
BS_SYSTEM_ORDER: [{
|
|
13989
|
+
title: '单据类型',
|
|
13990
|
+
dataIndex: 'billType',
|
|
13991
|
+
width: 150
|
|
13992
|
+
}, {
|
|
13993
|
+
title: '系统订单号',
|
|
13994
|
+
dataIndex: 'billNo',
|
|
13995
|
+
width: 150
|
|
13996
|
+
}, {
|
|
13997
|
+
title: '标签',
|
|
13998
|
+
dataIndex: 'billTag',
|
|
13999
|
+
width: 150
|
|
14000
|
+
}],
|
|
14001
|
+
WLN_SYSTEM_ORDER: [{
|
|
14002
|
+
title: '订单类型',
|
|
14003
|
+
dataIndex: 'billType',
|
|
14004
|
+
width: 150
|
|
14005
|
+
}, {
|
|
14006
|
+
title: '系统订单号',
|
|
14007
|
+
dataIndex: 'billNo',
|
|
14008
|
+
width: 150
|
|
14009
|
+
}, {
|
|
14010
|
+
title: '标记',
|
|
14011
|
+
dataIndex: 'billTag',
|
|
14012
|
+
width: 150
|
|
14013
|
+
}],
|
|
14014
|
+
WDT_SYSTEM_ORDER: [{
|
|
14015
|
+
title: '订单类型',
|
|
14016
|
+
dataIndex: 'billType',
|
|
14017
|
+
width: 150
|
|
14018
|
+
}, {
|
|
14019
|
+
title: '系统订单号',
|
|
14020
|
+
dataIndex: 'billNo',
|
|
14021
|
+
width: 150
|
|
14022
|
+
}, {
|
|
14023
|
+
title: '订单标签',
|
|
14024
|
+
dataIndex: 'billTag',
|
|
14025
|
+
width: 150
|
|
14026
|
+
}],
|
|
14027
|
+
BS_E3_SYSTEM_ORDER: [{
|
|
14028
|
+
title: '系统订单号',
|
|
14029
|
+
dataIndex: 'orderSn',
|
|
14030
|
+
width: 150
|
|
14031
|
+
}, {
|
|
14032
|
+
title: '订单状态',
|
|
14033
|
+
dataIndex: 'orderStatus',
|
|
14034
|
+
width: 100
|
|
14035
|
+
}, {
|
|
14036
|
+
title: '是否被拆分',
|
|
14037
|
+
dataIndex: 'isSplit',
|
|
14038
|
+
width: 100
|
|
14039
|
+
}, {
|
|
14040
|
+
title: '是否拆分子单',
|
|
14041
|
+
dataIndex: 'isSplitNew',
|
|
14042
|
+
width: 100
|
|
14043
|
+
}, {
|
|
14044
|
+
title: '是否被合并',
|
|
14045
|
+
dataIndex: 'isCombine',
|
|
14046
|
+
width: 100
|
|
14047
|
+
}, {
|
|
14048
|
+
title: '是否合并新单',
|
|
14049
|
+
dataIndex: 'isCombineNew',
|
|
14050
|
+
width: 100
|
|
14051
|
+
}, {
|
|
14052
|
+
title: '是否复制单',
|
|
14053
|
+
dataIndex: 'isCopy',
|
|
14054
|
+
width: 100
|
|
14055
|
+
}, {
|
|
14056
|
+
title: '是否换货单',
|
|
14057
|
+
dataIndex: 'isHH',
|
|
14058
|
+
width: 100
|
|
14059
|
+
}, {
|
|
14060
|
+
title: '订单备注',
|
|
14061
|
+
dataIndex: 'orderMsg',
|
|
14062
|
+
width: 150
|
|
14063
|
+
}]
|
|
14064
|
+
};
|
|
14065
|
+
var rowKeyMap = {
|
|
14066
|
+
BS_SYSTEM_ORDER: 'billNo',
|
|
14067
|
+
WLN_SYSTEM_ORDER: 'billNo',
|
|
14068
|
+
WDT_SYSTEM_ORDER: 'billNo',
|
|
14069
|
+
BS_E3_SYSTEM_ORDER: 'orderSn'
|
|
13327
14070
|
};
|
|
13328
14071
|
var index$1 = (function (props) {
|
|
13329
14072
|
var value = props.value,
|
|
@@ -13341,21 +14084,11 @@ var index$1 = (function (props) {
|
|
|
13341
14084
|
getWlnOrderList(value.orderNo);
|
|
13342
14085
|
} else if (type === 'WDT_SYSTEM_ORDER') {
|
|
13343
14086
|
getWdtOrderList(value.orderNo);
|
|
13344
|
-
}
|
|
14087
|
+
} else ;
|
|
13345
14088
|
}
|
|
13346
14089
|
}, [value, type]);
|
|
13347
14090
|
var columns = useMemo(function () {
|
|
13348
|
-
|
|
13349
|
-
return [{
|
|
13350
|
-
dataIndex: 'billType',
|
|
13351
|
-
title: columnsNameMap === null || columnsNameMap === void 0 ? void 0 : (_columnsNameMap$type = columnsNameMap[type]) === null || _columnsNameMap$type === void 0 ? void 0 : _columnsNameMap$type.typeName
|
|
13352
|
-
}, {
|
|
13353
|
-
dataIndex: 'billNo',
|
|
13354
|
-
title: '系统订单号'
|
|
13355
|
-
}, {
|
|
13356
|
-
dataIndex: 'billTag',
|
|
13357
|
-
title: columnsNameMap === null || columnsNameMap === void 0 ? void 0 : (_columnsNameMap$type2 = columnsNameMap[type]) === null || _columnsNameMap$type2 === void 0 ? void 0 : _columnsNameMap$type2.tagName
|
|
13358
|
-
}];
|
|
14091
|
+
return columnsMap[type] || [];
|
|
13359
14092
|
}, [type]);
|
|
13360
14093
|
var getOrderList = /*#__PURE__*/function () {
|
|
13361
14094
|
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderNo) {
|
|
@@ -13445,51 +14178,29 @@ var index$1 = (function (props) {
|
|
|
13445
14178
|
}();
|
|
13446
14179
|
var getWdtOrderList = /*#__PURE__*/function () {
|
|
13447
14180
|
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(orderNo) {
|
|
13448
|
-
var _yield$request3, success, data, trades;
|
|
13449
14181
|
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
|
13450
14182
|
while (1) switch (_context3.prev = _context3.next) {
|
|
13451
14183
|
case 0:
|
|
13452
|
-
|
|
13453
|
-
|
|
13454
|
-
method: 'post',
|
|
13455
|
-
data: {
|
|
13456
|
-
billNo: orderNo
|
|
13457
|
-
}
|
|
13458
|
-
});
|
|
13459
|
-
case 2:
|
|
13460
|
-
_yield$request3 = _context3.sent;
|
|
13461
|
-
success = _yield$request3.success;
|
|
13462
|
-
data = _yield$request3.data;
|
|
13463
|
-
if (success) {
|
|
13464
|
-
trades = ((data === null || data === void 0 ? void 0 : data.trades) || []).filter(function (item) {
|
|
14184
|
+
wdtUtils.getWdtOrderListSingleton(orderNo).then(function (data) {
|
|
14185
|
+
var trades = ((data === null || data === void 0 ? void 0 : data.trades) || []).filter(function (item) {
|
|
13465
14186
|
return (item.srcTid || '').split(',').includes(orderNo);
|
|
13466
|
-
}).map(function (item) {
|
|
13467
|
-
if (Array.isArray(item.goodDetails)) {
|
|
13468
|
-
item.goodDetails = item.goodDetails.filter(function (good) {
|
|
13469
|
-
return good.srcTid === orderNo;
|
|
13470
|
-
});
|
|
13471
|
-
}
|
|
13472
|
-
return item;
|
|
13473
14187
|
});
|
|
13474
|
-
_onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
13475
|
-
orders: trades
|
|
13476
|
-
|
|
13477
|
-
|
|
13478
|
-
billType
|
|
13479
|
-
billTag
|
|
13480
|
-
});
|
|
13481
|
-
}),
|
|
13482
|
-
showOrderInfo: trades.map(function (item) {
|
|
14188
|
+
_onChange === null || _onChange === void 0 ? void 0 : _onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
14189
|
+
orders: trades,
|
|
14190
|
+
showOrderInfo: trades.map(function (_ref4) {
|
|
14191
|
+
var billNo = _ref4.billNo,
|
|
14192
|
+
billType = _ref4.billType,
|
|
14193
|
+
billTag = _ref4.billTag;
|
|
13483
14194
|
return {
|
|
13484
|
-
billNo:
|
|
13485
|
-
billType:
|
|
13486
|
-
billTag:
|
|
14195
|
+
billNo: billNo,
|
|
14196
|
+
billType: billType,
|
|
14197
|
+
billTag: billTag
|
|
13487
14198
|
};
|
|
13488
14199
|
})
|
|
13489
14200
|
}));
|
|
13490
|
-
}
|
|
14201
|
+
});
|
|
13491
14202
|
onceRef.current = false;
|
|
13492
|
-
case
|
|
14203
|
+
case 2:
|
|
13493
14204
|
case "end":
|
|
13494
14205
|
return _context3.stop();
|
|
13495
14206
|
}
|
|
@@ -13519,7 +14230,7 @@ var index$1 = (function (props) {
|
|
|
13519
14230
|
dataSource: (value === null || value === void 0 ? void 0 : value.orders) || [],
|
|
13520
14231
|
columns: columns,
|
|
13521
14232
|
rowSelection: rowSelection,
|
|
13522
|
-
rowKey: 'billNo',
|
|
14233
|
+
rowKey: rowKeyMap[type] || 'billNo',
|
|
13523
14234
|
size: "small",
|
|
13524
14235
|
pagination: false,
|
|
13525
14236
|
scroll: {
|
|
@@ -13574,6 +14285,27 @@ var componentMap$1 = {
|
|
|
13574
14285
|
returnDeleteGood: 'wdtReturnDeleteGood',
|
|
13575
14286
|
exchangeDeleteGood: 'wdtExchangeDeleteGood'
|
|
13576
14287
|
}
|
|
14288
|
+
},
|
|
14289
|
+
'BS_E3_GOODS': {
|
|
14290
|
+
type: 'e3',
|
|
14291
|
+
key: 'bsE3Goods',
|
|
14292
|
+
name: '旺店通',
|
|
14293
|
+
eventNameMap: {
|
|
14294
|
+
type: 'bsE3Type',
|
|
14295
|
+
selectListReturn: 'bsE3SelectListReturn',
|
|
14296
|
+
selectList: 'bsE3SelectList',
|
|
14297
|
+
reissueSelectList: 'bsE3ReissueSelectList',
|
|
14298
|
+
reissueSelectListReturn: 'bsE3ReissueSelectListReturn',
|
|
14299
|
+
reissueDeleteGood: 'bsE3ReissueDeleteGood',
|
|
14300
|
+
changeShopCode: 'bsE3ChangeShopCode',
|
|
14301
|
+
reissueType: 'bsE3ReissueType',
|
|
14302
|
+
returnType: 'bsE3ReturnType',
|
|
14303
|
+
returnSelectListReturn: 'bsE3ReturnSelectListReturn',
|
|
14304
|
+
returnSelectList: 'bsE3ReturnSelectList',
|
|
14305
|
+
deleteGood: 'bsE3DeleteGood',
|
|
14306
|
+
returnDeleteGood: 'bsE3ReturnDeleteGood',
|
|
14307
|
+
exchangeDeleteGood: 'bsE3ExchangeDeleteGood'
|
|
14308
|
+
}
|
|
13577
14309
|
}
|
|
13578
14310
|
};
|
|
13579
14311
|
var CommonGoods = function CommonGoods(props) {
|
|
@@ -13582,6 +14314,10 @@ var CommonGoods = function CommonGoods(props) {
|
|
|
13582
14314
|
disabled = props.disabled,
|
|
13583
14315
|
onChange = props.onChange,
|
|
13584
14316
|
compType = props.type;
|
|
14317
|
+
var showModeBtn = ((value === null || value === void 0 ? void 0 : value.orders) || []).some(function (order) {
|
|
14318
|
+
return order.srcTid.includes(',');
|
|
14319
|
+
});
|
|
14320
|
+
var getOrderFlag = useRef(false);
|
|
13585
14321
|
var _useState = useState(false),
|
|
13586
14322
|
_useState2 = _slicedToArray(_useState, 2),
|
|
13587
14323
|
tableSelect = _useState2[0],
|
|
@@ -13589,8 +14325,36 @@ var CommonGoods = function CommonGoods(props) {
|
|
|
13589
14325
|
var withInfo = useRef(null);
|
|
13590
14326
|
var valueRef = useRef(null);
|
|
13591
14327
|
useEffect(function () {
|
|
14328
|
+
var _value$orders;
|
|
13592
14329
|
valueRef.current = value;
|
|
14330
|
+
if (!getOrderFlag.current && !(value === null || value === void 0 ? void 0 : (_value$orders = value.orders) === null || _value$orders === void 0 ? void 0 : _value$orders.length) && (value === null || value === void 0 ? void 0 : value.orderNo)) {
|
|
14331
|
+
getOrderFlag.current = true;
|
|
14332
|
+
getWdtOrderList(value === null || value === void 0 ? void 0 : value.orderNo);
|
|
14333
|
+
}
|
|
13593
14334
|
}, [value]);
|
|
14335
|
+
var getWdtOrderList = /*#__PURE__*/function () {
|
|
14336
|
+
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderNo) {
|
|
14337
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
14338
|
+
while (1) switch (_context.prev = _context.next) {
|
|
14339
|
+
case 0:
|
|
14340
|
+
wdtUtils.getWdtOrderListSingleton(orderNo).then(function (data) {
|
|
14341
|
+
var orders = ((data === null || data === void 0 ? void 0 : data.trades) || []).filter(function (trade) {
|
|
14342
|
+
return (value.selectIds || []).includes(trade.tradeNo);
|
|
14343
|
+
});
|
|
14344
|
+
onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
14345
|
+
orders: orders
|
|
14346
|
+
}));
|
|
14347
|
+
});
|
|
14348
|
+
case 1:
|
|
14349
|
+
case "end":
|
|
14350
|
+
return _context.stop();
|
|
14351
|
+
}
|
|
14352
|
+
}, _callee);
|
|
14353
|
+
}));
|
|
14354
|
+
return function getWdtOrderList(_x) {
|
|
14355
|
+
return _ref.apply(this, arguments);
|
|
14356
|
+
};
|
|
14357
|
+
}();
|
|
13594
14358
|
useEffect(function () {
|
|
13595
14359
|
pubsub.subscribe(componentMap$1[compType].eventNameMap.type, function (type, data) {
|
|
13596
14360
|
if (disabled) return;
|
|
@@ -13648,7 +14412,7 @@ var CommonGoods = function CommonGoods(props) {
|
|
|
13648
14412
|
});
|
|
13649
14413
|
pubsub.subscribeOnce(componentMap$1[compType].eventNameMap.changeShopCode, function (type, data) {
|
|
13650
14414
|
// console.log(data);
|
|
13651
|
-
onChange(_objectSpread2(_objectSpread2({}, valueRef === null || valueRef === void 0 ? void 0 : valueRef.current), {}, {
|
|
14415
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, valueRef === null || valueRef === void 0 ? void 0 : valueRef.current), {}, {
|
|
13652
14416
|
shopCode: data.shopCode
|
|
13653
14417
|
}));
|
|
13654
14418
|
});
|
|
@@ -13688,6 +14452,22 @@ var CommonGoods = function CommonGoods(props) {
|
|
|
13688
14452
|
var changeHandle = function changeHandle(list) {
|
|
13689
14453
|
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, componentMap$1[compType].key, list)));
|
|
13690
14454
|
};
|
|
14455
|
+
var handleModeChange = function handleModeChange(isStrict) {
|
|
14456
|
+
// isStrict 是否只展示当前平台订单商品
|
|
14457
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({
|
|
14458
|
+
isStrict: isStrict
|
|
14459
|
+
}, componentMap$1[compType].key, getGoodDetails({
|
|
14460
|
+
mode: isStrict
|
|
14461
|
+
}))));
|
|
14462
|
+
};
|
|
14463
|
+
var getGoodDetails = function getGoodDetails(_ref2) {
|
|
14464
|
+
var mode = _ref2.mode;
|
|
14465
|
+
var goodDetails = updateWdtGoodsHandle(value.orders || []);
|
|
14466
|
+
var orderNo = value.orderNo;
|
|
14467
|
+
return mode ? goodDetails.filter(function (goodItem) {
|
|
14468
|
+
return !orderNo || goodItem.srcTid === orderNo;
|
|
14469
|
+
}) : goodDetails;
|
|
14470
|
+
};
|
|
13691
14471
|
return /*#__PURE__*/React.createElement(GoodItem$1, _objectSpread2(_objectSpread2({
|
|
13692
14472
|
key: componentMap$1[compType].key
|
|
13693
14473
|
}, props), {}, {
|
|
@@ -13704,7 +14484,10 @@ var CommonGoods = function CommonGoods(props) {
|
|
|
13704
14484
|
},
|
|
13705
14485
|
onChange: function onChange(val) {
|
|
13706
14486
|
return changeHandle(val);
|
|
13707
|
-
}
|
|
14487
|
+
},
|
|
14488
|
+
onModeChange: handleModeChange,
|
|
14489
|
+
showModeBtn: showModeBtn,
|
|
14490
|
+
isStrict: value === null || value === void 0 ? void 0 : value.isStrict
|
|
13708
14491
|
}));
|
|
13709
14492
|
};
|
|
13710
14493
|
|
|
@@ -13971,8 +14754,8 @@ var typeMap$1 = {
|
|
|
13971
14754
|
key: 'wdtReissueGoods',
|
|
13972
14755
|
name: '旺店通',
|
|
13973
14756
|
typeName: 'wdtReissueType',
|
|
13974
|
-
|
|
13975
|
-
|
|
14757
|
+
systemOrder: 'wdtSystemOrder',
|
|
14758
|
+
systemOrderNo: 'wdtSystemOrderNo',
|
|
13976
14759
|
reissueSelectList: 'wdtReissueSelectList',
|
|
13977
14760
|
reissueSelectListReturn: 'wdtReissueSelectListReturn',
|
|
13978
14761
|
reissueDeleteGood: 'wdtReissueDeleteGood',
|
|
@@ -13985,7 +14768,7 @@ var typeMap$1 = {
|
|
|
13985
14768
|
}
|
|
13986
14769
|
};
|
|
13987
14770
|
var wdtReissue = function wdtReissue(props) {
|
|
13988
|
-
var
|
|
14771
|
+
var _value$wdtSystemOrder, _typeMap$type7, _typeMap$type25, _typeMap$type26, _value$typeMap$type$s5, _typeMap$type27, _typeMap$type28, _typeMap$type29;
|
|
13989
14772
|
var value = props.value,
|
|
13990
14773
|
onChange = props.onChange,
|
|
13991
14774
|
_props$reasonList = props.reasonList,
|
|
@@ -13993,177 +14776,147 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
13993
14776
|
disabled = props.disabled,
|
|
13994
14777
|
type = props.type,
|
|
13995
14778
|
other = _objectWithoutProperties(props, _excluded$g);
|
|
13996
|
-
var
|
|
13997
|
-
|
|
13998
|
-
|
|
13999
|
-
|
|
14000
|
-
|
|
14001
|
-
|
|
14002
|
-
|
|
14003
|
-
|
|
14004
|
-
var newValue = _objectSpread2({}, value);
|
|
14005
|
-
newValue["".concat((_typeMap$type2 = typeMap$1[type]) === null || _typeMap$type2 === void 0 ? void 0 : _typeMap$type2.key)] = newValue === null || newValue === void 0 ? void 0 : newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type3 = typeMap$1[type]) === null || _typeMap$type3 === void 0 ? void 0 : _typeMap$type3.key)].filter(function (item) {
|
|
14006
|
-
return item.sku !== data;
|
|
14007
|
-
});
|
|
14008
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
14009
|
-
}
|
|
14010
|
-
});
|
|
14011
|
-
pubsub.subscribeOnce("".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type4 = typeMap$1[type]) === null || _typeMap$type4 === void 0 ? void 0 : _typeMap$type4.changeShopCode), function (type, data) {
|
|
14012
|
-
onChange(_objectSpread2(_objectSpread2({}, value), {}, {
|
|
14013
|
-
shopCode: data.shopCode
|
|
14014
|
-
}));
|
|
14015
|
-
});
|
|
14016
|
-
}, [value, disabled]);
|
|
14779
|
+
var showModeBtn = ((value === null || value === void 0 ? void 0 : (_value$wdtSystemOrder = value.wdtSystemOrder) === null || _value$wdtSystemOrder === void 0 ? void 0 : _value$wdtSystemOrder.orders) || []).some(function (order) {
|
|
14780
|
+
return order.srcTid.includes(',');
|
|
14781
|
+
});
|
|
14782
|
+
var getOrderFlag = useRef(false);
|
|
14783
|
+
var _useState = useState(false),
|
|
14784
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
14785
|
+
isStrict = _useState2[0],
|
|
14786
|
+
setIsStrict = _useState2[1];
|
|
14017
14787
|
useEffect(function () {
|
|
14018
|
-
var _value$
|
|
14019
|
-
if (!(value === null || value === void 0 ? void 0 : (_value$
|
|
14020
|
-
|
|
14021
|
-
|
|
14022
|
-
|
|
14788
|
+
var _value$typeMap$type$s, _value$typeMap$type$s2, _typeMap$type, _value$typeMap$type$s3, _typeMap$type2;
|
|
14789
|
+
if (!getOrderFlag.current && !(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s = value[(_typeMap$type = typeMap$1[type]) === null || _typeMap$type === void 0 ? void 0 : _typeMap$type.systemOrder]) === null || _value$typeMap$type$s === void 0 ? void 0 : (_value$typeMap$type$s2 = _value$typeMap$type$s.orders) === null || _value$typeMap$type$s2 === void 0 ? void 0 : _value$typeMap$type$s2.length) && (value === null || value === void 0 ? void 0 : (_value$typeMap$type$s3 = value[(_typeMap$type2 = typeMap$1[type]) === null || _typeMap$type2 === void 0 ? void 0 : _typeMap$type2.systemOrder]) === null || _value$typeMap$type$s3 === void 0 ? void 0 : _value$typeMap$type$s3.orderNo)) {
|
|
14790
|
+
var _value$typeMap$type$s4, _typeMap$type3;
|
|
14791
|
+
getOrderFlag.current = true;
|
|
14792
|
+
getWdtOrderList(value === null || value === void 0 ? void 0 : (_value$typeMap$type$s4 = value[(_typeMap$type3 = typeMap$1[type]) === null || _typeMap$type3 === void 0 ? void 0 : _typeMap$type3.systemOrder]) === null || _value$typeMap$type$s4 === void 0 ? void 0 : _value$typeMap$type$s4.orderNo);
|
|
14023
14793
|
}
|
|
14024
14794
|
return;
|
|
14025
14795
|
}, [value]);
|
|
14026
14796
|
useEffect(function () {
|
|
14027
|
-
var _typeMap$
|
|
14028
|
-
var
|
|
14029
|
-
if (
|
|
14030
|
-
var _value$typeMap$type$t, _typeMap$
|
|
14031
|
-
if (['1'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t = value[(_typeMap$
|
|
14032
|
-
|
|
14797
|
+
var _typeMap$type4;
|
|
14798
|
+
var systemOrderNo = value === null || value === void 0 ? void 0 : value[(_typeMap$type4 = typeMap$1[type]) === null || _typeMap$type4 === void 0 ? void 0 : _typeMap$type4.systemOrderNo];
|
|
14799
|
+
if (systemOrderNo) {
|
|
14800
|
+
var _value$typeMap$type$t, _typeMap$type5;
|
|
14801
|
+
if (['1'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t = value[(_typeMap$type5 = typeMap$1[type]) === null || _typeMap$type5 === void 0 ? void 0 : _typeMap$type5.typeName]) === null || _value$typeMap$type$t === void 0 ? void 0 : _value$typeMap$type$t[0])) {
|
|
14802
|
+
var _typeMap$type6;
|
|
14803
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type6 = typeMap$1[type]) === null || _typeMap$type6 === void 0 ? void 0 : _typeMap$type6.key, getGoodDetails({
|
|
14804
|
+
mode: isStrict
|
|
14805
|
+
}))));
|
|
14033
14806
|
}
|
|
14034
14807
|
}
|
|
14035
14808
|
return;
|
|
14036
|
-
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$type7 = typeMap$1[type]) === null || _typeMap$type7 === void 0 ? void 0 : _typeMap$type7.
|
|
14037
|
-
useEffect(function () {
|
|
14038
|
-
var _value$typeMap$type$t2, _typeMap$type8, _typeMap$type9;
|
|
14039
|
-
var typeName = value === null || value === void 0 ? void 0 : (_value$typeMap$type$t2 = value[(_typeMap$type8 = typeMap$1[type]) === null || _typeMap$type8 === void 0 ? void 0 : _typeMap$type8.typeName]) === null || _value$typeMap$type$t2 === void 0 ? void 0 : _value$typeMap$type$t2[0];
|
|
14040
|
-
var wdtSystemOrderNo = value === null || value === void 0 ? void 0 : value[(_typeMap$type9 = typeMap$1[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.wdtSystemOrderNo];
|
|
14041
|
-
if (['1'].includes(typeName)) {
|
|
14042
|
-
wdtSystemOrderNo && getGoodItems(wdtSystemOrderNo);
|
|
14043
|
-
} else if (['2'].includes(typeName)) {
|
|
14044
|
-
var newValue = _objectSpread2({}, value);
|
|
14045
|
-
// newValue[`${typeMap?.[type]?.key}`] = [];
|
|
14046
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
14047
|
-
}
|
|
14048
|
-
return;
|
|
14049
|
-
}, [value === null || value === void 0 ? void 0 : (_value$typeMap$type$t3 = value[(_typeMap$type10 = typeMap$1[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.typeName]) === null || _value$typeMap$type$t3 === void 0 ? void 0 : _value$typeMap$type$t3[0]]);
|
|
14050
|
-
var getGoodItems = function getGoodItems(wdtSystemOrderNo) {
|
|
14051
|
-
var _value$typeMap$type$w, _typeMap$type11, _ref;
|
|
14052
|
-
var orders = value === null || value === void 0 ? void 0 : (_value$typeMap$type$w = value[(_typeMap$type11 = typeMap$1[type]) === null || _typeMap$type11 === void 0 ? void 0 : _typeMap$type11.wdtSystemOrder]) === null || _value$typeMap$type$w === void 0 ? void 0 : _value$typeMap$type$w.orders;
|
|
14053
|
-
var order = (_ref = orders || []) === null || _ref === void 0 ? void 0 : _ref.find(function (orderItem) {
|
|
14054
|
-
return orderItem.billNo === wdtSystemOrderNo;
|
|
14055
|
-
});
|
|
14056
|
-
if (order) {
|
|
14057
|
-
var _typeMap$type12, _order$goodDetails;
|
|
14058
|
-
var newValue = _objectSpread2({}, value);
|
|
14059
|
-
newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type12 = typeMap$1[type]) === null || _typeMap$type12 === void 0 ? void 0 : _typeMap$type12.key)] = order === null || order === void 0 ? void 0 : (_order$goodDetails = order.goodDetails) === null || _order$goodDetails === void 0 ? void 0 : _order$goodDetails.map(function (item) {
|
|
14060
|
-
var _typeMap$type13, _typeMap$type14;
|
|
14061
|
-
item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type13 = typeMap$1[type]) === null || _typeMap$type13 === void 0 ? void 0 : _typeMap$type13.formatDefaultField.money)] = 0;
|
|
14062
|
-
item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type14 = typeMap$1[type]) === null || _typeMap$type14 === void 0 ? void 0 : _typeMap$type14.formatDefaultField.share)] = 0;
|
|
14063
|
-
item.canUpdateNumber = true;
|
|
14064
|
-
return item;
|
|
14065
|
-
});
|
|
14066
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
14067
|
-
}
|
|
14068
|
-
};
|
|
14809
|
+
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$type7 = typeMap$1[type]) === null || _typeMap$type7 === void 0 ? void 0 : _typeMap$type7.systemOrderNo]]);
|
|
14069
14810
|
var getWdtOrderList = /*#__PURE__*/function () {
|
|
14070
|
-
var
|
|
14071
|
-
var _yield$request, success, data, _typeMap$type15, _typeMap$type16, orders, showOrderInfo;
|
|
14811
|
+
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderNo) {
|
|
14072
14812
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
14073
14813
|
while (1) switch (_context.prev = _context.next) {
|
|
14074
14814
|
case 0:
|
|
14075
|
-
|
|
14076
|
-
|
|
14077
|
-
|
|
14078
|
-
|
|
14079
|
-
billNo
|
|
14080
|
-
|
|
14081
|
-
|
|
14082
|
-
case 2:
|
|
14083
|
-
_yield$request = _context.sent;
|
|
14084
|
-
success = _yield$request.success;
|
|
14085
|
-
data = _yield$request.data;
|
|
14086
|
-
if (success) {
|
|
14087
|
-
orders = ((data === null || data === void 0 ? void 0 : data.trades) || []).map(function (item) {
|
|
14088
|
-
return _objectSpread2(_objectSpread2({}, item), {}, {
|
|
14089
|
-
billNo: item.tradeNo,
|
|
14090
|
-
billType: WDT_ORDER_TYPE_MAP[item.tradeType],
|
|
14091
|
-
billTag: item.tagName
|
|
14092
|
-
});
|
|
14093
|
-
});
|
|
14094
|
-
showOrderInfo = data === null || data === void 0 ? void 0 : data.trades.map(function (item) {
|
|
14815
|
+
wdtUtils.getWdtOrderListSingleton(orderNo).then(function (data) {
|
|
14816
|
+
var _typeMap$type8, _typeMap$type9;
|
|
14817
|
+
var orders = (data === null || data === void 0 ? void 0 : data.trades) || [];
|
|
14818
|
+
var showOrderInfo = orders.map(function (_ref2) {
|
|
14819
|
+
var billNo = _ref2.billNo,
|
|
14820
|
+
billType = _ref2.billType,
|
|
14821
|
+
billTag = _ref2.billTag;
|
|
14095
14822
|
return {
|
|
14096
|
-
billNo:
|
|
14097
|
-
billType:
|
|
14098
|
-
billTag:
|
|
14823
|
+
billNo: billNo,
|
|
14824
|
+
billType: billType,
|
|
14825
|
+
billTag: billTag
|
|
14099
14826
|
};
|
|
14100
14827
|
});
|
|
14101
|
-
onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$
|
|
14828
|
+
onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type8 = typeMap$1[type]) === null || _typeMap$type8 === void 0 ? void 0 : _typeMap$type8.systemOrder, _objectSpread2(_objectSpread2({}, value[(_typeMap$type9 = typeMap$1[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.systemOrder]), {}, {
|
|
14102
14829
|
showOrderInfo: showOrderInfo,
|
|
14103
14830
|
orders: orders
|
|
14104
14831
|
}))));
|
|
14105
|
-
}
|
|
14106
|
-
case
|
|
14832
|
+
});
|
|
14833
|
+
case 1:
|
|
14107
14834
|
case "end":
|
|
14108
14835
|
return _context.stop();
|
|
14109
14836
|
}
|
|
14110
14837
|
}, _callee);
|
|
14111
14838
|
}));
|
|
14112
14839
|
return function getWdtOrderList(_x) {
|
|
14113
|
-
return
|
|
14840
|
+
return _ref.apply(this, arguments);
|
|
14114
14841
|
};
|
|
14115
14842
|
}();
|
|
14116
14843
|
var changeTypeHandle = function changeTypeHandle(val) {
|
|
14117
|
-
var _typeMap$
|
|
14844
|
+
var _value$typeMap$type$t2, _typeMap$type10, _typeMap$type11;
|
|
14845
|
+
var typeName = val === null || val === void 0 ? void 0 : val[0];
|
|
14846
|
+
if (typeName === (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t2 = value[(_typeMap$type10 = typeMap$1[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.typeName]) === null || _value$typeMap$type$t2 === void 0 ? void 0 : _value$typeMap$type$t2[0])) return;
|
|
14847
|
+
// const systemOrderNo = value?.[typeMap[type]?.systemOrderNo];
|
|
14118
14848
|
var newValue = _objectSpread2({}, value);
|
|
14119
|
-
newValue[
|
|
14120
|
-
|
|
14849
|
+
newValue[(_typeMap$type11 = typeMap$1[type]) === null || _typeMap$type11 === void 0 ? void 0 : _typeMap$type11.typeName] = val;
|
|
14850
|
+
if (typeName === '1') {
|
|
14851
|
+
var _typeMap$type12;
|
|
14852
|
+
newValue[(_typeMap$type12 = typeMap$1[type]) === null || _typeMap$type12 === void 0 ? void 0 : _typeMap$type12.key] = getGoodDetails({
|
|
14853
|
+
mode: isStrict
|
|
14854
|
+
});
|
|
14855
|
+
} else if (typeName === '2') {
|
|
14856
|
+
var _typeMap$type13;
|
|
14857
|
+
// 切换到非原单,清空列表
|
|
14858
|
+
newValue[(_typeMap$type13 = typeMap$1[type]) === null || _typeMap$type13 === void 0 ? void 0 : _typeMap$type13.key] = [];
|
|
14859
|
+
}
|
|
14121
14860
|
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
14122
|
-
valueRef.current = newValue;
|
|
14123
|
-
// if (['2'].includes(val[0])) {
|
|
14124
|
-
// onChange?.(newValue);
|
|
14125
|
-
// valueRef.current = newValue;
|
|
14126
|
-
// }
|
|
14127
|
-
// pubsub.publish(`${typeMap?.[type]?.reissueType}`, {
|
|
14128
|
-
// val: val[0],
|
|
14129
|
-
// goodValue: newValue,
|
|
14130
|
-
// });
|
|
14131
14861
|
};
|
|
14132
|
-
|
|
14862
|
+
var handleModeChange = function handleModeChange(mode) {
|
|
14863
|
+
var _value$typeMap$type$t3, _typeMap$type14, _typeMap$type15;
|
|
14864
|
+
var isOriginalOrder = (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t3 = value[(_typeMap$type14 = typeMap$1[type]) === null || _typeMap$type14 === void 0 ? void 0 : _typeMap$type14.typeName]) === null || _value$typeMap$type$t3 === void 0 ? void 0 : _value$typeMap$type$t3[0]) === '1';
|
|
14865
|
+
setIsStrict(mode);
|
|
14866
|
+
if (!isOriginalOrder) return;
|
|
14867
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type15 = typeMap$1[type]) === null || _typeMap$type15 === void 0 ? void 0 : _typeMap$type15.key, getGoodDetails({
|
|
14868
|
+
mode: mode
|
|
14869
|
+
}))));
|
|
14870
|
+
};
|
|
14871
|
+
var getGoodDetails = function getGoodDetails(_ref3) {
|
|
14872
|
+
var _typeMap$type16, _typeMap$type17, _order$goodDetails;
|
|
14873
|
+
var mode = _ref3.mode;
|
|
14874
|
+
var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type16 = typeMap$1[type]) === null || _typeMap$type16 === void 0 ? void 0 : _typeMap$type16.systemOrder];
|
|
14875
|
+
var systemOrderNo = value === null || value === void 0 ? void 0 : value[(_typeMap$type17 = typeMap$1[type]) === null || _typeMap$type17 === void 0 ? void 0 : _typeMap$type17.systemOrderNo];
|
|
14876
|
+
var order = systemOrderNo && ((systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orders) || []).find(function (order) {
|
|
14877
|
+
return order.tradeNo === systemOrderNo;
|
|
14878
|
+
});
|
|
14879
|
+
var goodDetails = (order === null || order === void 0 ? void 0 : (_order$goodDetails = order.goodDetails) === null || _order$goodDetails === void 0 ? void 0 : _order$goodDetails.length) ? updateWdtGoodsHandle([order]) : [];
|
|
14880
|
+
var orderNo = systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orderNo;
|
|
14881
|
+
return mode ? goodDetails.filter(function (goodItem) {
|
|
14882
|
+
return !orderNo || goodItem.srcTid === orderNo;
|
|
14883
|
+
}) : goodDetails;
|
|
14884
|
+
};
|
|
14133
14885
|
var changeGoodHandle = function changeGoodHandle(val) {
|
|
14134
|
-
var _typeMap$
|
|
14886
|
+
var _typeMap$type18;
|
|
14135
14887
|
var newValue = _objectSpread2({}, value);
|
|
14136
|
-
newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
14137
|
-
var _typeMap$
|
|
14138
|
-
item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
14139
|
-
item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
14888
|
+
newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type18 = typeMap$1[type]) === null || _typeMap$type18 === void 0 ? void 0 : _typeMap$type18.key)] = (val || []).map(function (item) {
|
|
14889
|
+
var _typeMap$type19, _typeMap$type20;
|
|
14890
|
+
item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type19 = typeMap$1[type]) === null || _typeMap$type19 === void 0 ? void 0 : _typeMap$type19.formatDefaultField.money)] = 0;
|
|
14891
|
+
item["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type20 = typeMap$1[type]) === null || _typeMap$type20 === void 0 ? void 0 : _typeMap$type20.formatDefaultField.share)] = 0;
|
|
14140
14892
|
return item;
|
|
14141
14893
|
});
|
|
14142
14894
|
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
14143
14895
|
};
|
|
14144
14896
|
var changeSystemOrderHandle = function changeSystemOrderHandle(val) {
|
|
14145
|
-
var _typeMap$
|
|
14897
|
+
var _typeMap$type21, _value$typeMap$type$t4, _typeMap$type22;
|
|
14146
14898
|
var newValue = _objectSpread2({}, value);
|
|
14147
|
-
newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
14148
|
-
if (['2'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t4 = value[(_typeMap$
|
|
14149
|
-
var _typeMap$
|
|
14150
|
-
newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
14899
|
+
newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type21 = typeMap$1[type]) === null || _typeMap$type21 === void 0 ? void 0 : _typeMap$type21.systemOrderNo)] = val;
|
|
14900
|
+
if (['2'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t4 = value[(_typeMap$type22 = typeMap$1[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.typeName]) === null || _value$typeMap$type$t4 === void 0 ? void 0 : _value$typeMap$type$t4[0])) {
|
|
14901
|
+
var _typeMap$type23;
|
|
14902
|
+
newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type23 = typeMap$1[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.key)] = [];
|
|
14151
14903
|
}
|
|
14152
14904
|
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
14153
14905
|
};
|
|
14154
14906
|
//显示选择商品按钮 原单换不显示选择商品
|
|
14155
14907
|
var showChangeBtn = useMemo(function () {
|
|
14156
|
-
var _typeMap$
|
|
14157
|
-
return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$
|
|
14158
|
-
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$
|
|
14908
|
+
var _typeMap$type24;
|
|
14909
|
+
return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type24 = typeMap$1[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.systemOrderNo]);
|
|
14910
|
+
}, [value === null || value === void 0 ? void 0 : value[(_typeMap$type25 = typeMap$1[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.systemOrderNo]]);
|
|
14159
14911
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
|
|
14160
|
-
gutter: 8
|
|
14912
|
+
gutter: 8,
|
|
14913
|
+
wrap: true
|
|
14161
14914
|
}, /*#__PURE__*/React.createElement(Col, {
|
|
14162
14915
|
className: "gutter-row",
|
|
14163
14916
|
xs: {
|
|
14164
14917
|
span: 11
|
|
14165
14918
|
},
|
|
14166
|
-
|
|
14919
|
+
sm: {
|
|
14167
14920
|
span: 6
|
|
14168
14921
|
}
|
|
14169
14922
|
}, /*#__PURE__*/React.createElement(Select, {
|
|
@@ -14172,12 +14925,12 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
14172
14925
|
},
|
|
14173
14926
|
disabled: disabled,
|
|
14174
14927
|
allowClear: false,
|
|
14175
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
14928
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type26 = typeMap$1[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.systemOrderNo)],
|
|
14176
14929
|
onChange: function onChange(val) {
|
|
14177
14930
|
return changeSystemOrderHandle(val);
|
|
14178
14931
|
},
|
|
14179
14932
|
placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
|
|
14180
|
-
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$
|
|
14933
|
+
}, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type27 = typeMap$1[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
|
|
14181
14934
|
return /*#__PURE__*/React.createElement(Select.Option, {
|
|
14182
14935
|
key: item.billNo,
|
|
14183
14936
|
value: item.billNo,
|
|
@@ -14188,7 +14941,7 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
14188
14941
|
xs: {
|
|
14189
14942
|
span: 11
|
|
14190
14943
|
},
|
|
14191
|
-
|
|
14944
|
+
sm: {
|
|
14192
14945
|
span: 6
|
|
14193
14946
|
}
|
|
14194
14947
|
}, /*#__PURE__*/React.createElement(Cascader, {
|
|
@@ -14198,7 +14951,7 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
14198
14951
|
disabled: disabled,
|
|
14199
14952
|
allowClear: false,
|
|
14200
14953
|
options: reasonList,
|
|
14201
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
14954
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type28 = typeMap$1[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.typeName)],
|
|
14202
14955
|
onChange: function onChange(val) {
|
|
14203
14956
|
return changeTypeHandle(val);
|
|
14204
14957
|
}
|
|
@@ -14210,10 +14963,13 @@ var wdtReissue = function wdtReissue(props) {
|
|
|
14210
14963
|
canUpdateNumber: showChangeBtn,
|
|
14211
14964
|
showChangeBtn: showChangeBtn,
|
|
14212
14965
|
shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
|
|
14213
|
-
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$
|
|
14966
|
+
value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type29 = typeMap$1[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.key)],
|
|
14214
14967
|
onChange: function onChange(val) {
|
|
14215
14968
|
return changeGoodHandle(val);
|
|
14216
|
-
}
|
|
14969
|
+
},
|
|
14970
|
+
onModeChange: handleModeChange,
|
|
14971
|
+
showModeBtn: showModeBtn,
|
|
14972
|
+
isStrict: isStrict
|
|
14217
14973
|
})));
|
|
14218
14974
|
};
|
|
14219
14975
|
|
|
@@ -14223,7 +14979,7 @@ styleInject(css_248z$a);
|
|
|
14223
14979
|
var TabPane$1 = Tabs.TabPane;
|
|
14224
14980
|
var Option$2 = Select.Option;
|
|
14225
14981
|
var Search$1 = Input.Search;
|
|
14226
|
-
var GoodsModal$
|
|
14982
|
+
var GoodsModal$5 = function GoodsModal(props) {
|
|
14227
14983
|
var onSubmit = props.onSubmit,
|
|
14228
14984
|
_onCancel = props.onCancel,
|
|
14229
14985
|
visible = props.visible,
|
|
@@ -14674,7 +15430,7 @@ var Goods$1 = function Goods(props, ref) {
|
|
|
14674
15430
|
};
|
|
14675
15431
|
return /*#__PURE__*/React.createElement("div", {
|
|
14676
15432
|
className: "goodsBox"
|
|
14677
|
-
}, /*#__PURE__*/React.createElement(GoodsModal$
|
|
15433
|
+
}, /*#__PURE__*/React.createElement(GoodsModal$5, {
|
|
14678
15434
|
visible: visible,
|
|
14679
15435
|
onSubmit: onSubmit,
|
|
14680
15436
|
type: type,
|
|
@@ -14904,7 +15660,10 @@ var msgTypeCh = {
|
|
|
14904
15660
|
ding: '钉钉',
|
|
14905
15661
|
wechat: '微信',
|
|
14906
15662
|
qq: 'QQ',
|
|
14907
|
-
qywx: '企业微信'
|
|
15663
|
+
qywx: '企业微信',
|
|
15664
|
+
YZDKH: '邮政拦截',
|
|
15665
|
+
YT: '圆通拦截',
|
|
15666
|
+
feishu: '飞书'
|
|
14908
15667
|
};
|
|
14909
15668
|
var MsgStatus = function MsgStatus(props) {
|
|
14910
15669
|
var _value$changeIndex, _value$changeIndex2, _value$changeIndex3;
|