@kmkf-fe-packages/basic-components 2.0.54-beta.2 → 2.0.54-beta.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.esm.js CHANGED
@@ -3,384 +3,370 @@ import { Cascader, DatePicker, InputNumber, Input, Select, Upload, Image, messag
3
3
  import { EyeOutlined, DeleteOutlined, CloseOutlined, CopyOutlined, CloseCircleOutlined, CaretUpOutlined, MinusCircleFilled } from '@ant-design/icons';
4
4
  import request, { extend as extend$1 } from 'umi-request';
5
5
  import { CopyToClipboard } from 'react-copy-to-clipboard';
6
- import { AddressData, BsAddressData, WdtAddressData, GyAddressData, request as request$1, ExpressData, uuid, columnsGoodsList, LogisticsAddressData, SendDataCenter, BS_E3_BOOLEAN_STATUS_MAP, isNull, filterWdtOrders, WDT_ORDER_TYPE_MAP, filterBsE3Orders, filterGyOrders, GY_DELIVERY_STATE_MAPPING, servers, filterJstOrders, filterKmOrders, getIsPlatformCodesIncludeOrderNos, BS_SYSTEM_ORDER_CONFIG, KM_SYSTEM_ORDER_CONFIG, WLN_SYSTEM_ORDER_CONFIG, WDT_SYSTEM_ORDER_CONFIG, BS_E3_SYSTEM_ORDER_CONFIG, GY_SYSTEM_ORDER_CONFIG, JST_SYSTEM_ORDER_CONFIG, updateWdtGoodsHandle, updateBsE3GoodsHandle, updateGyGoodsHandle, updateJstGoodsHandle, jstMergeIdenticalGoods, msgTypeCh, pushGyLog } from '@kmkf-fe-packages/kmkf-utils';
6
+ import { AddressData, BsAddressData, WdtAddressData, GyAddressData, request as request$1, ExpressData, uuid, columnsGoodsList, LogisticsAddressData, SendDataCenter, BS_E3_BOOLEAN_STATUS_MAP, isNull, filterWdtOrders, WDT_ORDER_TYPE_MAP, tradeStatusMap, filterBsE3Orders, filterGyOrders, GY_DELIVERY_STATE_MAPPING, servers, filterJstOrders, filterKmOrders, getIsPlatformCodesIncludeOrderNos, BS_SYSTEM_ORDER_CONFIG, KM_SYSTEM_ORDER_CONFIG, WLN_SYSTEM_ORDER_CONFIG, WDT_SYSTEM_ORDER_CONFIG, BS_E3_SYSTEM_ORDER_CONFIG, GY_SYSTEM_ORDER_CONFIG, JST_SYSTEM_ORDER_CONFIG, updateWdtGoodsHandle, updateBsE3GoodsHandle, updateGyGoodsHandle, updateJstGoodsHandle, jstMergeIdenticalGoods, msgTypeCh, pushGyLog } from '@kmkf-fe-packages/kmkf-utils';
7
7
  import { debounce, isNaN as isNaN$1, isNumber as isNumber$1, cloneDeep, difference, differenceWith, isEqual, takeRight, reject, isEmpty, intersection, uniqBy } from 'lodash';
8
8
  import { useUpdateEffect, useDebounceEffect, useAntdTable } from 'ahooks';
9
9
  import zhCN from 'antd/lib/locale/zh_CN';
10
10
  import pubsub from 'pubsub-js';
11
11
  import BigNumber from 'bignumber.js';
12
12
 
13
- function _iterableToArrayLimit(r, l) {
14
- var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
15
- if (null != t) {
16
- var e,
17
- n,
18
- i,
19
- u,
20
- a = [],
21
- f = !0,
22
- o = !1;
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 (i = (t = t.call(r)).next, 0 === l) {
25
- if (Object(t) !== t) return;
26
- f = !1;
27
- } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
28
- } catch (r) {
29
- o = !0, n = r;
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 (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
32
+ if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return;
33
33
  } finally {
34
- if (o) throw n;
34
+ if (_d) throw _e;
35
35
  }
36
36
  }
37
- return a;
37
+ return _arr;
38
38
  }
39
39
  }
40
- function ownKeys(e, r) {
41
- var t = Object.keys(e);
40
+ function ownKeys(object, enumerableOnly) {
41
+ var keys = Object.keys(object);
42
42
  if (Object.getOwnPropertySymbols) {
43
- var o = Object.getOwnPropertySymbols(e);
44
- r && (o = o.filter(function (r) {
45
- return Object.getOwnPropertyDescriptor(e, r).enumerable;
46
- })), t.push.apply(t, o);
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 t;
49
- }
50
- function _objectSpread2(e) {
51
- for (var r = 1; r < arguments.length; r++) {
52
- var t = null != arguments[r] ? arguments[r] : {};
53
- r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {
54
- _defineProperty(e, r, t[r]);
55
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
56
- Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
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 e;
59
+ return target;
60
60
  }
61
61
  function _regeneratorRuntime() {
62
62
  _regeneratorRuntime = function () {
63
- return e;
63
+ return exports;
64
64
  };
65
- var t,
66
- e = {},
67
- r = Object.prototype,
68
- n = r.hasOwnProperty,
69
- o = Object.defineProperty || function (t, e, r) {
70
- t[e] = r.value;
65
+ var exports = {},
66
+ Op = Object.prototype,
67
+ hasOwn = Op.hasOwnProperty,
68
+ defineProperty = Object.defineProperty || function (obj, key, desc) {
69
+ obj[key] = desc.value;
71
70
  },
72
- i = "function" == typeof Symbol ? Symbol : {},
73
- a = i.iterator || "@@iterator",
74
- c = i.asyncIterator || "@@asyncIterator",
75
- u = i.toStringTag || "@@toStringTag";
76
- function define(t, e, r) {
77
- return Object.defineProperty(t, e, {
78
- value: r,
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
- }), t[e];
81
+ }), obj[key];
83
82
  }
84
83
  try {
85
84
  define({}, "");
86
- } catch (t) {
87
- define = function (t, e, r) {
88
- return t[e] = r;
85
+ } catch (err) {
86
+ define = function (obj, key, value) {
87
+ return obj[key] = value;
89
88
  };
90
89
  }
91
- function wrap(t, e, r, n) {
92
- var i = e && e.prototype instanceof Generator ? e : Generator,
93
- a = Object.create(i.prototype),
94
- c = new Context(n || []);
95
- return o(a, "_invoke", {
96
- value: makeInvokeMethod(t, r, c)
97
- }), a;
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(t, e, r) {
98
+ function tryCatch(fn, obj, arg) {
100
99
  try {
101
100
  return {
102
101
  type: "normal",
103
- arg: t.call(e, r)
102
+ arg: fn.call(obj, arg)
104
103
  };
105
- } catch (t) {
104
+ } catch (err) {
106
105
  return {
107
106
  type: "throw",
108
- arg: t
107
+ arg: err
109
108
  };
110
109
  }
111
110
  }
112
- e.wrap = wrap;
113
- var h = "suspendedStart",
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 p = {};
122
- define(p, a, function () {
116
+ var IteratorPrototype = {};
117
+ define(IteratorPrototype, iteratorSymbol, function () {
123
118
  return this;
124
119
  });
125
- var d = Object.getPrototypeOf,
126
- v = d && d(d(values([])));
127
- v && v !== r && n.call(v, a) && (p = v);
128
- var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p);
129
- function defineIteratorMethods(t) {
130
- ["next", "throw", "return"].forEach(function (e) {
131
- define(t, e, function (t) {
132
- return this._invoke(e, t);
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(t, e) {
137
- function invoke(r, o, i, a) {
138
- var c = tryCatch(t[r], t, o);
139
- if ("throw" !== c.type) {
140
- var u = c.arg,
141
- h = u.value;
142
- return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) {
143
- invoke("next", t, i, a);
144
- }, function (t) {
145
- invoke("throw", t, i, a);
146
- }) : e.resolve(h).then(function (t) {
147
- u.value = t, i(u);
148
- }, function (t) {
149
- return invoke("throw", t, i, a);
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
- a(c.arg);
147
+ reject(record.arg);
153
148
  }
154
- var r;
155
- o(this, "_invoke", {
156
- value: function (t, n) {
149
+ var previousPromise;
150
+ defineProperty(this, "_invoke", {
151
+ value: function (method, arg) {
157
152
  function callInvokeWithMethodAndArg() {
158
- return new e(function (e, r) {
159
- invoke(t, n, e, r);
153
+ return new PromiseImpl(function (resolve, reject) {
154
+ invoke(method, arg, resolve, reject);
160
155
  });
161
156
  }
162
- return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
157
+ return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
163
158
  }
164
159
  });
165
160
  }
166
- function makeInvokeMethod(e, r, n) {
167
- var o = h;
168
- return function (i, a) {
169
- if (o === f) throw new Error("Generator is already running");
170
- if (o === s) {
171
- if ("throw" === i) throw a;
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 (n.method = i, n.arg = a;;) {
178
- var c = n.delegate;
179
- if (c) {
180
- var u = maybeInvokeDelegate(c, n);
181
- if (u) {
182
- if (u === y) continue;
183
- return u;
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" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
187
- if (o === h) throw o = s, n.arg;
188
- n.dispatchException(n.arg);
189
- } else "return" === n.method && n.abrupt("return", n.arg);
190
- o = f;
191
- var p = tryCatch(e, r, n);
192
- if ("normal" === p.type) {
193
- if (o = n.done ? s : l, p.arg === y) continue;
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: p.arg,
196
- done: n.done
187
+ value: record.arg,
188
+ done: context.done
197
189
  };
198
190
  }
199
- "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
191
+ "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg);
200
192
  }
201
193
  };
202
194
  }
203
- function maybeInvokeDelegate(e, r) {
204
- var n = r.method,
205
- o = e.iterator[n];
206
- if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
207
- var i = tryCatch(o, e.iterator, r.arg);
208
- if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
209
- var a = i.arg;
210
- return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
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(t) {
213
- var e = {
214
- tryLoc: t[0]
204
+ function pushTryEntry(locs) {
205
+ var entry = {
206
+ tryLoc: locs[0]
215
207
  };
216
- 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
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(t) {
219
- var e = t.completion || {};
220
- e.type = "normal", delete e.arg, t.completion = e;
210
+ function resetTryEntry(entry) {
211
+ var record = entry.completion || {};
212
+ record.type = "normal", delete record.arg, entry.completion = record;
221
213
  }
222
- function Context(t) {
214
+ function Context(tryLocsList) {
223
215
  this.tryEntries = [{
224
216
  tryLoc: "root"
225
- }], t.forEach(pushTryEntry, this), this.reset(!0);
217
+ }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0);
226
218
  }
227
- function values(e) {
228
- if (e || "" === e) {
229
- var r = e[a];
230
- if (r) return r.call(e);
231
- if ("function" == typeof e.next) return e;
232
- if (!isNaN(e.length)) {
233
- var o = -1,
234
- i = function next() {
235
- for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
236
- return next.value = t, next.done = !0, next;
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 i.next = i;
230
+ return next.next = next;
239
231
  }
240
232
  }
241
- throw new TypeError(typeof e + " is not iterable");
233
+ return {
234
+ next: doneResult
235
+ };
242
236
  }
243
- return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
237
+ function doneResult() {
238
+ return {
239
+ value: undefined,
240
+ done: !0
241
+ };
242
+ }
243
+ return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", {
244
244
  value: GeneratorFunctionPrototype,
245
245
  configurable: !0
246
- }), o(GeneratorFunctionPrototype, "constructor", {
246
+ }), defineProperty(GeneratorFunctionPrototype, "constructor", {
247
247
  value: GeneratorFunction,
248
248
  configurable: !0
249
- }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
250
- var e = "function" == typeof t && t.constructor;
251
- return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
252
- }, e.mark = function (t) {
253
- return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
254
- }, e.awrap = function (t) {
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: t
256
+ __await: arg
257
257
  };
258
- }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
258
+ }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
259
259
  return this;
260
- }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
261
- void 0 === i && (i = Promise);
262
- var a = new AsyncIterator(wrap(t, r, n, o), i);
263
- return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
264
- return t.done ? t.value : a.next();
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(g), define(g, u, "Generator"), define(g, a, function () {
266
+ }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () {
267
267
  return this;
268
- }), define(g, "toString", function () {
268
+ }), define(Gp, "toString", function () {
269
269
  return "[object Generator]";
270
- }), e.keys = function (t) {
271
- var e = Object(t),
272
- r = [];
273
- for (var n in e) r.push(n);
274
- return r.reverse(), function next() {
275
- for (; r.length;) {
276
- var t = r.pop();
277
- if (t in e) return next.value = t, next.done = !1, next;
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
- }, e.values = values, Context.prototype = {
281
+ }, exports.values = values, Context.prototype = {
282
282
  constructor: Context,
283
- reset: function (e) {
284
- if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
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 t = this.tryEntries[0].completion;
289
- if ("throw" === t.type) throw t.arg;
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 (e) {
293
- if (this.done) throw e;
294
- var r = this;
295
- function handle(n, o) {
296
- return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
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 o = this.tryEntries.length - 1; o >= 0; --o) {
299
- var i = this.tryEntries[o],
300
- a = i.completion;
301
- if ("root" === i.tryLoc) return handle("end");
302
- if (i.tryLoc <= this.prev) {
303
- var c = n.call(i, "catchLoc"),
304
- u = n.call(i, "finallyLoc");
305
- if (c && u) {
306
- if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
307
- if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
308
- } else if (c) {
309
- if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
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 (!u) throw new Error("try statement without catch or finally");
312
- if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
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 (t, e) {
318
- for (var r = this.tryEntries.length - 1; r >= 0; --r) {
319
- var o = this.tryEntries[r];
320
- if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
321
- var i = o;
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
- i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
326
- var a = i ? i.completion : {};
327
- return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
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 (t, e) {
330
- if ("throw" === t.type) throw t.arg;
331
- return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
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 (t) {
334
- for (var e = this.tryEntries.length - 1; e >= 0; --e) {
335
- var r = this.tryEntries[e];
336
- if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
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 (t) {
340
- for (var e = this.tryEntries.length - 1; e >= 0; --e) {
341
- var r = this.tryEntries[e];
342
- if (r.tryLoc === t) {
343
- var n = r.completion;
344
- if ("throw" === n.type) {
345
- var o = n.arg;
346
- resetTryEntry(r);
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 o;
348
+ return thrown;
349
349
  }
350
350
  }
351
351
  throw new Error("illegal catch attempt");
352
352
  },
353
- delegateYield: function (e, r, n) {
353
+ delegateYield: function (iterable, resultName, nextLoc) {
354
354
  return this.delegate = {
355
- iterator: values(e),
356
- resultName: r,
357
- nextLoc: n
358
- }, "next" === this.method && (this.arg = t), y;
359
- }
360
- }, e;
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(o) {
362
+ function _typeof(obj) {
377
363
  "@babel/helpers - typeof";
378
364
 
379
- return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
380
- return typeof o;
381
- } : function (o) {
382
- return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
383
- }, _typeof(o);
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,71 @@ 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 _createForOfIteratorHelper(o, allowArrayLike) {
477
+ var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
478
+ if (!it) {
479
+ if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
480
+ if (it) o = it;
481
+ var i = 0;
482
+ var F = function () {};
483
+ return {
484
+ s: F,
485
+ n: function () {
486
+ if (i >= o.length) return {
487
+ done: true
488
+ };
489
+ return {
490
+ done: false,
491
+ value: o[i++]
492
+ };
493
+ },
494
+ e: function (e) {
495
+ throw e;
496
+ },
497
+ f: F
498
+ };
499
+ }
500
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
501
+ }
502
+ var normalCompletion = true,
503
+ didErr = false,
504
+ err;
505
+ return {
506
+ s: function () {
507
+ it = it.call(o);
508
+ },
509
+ n: function () {
510
+ var step = it.next();
511
+ normalCompletion = step.done;
512
+ return step;
513
+ },
514
+ e: function (e) {
515
+ didErr = true;
516
+ err = e;
517
+ },
518
+ f: function () {
519
+ try {
520
+ if (!normalCompletion && it.return != null) it.return();
521
+ } finally {
522
+ if (didErr) throw err;
523
+ }
524
+ }
525
+ };
526
+ }
527
+ function _toPrimitive(input, hint) {
528
+ if (typeof input !== "object" || input === null) return input;
529
+ var prim = input[Symbol.toPrimitive];
530
+ if (prim !== undefined) {
531
+ var res = prim.call(input, hint || "default");
532
+ if (typeof res !== "object") return res;
533
+ throw new TypeError("@@toPrimitive must return a primitive value.");
534
+ }
535
+ return (hint === "string" ? String : Number)(input);
536
+ }
537
+ function _toPropertyKey(arg) {
538
+ var key = _toPrimitive(arg, "string");
539
+ return typeof key === "symbol" ? key : String(key);
540
+ }
490
541
 
491
542
  function ApaasCascader(props) {
492
543
  return /*#__PURE__*/React.createElement(Cascader, _objectSpread2({
@@ -7950,7 +8001,8 @@ var WidgetMap = {
7950
8001
  var pageSize = 50;
7951
8002
  var SubForm = function SubForm(props) {
7952
8003
  var _selectOptions$;
7953
- var value = props.value,
8004
+ var _props$value = props.value,
8005
+ value = _props$value === void 0 ? [] : _props$value,
7954
8006
  onChange = props.onChange,
7955
8007
  needFilterShopByPermission = props.needFilterShopByPermission,
7956
8008
  _props$subConfig = props.subConfig,
@@ -8252,7 +8304,7 @@ var SubForm = function SubForm(props) {
8252
8304
  }
8253
8305
  });
8254
8306
  }
8255
- onChange === null || onChange === void 0 ? void 0 : onChange([].concat(_toConsumableArray(value), [_objectSpread2(_objectSpread2({}, newValue), {}, {
8307
+ onChange === null || onChange === void 0 ? void 0 : onChange([].concat(_toConsumableArray(value || []), [_objectSpread2(_objectSpread2({}, newValue), {}, {
8256
8308
  uuid: uuid()
8257
8309
  })]));
8258
8310
  };
@@ -10910,7 +10962,7 @@ var LogisticsInterception = function LogisticsInterception(props) {
10910
10962
  }
10911
10963
  })), /*#__PURE__*/React.createElement(Item, {
10912
10964
  label: '发件人手机号',
10913
- required: true,
10965
+ // required={true}
10914
10966
  key: 'interceptSenderMobile',
10915
10967
  hidden: !showSenderMobile
10916
10968
  }, /*#__PURE__*/React.createElement(Input, {
@@ -11090,7 +11142,11 @@ var LogisticsTrajectory = function LogisticsTrajectory(props) {
11090
11142
  _props$value = props.value,
11091
11143
  value = _props$value === void 0 ? {} : _props$value,
11092
11144
  disabled = props.disabled,
11093
- onChange = props.onChange;
11145
+ onChange = props.onChange,
11146
+ _props$isSingle = props.isSingle,
11147
+ isSingle = _props$isSingle === void 0 ? true : _props$isSingle,
11148
+ _props$trajectoryApiS = props.trajectoryApiStatus,
11149
+ trajectoryApiStatus = _props$trajectoryApiS === void 0 ? false : _props$trajectoryApiS;
11094
11150
  var handleInputChange = function handleInputChange(e, type) {
11095
11151
  var val = e.target.value;
11096
11152
  typeof onChange === 'function' && onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, type, val)));
@@ -11101,6 +11157,16 @@ var LogisticsTrajectory = function LogisticsTrajectory(props) {
11101
11157
  }));
11102
11158
  handleSearchSnapshot(val);
11103
11159
  };
11160
+ var handleStatusChange = function handleStatusChange(val) {
11161
+ var _value$trajectoryApiS;
11162
+ var newVal = _objectSpread2(_objectSpread2({}, value), {}, {
11163
+ trajectoryApiStatus: {
11164
+ status: val,
11165
+ reason: (value === null || value === void 0 ? void 0 : (_value$trajectoryApiS = value.trajectoryApiStatus) === null || _value$trajectoryApiS === void 0 ? void 0 : _value$trajectoryApiS.reason) || ''
11166
+ }
11167
+ });
11168
+ onChange(newVal);
11169
+ };
11104
11170
  var handleSearchSnapshot = function handleSearchSnapshot(company) {
11105
11171
  var trajectoryCompany = value.trajectoryCompany,
11106
11172
  trajectoryCode = value.trajectoryCode,
@@ -11200,6 +11266,31 @@ var LogisticsTrajectory = function LogisticsTrajectory(props) {
11200
11266
  }
11201
11267
  });
11202
11268
  };
11269
+ // 接口状态
11270
+ var LogisticsApiStatus = function LogisticsApiStatus() {
11271
+ var _value$trajectoryApiS2, _value$trajectoryApiS3, _value$trajectoryApiS4;
11272
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Select, {
11273
+ value: (value === null || value === void 0 ? void 0 : (_value$trajectoryApiS2 = value.trajectoryApiStatus) === null || _value$trajectoryApiS2 === void 0 ? void 0 : _value$trajectoryApiS2.status) || null,
11274
+ // disabled={true}
11275
+ style: {
11276
+ width: '100%',
11277
+ marginTop: '8px'
11278
+ },
11279
+ placeholder: "\u63A5\u53E3\u72B6\u6001",
11280
+ onChange: handleStatusChange,
11281
+ options: [{
11282
+ label: '成功',
11283
+ value: '成功'
11284
+ }, {
11285
+ label: '失败',
11286
+ value: '失败'
11287
+ }]
11288
+ }), (value === null || value === void 0 ? void 0 : (_value$trajectoryApiS3 = value.trajectoryApiStatus) === null || _value$trajectoryApiS3 === void 0 ? void 0 : _value$trajectoryApiS3.reason) ? /*#__PURE__*/React.createElement("div", {
11289
+ style: {
11290
+ color: 'red'
11291
+ }
11292
+ }, "\u5931\u8D25\u539F\u56E0\uFF1A", value === null || value === void 0 ? void 0 : (_value$trajectoryApiS4 = value.trajectoryApiStatus) === null || _value$trajectoryApiS4 === void 0 ? void 0 : _value$trajectoryApiS4.reason) : null);
11293
+ };
11203
11294
  //物流快照
11204
11295
  var LogisticsSnapshot = function LogisticsSnapshot() {
11205
11296
  return /*#__PURE__*/React.createElement(Input, {
@@ -11214,7 +11305,7 @@ var LogisticsTrajectory = function LogisticsTrajectory(props) {
11214
11305
  value: value === null || value === void 0 ? void 0 : value.trajectorySnapshot
11215
11306
  });
11216
11307
  };
11217
- return /*#__PURE__*/React.createElement("div", null, LogisticsCompany(), LogisticsCode(), (value === null || value === void 0 ? void 0 : value.trajectoryCompany) === 'SF' ? LogisticsPhone() : null, showField && showField.includes('snapshot') ? /*#__PURE__*/React.createElement(LogisticsSnapshot, null) : null);
11308
+ return /*#__PURE__*/React.createElement("div", null, LogisticsCompany(), LogisticsCode(), (value === null || value === void 0 ? void 0 : value.trajectoryCompany) === 'SF' ? LogisticsPhone() : null, trajectoryApiStatus && isSingle && LogisticsApiStatus(), showField && showField.includes('snapshot') ? /*#__PURE__*/React.createElement(LogisticsSnapshot, null) : null);
11218
11309
  };
11219
11310
 
11220
11311
  var LogisticsMoreTrajectory = function LogisticsMoreTrajectory(props) {
@@ -11427,7 +11518,8 @@ var LogisticsMoreTrajectory = function LogisticsMoreTrajectory(props) {
11427
11518
  disabled: disabled,
11428
11519
  onChange: function onChange(val) {
11429
11520
  return handleChange(val, changeIndex);
11430
- }
11521
+ },
11522
+ isSingle: false
11431
11523
  }));
11432
11524
  };
11433
11525
 
@@ -11450,7 +11542,7 @@ var typeInitValueMap = {
11450
11542
  }]
11451
11543
  };
11452
11544
  var jstGoods = function jstGoods(props) {
11453
- var _value$changeIndex, _value$changeIndex2, _value$changeIndex3, _value$changeIndex4, _value$changeIndex5, _value$changeIndex6, _value$changeIndex7, _value$changeIndex8, _value$changeIndex9;
11545
+ var _value$changeIndex, _value$changeIndex2, _value$changeIndex3, _value$changeIndex4, _value$changeIndex5, _value$changeIndex6, _value$changeIndex7, _value$changeIndex8, _value$changeIndex9, _value$changeIndex10, _value$changeIndex11, _value$changeIndex12;
11454
11546
  var _props$value = props.value,
11455
11547
  value = _props$value === void 0 ? [] : _props$value,
11456
11548
  onChange = props.onChange,
@@ -11468,8 +11560,8 @@ var jstGoods = function jstGoods(props) {
11468
11560
  setChangeIndex = _useState2[1]; //选中的包裹
11469
11561
  var sendOptions = SendDataCenter.getInstance(platformType).getSendData();
11470
11562
  var isSelectName = ['wdt', 'bsE3', 'km', 'gy', 'jst'].includes(platformType);
11563
+ var expressDateInstance = ExpressData.getInstance(platformType);
11471
11564
  var isSendGoodSavedId = isSelectName && !['jst'].includes(platformType);
11472
- var logisticsType = type === 1 && platformType === 'gy' ? 'input' : 'select';
11473
11565
  useEffect(function () {
11474
11566
  //没有值塞个默认值
11475
11567
  if (!(value === null || value === void 0 ? void 0 : value.length) && type !== 1) {
@@ -11552,59 +11644,51 @@ var jstGoods = function jstGoods(props) {
11552
11644
  return setChangeIndex(index);
11553
11645
  }
11554
11646
  }, "\u5305\u88F9".concat(index + 1)));
11555
- }))) : null, value.length || type === 1 ? /*#__PURE__*/React.createElement(React.Fragment, null, type === 1 ? /*#__PURE__*/React.createElement(Space, null, !showField || showField === 'logisticsCompany' ? /*#__PURE__*/React.createElement(ApaasLogistics, _objectSpread2(_objectSpread2({
11556
- type: logisticsType,
11647
+ }))) : null, value.length || type === 1 ? /*#__PURE__*/React.createElement(React.Fragment, null, type === 1 ? /*#__PURE__*/React.createElement(Space, null, !showField || showField === 'logisticsCompany' ? /*#__PURE__*/React.createElement(ApaasLogistics, {
11557
11648
  disabled: disabled,
11558
11649
  placeholder: "\u7269\u6D41\u516C\u53F8",
11559
11650
  onChange: function onChange(val) {
11560
- if (logisticsType === 'input') {
11561
- changeInputHandle(null, 'logisticsCompany');
11562
- changeInputHandle(val, 'logisticsCompanyName');
11563
- } else {
11564
- changeInputHandle(val, 'logisticsCompany');
11565
- }
11651
+ changeInputHandle(val, 'logisticsCompany');
11566
11652
  },
11567
- value: (_value$changeIndex = value[changeIndex]) === null || _value$changeIndex === void 0 ? void 0 : _value$changeIndex[logisticsType === 'input' ? 'logisticsCompanyName' : 'logisticsCompany']
11568
- }, logisticsType === 'input' ? {} : {
11653
+ value: platformType === 'gy' ? expressDateInstance.getExpressNameByCode((_value$changeIndex = value[changeIndex]) === null || _value$changeIndex === void 0 ? void 0 : _value$changeIndex['logisticsCompany'], false) ? (_value$changeIndex2 = value[changeIndex]) === null || _value$changeIndex2 === void 0 ? void 0 : _value$changeIndex2['logisticsCompany'] : (_value$changeIndex3 = value[changeIndex]) === null || _value$changeIndex3 === void 0 ? void 0 : _value$changeIndex3['logisticsCompanyName'] : (_value$changeIndex4 = value[changeIndex]) === null || _value$changeIndex4 === void 0 ? void 0 : _value$changeIndex4['logisticsCompany'],
11569
11654
  showSearch: true,
11570
11655
  dropdownMatchSelectWidth: false,
11571
11656
  filterOption: function filterOption(input, option) {
11572
11657
  return option.label.includes(input);
11573
- }
11574
- }), {}, {
11658
+ },
11575
11659
  style: {
11576
11660
  minWidth: '100px',
11577
11661
  maxWidth: '180px'
11578
11662
  },
11579
11663
  platformType: platformType
11580
- })) : null, !showField || showField === 'logisticsCode' ? /*#__PURE__*/React.createElement(Input, {
11664
+ }) : null, !showField || showField === 'logisticsCode' ? /*#__PURE__*/React.createElement(Input, {
11581
11665
  disabled: disabled,
11582
11666
  placeholder: "\u7269\u6D41\u5355\u53F7",
11583
11667
  onChange: function onChange(e) {
11584
11668
  return changeInputHandle(e.target.value, 'logisticsCode');
11585
11669
  },
11586
- value: (_value$changeIndex2 = value[changeIndex]) === null || _value$changeIndex2 === void 0 ? void 0 : _value$changeIndex2.logisticsCode
11670
+ value: (_value$changeIndex5 = value[changeIndex]) === null || _value$changeIndex5 === void 0 ? void 0 : _value$changeIndex5.logisticsCode
11587
11671
  }) : null) : null, type === 2 ? /*#__PURE__*/React.createElement(Space, null, ['supplyId', 'all'].includes(showField) && /*#__PURE__*/React.createElement(Input, {
11588
11672
  disabled: disabled,
11589
11673
  placeholder: "\u8BF7\u8F93\u5165\u4F9B\u9500\u5546\u7F16\u7801",
11590
11674
  onChange: function onChange(e) {
11591
11675
  return changeInputHandle(e.target.value, 'supplyId');
11592
11676
  },
11593
- value: (_value$changeIndex3 = value[changeIndex]) === null || _value$changeIndex3 === void 0 ? void 0 : _value$changeIndex3.supplyId
11677
+ value: (_value$changeIndex6 = value[changeIndex]) === null || _value$changeIndex6 === void 0 ? void 0 : _value$changeIndex6.supplyId
11594
11678
  }), ['supplyName', 'all'].includes(showField) && /*#__PURE__*/React.createElement(Input, {
11595
11679
  disabled: disabled,
11596
11680
  placeholder: "\u8BF7\u8F93\u5165\u4F9B\u9500\u5546\u540D\u79F0",
11597
11681
  onChange: function onChange(e) {
11598
11682
  return changeInputHandle(e.target.value, 'supplyName');
11599
11683
  },
11600
- value: (_value$changeIndex4 = value[changeIndex]) === null || _value$changeIndex4 === void 0 ? void 0 : _value$changeIndex4.supplyName
11684
+ value: (_value$changeIndex7 = value[changeIndex]) === null || _value$changeIndex7 === void 0 ? void 0 : _value$changeIndex7.supplyName
11601
11685
  })) : null, type === 3 ? /*#__PURE__*/React.createElement(Space, null, ['sendId', 'all'].includes(showField) && /*#__PURE__*/React.createElement(Input, {
11602
11686
  disabled: disabled,
11603
11687
  placeholder: "\u8BF7\u8F93\u5165\u53D1\u8D27\u4ED3\u7F16\u7801",
11604
11688
  onChange: function onChange(e) {
11605
11689
  return changeInputHandle(e.target.value, 'sendId');
11606
11690
  },
11607
- value: (_value$changeIndex5 = value[changeIndex]) === null || _value$changeIndex5 === void 0 ? void 0 : _value$changeIndex5.sendId
11691
+ value: (_value$changeIndex8 = value[changeIndex]) === null || _value$changeIndex8 === void 0 ? void 0 : _value$changeIndex8.sendId
11608
11692
  }), ['sendName', 'all'].includes(showField) && (isSelectName ? /*#__PURE__*/React.createElement(Select, {
11609
11693
  style: {
11610
11694
  minWidth: '100px',
@@ -11615,7 +11699,7 @@ var jstGoods = function jstGoods(props) {
11615
11699
  showSearch: true,
11616
11700
  options: sendOptions,
11617
11701
  filterOption: filterOption,
11618
- value: ((_value$changeIndex6 = value[changeIndex]) === null || _value$changeIndex6 === void 0 ? void 0 : _value$changeIndex6.sendSnapshotId) || ((_value$changeIndex7 = value[changeIndex]) === null || _value$changeIndex7 === void 0 ? void 0 : _value$changeIndex7.sendName) || null,
11702
+ value: ((_value$changeIndex9 = value[changeIndex]) === null || _value$changeIndex9 === void 0 ? void 0 : _value$changeIndex9.sendSnapshotId) || ((_value$changeIndex10 = value[changeIndex]) === null || _value$changeIndex10 === void 0 ? void 0 : _value$changeIndex10.sendName) || null,
11619
11703
  onChange: function onChange(value, option) {
11620
11704
  return handleSelected(value, 'sendName', option, onlyShowFieldSelect);
11621
11705
  }
@@ -11625,14 +11709,14 @@ var jstGoods = function jstGoods(props) {
11625
11709
  onChange: function onChange(e) {
11626
11710
  return changeInputHandle(e.target.value, 'sendName');
11627
11711
  },
11628
- value: (_value$changeIndex8 = value[changeIndex]) === null || _value$changeIndex8 === void 0 ? void 0 : _value$changeIndex8.sendName
11712
+ value: (_value$changeIndex11 = value[changeIndex]) === null || _value$changeIndex11 === void 0 ? void 0 : _value$changeIndex11.sendName
11629
11713
  }))) : null, type === 4 ? /*#__PURE__*/React.createElement(Space, null, /*#__PURE__*/React.createElement(Input, {
11630
11714
  disabled: disabled,
11631
11715
  placeholder: "\u8BF7\u8F93\u5165\u51FA\u5E93\u5355\u7F16\u53F7",
11632
11716
  onChange: function onChange(e) {
11633
11717
  return changeInputHandle(e.target.value, 'deliveryNo');
11634
11718
  },
11635
- value: (_value$changeIndex9 = value[changeIndex]) === null || _value$changeIndex9 === void 0 ? void 0 : _value$changeIndex9.sendName
11719
+ value: (_value$changeIndex12 = value[changeIndex]) === null || _value$changeIndex12 === void 0 ? void 0 : _value$changeIndex12.sendName
11636
11720
  })) : null) : null);
11637
11721
  };
11638
11722
 
@@ -12547,9 +12631,7 @@ var useGetColumns = (function (type) {
12547
12631
  loading = _useState4[0],
12548
12632
  setLoading = _useState4[1];
12549
12633
  var showColumnsDataIndexList = useMemo(function () {
12550
- return columns.filter(function (item) {
12551
- return Object.hasOwn(item, 'dataIndex');
12552
- }).map(function (item) {
12634
+ return columns.map(function (item) {
12553
12635
  return item.dataIndex;
12554
12636
  });
12555
12637
  }, [columns]);
@@ -15166,7 +15248,7 @@ var getColumns$5 = function getColumns() {
15166
15248
  ellipsis: true,
15167
15249
  align: 'center',
15168
15250
  render: function render(val, record, index) {
15169
- return (record.qty || 0) * (+record.salePrice || 0);
15251
+ return ((record.qty || 0) * (+record.salePrice || 0)).toFixed(2);
15170
15252
  }
15171
15253
  }, {
15172
15254
  dataIndex: 'batchId',
@@ -15442,7 +15524,7 @@ var getColumns$5 = function getColumns() {
15442
15524
  dataIndex: 'saleAmount',
15443
15525
  title: '总金额',
15444
15526
  render: function render(val, record) {
15445
- return (record.qty || 0) * (+record.salePrice || 0);
15527
+ return ((record.qty || 0) * (+record.salePrice || 0)).toFixed(2);
15446
15528
  }
15447
15529
  }, {
15448
15530
  dataIndex: 'batchId',
@@ -15551,7 +15633,7 @@ var getColumns$5 = function getColumns() {
15551
15633
  dataIndex: 'saleAmount',
15552
15634
  title: '总金额',
15553
15635
  render: function render(val, record) {
15554
- return (record.qty || 0) * (+record.salePrice || 0);
15636
+ return ((record.qty || 0) * (+record.salePrice || 0)).toFixed(2);
15555
15637
  }
15556
15638
  }, {
15557
15639
  dataIndex: 'isGift',
@@ -15737,6 +15819,29 @@ var getColumnsMap$1 = function getColumnsMap(args) {
15737
15819
  });
15738
15820
  };
15739
15821
  var erpColumnsMap = getColumnsMap$1();
15822
+ var erpFormValidator = function erpFormValidator(_rule, value, type) {
15823
+ var validatorFnList = (erpColumnsMap[type] || erpColumnsMap['default']).map(function (column) {
15824
+ return column.validator;
15825
+ }).filter(Boolean);
15826
+ var res = null;
15827
+ var _iterator = _createForOfIteratorHelper(validatorFnList),
15828
+ _step;
15829
+ try {
15830
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
15831
+ var validatorFn = _step.value;
15832
+ var validatorResult = validatorFn(_rule, value, type);
15833
+ if (validatorResult) {
15834
+ res = validatorResult;
15835
+ break;
15836
+ }
15837
+ }
15838
+ } catch (err) {
15839
+ _iterator.e(err);
15840
+ } finally {
15841
+ _iterator.f();
15842
+ }
15843
+ return res;
15844
+ };
15740
15845
  var getColumnsBaseInfo$1 = function getColumnsBaseInfo() {
15741
15846
  var clone_columnsMap = cloneDeep(getColumnsMap$1());
15742
15847
  var newColumns = {};
@@ -15867,6 +15972,7 @@ var GoodsModalMap = {
15867
15972
  BS_E3_EXCHANGE_GOODS: BsE3GoodsModal,
15868
15973
  GY_GOODS: GyGoodsModal$2,
15869
15974
  GY_REISSUE_GOODS: GyGoodsModal$2,
15975
+ GY_RETURN_GOODS: GyGoodsModal$2,
15870
15976
  JST_GOODS: JstGoodsModal,
15871
15977
  JST_REISSUE_GOODS: JstGoodsModal,
15872
15978
  JST_RETURN_GOODS: JstGoodsModal,
@@ -15904,7 +16010,7 @@ var SelectTradeGoods = function SelectTradeGoods(_ref) {
15904
16010
  return item === null || item === void 0 ? void 0 : item[uniqueKey];
15905
16011
  }));
15906
16012
  var handleChangeSelectedKeys = function handleChangeSelectedKeys(keys) {
15907
- console.log('handleChangeSelectedKeys', keys, unCurrentTradeOriginGoods);
16013
+ // console.log('handleChangeSelectedKeys', keys, unCurrentTradeOriginGoods);
15908
16014
  onChangeSelectedKeys(keys.concat(unCurrentTradeOriginGoods));
15909
16015
  };
15910
16016
  var rowSelection = {
@@ -15939,7 +16045,7 @@ var getButtonText = function getButtonText() {
15939
16045
  if (['WDT_REISSUE_GOODS'].includes(type)) {
15940
16046
  return '选择旺店通商品';
15941
16047
  }
15942
- if (['GY_GOODS', 'GY_REISSUE_GOODS'].includes(type)) {
16048
+ if (['GY_GOODS', 'GY_REISSUE_GOODS', 'GY_RETURN_GOODS'].includes(type)) {
15943
16049
  return '选择管易ERP商品';
15944
16050
  }
15945
16051
  if (['JST_GOODS', 'JST_REISSUE_GOODS', 'JST_RETURN_GOODS', 'JST_EXCHANGE_GOODS'].includes(type)) {
@@ -16242,7 +16348,7 @@ var GoodItem$1 = function GoodItem(props) {
16242
16348
  canUpdateNumber: canUpdateNumber
16243
16349
  });
16244
16350
  });
16245
- } else if (['GY_GOODS', 'GY_REISSUE_GOODS'].includes(type)) {
16351
+ } else if (['GY_GOODS', 'GY_REISSUE_GOODS', 'GY_RETURN_GOODS'].includes(type)) {
16246
16352
  newList = list.map(function (item) {
16247
16353
  var goodName = item.goodName,
16248
16354
  goodShortName = item.goodShortName,
@@ -17020,10 +17126,12 @@ var getWdtOrderListSingleton = function getWdtOrderListSingleton(orderNo) {
17020
17126
  var _data$data, _data$data$trades;
17021
17127
  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) {
17022
17128
  data.data.trades = filterWdtOrders(data === null || data === void 0 ? void 0 : data.data, orderNo).map(function (item) {
17129
+ var _tradeStatusMap$data$;
17023
17130
  return _objectSpread2(_objectSpread2({}, item), {}, {
17024
17131
  billNo: item.tradeNo,
17025
17132
  billType: WDT_ORDER_TYPE_MAP[item.tradeType],
17026
- billTag: item.tagName
17133
+ billTag: item.tagName,
17134
+ tradeStatusValue: tradeStatusMap === null || tradeStatusMap === void 0 ? void 0 : (_tradeStatusMap$data$ = tradeStatusMap[data.data.version]) === null || _tradeStatusMap$data$ === void 0 ? void 0 : _tradeStatusMap$data$[item.tradeStatus]
17027
17135
  });
17028
17136
  });
17029
17137
  }
@@ -17266,7 +17374,6 @@ var index$3 = (function (props) {
17266
17374
  } else if (type === 'BS_E3_SYSTEM_ORDER') {
17267
17375
  getBsE3OrderList(value.orderNo);
17268
17376
  } else if (type === 'GY_SYSTEM_ORDER') {
17269
- console.log('触发gy--getGyOrderList--1');
17270
17377
  getGyOrderList(value.orderNo);
17271
17378
  } else if (type === 'JST_SYSTEM_ORDER') {
17272
17379
  getJstOrderList(value.orderNo);
@@ -17380,11 +17487,13 @@ var index$3 = (function (props) {
17380
17487
  showOrderInfo: trades.map(function (_ref4) {
17381
17488
  var billNo = _ref4.billNo,
17382
17489
  billType = _ref4.billType,
17383
- billTag = _ref4.billTag;
17490
+ billTag = _ref4.billTag,
17491
+ tradeStatusValue = _ref4.tradeStatusValue;
17384
17492
  return {
17385
17493
  billNo: billNo,
17386
17494
  billType: billType,
17387
- billTag: billTag
17495
+ billTag: billTag,
17496
+ tradeStatusValue: tradeStatusValue
17388
17497
  };
17389
17498
  })
17390
17499
  }));
@@ -17702,7 +17811,7 @@ var CommonGoods = function CommonGoods(props) {
17702
17811
  disabled = props.disabled,
17703
17812
  onChange = props.onChange,
17704
17813
  compType = props.type;
17705
- console.log('value?.orders', value === null || value === void 0 ? void 0 : value.orders);
17814
+ // console.log('value?.orders', value?.orders);
17706
17815
  // 合并单订单会包含","
17707
17816
  var showModeBtn = !['BS_E3_GOODS'].includes(compType) && ((value === null || value === void 0 ? void 0 : value.orders) || []).some(function (order) {
17708
17817
  var _order$componentMap$c;
@@ -18226,7 +18335,7 @@ var typeMap$1 = {
18226
18335
  }
18227
18336
  };
18228
18337
  var wdtReissue = function wdtReissue(props) {
18229
- var _value$wdtSystemOrder, _typeMap$type24, _typeMap$type26, _typeMap$type27, _value$typeMap$type$s5, _typeMap$type28, _typeMap$type29, _typeMap$type30;
18338
+ var _value$wdtSystemOrder, _typeMap$type23, _typeMap$type25, _typeMap$type26, _value$typeMap$type$s5, _typeMap$type27, _typeMap$type28, _typeMap$type29;
18230
18339
  var value = props.value,
18231
18340
  onChange = props.onChange,
18232
18341
  _props$reasonList = props.reasonList,
@@ -18296,11 +18405,13 @@ var wdtReissue = function wdtReissue(props) {
18296
18405
  var showOrderInfo = orders.map(function (_ref2) {
18297
18406
  var billNo = _ref2.billNo,
18298
18407
  billType = _ref2.billType,
18299
- billTag = _ref2.billTag;
18408
+ billTag = _ref2.billTag,
18409
+ tradeStatusValue = _ref2.tradeStatusValue;
18300
18410
  return {
18301
18411
  billNo: billNo,
18302
18412
  billType: billType,
18303
- billTag: billTag
18413
+ billTag: billTag,
18414
+ tradeStatusValue: tradeStatusValue
18304
18415
  };
18305
18416
  });
18306
18417
  onChange(_objectSpread2(_objectSpread2({}, valueRef.current || {}), {}, _defineProperty({}, (_typeMap$type5 = typeMap$1[type]) === null || _typeMap$type5 === void 0 ? void 0 : _typeMap$type5.systemOrder, _objectSpread2(_objectSpread2({}, ((_ref3 = valueRef.current || {}) === null || _ref3 === void 0 ? void 0 : _ref3[(_typeMap$type6 = typeMap$1[type]) === null || _typeMap$type6 === void 0 ? void 0 : _typeMap$type6.systemOrder]) || {}), {}, {
@@ -18383,7 +18494,7 @@ var wdtReissue = function wdtReissue(props) {
18383
18494
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
18384
18495
  };
18385
18496
  var selectedGoodsChange = useCallback(function (skuList) {
18386
- var _typeMap$type21, _typeMap$type22, _uniqBy, _typeMap$type23;
18497
+ var _typeMap$type21, _typeMap$type22, _uniqBy;
18387
18498
  var newValue = _objectSpread2({}, value);
18388
18499
  // 原订单商品
18389
18500
  var originTradeGoodList = getGoodDetails({
@@ -18394,14 +18505,14 @@ var wdtReissue = function wdtReissue(props) {
18394
18505
  newValue["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type22 = typeMap$1[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.key)] = (_uniqBy = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
18395
18506
  return skuList.includes(item.uuid);
18396
18507
  });
18397
- console.log('商品发生变化', 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)]);
18508
+ // console.log('商品发生变化', newValue[`${typeMap?.[type]?.key}`]);
18398
18509
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
18399
- }, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type24 = typeMap$1[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.key)], isStrict]);
18510
+ }, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type23 = typeMap$1[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.key)], isStrict]);
18400
18511
  //显示选择商品按钮 原单换不显示选择商品
18401
18512
  var showChangeBtn = useMemo(function () {
18402
- var _typeMap$type25;
18403
- return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type25 = typeMap$1[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.systemOrderNo]);
18404
- }, [value === null || value === void 0 ? void 0 : value[(_typeMap$type26 = typeMap$1[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.systemOrderNo]]);
18513
+ var _typeMap$type24;
18514
+ return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type24 = typeMap$1[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.systemOrderNo]);
18515
+ }, [value === null || value === void 0 ? void 0 : value[(_typeMap$type25 = typeMap$1[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.systemOrderNo]]);
18405
18516
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
18406
18517
  gutter: 8,
18407
18518
  wrap: true
@@ -18419,12 +18530,12 @@ var wdtReissue = function wdtReissue(props) {
18419
18530
  },
18420
18531
  disabled: disabled,
18421
18532
  allowClear: false,
18422
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type27 = typeMap$1[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrderNo)],
18533
+ 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)],
18423
18534
  onChange: function onChange(val) {
18424
18535
  return changeSystemOrderHandle(val);
18425
18536
  },
18426
18537
  placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
18427
- }, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type28 = typeMap$1[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
18538
+ }, ((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) {
18428
18539
  return /*#__PURE__*/React.createElement(Select.Option, {
18429
18540
  key: item.billNo,
18430
18541
  value: item.billNo,
@@ -18445,7 +18556,7 @@ var wdtReissue = function wdtReissue(props) {
18445
18556
  disabled: disabled,
18446
18557
  allowClear: false,
18447
18558
  options: reasonList,
18448
- 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.typeName)],
18559
+ 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)],
18449
18560
  onChange: function onChange(val) {
18450
18561
  return changeTypeHandle(val);
18451
18562
  }
@@ -18457,7 +18568,7 @@ var wdtReissue = function wdtReissue(props) {
18457
18568
  canUpdateNumber: showChangeBtn,
18458
18569
  showChangeBtn: showChangeBtn,
18459
18570
  shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
18460
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$1 === null || typeMap$1 === void 0 ? void 0 : (_typeMap$type30 = typeMap$1[type]) === null || _typeMap$type30 === void 0 ? void 0 : _typeMap$type30.key)],
18571
+ 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)],
18461
18572
  onChange: function onChange(val) {
18462
18573
  return changeGoodHandle(val);
18463
18574
  },
@@ -19529,6 +19640,39 @@ var MsgStatus = function MsgStatus(props) {
19529
19640
  }, "\u5931\u8D25\u539F\u56E0\uFF1A", (_value$changeIndex3 = value[changeIndex]) === null || _value$changeIndex3 === void 0 ? void 0 : _value$changeIndex3.reason) : null) : null);
19530
19641
  };
19531
19642
 
19643
+ var _excluded$n = ["showOnly", "getOptionsAsync"];
19644
+ var AsyncSelect = function AsyncSelect(props) {
19645
+ var _props$showOnly = props.showOnly,
19646
+ showOnly = _props$showOnly === void 0 ? false : _props$showOnly,
19647
+ getOptionsAsync = props.getOptionsAsync,
19648
+ otherProps = _objectWithoutProperties(props, _excluded$n);
19649
+ var _React$useState = React.useState([]),
19650
+ _React$useState2 = _slicedToArray(_React$useState, 2),
19651
+ data = _React$useState2[0],
19652
+ setData = _React$useState2[1];
19653
+ React.useEffect(function () {
19654
+ getOptionsAsync === null || getOptionsAsync === void 0 ? void 0 : getOptionsAsync().then(function (list) {
19655
+ setData(list);
19656
+ });
19657
+ }, []);
19658
+ var options = [].concat(_toConsumableArray(props.options || []), _toConsumableArray(data || []));
19659
+ if (showOnly) {
19660
+ var selectedItem = options.find(function (option) {
19661
+ return option.value === props.value;
19662
+ });
19663
+ return selectedItem ? selectedItem.label : props.value;
19664
+ }
19665
+ return /*#__PURE__*/React.createElement(Select, _objectSpread2(_objectSpread2({
19666
+ showSearch: true,
19667
+ filterOption: function filterOption(input, option) {
19668
+ return option.label.includes(input);
19669
+ },
19670
+ notFoundContent: null
19671
+ }, otherProps), {}, {
19672
+ options: options
19673
+ }));
19674
+ };
19675
+
19532
19676
  var CalculationInput = function CalculationInput(props) {
19533
19677
  var _props$config = props.config,
19534
19678
  config = _props$config === void 0 ? {} : _props$config;
@@ -19547,7 +19691,7 @@ var CalculationInput = function CalculationInput(props) {
19547
19691
  }, config === null || config === void 0 ? void 0 : config.unit));
19548
19692
  };
19549
19693
 
19550
- var _excluded$n = ["value", "onChange", "reasonList", "disabled", "type"];
19694
+ var _excluded$o = ["value", "onChange", "reasonList", "disabled", "type"];
19551
19695
  var typeMap$3 = {
19552
19696
  BS_E3_REISSUE_GOODS: {
19553
19697
  key: 'bsE3ReissueGoods',
@@ -19565,7 +19709,7 @@ var bsE3Reissue = function bsE3Reissue(props) {
19565
19709
  reasonList = _props$reasonList === void 0 ? [] : _props$reasonList,
19566
19710
  disabled = props.disabled,
19567
19711
  type = props.type,
19568
- other = _objectWithoutProperties(props, _excluded$n);
19712
+ other = _objectWithoutProperties(props, _excluded$o);
19569
19713
  var getOrderFlag = useRef(false);
19570
19714
  var valueRef = useRef(null);
19571
19715
  var _useState = useState(false),
@@ -19783,7 +19927,7 @@ var bsE3Reissue = function bsE3Reissue(props) {
19783
19927
  })));
19784
19928
  };
19785
19929
 
19786
- var _excluded$o = ["value", "onChange", "reasonList", "disabled", "type"],
19930
+ var _excluded$p = ["value", "onChange", "reasonList", "disabled", "type"],
19787
19931
  _excluded2 = ["billNo", "billType", "billTag", "tradeTagName", "deliveryState", "vipCode", "shopCode"];
19788
19932
  var typeMap$4 = {
19789
19933
  GY_REISSUE_GOODS: {
@@ -19805,14 +19949,14 @@ var typeMap$4 = {
19805
19949
  }
19806
19950
  };
19807
19951
  var GyReissue = function GyReissue(props) {
19808
- var _typeMap$type28, _typeMap$type30, _typeMap$type31, _value$typeMap$type$s5, _typeMap$type32, _typeMap$type33, _typeMap$type34;
19952
+ var _typeMap$type27, _typeMap$type28, _typeMap$type29, _systemOrder$orders, _typeMap$type30, _value$typeMap$type$s5, _typeMap$type31, _typeMap$type32, _typeMap$type33;
19809
19953
  var value = props.value,
19810
19954
  onChange = props.onChange,
19811
19955
  _props$reasonList = props.reasonList,
19812
19956
  reasonList = _props$reasonList === void 0 ? [] : _props$reasonList,
19813
19957
  disabled = props.disabled,
19814
19958
  type = props.type,
19815
- other = _objectWithoutProperties(props, _excluded$o);
19959
+ other = _objectWithoutProperties(props, _excluded$p);
19816
19960
  // const showModeBtn = (value?.gySystemOrder?.orders || []).some((order: any) =>
19817
19961
  // order?.platformCode?.includes(';'),
19818
19962
  // );
@@ -19960,7 +20104,7 @@ var GyReissue = function GyReissue(props) {
19960
20104
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
19961
20105
  };
19962
20106
  var selectedGoodsChange = useCallback(function (skuList) {
19963
- var _ref12, _typeMap$type25, _typeMap$type26, _uniqBy, _typeMap$type27;
20107
+ var _ref12, _typeMap$type25, _typeMap$type26, _uniqBy;
19964
20108
  pushGyLog('beforeSelectedGoodsChange', valueRef.current || {});
19965
20109
  var newValue = _objectSpread2({}, valueRef.current || {});
19966
20110
  // 原订单商品
@@ -19972,21 +20116,15 @@ var GyReissue = function GyReissue(props) {
19972
20116
  newValue["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type26 = typeMap$4[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.key)] = (_uniqBy = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
19973
20117
  return skuList.includes(item.uuid);
19974
20118
  });
19975
- console.log('商品发生变化', newValue["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type27 = typeMap$4[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.key)]);
20119
+ // console.log('商品发生变化', newValue[`${typeMap?.[type]?.key}`]);
19976
20120
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
19977
20121
  pushGyLog('afterSelectedGoodsChange', newValue);
19978
- }, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type28 = typeMap$4[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.key)], isStrict]);
20122
+ }, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type27 = typeMap$4[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.key)], isStrict]);
19979
20123
  //系统单选择后展示选择商品按钮,系统单未选择的时候不展示
19980
- var showChangeBtn = useMemo(function () {
19981
- var _typeMap$type29;
19982
- return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type29 = typeMap$4[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.systemOrderNo]);
19983
- }, [value === null || value === void 0 ? void 0 : value[(_typeMap$type30 = typeMap$4[type]) === null || _typeMap$type30 === void 0 ? void 0 : _typeMap$type30.systemOrderNo]]);
19984
- return /*#__PURE__*/React.createElement("div", {
19985
- id: "TEST_GY",
19986
- onClick: function onClick() {
19987
- console.log('TEST_GY', value);
19988
- }
19989
- }, /*#__PURE__*/React.createElement(Row, {
20124
+ var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type28 = typeMap$4[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.systemOrder];
20125
+ var showChangeBtn = !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type29 = typeMap$4[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.systemOrderNo]);
20126
+ var showErpGoodsBtn = showChangeBtn || type === 'GY_REISSUE_GOODS' && systemOrder && systemOrder.orderNo && !((_systemOrder$orders = systemOrder.orders) === null || _systemOrder$orders === void 0 ? void 0 : _systemOrder$orders.length);
20127
+ return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Row, {
19990
20128
  gutter: 8,
19991
20129
  wrap: true
19992
20130
  }, /*#__PURE__*/React.createElement(Col, {
@@ -20003,12 +20141,12 @@ var GyReissue = function GyReissue(props) {
20003
20141
  },
20004
20142
  disabled: disabled,
20005
20143
  allowClear: false,
20006
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type31 = typeMap$4[type]) === null || _typeMap$type31 === void 0 ? void 0 : _typeMap$type31.systemOrderNo)],
20144
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type30 = typeMap$4[type]) === null || _typeMap$type30 === void 0 ? void 0 : _typeMap$type30.systemOrderNo)],
20007
20145
  onChange: function onChange(val) {
20008
20146
  return changeSystemOrderHandle(val);
20009
20147
  },
20010
20148
  placeholder: "\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"
20011
- }, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type32 = typeMap$4[type]) === null || _typeMap$type32 === void 0 ? void 0 : _typeMap$type32.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
20149
+ }, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type31 = typeMap$4[type]) === null || _typeMap$type31 === void 0 ? void 0 : _typeMap$type31.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
20012
20150
  return /*#__PURE__*/React.createElement(Select.Option, {
20013
20151
  key: item.billNo,
20014
20152
  value: item.billNo,
@@ -20029,7 +20167,7 @@ var GyReissue = function GyReissue(props) {
20029
20167
  disabled: disabled,
20030
20168
  allowClear: false,
20031
20169
  options: reasonList,
20032
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type33 = typeMap$4[type]) === null || _typeMap$type33 === void 0 ? void 0 : _typeMap$type33.typeName)],
20170
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type32 = typeMap$4[type]) === null || _typeMap$type32 === void 0 ? void 0 : _typeMap$type32.typeName)],
20033
20171
  onChange: function onChange(val) {
20034
20172
  return changeTypeHandle(val);
20035
20173
  }
@@ -20040,8 +20178,10 @@ var GyReissue = function GyReissue(props) {
20040
20178
  disabled: disabled,
20041
20179
  canUpdateNumber: showChangeBtn,
20042
20180
  showChangeBtn: showChangeBtn,
20181
+ showErpGoodsBtn: showErpGoodsBtn,
20182
+ alwaysShowChooseErpGoodsBtn: showErpGoodsBtn,
20043
20183
  shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
20044
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type34 = typeMap$4[type]) === null || _typeMap$type34 === void 0 ? void 0 : _typeMap$type34.key)],
20184
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$4 === null || typeMap$4 === void 0 ? void 0 : (_typeMap$type33 = typeMap$4[type]) === null || _typeMap$type33 === void 0 ? void 0 : _typeMap$type33.key)],
20045
20185
  onChange: function onChange(val) {
20046
20186
  return changeGoodHandle(val);
20047
20187
  },
@@ -20056,7 +20196,7 @@ var GyReissue = function GyReissue(props) {
20056
20196
  })));
20057
20197
  };
20058
20198
 
20059
- var _excluded$p = ["value", "onChange", "reasonList", "disabled", "type"],
20199
+ var _excluded$q = ["value", "onChange", "reasonList", "disabled", "type"],
20060
20200
  _excluded2$1 = ["billNo", "billType", "billTag", "tradeTagName", "deliveryState", "vipCode", "shopCode"];
20061
20201
  var typeMap$5 = {
20062
20202
  GY_RETURN_GOODS: {
@@ -20078,14 +20218,14 @@ var typeMap$5 = {
20078
20218
  }
20079
20219
  };
20080
20220
  var GyReturnGoods = function GyReturnGoods(props) {
20081
- var _typeMap$type10, _typeMap$type28, _typeMap$type29, _value$typeMap$type$s5, _typeMap$type30, _typeMap$type31, _typeMap$type32;
20221
+ var _typeMap$type9, _typeMap$type26, _systemOrder$orders, _typeMap$type27, _typeMap$type28, _value$typeMap$type$s5, _typeMap$type29, _typeMap$type30, _typeMap$type31;
20082
20222
  var value = props.value,
20083
20223
  onChange = props.onChange,
20084
20224
  _props$reasonList = props.reasonList,
20085
20225
  reasonList = _props$reasonList === void 0 ? [] : _props$reasonList,
20086
20226
  disabled = props.disabled,
20087
20227
  type = props.type,
20088
- other = _objectWithoutProperties(props, _excluded$p);
20228
+ other = _objectWithoutProperties(props, _excluded$q);
20089
20229
  var valueRef = useRef({});
20090
20230
  var getOrderFlag = useRef(false);
20091
20231
  var _useState = useState(false),
@@ -20186,7 +20326,7 @@ var GyReturnGoods = function GyReturnGoods(props) {
20186
20326
  };
20187
20327
  }();
20188
20328
  var selectedGoodsChange = useCallback(function (skuList) {
20189
- var _typeMap$type7, _typeMap$type8, _uniqBy, _typeMap$type9;
20329
+ var _typeMap$type7, _typeMap$type8, _uniqBy;
20190
20330
  var newValue = _objectSpread2({}, value);
20191
20331
  // 原订单商品
20192
20332
  var originTradeGoodList = getGoodDetails({
@@ -20197,49 +20337,49 @@ var GyReturnGoods = function GyReturnGoods(props) {
20197
20337
  newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type8 = typeMap$5[type]) === null || _typeMap$type8 === void 0 ? void 0 : _typeMap$type8.key)] = (_uniqBy = uniqBy(originTradeGoodList.concat(currentSelectGoodList), 'uuid')) === null || _uniqBy === void 0 ? void 0 : _uniqBy.filter(function (item) {
20198
20338
  return skuList.includes(item.uuid);
20199
20339
  });
20200
- console.log('商品发生变化', newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type9 = typeMap$5[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.key)]);
20340
+ // console.log('商品发生变化', newValue[`${typeMap?.[type]?.key}`]);
20201
20341
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
20202
- }, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type10 = typeMap$5[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.key)], isStrict]);
20342
+ }, [value === null || value === void 0 ? void 0 : value["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type9 = typeMap$5[type]) === null || _typeMap$type9 === void 0 ? void 0 : _typeMap$type9.key)], isStrict]);
20203
20343
  var changeTypeHandle = function changeTypeHandle(val) {
20204
- var _value$typeMap$type$t, _typeMap$type11, _typeMap$type12;
20344
+ var _value$typeMap$type$t, _typeMap$type10, _typeMap$type11;
20205
20345
  var typeName = val === null || val === void 0 ? void 0 : val[0];
20206
- if (typeName === (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t = value[(_typeMap$type11 = typeMap$5[type]) === null || _typeMap$type11 === void 0 ? void 0 : _typeMap$type11.typeName]) === null || _value$typeMap$type$t === void 0 ? void 0 : _value$typeMap$type$t[0])) return;
20346
+ if (typeName === (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t = value[(_typeMap$type10 = typeMap$5[type]) === null || _typeMap$type10 === void 0 ? void 0 : _typeMap$type10.typeName]) === null || _value$typeMap$type$t === void 0 ? void 0 : _value$typeMap$type$t[0])) return;
20207
20347
  // const systemOrderNo = value?.[typeMap[type]?.systemOrderNo];
20208
20348
  var newValue = _objectSpread2({}, value);
20209
- newValue[(_typeMap$type12 = typeMap$5[type]) === null || _typeMap$type12 === void 0 ? void 0 : _typeMap$type12.typeName] = val;
20349
+ newValue[(_typeMap$type11 = typeMap$5[type]) === null || _typeMap$type11 === void 0 ? void 0 : _typeMap$type11.typeName] = val;
20210
20350
  if (typeName === '1') {
20211
- var _typeMap$type13;
20212
- newValue[(_typeMap$type13 = typeMap$5[type]) === null || _typeMap$type13 === void 0 ? void 0 : _typeMap$type13.key] = getGoodDetails({
20351
+ var _typeMap$type12;
20352
+ newValue[(_typeMap$type12 = typeMap$5[type]) === null || _typeMap$type12 === void 0 ? void 0 : _typeMap$type12.key] = getGoodDetails({
20213
20353
  mode: isStrict
20214
20354
  });
20215
20355
  } else if (typeName === '2') {
20216
- var _typeMap$type14;
20356
+ var _typeMap$type13;
20217
20357
  // 切换到非原单,清空列表
20218
- newValue[(_typeMap$type14 = typeMap$5[type]) === null || _typeMap$type14 === void 0 ? void 0 : _typeMap$type14.key] = [];
20358
+ newValue[(_typeMap$type13 = typeMap$5[type]) === null || _typeMap$type13 === void 0 ? void 0 : _typeMap$type13.key] = [];
20219
20359
  }
20220
20360
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
20221
20361
  };
20222
20362
  var changeGoodHandle = function changeGoodHandle(val) {
20223
- var _typeMap$type15;
20363
+ var _typeMap$type14;
20224
20364
  var newValue = _objectSpread2({}, value);
20225
- newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type15 = typeMap$5[type]) === null || _typeMap$type15 === void 0 ? void 0 : _typeMap$type15.key)] = (val || []).map(function (item) {
20226
- var _typeMap$type16, _typeMap$type17;
20227
- item["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type16 = typeMap$5[type]) === null || _typeMap$type16 === void 0 ? void 0 : _typeMap$type16.formatDefaultField.money)] = 0;
20228
- item["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type17 = typeMap$5[type]) === null || _typeMap$type17 === void 0 ? void 0 : _typeMap$type17.formatDefaultField.share)] = 0;
20365
+ newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type14 = typeMap$5[type]) === null || _typeMap$type14 === void 0 ? void 0 : _typeMap$type14.key)] = (val || []).map(function (item) {
20366
+ var _typeMap$type15, _typeMap$type16;
20367
+ item["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type15 = typeMap$5[type]) === null || _typeMap$type15 === void 0 ? void 0 : _typeMap$type15.formatDefaultField.money)] = 0;
20368
+ item["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type16 = typeMap$5[type]) === null || _typeMap$type16 === void 0 ? void 0 : _typeMap$type16.formatDefaultField.share)] = 0;
20229
20369
  return item;
20230
20370
  });
20231
20371
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
20232
20372
  };
20233
20373
  var changeSystemOrderHandle = function changeSystemOrderHandle(val) {
20234
- var _typeMap$type18, _value$typeMap$type$t2, _typeMap$type19, _value$typeMap$type$t3, _typeMap$type21;
20374
+ var _typeMap$type17, _value$typeMap$type$t2, _typeMap$type18, _value$typeMap$type$t3, _typeMap$type20;
20235
20375
  var newValue = _objectSpread2({}, value);
20236
- newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type18 = typeMap$5[type]) === null || _typeMap$type18 === void 0 ? void 0 : _typeMap$type18.systemOrderNo)] = val;
20237
- if (['2'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t2 = value[(_typeMap$type19 = typeMap$5[type]) === null || _typeMap$type19 === void 0 ? void 0 : _typeMap$type19.typeName]) === null || _value$typeMap$type$t2 === void 0 ? void 0 : _value$typeMap$type$t2[0])) {
20238
- var _typeMap$type20;
20239
- newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type20 = typeMap$5[type]) === null || _typeMap$type20 === void 0 ? void 0 : _typeMap$type20.key)] = [];
20240
- } else if (['1'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t3 = value[(_typeMap$type21 = typeMap$5[type]) === null || _typeMap$type21 === void 0 ? void 0 : _typeMap$type21.typeName]) === null || _value$typeMap$type$t3 === void 0 ? void 0 : _value$typeMap$type$t3[0])) {
20241
- var _typeMap$type22;
20242
- newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type22 = typeMap$5[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.key)] = getGoodDetails({
20376
+ newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type17 = typeMap$5[type]) === null || _typeMap$type17 === void 0 ? void 0 : _typeMap$type17.systemOrderNo)] = val;
20377
+ if (['2'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t2 = value[(_typeMap$type18 = typeMap$5[type]) === null || _typeMap$type18 === void 0 ? void 0 : _typeMap$type18.typeName]) === null || _value$typeMap$type$t2 === void 0 ? void 0 : _value$typeMap$type$t2[0])) {
20378
+ var _typeMap$type19;
20379
+ newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type19 = typeMap$5[type]) === null || _typeMap$type19 === void 0 ? void 0 : _typeMap$type19.key)] = [];
20380
+ } else if (['1'].includes(value === null || value === void 0 ? void 0 : (_value$typeMap$type$t3 = value[(_typeMap$type20 = typeMap$5[type]) === null || _typeMap$type20 === void 0 ? void 0 : _typeMap$type20.typeName]) === null || _value$typeMap$type$t3 === void 0 ? void 0 : _value$typeMap$type$t3[0])) {
20381
+ var _typeMap$type21;
20382
+ newValue["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type21 = typeMap$5[type]) === null || _typeMap$type21 === void 0 ? void 0 : _typeMap$type21.key)] = getGoodDetails({
20243
20383
  mode: isStrict,
20244
20384
  sysOrderNo: val
20245
20385
  });
@@ -20247,11 +20387,11 @@ var GyReturnGoods = function GyReturnGoods(props) {
20247
20387
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
20248
20388
  };
20249
20389
  var getGoodDetails = function getGoodDetails(_ref4) {
20250
- var _typeMap$type23, _typeMap$type24, _order$details;
20390
+ var _typeMap$type22, _typeMap$type23, _order$details;
20251
20391
  var mode = _ref4.mode,
20252
20392
  sysOrderNo = _ref4.sysOrderNo;
20253
- var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type23 = typeMap$5[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.systemOrder];
20254
- var systemOrderNo = sysOrderNo !== null && sysOrderNo !== void 0 ? sysOrderNo : value === null || value === void 0 ? void 0 : value[(_typeMap$type24 = typeMap$5[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.systemOrderNo];
20393
+ var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type22 = typeMap$5[type]) === null || _typeMap$type22 === void 0 ? void 0 : _typeMap$type22.systemOrder];
20394
+ var systemOrderNo = sysOrderNo !== null && sysOrderNo !== void 0 ? sysOrderNo : value === null || value === void 0 ? void 0 : value[(_typeMap$type23 = typeMap$5[type]) === null || _typeMap$type23 === void 0 ? void 0 : _typeMap$type23.systemOrderNo];
20255
20395
  var order = systemOrderNo && ((systemOrder === null || systemOrder === void 0 ? void 0 : systemOrder.orders) || []).find(function (order) {
20256
20396
  return order.code === systemOrderNo;
20257
20397
  });
@@ -20262,19 +20402,18 @@ var GyReturnGoods = function GyReturnGoods(props) {
20262
20402
  }) : goodDetails;
20263
20403
  };
20264
20404
  var handleModeChange = function handleModeChange(mode) {
20265
- var _value$typeMap$type$t4, _typeMap$type25, _typeMap$type26;
20266
- var isOriginalOrder = (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t4 = value[(_typeMap$type25 = typeMap$5[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.typeName]) === null || _value$typeMap$type$t4 === void 0 ? void 0 : _value$typeMap$type$t4[0]) === '1';
20405
+ var _value$typeMap$type$t4, _typeMap$type24, _typeMap$type25;
20406
+ var isOriginalOrder = (value === null || value === void 0 ? void 0 : (_value$typeMap$type$t4 = value[(_typeMap$type24 = typeMap$5[type]) === null || _typeMap$type24 === void 0 ? void 0 : _typeMap$type24.typeName]) === null || _value$typeMap$type$t4 === void 0 ? void 0 : _value$typeMap$type$t4[0]) === '1';
20267
20407
  setIsStrict(mode);
20268
20408
  if (!isOriginalOrder) return;
20269
- onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type26 = typeMap$5[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.key, getGoodDetails({
20409
+ onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2(_objectSpread2({}, value), {}, _defineProperty({}, (_typeMap$type25 = typeMap$5[type]) === null || _typeMap$type25 === void 0 ? void 0 : _typeMap$type25.key, getGoodDetails({
20270
20410
  mode: mode
20271
20411
  }))));
20272
20412
  };
20273
20413
  //系统单选择后展示选择商品按钮,系统单未选择的时候不展示
20274
- var showChangeBtn = useMemo(function () {
20275
- var _typeMap$type27;
20276
- return !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type27 = typeMap$5[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrderNo]);
20277
- }, [value === null || value === void 0 ? void 0 : value[(_typeMap$type28 = typeMap$5[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.systemOrderNo]]);
20414
+ var systemOrder = value === null || value === void 0 ? void 0 : value[(_typeMap$type26 = typeMap$5[type]) === null || _typeMap$type26 === void 0 ? void 0 : _typeMap$type26.systemOrder];
20415
+ var showErpGoodsBtn = type === 'GY_RETURN_GOODS' && systemOrder && systemOrder.orderNo && !((_systemOrder$orders = systemOrder.orders) === null || _systemOrder$orders === void 0 ? void 0 : _systemOrder$orders.length);
20416
+ var showChangeBtn = !!(value === null || value === void 0 ? void 0 : value[(_typeMap$type27 = typeMap$5[type]) === null || _typeMap$type27 === void 0 ? void 0 : _typeMap$type27.systemOrderNo]);
20278
20417
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
20279
20418
  gutter: 8,
20280
20419
  wrap: true
@@ -20292,12 +20431,12 @@ var GyReturnGoods = function GyReturnGoods(props) {
20292
20431
  },
20293
20432
  disabled: disabled,
20294
20433
  allowClear: false,
20295
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type29 = typeMap$5[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.systemOrderNo)],
20434
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type28 = typeMap$5[type]) === null || _typeMap$type28 === void 0 ? void 0 : _typeMap$type28.systemOrderNo)],
20296
20435
  onChange: function onChange(val) {
20297
20436
  return changeSystemOrderHandle(val);
20298
20437
  },
20299
20438
  placeholder: "\u9009\u62E9\u9000\u8D27\u7684\u7CFB\u7EDF\u5355"
20300
- }, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type30 = typeMap$5[type]) === null || _typeMap$type30 === void 0 ? void 0 : _typeMap$type30.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
20439
+ }, ((value === null || value === void 0 ? void 0 : (_value$typeMap$type$s5 = value[(_typeMap$type29 = typeMap$5[type]) === null || _typeMap$type29 === void 0 ? void 0 : _typeMap$type29.systemOrder]) === null || _value$typeMap$type$s5 === void 0 ? void 0 : _value$typeMap$type$s5.showOrderInfo) || []).map(function (item) {
20301
20440
  return /*#__PURE__*/React.createElement(Select.Option, {
20302
20441
  key: item.billNo,
20303
20442
  value: item.billNo,
@@ -20318,7 +20457,7 @@ var GyReturnGoods = function GyReturnGoods(props) {
20318
20457
  disabled: disabled,
20319
20458
  allowClear: false,
20320
20459
  options: reasonList,
20321
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type31 = typeMap$5[type]) === null || _typeMap$type31 === void 0 ? void 0 : _typeMap$type31.typeName)],
20460
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type30 = typeMap$5[type]) === null || _typeMap$type30 === void 0 ? void 0 : _typeMap$type30.typeName)],
20322
20461
  onChange: function onChange(val) {
20323
20462
  return changeTypeHandle(val);
20324
20463
  }
@@ -20330,13 +20469,14 @@ var GyReturnGoods = function GyReturnGoods(props) {
20330
20469
  canUpdateNumber: showChangeBtn,
20331
20470
  showChangeBtn: showChangeBtn,
20332
20471
  shopCode: value === null || value === void 0 ? void 0 : value.shopCode,
20333
- value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type32 = typeMap$5[type]) === null || _typeMap$type32 === void 0 ? void 0 : _typeMap$type32.key)],
20472
+ value: value === null || value === void 0 ? void 0 : value["".concat(typeMap$5 === null || typeMap$5 === void 0 ? void 0 : (_typeMap$type31 = typeMap$5[type]) === null || _typeMap$type31 === void 0 ? void 0 : _typeMap$type31.key)],
20334
20473
  onChange: function onChange(val) {
20335
20474
  return changeGoodHandle(val);
20336
20475
  },
20337
20476
  onModeChange: handleModeChange,
20338
20477
  isStrict: isStrict,
20339
- showErpGoodsBtn: false,
20478
+ showErpGoodsBtn: showErpGoodsBtn,
20479
+ alwaysShowChooseErpGoodsBtn: showErpGoodsBtn,
20340
20480
  tradeGoods: {
20341
20481
  originDataSource: getGoodDetails({
20342
20482
  mode: isStrict
@@ -20346,4 +20486,4 @@ var GyReturnGoods = function GyReturnGoods(props) {
20346
20486
  })));
20347
20487
  };
20348
20488
 
20349
- export { ApaasAddress as Address, AliPay, Province as ApaasAddress, ApaasCascader, ApaasCheckbox, ApaasDate, withFormItem as ApaasHoc, ApaasInput, ApaasInputNumber, ApaasLogistics, ApaasMultipleSelect, ApaasPosting, ApaasRadio, ApaasRate, ApaasSelect, ApaasSlider, ApaasTextArea, ApaasUpload, index as ApaasUploadAsync, ApaasUploadFile, index$1 as ApaasUploadProAsync, bsE3Reissue as BsE3Reissue, BsExchange, BsGoods, BsReissue, BsReturnGoods as BsReturn, index$3 as BsSystemOrder, BuyerNick, CalculationInput, ChooseBaby, CommonExchangeGoods, CommonGoods, CommonSystemOrder$1 as CommonMultiStatus, CommonReturnGoods, CommonStatus, CommonSystemOrder, CopyTextIcon, ExpressLogistics, Goods, index$4 as GoodsTable, GyReissue, GyReturnGoods as GyReturn, IdentifyAddress, Invoice, jstGoods as JstGoods, ItemList as JstItemList, LogisticsInterception, LogisticsMoreInterception, LogisticsMoreTrajectory, LogisticsTrajectory, MsgStatus, ParseLogistics, Payment, PublicReissue, RemarkInput as Remark, ExpressLogistics as ReturnLogistics, ShopNameSelect as ShopName, Status, SubForm, Supplier, TBGoodId, TBGoodSerial, TradeId, WdtGoodList, wdtReissue as WdtReissue, WlnGoods, columnsBaseInfoMap, erpColumnsMap, index$2 as erpModalColumnsMap, getColumns$4 as getGyColumns, getColumns$5 as getJstColumns, getColumns$2 as getWdtColumns, getColumns$3 as getWlnColumns };
20489
+ export { ApaasAddress as Address, AliPay, Province as ApaasAddress, ApaasCascader, ApaasCheckbox, ApaasDate, withFormItem as ApaasHoc, ApaasInput, ApaasInputNumber, ApaasLogistics, ApaasMultipleSelect, ApaasPosting, ApaasRadio, ApaasRate, ApaasSelect, ApaasSlider, ApaasTextArea, ApaasUpload, index as ApaasUploadAsync, ApaasUploadFile, index$1 as ApaasUploadProAsync, AsyncSelect, bsE3Reissue as BsE3Reissue, BsExchange, BsGoods, BsReissue, BsReturnGoods as BsReturn, index$3 as BsSystemOrder, BuyerNick, CalculationInput, ChooseBaby, CommonExchangeGoods, CommonGoods, CommonSystemOrder$1 as CommonMultiStatus, CommonReturnGoods, CommonStatus, CommonSystemOrder, CopyTextIcon, ExpressLogistics, Goods, index$4 as GoodsTable, GyReissue, GyReturnGoods as GyReturn, IdentifyAddress, Invoice, jstGoods as JstGoods, ItemList as JstItemList, LogisticsInterception, LogisticsMoreInterception, LogisticsMoreTrajectory, LogisticsTrajectory, MsgStatus, ParseLogistics, Payment, PublicReissue, RemarkInput as Remark, ExpressLogistics as ReturnLogistics, ShopNameSelect as ShopName, Status, SubForm, Supplier, TBGoodId, TBGoodSerial, TradeId, WdtGoodList, wdtReissue as WdtReissue, WlnGoods, columnsBaseInfoMap, erpColumnsMap, erpFormValidator, index$2 as erpModalColumnsMap, getColumns$4 as getGyColumns, getColumns$5 as getJstColumns, getColumns$2 as getWdtColumns, getColumns$3 as getWlnColumns };