kts-component-invoice-operate 1.2.21 → 1.2.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.
Files changed (35) hide show
  1. package/dist/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/index.d.ts +2 -0
  2. package/dist/Invoice/InvoiceController/fns/addGood.d.ts +1 -1
  3. package/dist/Invoice/InvoiceController/fns/addGoodDiscount.d.ts +1 -1
  4. package/dist/Invoice/InvoiceController/fns/delGood.d.ts +1 -1
  5. package/dist/Invoice/InvoiceController/fns/getGoodsSearch.d.ts +2 -0
  6. package/dist/Invoice/InvoiceController/fns/saveEditGood.d.ts +1 -1
  7. package/dist/Invoice/InvoiceController/fns/setEditGood.d.ts +1 -1
  8. package/dist/Invoice/InvoiceController/fns/setGoods.d.ts +1 -1
  9. package/dist/Invoice/InvoiceController/fns/updateInvoiceNo.d.ts +1 -1
  10. package/dist/Invoice/InvoiceController/index.d.ts +3 -0
  11. package/dist/Invoice/tools/coolingFn/index.d.ts +1 -1
  12. package/dist/Invoice/tools/lazyFn/index.d.ts +1 -1
  13. package/dist/Invoice/ui/GoodsList/ui/Search/index.d.ts +2 -0
  14. package/dist/index.esm.js +1203 -615
  15. package/dist/index.js +1203 -615
  16. package/docs/index.md +1 -1
  17. package/package.json +1 -1
  18. package/src/Invoice/InvoiceController/InvoiceControllerState/GoodsListState/index.ts +4 -1
  19. package/src/Invoice/InvoiceController/fns/getGoodsSearch.ts +17 -0
  20. package/src/Invoice/InvoiceController/index.ts +4 -0
  21. package/src/Invoice/ui/EndowCodeDrawer/index.tsx +19 -13
  22. package/src/Invoice/ui/GoodsList/hook/useColumns/index.tsx +27 -4
  23. package/src/Invoice/ui/GoodsList/hook/useRowSelection/index.tsx +34 -8
  24. package/src/Invoice/ui/GoodsList/index.less +41 -33
  25. package/src/Invoice/ui/GoodsList/index.tsx +11 -1
  26. package/src/Invoice/ui/GoodsList/ui/AddRowButton/index.tsx +5 -2
  27. package/src/Invoice/ui/GoodsList/ui/Search/icon/magnifier.svg +1 -0
  28. package/src/Invoice/ui/GoodsList/ui/Search/index.less +10 -0
  29. package/src/Invoice/ui/GoodsList/ui/Search/index.tsx +47 -0
  30. package/docs-dist/404.html +0 -33
  31. package/docs-dist/index.html +0 -33
  32. package/docs-dist/static/auto.a6cd905c.svg +0 -1
  33. package/docs-dist/static/spot.42e620e1.svg +0 -1
  34. package/docs-dist/umi.css +0 -20
  35. package/docs-dist/umi.js +0 -1
package/dist/index.esm.js CHANGED
@@ -13,14 +13,9 @@ function ownKeys(object, enumerableOnly) {
13
13
 
14
14
  if (Object.getOwnPropertySymbols) {
15
15
  var symbols = Object.getOwnPropertySymbols(object);
16
-
17
- if (enumerableOnly) {
18
- symbols = symbols.filter(function (sym) {
19
- return Object.getOwnPropertyDescriptor(object, sym).enumerable;
20
- });
21
- }
22
-
23
- keys.push.apply(keys, symbols);
16
+ enumerableOnly && (symbols = symbols.filter(function (sym) {
17
+ return Object.getOwnPropertyDescriptor(object, sym).enumerable;
18
+ })), keys.push.apply(keys, symbols);
24
19
  }
25
20
 
26
21
  return keys;
@@ -28,22 +23,360 @@ function ownKeys(object, enumerableOnly) {
28
23
 
29
24
  function _objectSpread2(target) {
30
25
  for (var i = 1; i < arguments.length; i++) {
31
- var source = arguments[i] != null ? arguments[i] : {};
26
+ var source = null != arguments[i] ? arguments[i] : {};
27
+ i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
28
+ _defineProperty(target, key, source[key]);
29
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {
30
+ Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
31
+ });
32
+ }
32
33
 
33
- if (i % 2) {
34
- ownKeys(Object(source), true).forEach(function (key) {
35
- _defineProperty(target, key, source[key]);
36
- });
37
- } else if (Object.getOwnPropertyDescriptors) {
38
- Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
39
- } else {
40
- ownKeys(Object(source)).forEach(function (key) {
41
- Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
34
+ return target;
35
+ }
36
+
37
+ function _regeneratorRuntime() {
38
+ /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
39
+
40
+ _regeneratorRuntime = function () {
41
+ return exports;
42
+ };
43
+
44
+ var exports = {},
45
+ Op = Object.prototype,
46
+ hasOwn = Op.hasOwnProperty,
47
+ $Symbol = "function" == typeof Symbol ? Symbol : {},
48
+ iteratorSymbol = $Symbol.iterator || "@@iterator",
49
+ asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator",
50
+ toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
51
+
52
+ function define(obj, key, value) {
53
+ return Object.defineProperty(obj, key, {
54
+ value: value,
55
+ enumerable: !0,
56
+ configurable: !0,
57
+ writable: !0
58
+ }), obj[key];
59
+ }
60
+
61
+ try {
62
+ define({}, "");
63
+ } catch (err) {
64
+ define = function (obj, key, value) {
65
+ return obj[key] = value;
66
+ };
67
+ }
68
+
69
+ function wrap(innerFn, outerFn, self, tryLocsList) {
70
+ var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator,
71
+ generator = Object.create(protoGenerator.prototype),
72
+ context = new Context(tryLocsList || []);
73
+ return generator._invoke = function (innerFn, self, context) {
74
+ var state = "suspendedStart";
75
+ return function (method, arg) {
76
+ if ("executing" === state) throw new Error("Generator is already running");
77
+
78
+ if ("completed" === state) {
79
+ if ("throw" === method) throw arg;
80
+ return doneResult();
81
+ }
82
+
83
+ for (context.method = method, context.arg = arg;;) {
84
+ var delegate = context.delegate;
85
+
86
+ if (delegate) {
87
+ var delegateResult = maybeInvokeDelegate(delegate, context);
88
+
89
+ if (delegateResult) {
90
+ if (delegateResult === ContinueSentinel) continue;
91
+ return delegateResult;
92
+ }
93
+ }
94
+
95
+ if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) {
96
+ if ("suspendedStart" === state) throw state = "completed", context.arg;
97
+ context.dispatchException(context.arg);
98
+ } else "return" === context.method && context.abrupt("return", context.arg);
99
+ state = "executing";
100
+ var record = tryCatch(innerFn, self, context);
101
+
102
+ if ("normal" === record.type) {
103
+ if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue;
104
+ return {
105
+ value: record.arg,
106
+ done: context.done
107
+ };
108
+ }
109
+
110
+ "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg);
111
+ }
112
+ };
113
+ }(innerFn, self, context), generator;
114
+ }
115
+
116
+ function tryCatch(fn, obj, arg) {
117
+ try {
118
+ return {
119
+ type: "normal",
120
+ arg: fn.call(obj, arg)
121
+ };
122
+ } catch (err) {
123
+ return {
124
+ type: "throw",
125
+ arg: err
126
+ };
127
+ }
128
+ }
129
+
130
+ exports.wrap = wrap;
131
+ var ContinueSentinel = {};
132
+
133
+ function Generator() {}
134
+
135
+ function GeneratorFunction() {}
136
+
137
+ function GeneratorFunctionPrototype() {}
138
+
139
+ var IteratorPrototype = {};
140
+ define(IteratorPrototype, iteratorSymbol, function () {
141
+ return this;
142
+ });
143
+ var getProto = Object.getPrototypeOf,
144
+ NativeIteratorPrototype = getProto && getProto(getProto(values([])));
145
+ NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype);
146
+ var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype);
147
+
148
+ function defineIteratorMethods(prototype) {
149
+ ["next", "throw", "return"].forEach(function (method) {
150
+ define(prototype, method, function (arg) {
151
+ return this._invoke(method, arg);
42
152
  });
153
+ });
154
+ }
155
+
156
+ function AsyncIterator(generator, PromiseImpl) {
157
+ function invoke(method, arg, resolve, reject) {
158
+ var record = tryCatch(generator[method], generator, arg);
159
+
160
+ if ("throw" !== record.type) {
161
+ var result = record.arg,
162
+ value = result.value;
163
+ return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) {
164
+ invoke("next", value, resolve, reject);
165
+ }, function (err) {
166
+ invoke("throw", err, resolve, reject);
167
+ }) : PromiseImpl.resolve(value).then(function (unwrapped) {
168
+ result.value = unwrapped, resolve(result);
169
+ }, function (error) {
170
+ return invoke("throw", error, resolve, reject);
171
+ });
172
+ }
173
+
174
+ reject(record.arg);
43
175
  }
176
+
177
+ var previousPromise;
178
+
179
+ this._invoke = function (method, arg) {
180
+ function callInvokeWithMethodAndArg() {
181
+ return new PromiseImpl(function (resolve, reject) {
182
+ invoke(method, arg, resolve, reject);
183
+ });
184
+ }
185
+
186
+ return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
187
+ };
44
188
  }
45
189
 
46
- return target;
190
+ function maybeInvokeDelegate(delegate, context) {
191
+ var method = delegate.iterator[context.method];
192
+
193
+ if (undefined === method) {
194
+ if (context.delegate = null, "throw" === context.method) {
195
+ if (delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method)) return ContinueSentinel;
196
+ context.method = "throw", context.arg = new TypeError("The iterator does not provide a 'throw' method");
197
+ }
198
+
199
+ return ContinueSentinel;
200
+ }
201
+
202
+ var record = tryCatch(method, delegate.iterator, context.arg);
203
+ if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel;
204
+ var info = record.arg;
205
+ 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);
206
+ }
207
+
208
+ function pushTryEntry(locs) {
209
+ var entry = {
210
+ tryLoc: locs[0]
211
+ };
212
+ 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry);
213
+ }
214
+
215
+ function resetTryEntry(entry) {
216
+ var record = entry.completion || {};
217
+ record.type = "normal", delete record.arg, entry.completion = record;
218
+ }
219
+
220
+ function Context(tryLocsList) {
221
+ this.tryEntries = [{
222
+ tryLoc: "root"
223
+ }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0);
224
+ }
225
+
226
+ function values(iterable) {
227
+ if (iterable) {
228
+ var iteratorMethod = iterable[iteratorSymbol];
229
+ if (iteratorMethod) return iteratorMethod.call(iterable);
230
+ if ("function" == typeof iterable.next) return iterable;
231
+
232
+ if (!isNaN(iterable.length)) {
233
+ var i = -1,
234
+ next = function next() {
235
+ for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next;
236
+
237
+ return next.value = undefined, next.done = !0, next;
238
+ };
239
+
240
+ return next.next = next;
241
+ }
242
+ }
243
+
244
+ return {
245
+ next: doneResult
246
+ };
247
+ }
248
+
249
+ function doneResult() {
250
+ return {
251
+ value: undefined,
252
+ done: !0
253
+ };
254
+ }
255
+
256
+ return GeneratorFunction.prototype = GeneratorFunctionPrototype, define(Gp, "constructor", GeneratorFunctionPrototype), define(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) {
257
+ var ctor = "function" == typeof genFun && genFun.constructor;
258
+ return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name));
259
+ }, exports.mark = function (genFun) {
260
+ return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun;
261
+ }, exports.awrap = function (arg) {
262
+ return {
263
+ __await: arg
264
+ };
265
+ }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
266
+ return this;
267
+ }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) {
268
+ void 0 === PromiseImpl && (PromiseImpl = Promise);
269
+ var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl);
270
+ return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) {
271
+ return result.done ? result.value : iter.next();
272
+ });
273
+ }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () {
274
+ return this;
275
+ }), define(Gp, "toString", function () {
276
+ return "[object Generator]";
277
+ }), exports.keys = function (object) {
278
+ var keys = [];
279
+
280
+ for (var key in object) keys.push(key);
281
+
282
+ return keys.reverse(), function next() {
283
+ for (; keys.length;) {
284
+ var key = keys.pop();
285
+ if (key in object) return next.value = key, next.done = !1, next;
286
+ }
287
+
288
+ return next.done = !0, next;
289
+ };
290
+ }, exports.values = values, Context.prototype = {
291
+ constructor: Context,
292
+ reset: function (skipTempReset) {
293
+ 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);
294
+ },
295
+ stop: function () {
296
+ this.done = !0;
297
+ var rootRecord = this.tryEntries[0].completion;
298
+ if ("throw" === rootRecord.type) throw rootRecord.arg;
299
+ return this.rval;
300
+ },
301
+ dispatchException: function (exception) {
302
+ if (this.done) throw exception;
303
+ var context = this;
304
+
305
+ function handle(loc, caught) {
306
+ return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught;
307
+ }
308
+
309
+ for (var i = this.tryEntries.length - 1; i >= 0; --i) {
310
+ var entry = this.tryEntries[i],
311
+ record = entry.completion;
312
+ if ("root" === entry.tryLoc) return handle("end");
313
+
314
+ if (entry.tryLoc <= this.prev) {
315
+ var hasCatch = hasOwn.call(entry, "catchLoc"),
316
+ hasFinally = hasOwn.call(entry, "finallyLoc");
317
+
318
+ if (hasCatch && hasFinally) {
319
+ if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
320
+ if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
321
+ } else if (hasCatch) {
322
+ if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
323
+ } else {
324
+ if (!hasFinally) throw new Error("try statement without catch or finally");
325
+ if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
326
+ }
327
+ }
328
+ }
329
+ },
330
+ abrupt: function (type, arg) {
331
+ for (var i = this.tryEntries.length - 1; i >= 0; --i) {
332
+ var entry = this.tryEntries[i];
333
+
334
+ if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) {
335
+ var finallyEntry = entry;
336
+ break;
337
+ }
338
+ }
339
+
340
+ finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null);
341
+ var record = finallyEntry ? finallyEntry.completion : {};
342
+ return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record);
343
+ },
344
+ complete: function (record, afterLoc) {
345
+ if ("throw" === record.type) throw record.arg;
346
+ 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;
347
+ },
348
+ finish: function (finallyLoc) {
349
+ for (var i = this.tryEntries.length - 1; i >= 0; --i) {
350
+ var entry = this.tryEntries[i];
351
+ if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel;
352
+ }
353
+ },
354
+ catch: function (tryLoc) {
355
+ for (var i = this.tryEntries.length - 1; i >= 0; --i) {
356
+ var entry = this.tryEntries[i];
357
+
358
+ if (entry.tryLoc === tryLoc) {
359
+ var record = entry.completion;
360
+
361
+ if ("throw" === record.type) {
362
+ var thrown = record.arg;
363
+ resetTryEntry(entry);
364
+ }
365
+
366
+ return thrown;
367
+ }
368
+ }
369
+
370
+ throw new Error("illegal catch attempt");
371
+ },
372
+ delegateYield: function (iterable, resultName, nextLoc) {
373
+ return this.delegate = {
374
+ iterator: values(iterable),
375
+ resultName: resultName,
376
+ nextLoc: nextLoc
377
+ }, "next" === this.method && (this.arg = undefined), ContinueSentinel;
378
+ }
379
+ }, exports;
47
380
  }
48
381
 
49
382
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
@@ -101,6 +434,9 @@ function _defineProperties(target, props) {
101
434
  function _createClass(Constructor, protoProps, staticProps) {
102
435
  if (protoProps) _defineProperties(Constructor.prototype, protoProps);
103
436
  if (staticProps) _defineProperties(Constructor, staticProps);
437
+ Object.defineProperty(Constructor, "prototype", {
438
+ writable: false
439
+ });
104
440
  return Constructor;
105
441
  }
106
442
 
@@ -131,22 +467,24 @@ function _inherits(subClass, superClass) {
131
467
  configurable: true
132
468
  }
133
469
  });
470
+ Object.defineProperty(subClass, "prototype", {
471
+ writable: false
472
+ });
134
473
  if (superClass) _setPrototypeOf(subClass, superClass);
135
474
  }
136
475
 
137
476
  function _getPrototypeOf(o) {
138
- _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {
477
+ _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) {
139
478
  return o.__proto__ || Object.getPrototypeOf(o);
140
479
  };
141
480
  return _getPrototypeOf(o);
142
481
  }
143
482
 
144
483
  function _setPrototypeOf(o, p) {
145
- _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
484
+ _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
146
485
  o.__proto__ = p;
147
486
  return o;
148
487
  };
149
-
150
488
  return _setPrototypeOf(o, p);
151
489
  }
152
490
 
@@ -345,12 +683,12 @@ var InvoiceControllerForm = /*#__PURE__*/function (_GreyReactBox) {
345
683
  }, {
346
684
  key: "validateFields",
347
685
  value: function () {
348
- var _validateFields2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
686
+ var _validateFields2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
349
687
  var _this3 = this;
350
688
 
351
689
  var _errors, _values, arr, i, key, _yield$_validateField, errors, values, _this$state$goodsList;
352
690
 
353
- return regeneratorRuntime.wrap(function _callee$(_context) {
691
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
354
692
  while (1) {
355
693
  switch (_context.prev = _context.next) {
356
694
  case 0:
@@ -479,7 +817,7 @@ var _validateFields = function _validateFields(form) {
479
817
  });
480
818
  };
481
819
 
482
- var ImportGoods = function ImportGoods() {
820
+ var ImportGoods = /*#__PURE__*/_createClass(function ImportGoods() {
483
821
  _classCallCheck(this, ImportGoods);
484
822
 
485
823
  this.columns = [{
@@ -521,8 +859,8 @@ var ImportGoods = function ImportGoods() {
521
859
  this.topExpand = void 0;
522
860
 
523
861
  this.verifyFn = /*#__PURE__*/function () {
524
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(record) {
525
- return regeneratorRuntime.wrap(function _callee$(_context) {
862
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(record) {
863
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
526
864
  while (1) {
527
865
  switch (_context.prev = _context.next) {
528
866
  case 0:
@@ -564,7 +902,7 @@ var ImportGoods = function ImportGoods() {
564
902
  return _ref.apply(this, arguments);
565
903
  };
566
904
  }();
567
- };
905
+ });
568
906
 
569
907
  var LineAttributeType;
570
908
 
@@ -576,12 +914,12 @@ var LineAttributeType;
576
914
 
577
915
  var LineAttributeType$1 = LineAttributeType;
578
916
 
579
- var EndowCode = function EndowCode() {
917
+ var EndowCode = /*#__PURE__*/_createClass(function EndowCode() {
580
918
  _classCallCheck(this, EndowCode);
581
919
 
582
920
  this.endowcodeGoodIndex = [];
583
- this.getTaxCategoryCodeList = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
584
- return regeneratorRuntime.wrap(function _callee$(_context) {
921
+ this.getTaxCategoryCodeList = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
922
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
585
923
  while (1) {
586
924
  switch (_context.prev = _context.next) {
587
925
  case 0:
@@ -613,7 +951,7 @@ var EndowCode = function EndowCode() {
613
951
  value: 3
614
952
  }];
615
953
  this.cache = {};
616
- };
954
+ });
617
955
 
618
956
  function draft(value) {
619
957
  if (!value) return true; // isDiscount
@@ -634,7 +972,7 @@ function draft(value) {
634
972
  }
635
973
  }
636
974
 
637
- var GoodsListState = function GoodsListState() {
975
+ var GoodsListState = /*#__PURE__*/_createClass(function GoodsListState() {
638
976
  _classCallCheck(this, GoodsListState);
639
977
 
640
978
  this.deduction = 0;
@@ -647,6 +985,7 @@ var GoodsListState = function GoodsListState() {
647
985
  this.unitList = [];
648
986
  this.defaultRate = 3;
649
987
  this.taxRateList = [0, 3, 5, 6, 9, 13];
988
+ this.searchValue = '';
650
989
  this.goodsList = [];
651
990
  this.goodsMap = new Map();
652
991
  this.goodsMenuExpand = [];
@@ -655,9 +994,9 @@ var GoodsListState = function GoodsListState() {
655
994
  this.endowCode = new EndowCode();
656
995
  this.importGoods = new ImportGoods();
657
996
  this.isVisibleDrawer = false;
658
- };
997
+ });
659
998
 
660
- var BuyerState = function BuyerState() {
999
+ var BuyerState = /*#__PURE__*/_createClass(function BuyerState() {
661
1000
  _classCallCheck(this, BuyerState);
662
1001
 
663
1002
  this.columns = [{
@@ -683,8 +1022,8 @@ var BuyerState = function BuyerState() {
683
1022
  }];
684
1023
 
685
1024
  this.onRowClick = /*#__PURE__*/function () {
686
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(record) {
687
- return regeneratorRuntime.wrap(function _callee$(_context) {
1025
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(record) {
1026
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
688
1027
  while (1) {
689
1028
  switch (_context.prev = _context.next) {
690
1029
  case 0:
@@ -708,9 +1047,9 @@ var BuyerState = function BuyerState() {
708
1047
  this.isVisibleDrawer = false;
709
1048
  this.topExpand = void 0;
710
1049
  this.autoContainer = void 0;
711
- };
1050
+ });
712
1051
 
713
- var InvoiceControllerState = function InvoiceControllerState() {
1052
+ var InvoiceControllerState = /*#__PURE__*/_createClass(function InvoiceControllerState() {
714
1053
  _classCallCheck(this, InvoiceControllerState);
715
1054
 
716
1055
  this.model = 'default';
@@ -718,15 +1057,15 @@ var InvoiceControllerState = function InvoiceControllerState() {
718
1057
  this.invoiceType = '08';
719
1058
  this.buyerState = new BuyerState();
720
1059
  this.goodsListState = new GoodsListState();
721
- };
1060
+ });
722
1061
 
723
1062
  /**
724
1063
  * 设置当前的编辑货物
725
1064
  */
726
1065
  var setEditGood = /*#__PURE__*/(function () {
727
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(state, newEditGood) {
1066
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(state, newEditGood) {
728
1067
  var editGood;
729
- return regeneratorRuntime.wrap(function _callee$(_context) {
1068
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
730
1069
  while (1) {
731
1070
  switch (_context.prev = _context.next) {
732
1071
  case 0:
@@ -758,9 +1097,9 @@ var setEditGood = /*#__PURE__*/(function () {
758
1097
  * 设置单个货物属性
759
1098
  */
760
1099
  var setGoods = /*#__PURE__*/(function () {
761
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(state, options) {
1100
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(state, options) {
762
1101
  var goodsList;
763
- return regeneratorRuntime.wrap(function _callee$(_context) {
1102
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
764
1103
  while (1) {
765
1104
  switch (_context.prev = _context.next) {
766
1105
  case 0:
@@ -797,9 +1136,9 @@ var setGoods = /*#__PURE__*/(function () {
797
1136
  */
798
1137
 
799
1138
  var delGood = /*#__PURE__*/(function () {
800
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(state, $index) {
1139
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(state, $index) {
801
1140
  var goods;
802
- return regeneratorRuntime.wrap(function _callee$(_context) {
1141
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
803
1142
  while (1) {
804
1143
  switch (_context.prev = _context.next) {
805
1144
  case 0:
@@ -948,10 +1287,10 @@ function countPrice(amount, quantity) {
948
1287
  */
949
1288
 
950
1289
  var addGoodDiscount = /*#__PURE__*/(function () {
951
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(state, options) {
1290
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(state, options) {
952
1291
  var _options$indexList, indexList, discount, goodsMap, goodsList, discountGroup, amountSum, _loop, t, _ret;
953
1292
 
954
- return regeneratorRuntime.wrap(function _callee$(_context) {
1293
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
955
1294
  while (1) {
956
1295
  switch (_context.prev = _context.next) {
957
1296
  case 0:
@@ -1070,8 +1409,8 @@ var addGoodDiscount = /*#__PURE__*/(function () {
1070
1409
  */
1071
1410
 
1072
1411
  var addGood = /*#__PURE__*/(function () {
1073
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(state, options) {
1074
- return regeneratorRuntime.wrap(function _callee$(_context) {
1412
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(state, options) {
1413
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
1075
1414
  while (1) {
1076
1415
  switch (_context.prev = _context.next) {
1077
1416
  case 0:
@@ -1096,9 +1435,9 @@ var addGood = /*#__PURE__*/(function () {
1096
1435
  * 保存正在编辑的货物
1097
1436
  */
1098
1437
  var saveEditGood = /*#__PURE__*/(function () {
1099
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(state) {
1438
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(state) {
1100
1439
  var editGood, form;
1101
- return regeneratorRuntime.wrap(function _callee$(_context) {
1440
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
1102
1441
  while (1) {
1103
1442
  switch (_context.prev = _context.next) {
1104
1443
  case 0:
@@ -1146,8 +1485,8 @@ var saveEditGood = /*#__PURE__*/(function () {
1146
1485
  var validateFields = function validateFields(form) {
1147
1486
  return new Promise(function (resolve) {
1148
1487
  form.validateFields( /*#__PURE__*/function () {
1149
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(err, values) {
1150
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
1488
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(err, values) {
1489
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
1151
1490
  while (1) {
1152
1491
  switch (_context2.prev = _context2.next) {
1153
1492
  case 0:
@@ -1171,6 +1510,23 @@ var validateFields = function validateFields(form) {
1171
1510
  });
1172
1511
  };
1173
1512
 
1513
+ function getGoodsSearch(goodsList, search) {
1514
+ if (!search) return goodsList;
1515
+ return goodsList.filter(function (e) {
1516
+ var _e$itemName$indexOf, _e$itemName, _e$itemModelName$inde, _e$itemModelName;
1517
+
1518
+ if (((_e$itemName$indexOf = (_e$itemName = e.itemName) === null || _e$itemName === void 0 ? void 0 : _e$itemName.indexOf(search)) !== null && _e$itemName$indexOf !== void 0 ? _e$itemName$indexOf : -1) >= 0) {
1519
+ return true;
1520
+ } else if (((_e$itemModelName$inde = (_e$itemModelName = e.itemModelName) === null || _e$itemModelName === void 0 ? void 0 : _e$itemModelName.indexOf(search)) !== null && _e$itemModelName$inde !== void 0 ? _e$itemModelName$inde : -1) >= 0) {
1521
+ return true;
1522
+ } else if ("".concat(e.lineAmountIncludeTax).indexOf(search) >= 0) {
1523
+ return true;
1524
+ } else {
1525
+ return false;
1526
+ }
1527
+ });
1528
+ }
1529
+
1174
1530
  var InvoiceController = /*#__PURE__*/function (_InvoiceControllerFor) {
1175
1531
  _inherits(InvoiceController, _InvoiceControllerFor);
1176
1532
 
@@ -1194,18 +1550,19 @@ var InvoiceController = /*#__PURE__*/function (_InvoiceControllerFor) {
1194
1550
  _this.addGoodDiscount = _this.pipeline(addGoodDiscount);
1195
1551
  _this.getGoodsList = void 0;
1196
1552
  _this.getTaxCategoryCodeList = void 0;
1553
+ _this.getGoodsSearch = getGoodsSearch;
1197
1554
  return _this;
1198
1555
  } // ----------------- 发票头 模块相关 -----------------
1199
1556
 
1200
1557
  /** 更新发票单据编号 */
1201
1558
 
1202
1559
 
1203
- return InvoiceController;
1560
+ return _createClass(InvoiceController);
1204
1561
  }(InvoiceControllerForm);
1205
1562
 
1206
1563
  var _defs, _path, _path2, _path3;
1207
1564
 
1208
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
1565
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
1209
1566
 
1210
1567
  function SvgAuto(props) {
1211
1568
  return /*#__PURE__*/createElement("svg", _extends({
@@ -1274,7 +1631,7 @@ var InvoiceHeader = decorator(Form.create())(function (props) {
1274
1631
  render: function render(form) {
1275
1632
  return form.getFieldDecorator('code', {
1276
1633
  initialValue: props.defaultCode
1277
- })( /*#__PURE__*/React.createElement(FormSpanString, null));
1634
+ })(React.createElement(FormSpanString, null));
1278
1635
  }
1279
1636
  });
1280
1637
  }
@@ -1287,7 +1644,7 @@ var InvoiceHeader = decorator(Form.create())(function (props) {
1287
1644
  render: function render(form) {
1288
1645
  return form.getFieldDecorator('no', {
1289
1646
  initialValue: props.defaultNo
1290
- })( /*#__PURE__*/React.createElement(FormSpanString, null));
1647
+ })(React.createElement(FormSpanString, null));
1291
1648
  }
1292
1649
  });
1293
1650
  }
@@ -1298,7 +1655,7 @@ var InvoiceHeader = decorator(Form.create())(function (props) {
1298
1655
  render: function render(form) {
1299
1656
  return form.getFieldDecorator('invoicingDate', {
1300
1657
  initialValue: props.defaultInvoicingDate
1301
- })( /*#__PURE__*/React.createElement(FormSpanString, null));
1658
+ })(React.createElement(FormSpanString, null));
1302
1659
  }
1303
1660
  });
1304
1661
  }
@@ -1309,7 +1666,7 @@ var InvoiceHeader = decorator(Form.create())(function (props) {
1309
1666
  render: function render(form) {
1310
1667
  return form.getFieldDecorator('defaultValidationCode', {
1311
1668
  initialValue: props.defaultValidationCode
1312
- })( /*#__PURE__*/React.createElement(FormSpanString, null));
1669
+ })(React.createElement(FormSpanString, null));
1313
1670
  }
1314
1671
  });
1315
1672
  }
@@ -1329,28 +1686,28 @@ var InvoiceHeader = decorator(Form.create())(function (props) {
1329
1686
  React.useEffect(function () {
1330
1687
  setTypeIndex(props.typeOptionIndex || 0);
1331
1688
  }, [props.typeOption]);
1332
- return /*#__PURE__*/React.createElement("div", {
1689
+ return React.createElement("div", {
1333
1690
  className: "kts-invoice-operate-invoice-header"
1334
- }, /*#__PURE__*/React.createElement("div", {
1691
+ }, React.createElement("div", {
1335
1692
  className: "invoice-header-title"
1336
- }, title), /*#__PURE__*/React.createElement("div", {
1693
+ }, title), React.createElement("div", {
1337
1694
  className: "invoice-header-no"
1338
- }, isInvoiceNo ? /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", null, "\u53D1\u7968\u5355\u636E\u7F16\u53F7 :"), getFieldDecorator('id', {
1695
+ }, isInvoiceNo ? React.createElement("div", null, React.createElement("label", null, "\u53D1\u7968\u5355\u636E\u7F16\u53F7 :"), getFieldDecorator('id', {
1339
1696
  initialValue: props.defaultId
1340
- })( /*#__PURE__*/React.createElement(Input, {
1697
+ })(React.createElement(Input, {
1341
1698
  disabled: readOnlyInvoiceNo,
1342
1699
  style: {
1343
1700
  width: 230
1344
1701
  },
1345
1702
  size: "small",
1346
- suffix: controller.updateInvoiceNo && /*#__PURE__*/React.createElement(Icon, {
1703
+ suffix: controller.updateInvoiceNo && React.createElement(Icon, {
1347
1704
  style: {
1348
1705
  cursor: 'pointer'
1349
1706
  },
1350
1707
  component: SvgAuto,
1351
1708
  onClick: function () {
1352
- var _onClick = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
1353
- return regeneratorRuntime.wrap(function _callee$(_context) {
1709
+ var _onClick = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
1710
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
1354
1711
  while (1) {
1355
1712
  switch (_context.prev = _context.next) {
1356
1713
  case 0:
@@ -1387,15 +1744,15 @@ var InvoiceHeader = decorator(Form.create())(function (props) {
1387
1744
  return onClick;
1388
1745
  }()
1389
1746
  })
1390
- }))) : /*#__PURE__*/React.createElement("div", {
1747
+ }))) : React.createElement("div", {
1391
1748
  style: {
1392
1749
  height: 20
1393
1750
  }
1394
- }), tag && /*#__PURE__*/React.createElement(Tag, null, tag), /*#__PURE__*/React.createElement("div", {
1751
+ }), tag && React.createElement(Tag, null, tag), React.createElement("div", {
1395
1752
  className: "invoice-header-type"
1396
1753
  }, props.typeOption ? getFieldDecorator('type', {
1397
1754
  initialValue: typeIndex
1398
- })( /*#__PURE__*/React.createElement(Select, {
1755
+ })(React.createElement(Select, {
1399
1756
  size: "small",
1400
1757
  style: {
1401
1758
  width: 230
@@ -1404,20 +1761,20 @@ var InvoiceHeader = decorator(Form.create())(function (props) {
1404
1761
  setTypeIndex(e);
1405
1762
  }
1406
1763
  }, props.typeOption.map(function (e, i) {
1407
- return /*#__PURE__*/React.createElement(Select.Option, {
1764
+ return React.createElement(Select.Option, {
1408
1765
  key: i,
1409
1766
  value: i
1410
1767
  }, e.title);
1411
- }))) : props.renderExpand && props.renderExpand(props.form))), props.typeOption && /*#__PURE__*/React.createElement("div", {
1768
+ }))) : props.renderExpand && props.renderExpand(props.form))), props.typeOption && React.createElement("div", {
1412
1769
  style: {
1413
1770
  marginTop: 10
1414
1771
  }
1415
- }, props.renderExpand && props.renderExpand(props.form)), /*#__PURE__*/React.createElement("div", {
1772
+ }, props.renderExpand && props.renderExpand(props.form)), React.createElement("div", {
1416
1773
  className: "invoice-header-property"
1417
- }, _toConsumableArray(props.fieldExpand || []).map(function (e) {}), /*#__PURE__*/React.createElement(Row, null, fieldExpand.map(function (e) {
1418
- return /*#__PURE__*/React.createElement(Col, {
1774
+ }, _toConsumableArray(props.fieldExpand || []).map(function (e) {}), React.createElement(Row, null, fieldExpand.map(function (e) {
1775
+ return React.createElement(Col, {
1419
1776
  span: 24 / fieldExpand.length
1420
- }, /*#__PURE__*/React.createElement("label", null, e.label), e.render(form));
1777
+ }, React.createElement("label", null, e.label), e.render(form));
1421
1778
  }))));
1422
1779
  });
1423
1780
 
@@ -1436,7 +1793,7 @@ var FormSpanString = /*#__PURE__*/function (_React$Component) {
1436
1793
  key: "render",
1437
1794
  value: function render() {
1438
1795
  // return <span>{this.props.value}</span>;
1439
- return /*#__PURE__*/React.createElement(Input, {
1796
+ return React.createElement(Input, {
1440
1797
  size: "small",
1441
1798
  disabled: true,
1442
1799
  value: this.props.value
@@ -1539,12 +1896,12 @@ function TableVirtual (props) {
1539
1896
  if (!table) return;
1540
1897
  table.style.top = "".concat(pointer * rowHeight, "px");
1541
1898
  }, [pointer, self, rowHeight]);
1542
- return /*#__PURE__*/React.createElement("span", {
1899
+ return React.createElement("span", {
1543
1900
  className: "kts-invoice-operate-goods-table-virtual",
1544
1901
  ref: function ref(e) {
1545
1902
  setSelf(e);
1546
1903
  }
1547
- }, /*#__PURE__*/React.createElement(Table, _objectSpread2(_objectSpread2({}, props), {}, {
1904
+ }, React.createElement(Table, _objectSpread2(_objectSpread2({}, props), {}, {
1548
1905
  dataSource: dataSource
1549
1906
  })));
1550
1907
  }
@@ -1616,50 +1973,50 @@ var Statistics = (function () {
1616
1973
  });
1617
1974
  return sum.done().toNumber();
1618
1975
  }, []);
1619
- return /*#__PURE__*/React.createElement("div", {
1976
+ return React.createElement("div", {
1620
1977
  className: "kts-invoice-operate-goods-list-statistics"
1621
- }, /*#__PURE__*/React.createElement("div", {
1978
+ }, React.createElement("div", {
1622
1979
  className: "kts-invoice-operate-goods-list-statistics-row"
1623
- }, /*#__PURE__*/React.createElement("div", {
1980
+ }, React.createElement("div", {
1624
1981
  style: {
1625
1982
  width: 45
1626
1983
  }
1627
- }), /*#__PURE__*/React.createElement("div", {
1984
+ }), React.createElement("div", {
1628
1985
  style: {
1629
1986
  flex: 1
1630
1987
  }
1631
- }, /*#__PURE__*/React.createElement("label", null, "\u5408\u8BA1")), /*#__PURE__*/React.createElement("div", {
1988
+ }, React.createElement("label", null, "\u5408\u8BA1")), React.createElement("div", {
1632
1989
  style: {
1633
1990
  width: 119 + 70
1634
1991
  }
1635
- }, /*#__PURE__*/React.createElement("label", null, parseFloat(isTaxIncluded ? lineAmountIncludeTax : lineAmountExcludeTax).toFixed(2))), /*#__PURE__*/React.createElement("div", {
1992
+ }, React.createElement("label", null, parseFloat(isTaxIncluded ? lineAmountIncludeTax : lineAmountExcludeTax).toFixed(2))), React.createElement("div", {
1636
1993
  style: {
1637
1994
  width: 119 + 50 + 1
1638
1995
  }
1639
- }, /*#__PURE__*/React.createElement("label", null, parseFloat(taxAmount).toFixed(2)))), /*#__PURE__*/React.createElement("div", {
1996
+ }, React.createElement("label", null, parseFloat(taxAmount).toFixed(2)))), React.createElement("div", {
1640
1997
  className: "kts-invoice-operate-goods-list-statistics-row"
1641
- }, /*#__PURE__*/React.createElement("div", {
1998
+ }, React.createElement("div", {
1642
1999
  style: {
1643
2000
  width: 45
1644
2001
  }
1645
- }), /*#__PURE__*/React.createElement("div", {
2002
+ }), React.createElement("div", {
1646
2003
  style: {
1647
2004
  flex: 4,
1648
2005
  border: 'none'
1649
2006
  }
1650
- }, /*#__PURE__*/React.createElement("label", null, "\u4EF7\u7A0E\u5408\u8BA1\uFF08\u5927\u5199\uFF09"), /*#__PURE__*/React.createElement("label", null, nzhcn.toMoney(lineAmountIncludeTax, {
2007
+ }, React.createElement("label", null, "\u4EF7\u7A0E\u5408\u8BA1\uFF08\u5927\u5199\uFF09"), React.createElement("label", null, nzhcn.toMoney(lineAmountIncludeTax, {
1651
2008
  outSymbol: false
1652
- }))), /*#__PURE__*/React.createElement("div", {
2009
+ }))), React.createElement("div", {
1653
2010
  style: {
1654
2011
  flex: 1,
1655
2012
  border: 'none'
1656
2013
  }
1657
- }, /*#__PURE__*/React.createElement("label", null, "\uFF08\u5C0F\u5199\uFF09")), /*#__PURE__*/React.createElement("div", {
2014
+ }, React.createElement("label", null, "\uFF08\u5C0F\u5199\uFF09")), React.createElement("div", {
1658
2015
  style: {
1659
2016
  flex: 3,
1660
2017
  border: 'none'
1661
2018
  }
1662
- }, /*#__PURE__*/React.createElement("label", null, parseFloat(lineAmountIncludeTax).toFixed(2)))));
2019
+ }, React.createElement("label", null, parseFloat(lineAmountIncludeTax).toFixed(2)))));
1663
2020
  });
1664
2021
 
1665
2022
  var AddRowButton = (function () {
@@ -1672,6 +2029,11 @@ var AddRowButton = (function () {
1672
2029
  var goodsNum = controller.useMemo(function (s) {
1673
2030
  return s.goodsListState.goodsList.length;
1674
2031
  }, []);
2032
+ /** 搜索条件 */
2033
+
2034
+ var searchValue = controller.useMemo(function (s) {
2035
+ return s.goodsListState.searchValue;
2036
+ }, []);
1675
2037
  /** 产品最大数 */
1676
2038
 
1677
2039
  var goodMax = controller.useMemo(function (s) {
@@ -1680,10 +2042,10 @@ var AddRowButton = (function () {
1680
2042
  /** 按钮是否禁用 */
1681
2043
 
1682
2044
  var disabled = React.useMemo(function () {
1683
- return typeof goodMax === 'number' ? goodsNum >= goodMax : false;
1684
- }, [goodMax, goodsNum]);
1685
- var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2() {
1686
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
2045
+ return typeof goodMax === 'number' ? goodsNum >= goodMax : !!searchValue;
2046
+ }, [goodMax, goodsNum, searchValue]);
2047
+ var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
2048
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
1687
2049
  while (1) {
1688
2050
  switch (_context2.prev = _context2.next) {
1689
2051
  case 0:
@@ -1697,8 +2059,8 @@ var AddRowButton = (function () {
1697
2059
  case 4:
1698
2060
  _context2.next = 6;
1699
2061
  return controller.pipeline( /*#__PURE__*/function () {
1700
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
1701
- return regeneratorRuntime.wrap(function _callee$(_context) {
2062
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
2063
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
1702
2064
  while (1) {
1703
2065
  switch (_context.prev = _context.next) {
1704
2066
  case 0:
@@ -1743,8 +2105,8 @@ var AddRowButton = (function () {
1743
2105
  }
1744
2106
  }, _callee2);
1745
2107
  })), [controller]);
1746
- if (model === 'prefab') return /*#__PURE__*/React.createElement(React.Fragment, null);
1747
- return /*#__PURE__*/React.createElement(Button, {
2108
+ if (model === 'prefab') return React.createElement(React.Fragment, null);
2109
+ return React.createElement(Button, {
1748
2110
  icon: "plus-circle",
1749
2111
  onClick: onClick,
1750
2112
  disabled: disabled
@@ -1765,8 +2127,8 @@ var TaxIncludedSwitch = (function () {
1765
2127
  }, []);
1766
2128
  var onChange = React.useCallback(function (e) {
1767
2129
  controller.pipeline( /*#__PURE__*/function () {
1768
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
1769
- return regeneratorRuntime.wrap(function _callee$(_context) {
2130
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
2131
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
1770
2132
  while (1) {
1771
2133
  switch (_context.prev = _context.next) {
1772
2134
  case 0:
@@ -1787,7 +2149,7 @@ var TaxIncludedSwitch = (function () {
1787
2149
  };
1788
2150
  }())();
1789
2151
  }, []);
1790
- return /*#__PURE__*/React.createElement("span", null, /*#__PURE__*/React.createElement("label", null, "\u542B\u7A0E:"), /*#__PURE__*/React.createElement(Switch, {
2152
+ return React.createElement("span", null, React.createElement("label", null, "\u542B\u7A0E:"), React.createElement(Switch, {
1791
2153
  disabled: isSwitchTax === false,
1792
2154
  checked: isTaxIncluded,
1793
2155
  checkedChildren: "\u5F00",
@@ -1797,6 +2159,108 @@ var TaxIncludedSwitch = (function () {
1797
2159
  }));
1798
2160
  });
1799
2161
 
2162
+ var _path$1;
2163
+
2164
+ function _extends$1() { _extends$1 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$1.apply(this, arguments); }
2165
+
2166
+ function SvgMagnifier(props) {
2167
+ return /*#__PURE__*/createElement("svg", _extends$1({
2168
+ className: "magnifier_svg__icon",
2169
+ viewBox: "0 0 1024 1024",
2170
+ xmlns: "http://www.w3.org/2000/svg",
2171
+ width: 200,
2172
+ height: 200
2173
+ }, props), _path$1 || (_path$1 = /*#__PURE__*/createElement("path", {
2174
+ d: "M985.781 918.594L820.773 765.526c27.373-32.973 49.655-69.577 66.437-109.258 22.933-54.219 34.56-111.795 34.56-171.13 0-59.333-11.627-116.91-34.56-171.13-22.143-52.354-53.838-99.365-94.2-139.729s-87.377-72.056-139.73-94.199c-54.219-22.933-111.795-34.561-171.13-34.561S365.24 57.148 311.022 80.08c-52.354 22.143-99.365 53.837-139.73 94.2s-72.057 87.375-94.2 139.73c-22.932 54.218-34.56 111.795-34.56 171.13 0 59.334 11.628 116.91 34.56 171.129 22.144 52.354 53.838 99.365 94.2 139.729s87.376 72.057 139.73 94.2c54.219 22.933 111.795 34.56 171.13 34.56s116.91-11.627 171.13-34.56c45.352-19.181 86.686-45.543 123.171-78.487l165.803 153.804a31.886 31.886 0 0021.756 8.54c8.593 0 17.163-3.442 23.467-10.238 12.019-12.956 11.26-33.205-1.698-45.223zm-503.63-57.836c-207.117 0-375.62-168.502-375.62-375.62 0-207.117 168.503-375.62 375.62-375.62s375.62 168.503 375.62 375.62c0 207.118-168.503 375.62-375.62 375.62z"
2175
+ })));
2176
+ }
2177
+
2178
+ var css_248z$4 = ".kts-invoice-operate-goods-list-able-list .kts-invoice-operate-goods-list-search {\n width: 330px;\n}\n.kts-invoice-operate-goods-list-able-list .kts-invoice-operate-goods-list-search input {\n border-radius: 999px;\n border-color: #b8b8b8;\n}\n";
2179
+ styleInject(css_248z$4);
2180
+
2181
+ function Search() {
2182
+ var controller = default_1.useInvoiceController();
2183
+
2184
+ var _React$useState = React.useState(''),
2185
+ _React$useState2 = _slicedToArray(_React$useState, 2),
2186
+ value = _React$useState2[0],
2187
+ setValue = _React$useState2[1];
2188
+
2189
+ var readOnly = controller.useMemo(function (s) {
2190
+ return !!s.goodsListState.editGood;
2191
+ }, []);
2192
+ var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
2193
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
2194
+ while (1) {
2195
+ switch (_context.prev = _context.next) {
2196
+ case 0:
2197
+ _context.next = 2;
2198
+ return controller.saveEditGood();
2199
+
2200
+ case 2:
2201
+ _context.next = 4;
2202
+ return controller.wait();
2203
+
2204
+ case 4:
2205
+ if (!controller.state.goodsListState.editGood) {
2206
+ _context.next = 7;
2207
+ break;
2208
+ }
2209
+
2210
+ message.error({
2211
+ content: '你正在编辑一个货物',
2212
+ key: '你正在编辑一个货物'
2213
+ });
2214
+ return _context.abrupt("return");
2215
+
2216
+ case 7:
2217
+ case "end":
2218
+ return _context.stop();
2219
+ }
2220
+ }
2221
+ }, _callee);
2222
+ })), []);
2223
+ React.useEffect(function () {
2224
+ controller.run( /*#__PURE__*/function () {
2225
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(s) {
2226
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
2227
+ while (1) {
2228
+ switch (_context2.prev = _context2.next) {
2229
+ case 0:
2230
+ s.goodsListState.searchValue = value;
2231
+
2232
+ case 1:
2233
+ case "end":
2234
+ return _context2.stop();
2235
+ }
2236
+ }
2237
+ }, _callee2);
2238
+ }));
2239
+
2240
+ return function (_x) {
2241
+ return _ref2.apply(this, arguments);
2242
+ };
2243
+ }());
2244
+ }, [value, controller]);
2245
+ return React.createElement(Input, {
2246
+ size: "small",
2247
+ readOnly: readOnly,
2248
+ value: value,
2249
+ className: "kts-invoice-operate-goods-list-search",
2250
+ placeholder: "\u8BF7\u60A8\u8F93\u5165\u8D27\u7269\u540D\u79F0\u3001\u89C4\u683C\u578B\u53F7\u3001\u91D1\u989D(\u542B\u7A0E)\u641C\u7D22",
2251
+ prefix: React.createElement(Icon, {
2252
+ component: SvgMagnifier,
2253
+ style: {
2254
+ color: "#b8b8b8"
2255
+ }
2256
+ }),
2257
+ onChange: function onChange(e) {
2258
+ setValue(e.target.value);
2259
+ },
2260
+ onClick: onClick
2261
+ });
2262
+ }
2263
+
1800
2264
  function TableRow(props) {
1801
2265
  var controller = default_1.useInvoiceController();
1802
2266
  var goodsMap = controller.useMemo(function (s) {
@@ -1807,7 +2271,7 @@ function TableRow(props) {
1807
2271
  if (!i) return false;
1808
2272
  return i.lineAttribute !== LineAttributeType$1.正常;
1809
2273
  }, [props['data-row-key'], goodsMap]);
1810
- return /*#__PURE__*/React.createElement("tr", _objectSpread2(_objectSpread2({}, props), {}, {
2274
+ return React.createElement("tr", _objectSpread2(_objectSpread2({}, props), {}, {
1811
2275
  className: "".concat(isR ? 'kts-invoice-operate-goods-discount ' : '').concat(props.className)
1812
2276
  }));
1813
2277
  }
@@ -1847,8 +2311,8 @@ var evaluate = (function (expr) {
1847
2311
  return parseFloat(math.evaluate(expr).toFixed(fractionDigits));
1848
2312
  });
1849
2313
 
1850
- var css_248z$4 = ".kts-invoice-operate-goods-list-add-discount-row .ktsAnt3x-drawer-wrapper-body {\n display: flex;\n flex-direction: column;\n}\n.kts-invoice-operate-goods-list-add-discount-row .ktsAnt3x-drawer-wrapper-body .ktsAnt3x-drawer-body {\n flex: 1;\n display: flex;\n flex-direction: column;\n}\n.kts-invoice-operate-goods-list-add-discount-row .ktsAnt3x-drawer-wrapper-body .ktsAnt3x-drawer-body .add-discount-row-body {\n flex: 1;\n overflow: auto;\n}\n.kts-invoice-operate-goods-list-add-discount-row .ktsAnt3x-drawer-wrapper-body .ktsAnt3x-drawer-body .add-discount-row-footer {\n flex: none;\n}\n";
1851
- styleInject(css_248z$4);
2314
+ var css_248z$5 = ".kts-invoice-operate-goods-list-add-discount-row .ktsAnt3x-drawer-wrapper-body {\n display: flex;\n flex-direction: column;\n}\n.kts-invoice-operate-goods-list-add-discount-row .ktsAnt3x-drawer-wrapper-body .ktsAnt3x-drawer-body {\n flex: 1;\n display: flex;\n flex-direction: column;\n}\n.kts-invoice-operate-goods-list-add-discount-row .ktsAnt3x-drawer-wrapper-body .ktsAnt3x-drawer-body .add-discount-row-body {\n flex: 1;\n overflow: auto;\n}\n.kts-invoice-operate-goods-list-add-discount-row .ktsAnt3x-drawer-wrapper-body .ktsAnt3x-drawer-body .add-discount-row-footer {\n flex: none;\n}\n";
2315
+ styleInject(css_248z$5);
1852
2316
 
1853
2317
  var Text = Typography.Text;
1854
2318
 
@@ -1891,8 +2355,8 @@ var AddDiscountRowButton = decorator(Form.create())(function (props) {
1891
2355
 
1892
2356
  var onClose = React.useCallback(function () {
1893
2357
  controller.pipeline( /*#__PURE__*/function () {
1894
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
1895
- return regeneratorRuntime.wrap(function _callee$(_context) {
2358
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
2359
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
1896
2360
  while (1) {
1897
2361
  switch (_context.prev = _context.next) {
1898
2362
  case 0:
@@ -1913,8 +2377,8 @@ var AddDiscountRowButton = decorator(Form.create())(function (props) {
1913
2377
  }, []);
1914
2378
  /** 点击了 添加折扣行 按钮 */
1915
2379
 
1916
- var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee3() {
1917
- return regeneratorRuntime.wrap(function _callee3$(_context3) {
2380
+ var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
2381
+ return _regeneratorRuntime().wrap(function _callee3$(_context3) {
1918
2382
  while (1) {
1919
2383
  switch (_context3.prev = _context3.next) {
1920
2384
  case 0:
@@ -1928,9 +2392,9 @@ var AddDiscountRowButton = decorator(Form.create())(function (props) {
1928
2392
  case 4:
1929
2393
  _context3.next = 6;
1930
2394
  return controller.pipeline( /*#__PURE__*/function () {
1931
- var _ref3 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(s) {
2395
+ var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(s) {
1932
2396
  var isOk;
1933
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
2397
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
1934
2398
  while (1) {
1935
2399
  switch (_context2.prev = _context2.next) {
1936
2400
  case 0:
@@ -2004,12 +2468,12 @@ var AddDiscountRowButton = decorator(Form.create())(function (props) {
2004
2468
  }
2005
2469
  }, _callee3);
2006
2470
  })), [controller]);
2007
- if (model === 'prefab') return /*#__PURE__*/React.createElement(React.Fragment, null);
2008
- return /*#__PURE__*/React.createElement(React.Fragment, null, isAddDiscount !== false && /*#__PURE__*/React.createElement(Button, {
2471
+ if (model === 'prefab') return React.createElement(React.Fragment, null);
2472
+ return React.createElement(React.Fragment, null, isAddDiscount !== false && React.createElement(Button, {
2009
2473
  icon: "plus-circle",
2010
2474
  disabled: disabled,
2011
2475
  onClick: onClick
2012
- }, "\u6DFB\u52A0\u6298\u6263\u884C"), /*#__PURE__*/React.createElement(Drawer, {
2476
+ }, "\u6DFB\u52A0\u6298\u6263\u884C"), React.createElement(Drawer, {
2013
2477
  className: "kts-invoice-operate-goods-list-add-discount-row",
2014
2478
  width: 540,
2015
2479
  title: "\u6DFB\u52A0\u6298\u6263\u884C",
@@ -2017,7 +2481,7 @@ var AddDiscountRowButton = decorator(Form.create())(function (props) {
2017
2481
  destroyOnClose: true,
2018
2482
  onClose: onClose,
2019
2483
  visible: visible
2020
- }, /*#__PURE__*/React.createElement(DrawerBody, null)));
2484
+ }, React.createElement(DrawerBody, null)));
2021
2485
  });
2022
2486
  var DrawerBody = decorator(Form.create())(function (props) {
2023
2487
  var form = props.form;
@@ -2051,8 +2515,8 @@ var DrawerBody = decorator(Form.create())(function (props) {
2051
2515
 
2052
2516
  var onClose = React.useCallback(function () {
2053
2517
  controller.pipeline( /*#__PURE__*/function () {
2054
- var _ref4 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee4(s) {
2055
- return regeneratorRuntime.wrap(function _callee4$(_context4) {
2518
+ var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(s) {
2519
+ return _regeneratorRuntime().wrap(function _callee4$(_context4) {
2056
2520
  while (1) {
2057
2521
  switch (_context4.prev = _context4.next) {
2058
2522
  case 0:
@@ -2080,8 +2544,8 @@ var DrawerBody = decorator(Form.create())(function (props) {
2080
2544
  var discount = parseFloat(parseFloat(values.discount).toFixed(4));
2081
2545
  var indexList = discountGoodIndex;
2082
2546
  controller.pipeline( /*#__PURE__*/function () {
2083
- var _ref5 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee5(s) {
2084
- return regeneratorRuntime.wrap(function _callee5$(_context5) {
2547
+ var _ref5 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(s) {
2548
+ return _regeneratorRuntime().wrap(function _callee5$(_context5) {
2085
2549
  while (1) {
2086
2550
  switch (_context5.prev = _context5.next) {
2087
2551
  case 0:
@@ -2129,13 +2593,13 @@ var DrawerBody = decorator(Form.create())(function (props) {
2129
2593
  });
2130
2594
  });
2131
2595
  }, 300), [form, lineAmountSum]);
2132
- return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
2596
+ return React.createElement(React.Fragment, null, React.createElement("div", {
2133
2597
  className: "add-discount-row-body"
2134
- }, /*#__PURE__*/React.createElement("p", null, "\u5F53\u524D\u9009\u62E9", /*#__PURE__*/React.createElement(Text, {
2598
+ }, React.createElement("p", null, "\u5F53\u524D\u9009\u62E9", React.createElement(Text, {
2135
2599
  type: "danger"
2136
- }, discountGoodIndex.length), "\u884C\u88AB\u6298\u6263\u5546\u54C1\u884C\uFF0C\u91D1\u989D\u5408\u8BA1\xA5", /*#__PURE__*/React.createElement(Text, {
2600
+ }, discountGoodIndex.length), "\u884C\u88AB\u6298\u6263\u5546\u54C1\u884C\uFF0C\u91D1\u989D\u5408\u8BA1\xA5", React.createElement(Text, {
2137
2601
  type: "danger"
2138
- }, lineAmountSum.toFixed(2))), /*#__PURE__*/React.createElement(Form.Item, {
2602
+ }, lineAmountSum.toFixed(2))), React.createElement(Form.Item, {
2139
2603
  label: "\u6298\u6263\u7387\uFF1A"
2140
2604
  }, getFieldDecorator('discount', {
2141
2605
  rules: [{
@@ -2165,11 +2629,11 @@ var DrawerBody = decorator(Form.create())(function (props) {
2165
2629
  callback();
2166
2630
  }
2167
2631
  }]
2168
- })( /*#__PURE__*/React.createElement(Input, {
2632
+ })(React.createElement(Input, {
2169
2633
  placeholder: "\u8BF7\u8F93\u5165\u5927\u4E8E0\u5C0F\u4E8E100\u7684\u6570\u5B57",
2170
2634
  suffix: "%",
2171
2635
  onChange: onChangeDiscount
2172
- }))), /*#__PURE__*/React.createElement(Form.Item, {
2636
+ }))), React.createElement(Form.Item, {
2173
2637
  label: "\u6298\u6263\u91D1\u989D\uFF1A"
2174
2638
  }, getFieldDecorator('discolineAmountunt', {
2175
2639
  rules: [{
@@ -2199,19 +2663,19 @@ var DrawerBody = decorator(Form.create())(function (props) {
2199
2663
  callback();
2200
2664
  }
2201
2665
  }]
2202
- })( /*#__PURE__*/React.createElement(Input, {
2666
+ })(React.createElement(Input, {
2203
2667
  placeholder: "\u8BF7\u8F93\u5165\u5927\u4E8E0\u5C0F\u4E8E\u91D1\u989D\u5408\u8BA1\u7684\u6570\u5B57",
2204
2668
  suffix: "\xA5",
2205
2669
  onChange: onChangeDiscolineAmountunt
2206
- })))), /*#__PURE__*/React.createElement("div", {
2670
+ })))), React.createElement("div", {
2207
2671
  className: "add-discount-row-footer"
2208
- }, /*#__PURE__*/React.createElement(Button, {
2672
+ }, React.createElement(Button, {
2209
2673
  block: true,
2210
2674
  style: {
2211
2675
  marginBottom: 12
2212
2676
  },
2213
2677
  onClick: onClose
2214
- }, "\u53D6\u6D88"), /*#__PURE__*/React.createElement(Button, {
2678
+ }, "\u53D6\u6D88"), React.createElement(Button, {
2215
2679
  type: "primary",
2216
2680
  block: true,
2217
2681
  onClick: onClickSave
@@ -2248,8 +2712,8 @@ var EndowCodeButton = (function () {
2248
2712
  var disabled = controller.useMemo(function (s) {
2249
2713
  if (s.goodsListState.selectedGoodIndex.length <= 0) return true;
2250
2714
  }, []);
2251
- var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2() {
2252
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
2715
+ var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
2716
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
2253
2717
  while (1) {
2254
2718
  switch (_context2.prev = _context2.next) {
2255
2719
  case 0:
@@ -2263,8 +2727,8 @@ var EndowCodeButton = (function () {
2263
2727
  case 4:
2264
2728
  _context2.next = 6;
2265
2729
  return controller.pipeline( /*#__PURE__*/function () {
2266
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
2267
- return regeneratorRuntime.wrap(function _callee$(_context) {
2730
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
2731
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
2268
2732
  while (1) {
2269
2733
  switch (_context.prev = _context.next) {
2270
2734
  case 0:
@@ -2319,7 +2783,7 @@ var EndowCodeButton = (function () {
2319
2783
  }
2320
2784
  }, _callee2);
2321
2785
  })), [controller]);
2322
- return /*#__PURE__*/React.createElement(Button, {
2786
+ return React.createElement(Button, {
2323
2787
  icon: "file-add",
2324
2788
  disabled: disabled,
2325
2789
  onClick: onClick
@@ -2343,9 +2807,9 @@ var DelRowButton = (function () {
2343
2807
  }, []);
2344
2808
  var onClick = React.useCallback(function () {
2345
2809
  controller.pipeline( /*#__PURE__*/function () {
2346
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
2810
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
2347
2811
  var goodsList;
2348
- return regeneratorRuntime.wrap(function _callee$(_context) {
2812
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
2349
2813
  while (1) {
2350
2814
  switch (_context.prev = _context.next) {
2351
2815
  case 0:
@@ -2377,24 +2841,24 @@ var DelRowButton = (function () {
2377
2841
  };
2378
2842
  }())();
2379
2843
  }, [controller]);
2380
- if (model === 'prefab') return /*#__PURE__*/React.createElement(React.Fragment, null);
2381
- return /*#__PURE__*/React.createElement(Button, {
2844
+ if (model === 'prefab') return React.createElement(React.Fragment, null);
2845
+ return React.createElement(Button, {
2382
2846
  icon: "delete",
2383
2847
  onClick: onClick,
2384
2848
  disabled: disabled
2385
2849
  }, "\u5220\u9664\u884C");
2386
2850
  });
2387
2851
 
2388
- var _defs$1, _path$1;
2852
+ var _defs$1, _path$2;
2389
2853
 
2390
- function _extends$1() { _extends$1 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$1.apply(this, arguments); }
2854
+ function _extends$2() { _extends$2 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$2.apply(this, arguments); }
2391
2855
 
2392
2856
  function SvgSpot(props) {
2393
- return /*#__PURE__*/createElement("svg", _extends$1({
2857
+ return /*#__PURE__*/createElement("svg", _extends$2({
2394
2858
  className: "spot_svg__icon",
2395
2859
  viewBox: "0 0 1024 1024",
2396
2860
  xmlns: "http://www.w3.org/2000/svg"
2397
- }, props), _defs$1 || (_defs$1 = /*#__PURE__*/createElement("defs", null, /*#__PURE__*/createElement("style", null))), _path$1 || (_path$1 = /*#__PURE__*/createElement("path", {
2861
+ }, props), _defs$1 || (_defs$1 = /*#__PURE__*/createElement("defs", null, /*#__PURE__*/createElement("style", null))), _path$2 || (_path$2 = /*#__PURE__*/createElement("path", {
2398
2862
  d: "M416 512a1.5 1.5 0 10192 0 1.5 1.5 0 10-192 0zM416 96.64a1.5 1.5 0 10192 0 1.5 1.5 0 10-192 0zM416 927.36a1.5 1.5 0 10192 0 1.5 1.5 0 10-192 0z"
2399
2863
  })));
2400
2864
  }
@@ -2411,10 +2875,10 @@ var useDelItem = (function (goods) {
2411
2875
  }
2412
2876
 
2413
2877
  return React.useMemo(function () {
2414
- return /*#__PURE__*/React.createElement(Menu.Item, {
2878
+ return React.createElement(Menu.Item, {
2415
2879
  key: "delItem",
2416
2880
  onClick: onClick
2417
- }, /*#__PURE__*/React.createElement(Text$1, {
2881
+ }, React.createElement(Text$1, {
2418
2882
  strong: true,
2419
2883
  type: "danger"
2420
2884
  }, "\u5220\u9664"));
@@ -2426,8 +2890,8 @@ var useAddDiscount = (function (goods) {
2426
2890
  var controller = default_1.useInvoiceController();
2427
2891
  /** 点击了 添加折扣行 按钮 */
2428
2892
 
2429
- var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2() {
2430
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
2893
+ var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
2894
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
2431
2895
  while (1) {
2432
2896
  switch (_context2.prev = _context2.next) {
2433
2897
  case 0:
@@ -2441,9 +2905,9 @@ var useAddDiscount = (function (goods) {
2441
2905
  case 4:
2442
2906
  _context2.next = 6;
2443
2907
  return controller.pipeline( /*#__PURE__*/function () {
2444
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
2908
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
2445
2909
  var err, key;
2446
- return regeneratorRuntime.wrap(function _callee$(_context) {
2910
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
2447
2911
  while (1) {
2448
2912
  switch (_context.prev = _context.next) {
2449
2913
  case 0:
@@ -2453,7 +2917,7 @@ var useAddDiscount = (function (goods) {
2453
2917
  }
2454
2918
 
2455
2919
  err = s.goodsListState.form.getFieldsError();
2456
- _context.t0 = regeneratorRuntime.keys(err);
2920
+ _context.t0 = _regeneratorRuntime().keys(err);
2457
2921
 
2458
2922
  case 3:
2459
2923
  if ((_context.t1 = _context.t0()).done) {
@@ -2533,17 +2997,17 @@ var useAddDiscount = (function (goods) {
2533
2997
  return undefined;
2534
2998
  }
2535
2999
 
2536
- return /*#__PURE__*/React.createElement(Menu.Item, {
3000
+ return React.createElement(Menu.Item, {
2537
3001
  key: "addDiscount",
2538
3002
  onClick: onClick
2539
- }, /*#__PURE__*/React.createElement(Text$2, {
3003
+ }, React.createElement(Text$2, {
2540
3004
  strong: true
2541
3005
  }, "\u6DFB\u52A0\u6298\u6263\u884C"));
2542
3006
  }, [onClick, goods.lineAttribute]);
2543
3007
  });
2544
3008
 
2545
3009
  //! moment.js
2546
- //! version : 2.29.1
3010
+ //! version : 2.29.3
2547
3011
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
2548
3012
  //! license : MIT
2549
3013
  //! momentjs.com
@@ -2614,8 +3078,9 @@ function isDate(input) {
2614
3078
 
2615
3079
  function map(arr, fn) {
2616
3080
  var res = [],
2617
- i;
2618
- for (i = 0; i < arr.length; ++i) {
3081
+ i,
3082
+ arrLen = arr.length;
3083
+ for (i = 0; i < arrLen; ++i) {
2619
3084
  res.push(fn(arr[i], i));
2620
3085
  }
2621
3086
  return res;
@@ -2744,7 +3209,10 @@ var momentProperties = (hooks.momentProperties = []),
2744
3209
  updateInProgress = false;
2745
3210
 
2746
3211
  function copyConfig(to, from) {
2747
- var i, prop, val;
3212
+ var i,
3213
+ prop,
3214
+ val,
3215
+ momentPropertiesLen = momentProperties.length;
2748
3216
 
2749
3217
  if (!isUndefined(from._isAMomentObject)) {
2750
3218
  to._isAMomentObject = from._isAMomentObject;
@@ -2777,8 +3245,8 @@ function copyConfig(to, from) {
2777
3245
  to._locale = from._locale;
2778
3246
  }
2779
3247
 
2780
- if (momentProperties.length > 0) {
2781
- for (i = 0; i < momentProperties.length; i++) {
3248
+ if (momentPropertiesLen > 0) {
3249
+ for (i = 0; i < momentPropertiesLen; i++) {
2782
3250
  prop = momentProperties[i];
2783
3251
  val = from[prop];
2784
3252
  if (!isUndefined(val)) {
@@ -2833,8 +3301,9 @@ function deprecate(msg, fn) {
2833
3301
  var args = [],
2834
3302
  arg,
2835
3303
  i,
2836
- key;
2837
- for (i = 0; i < arguments.length; i++) {
3304
+ key,
3305
+ argLen = arguments.length;
3306
+ for (i = 0; i < argLen; i++) {
2838
3307
  arg = '';
2839
3308
  if (typeof arguments[i] === 'object') {
2840
3309
  arg += '\n[' + i + '] ';
@@ -2984,7 +3453,8 @@ function zeroFill(number, targetLength, forceSign) {
2984
3453
  );
2985
3454
  }
2986
3455
 
2987
- var formattingTokens = /(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,
3456
+ var formattingTokens =
3457
+ /(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,
2988
3458
  localFormattingTokens = /(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,
2989
3459
  formatFunctions = {},
2990
3460
  formatTokenFunctions = {};
@@ -3288,8 +3758,9 @@ function stringSet(units, value) {
3288
3758
  if (typeof units === 'object') {
3289
3759
  units = normalizeObjectUnits(units);
3290
3760
  var prioritized = getPrioritizedUnits(units),
3291
- i;
3292
- for (i = 0; i < prioritized.length; i++) {
3761
+ i,
3762
+ prioritizedLen = prioritized.length;
3763
+ for (i = 0; i < prioritizedLen; i++) {
3293
3764
  this[prioritized[i].unit](units[prioritized[i].unit]);
3294
3765
  }
3295
3766
  } else {
@@ -3319,7 +3790,8 @@ var match1 = /\d/, // 0 - 9
3319
3790
  matchTimestamp = /[+-]?\d+(\.\d{1,3})?/, // 123456789 123456789.123
3320
3791
  // any word (or two) characters or numbers including two/three word month in arabic.
3321
3792
  // includes scottish gaelic two word and hyphenated months
3322
- matchWord = /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,
3793
+ matchWord =
3794
+ /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,
3323
3795
  regexes;
3324
3796
 
3325
3797
  regexes = {};
@@ -3345,15 +3817,12 @@ function unescapeFormat(s) {
3345
3817
  return regexEscape(
3346
3818
  s
3347
3819
  .replace('\\', '')
3348
- .replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g, function (
3349
- matched,
3350
- p1,
3351
- p2,
3352
- p3,
3353
- p4
3354
- ) {
3355
- return p1 || p2 || p3 || p4;
3356
- })
3820
+ .replace(
3821
+ /\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,
3822
+ function (matched, p1, p2, p3, p4) {
3823
+ return p1 || p2 || p3 || p4;
3824
+ }
3825
+ )
3357
3826
  );
3358
3827
  }
3359
3828
 
@@ -3365,7 +3834,8 @@ var tokens = {};
3365
3834
 
3366
3835
  function addParseToken(token, callback) {
3367
3836
  var i,
3368
- func = callback;
3837
+ func = callback,
3838
+ tokenLen;
3369
3839
  if (typeof token === 'string') {
3370
3840
  token = [token];
3371
3841
  }
@@ -3374,7 +3844,8 @@ function addParseToken(token, callback) {
3374
3844
  array[callback] = toInt(input);
3375
3845
  };
3376
3846
  }
3377
- for (i = 0; i < token.length; i++) {
3847
+ tokenLen = token.length;
3848
+ for (i = 0; i < tokenLen; i++) {
3378
3849
  tokens[token[i]] = func;
3379
3850
  }
3380
3851
  }
@@ -3485,12 +3956,12 @@ addParseToken(['MMM', 'MMMM'], function (input, array, config, token) {
3485
3956
 
3486
3957
  // LOCALES
3487
3958
 
3488
- var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split(
3489
- '_'
3490
- ),
3491
- defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split(
3492
- '_'
3493
- ),
3959
+ var defaultLocaleMonths =
3960
+ 'January_February_March_April_May_June_July_August_September_October_November_December'.split(
3961
+ '_'
3962
+ ),
3963
+ defaultLocaleMonthsShort =
3964
+ 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),
3494
3965
  MONTHS_IN_FORMAT = /D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,
3495
3966
  defaultMonthsShortRegex = matchWord,
3496
3967
  defaultMonthsRegex = matchWord;
@@ -3932,14 +4403,12 @@ addRegexToken('ww', match1to2, match2);
3932
4403
  addRegexToken('W', match1to2);
3933
4404
  addRegexToken('WW', match1to2, match2);
3934
4405
 
3935
- addWeekParseToken(['w', 'ww', 'W', 'WW'], function (
3936
- input,
3937
- week,
3938
- config,
3939
- token
3940
- ) {
3941
- week[token.substr(0, 1)] = toInt(input);
3942
- });
4406
+ addWeekParseToken(
4407
+ ['w', 'ww', 'W', 'WW'],
4408
+ function (input, week, config, token) {
4409
+ week[token.substr(0, 1)] = toInt(input);
4410
+ }
4411
+ );
3943
4412
 
3944
4413
  // HELPERS
3945
4414
 
@@ -4064,9 +4533,8 @@ function shiftWeekdays(ws, n) {
4064
4533
  return ws.slice(n, 7).concat(ws.slice(0, n));
4065
4534
  }
4066
4535
 
4067
- var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split(
4068
- '_'
4069
- ),
4536
+ var defaultLocaleWeekdays =
4537
+ 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_'),
4070
4538
  defaultLocaleWeekdaysShort = 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),
4071
4539
  defaultLocaleWeekdaysMin = 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),
4072
4540
  defaultWeekdaysRegex = matchWord,
@@ -4614,6 +5082,11 @@ function chooseLocale(names) {
4614
5082
  return globalLocale;
4615
5083
  }
4616
5084
 
5085
+ function isLocaleNameSane(name) {
5086
+ // Prevent names that look like filesystem paths, i.e contain '/' or '\'
5087
+ return name.match('^[^/\\\\]*$') != null;
5088
+ }
5089
+
4617
5090
  function loadLocale(name) {
4618
5091
  var oldLocale = null,
4619
5092
  aliasedRequire;
@@ -4622,7 +5095,8 @@ function loadLocale(name) {
4622
5095
  locales[name] === undefined &&
4623
5096
  typeof module !== 'undefined' &&
4624
5097
  module &&
4625
- module.exports
5098
+ module.exports &&
5099
+ isLocaleNameSane(name)
4626
5100
  ) {
4627
5101
  try {
4628
5102
  oldLocale = globalLocale._abbr;
@@ -4839,8 +5313,10 @@ function checkOverflow(m) {
4839
5313
 
4840
5314
  // iso 8601 regex
4841
5315
  // 0000-00-00 0000-W00 or 0000-W00-0 + T + 00 or 00:00 or 00:00:00 or 00:00:00.000 + +00:00 or +0000 or +00)
4842
- var extendedIsoRegex = /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,
4843
- basicIsoRegex = /^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,
5316
+ var extendedIsoRegex =
5317
+ /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,
5318
+ basicIsoRegex =
5319
+ /^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,
4844
5320
  tzRegex = /Z|[+-]\d\d(?::?\d\d)?/,
4845
5321
  isoDates = [
4846
5322
  ['YYYYYY-MM-DD', /[+-]\d{6}-\d\d-\d\d/],
@@ -4871,7 +5347,8 @@ var extendedIsoRegex = /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\
4871
5347
  ],
4872
5348
  aspNetJsonRegex = /^\/?Date\((-?\d+)/i,
4873
5349
  // RFC 2822 regex: For details see https://tools.ietf.org/html/rfc2822#section-3.3
4874
- rfc2822 = /^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,
5350
+ rfc2822 =
5351
+ /^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,
4875
5352
  obsOffsets = {
4876
5353
  UT: 0,
4877
5354
  GMT: 0,
@@ -4894,12 +5371,13 @@ function configFromISO(config) {
4894
5371
  allowTime,
4895
5372
  dateFormat,
4896
5373
  timeFormat,
4897
- tzFormat;
5374
+ tzFormat,
5375
+ isoDatesLen = isoDates.length,
5376
+ isoTimesLen = isoTimes.length;
4898
5377
 
4899
5378
  if (match) {
4900
5379
  getParsingFlags(config).iso = true;
4901
-
4902
- for (i = 0, l = isoDates.length; i < l; i++) {
5380
+ for (i = 0, l = isoDatesLen; i < l; i++) {
4903
5381
  if (isoDates[i][1].exec(match[1])) {
4904
5382
  dateFormat = isoDates[i][0];
4905
5383
  allowTime = isoDates[i][2] !== false;
@@ -4911,7 +5389,7 @@ function configFromISO(config) {
4911
5389
  return;
4912
5390
  }
4913
5391
  if (match[3]) {
4914
- for (i = 0, l = isoTimes.length; i < l; i++) {
5392
+ for (i = 0, l = isoTimesLen; i < l; i++) {
4915
5393
  if (isoTimes[i][1].exec(match[3])) {
4916
5394
  // match[2] should be 'T' or space
4917
5395
  timeFormat = (match[2] || ' ') + isoTimes[i][0];
@@ -5291,12 +5769,13 @@ function configFromStringAndFormat(config) {
5291
5769
  skipped,
5292
5770
  stringLength = string.length,
5293
5771
  totalParsedInputLength = 0,
5294
- era;
5772
+ era,
5773
+ tokenLen;
5295
5774
 
5296
5775
  tokens =
5297
5776
  expandFormat(config._f, config._locale).match(formattingTokens) || [];
5298
-
5299
- for (i = 0; i < tokens.length; i++) {
5777
+ tokenLen = tokens.length;
5778
+ for (i = 0; i < tokenLen; i++) {
5300
5779
  token = tokens[i];
5301
5780
  parsedInput = (string.match(getParseRegexForToken(token, config)) ||
5302
5781
  [])[0];
@@ -5391,15 +5870,16 @@ function configFromStringAndArray(config) {
5391
5870
  i,
5392
5871
  currentScore,
5393
5872
  validFormatFound,
5394
- bestFormatIsValid = false;
5873
+ bestFormatIsValid = false,
5874
+ configfLen = config._f.length;
5395
5875
 
5396
- if (config._f.length === 0) {
5876
+ if (configfLen === 0) {
5397
5877
  getParsingFlags(config).invalidFormat = true;
5398
5878
  config._d = new Date(NaN);
5399
5879
  return;
5400
5880
  }
5401
5881
 
5402
- for (i = 0; i < config._f.length; i++) {
5882
+ for (i = 0; i < configfLen; i++) {
5403
5883
  currentScore = 0;
5404
5884
  validFormatFound = false;
5405
5885
  tempConfig = copyConfig({}, config);
@@ -5640,7 +6120,8 @@ var ordering = [
5640
6120
  function isDurationValid(m) {
5641
6121
  var key,
5642
6122
  unitHasDecimal = false,
5643
- i;
6123
+ i,
6124
+ orderLen = ordering.length;
5644
6125
  for (key in m) {
5645
6126
  if (
5646
6127
  hasOwnProp(m, key) &&
@@ -5653,7 +6134,7 @@ function isDurationValid(m) {
5653
6134
  }
5654
6135
  }
5655
6136
 
5656
- for (i = 0; i < ordering.length; ++i) {
6137
+ for (i = 0; i < orderLen; ++i) {
5657
6138
  if (m[ordering[i]]) {
5658
6139
  if (unitHasDecimal) {
5659
6140
  return false; // only allow non-integers for smallest unit
@@ -5978,7 +6459,8 @@ var aspNetRegex = /^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,
5978
6459
  // from http://docs.closure-library.googlecode.com/git/closure_goog_date_date.js.source.html
5979
6460
  // somewhat more in line with 4.4.3.2 2004 spec, but allows decimal anywhere
5980
6461
  // and further modified to allow for strings containing both week and day
5981
- isoRegex = /^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;
6462
+ isoRegex =
6463
+ /^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;
5982
6464
 
5983
6465
  function createDuration(input, key) {
5984
6466
  var duration = input,
@@ -6199,9 +6681,10 @@ function isMomentInputObject(input) {
6199
6681
  'ms',
6200
6682
  ],
6201
6683
  i,
6202
- property;
6684
+ property,
6685
+ propertyLen = properties.length;
6203
6686
 
6204
- for (i = 0; i < properties.length; i += 1) {
6687
+ for (i = 0; i < propertyLen; i += 1) {
6205
6688
  property = properties[i];
6206
6689
  propertyTest = propertyTest || hasOwnProp(input, property);
6207
6690
  }
@@ -6824,19 +7307,17 @@ addRegexToken('NNN', matchEraAbbr);
6824
7307
  addRegexToken('NNNN', matchEraName);
6825
7308
  addRegexToken('NNNNN', matchEraNarrow);
6826
7309
 
6827
- addParseToken(['N', 'NN', 'NNN', 'NNNN', 'NNNNN'], function (
6828
- input,
6829
- array,
6830
- config,
6831
- token
6832
- ) {
6833
- var era = config._locale.erasParse(input, token, config._strict);
6834
- if (era) {
6835
- getParsingFlags(config).era = era;
6836
- } else {
6837
- getParsingFlags(config).invalidEra = input;
7310
+ addParseToken(
7311
+ ['N', 'NN', 'NNN', 'NNNN', 'NNNNN'],
7312
+ function (input, array, config, token) {
7313
+ var era = config._locale.erasParse(input, token, config._strict);
7314
+ if (era) {
7315
+ getParsingFlags(config).era = era;
7316
+ } else {
7317
+ getParsingFlags(config).invalidEra = input;
7318
+ }
6838
7319
  }
6839
- });
7320
+ );
6840
7321
 
6841
7322
  addRegexToken('y', matchUnsigned);
6842
7323
  addRegexToken('yy', matchUnsigned);
@@ -7128,14 +7609,12 @@ addRegexToken('gggg', match1to4, match4);
7128
7609
  addRegexToken('GGGGG', match1to6, match6);
7129
7610
  addRegexToken('ggggg', match1to6, match6);
7130
7611
 
7131
- addWeekParseToken(['gggg', 'ggggg', 'GGGG', 'GGGGG'], function (
7132
- input,
7133
- week,
7134
- config,
7135
- token
7136
- ) {
7137
- week[token.substr(0, 2)] = toInt(input);
7138
- });
7612
+ addWeekParseToken(
7613
+ ['gggg', 'ggggg', 'GGGG', 'GGGGG'],
7614
+ function (input, week, config, token) {
7615
+ week[token.substr(0, 2)] = toInt(input);
7616
+ }
7617
+ );
7139
7618
 
7140
7619
  addWeekParseToken(['gg', 'GG'], function (input, week, config, token) {
7141
7620
  week[token] = hooks.parseTwoDigitYear(input);
@@ -8158,7 +8637,7 @@ addParseToken('x', function (input, array, config) {
8158
8637
 
8159
8638
  //! moment.js
8160
8639
 
8161
- hooks.version = '2.29.1';
8640
+ hooks.version = '2.29.3';
8162
8641
 
8163
8642
  setHookCallback(createLocal);
8164
8643
 
@@ -8247,10 +8726,10 @@ var promptErr = function promptErr(err) {
8247
8726
 
8248
8727
  var onChangeQuantity = lazyFn$1(function (controller, form, record) {
8249
8728
  form.validateFields( /*#__PURE__*/function () {
8250
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(err, values) {
8729
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(err, values) {
8251
8730
  var quantity, priceIncludeTax, lineAmountIncludeTax, _lineAmountIncludeTax, _priceIncludeTax, priceExcludeTax, lineAmountExcludeTax, _lineAmountExcludeTax, _priceExcludeTax;
8252
8731
 
8253
- return regeneratorRuntime.wrap(function _callee$(_context) {
8732
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
8254
8733
  while (1) {
8255
8734
  switch (_context.prev = _context.next) {
8256
8735
  case 0:
@@ -8396,10 +8875,10 @@ var onChangeQuantity = lazyFn$1(function (controller, form, record) {
8396
8875
 
8397
8876
  var onChangePriceIncludeTax = lazyFn$1(function (controller, form, record) {
8398
8877
  form.validateFields( /*#__PURE__*/function () {
8399
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(err, values) {
8878
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(err, values) {
8400
8879
  var priceIncludeTax, quantity, lineAmountIncludeTax, _lineAmountIncludeTax2, _quantity;
8401
8880
 
8402
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
8881
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
8403
8882
  while (1) {
8404
8883
  switch (_context2.prev = _context2.next) {
8405
8884
  case 0:
@@ -8495,10 +8974,10 @@ var onChangePriceIncludeTax = lazyFn$1(function (controller, form, record) {
8495
8974
 
8496
8975
  var onChangePriceExcludeTax = lazyFn$1(function (controller, form, record) {
8497
8976
  form.validateFields( /*#__PURE__*/function () {
8498
- var _ref3 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee3(err, values) {
8977
+ var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(err, values) {
8499
8978
  var priceExcludeTax, quantity, lineAmountExcludeTax, _lineAmountExcludeTax2, _quantity2;
8500
8979
 
8501
- return regeneratorRuntime.wrap(function _callee3$(_context3) {
8980
+ return _regeneratorRuntime().wrap(function _callee3$(_context3) {
8502
8981
  while (1) {
8503
8982
  switch (_context3.prev = _context3.next) {
8504
8983
  case 0:
@@ -8594,10 +9073,10 @@ var onChangePriceExcludeTax = lazyFn$1(function (controller, form, record) {
8594
9073
 
8595
9074
  var onChangeLineAmountIncludeTax = lazyFn$1(function (controller, form, record) {
8596
9075
  form.validateFields( /*#__PURE__*/function () {
8597
- var _ref4 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee4(err, values) {
9076
+ var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(err, values) {
8598
9077
  var lineAmountIncludeTax, quantity, priceIncludeTax, _priceIncludeTax2, _quantity3;
8599
9078
 
8600
- return regeneratorRuntime.wrap(function _callee4$(_context4) {
9079
+ return _regeneratorRuntime().wrap(function _callee4$(_context4) {
8601
9080
  while (1) {
8602
9081
  switch (_context4.prev = _context4.next) {
8603
9082
  case 0:
@@ -8686,10 +9165,10 @@ var onChangeLineAmountIncludeTax = lazyFn$1(function (controller, form, record)
8686
9165
 
8687
9166
  var onChangeLineAmountExcludeTax = lazyFn$1(function (controller, form, record) {
8688
9167
  form.validateFields( /*#__PURE__*/function () {
8689
- var _ref5 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee5(err, values) {
9168
+ var _ref5 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(err, values) {
8690
9169
  var lineAmountExcludeTax, quantity, priceExcludeTax, _priceExcludeTax2, _quantity4;
8691
9170
 
8692
- return regeneratorRuntime.wrap(function _callee5$(_context5) {
9171
+ return _regeneratorRuntime().wrap(function _callee5$(_context5) {
8693
9172
  while (1) {
8694
9173
  switch (_context5.prev = _context5.next) {
8695
9174
  case 0:
@@ -8778,9 +9257,9 @@ var onChangeLineAmountExcludeTax = lazyFn$1(function (controller, form, record)
8778
9257
 
8779
9258
  var onChangeTaxRate = lazyFn$1(function (controller, form, record) {
8780
9259
  form.validateFields( /*#__PURE__*/function () {
8781
- var _ref6 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee6(err, values) {
9260
+ var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(err, values) {
8782
9261
  var taxRate;
8783
- return regeneratorRuntime.wrap(function _callee6$(_context6) {
9262
+ return _regeneratorRuntime().wrap(function _callee6$(_context6) {
8784
9263
  while (1) {
8785
9264
  switch (_context6.prev = _context6.next) {
8786
9265
  case 0:
@@ -8869,9 +9348,9 @@ function dutyFree(controller, taxRate, form, record) {
8869
9348
 
8870
9349
  var updateUnitPriceExcludingTax = function updateUnitPriceExcludingTax(controller, form, record) {
8871
9350
  form.validateFields( /*#__PURE__*/function () {
8872
- var _ref7 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee7(err, values) {
9351
+ var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee7(err, values) {
8873
9352
  var taxAmount, lineAmountExcludeTax, priceExcludeTax, deduction;
8874
- return regeneratorRuntime.wrap(function _callee7$(_context7) {
9353
+ return _regeneratorRuntime().wrap(function _callee7$(_context7) {
8875
9354
  while (1) {
8876
9355
  switch (_context7.prev = _context7.next) {
8877
9356
  case 0:
@@ -8935,9 +9414,9 @@ var updateUnitPriceExcludingTax = function updateUnitPriceExcludingTax(controlle
8935
9414
 
8936
9415
  var updateUnitPriceTax = function updateUnitPriceTax(controller, form, record) {
8937
9416
  form.validateFields( /*#__PURE__*/function () {
8938
- var _ref8 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee8(err, values) {
9417
+ var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee8(err, values) {
8939
9418
  var lineAmountExcludeTax, lineAmountIncludeTax, taxAmount, priceExcludeTax, priceIncludeTax;
8940
- return regeneratorRuntime.wrap(function _callee8$(_context8) {
9419
+ return _regeneratorRuntime().wrap(function _callee8$(_context8) {
8941
9420
  while (1) {
8942
9421
  switch (_context8.prev = _context8.next) {
8943
9422
  case 0:
@@ -9010,9 +9489,9 @@ var updateUnitPriceTax = function updateUnitPriceTax(controller, form, record) {
9010
9489
 
9011
9490
  var onSaveEditGood = lazyFn$1(function (controller, form, record, id) {
9012
9491
  form.validateFields( /*#__PURE__*/function () {
9013
- var _ref9 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee9(err, values) {
9492
+ var _ref9 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee9(err, values) {
9014
9493
  var v;
9015
- return regeneratorRuntime.wrap(function _callee9$(_context9) {
9494
+ return _regeneratorRuntime().wrap(function _callee9$(_context9) {
9016
9495
  while (1) {
9017
9496
  switch (_context9.prev = _context9.next) {
9018
9497
  case 0:
@@ -9047,8 +9526,8 @@ var onSaveEditGood = lazyFn$1(function (controller, form, record, id) {
9047
9526
  /** 单调赋码 */
9048
9527
 
9049
9528
  var endowCode = /*#__PURE__*/function () {
9050
- var _ref10 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee11(controller, goods) {
9051
- return regeneratorRuntime.wrap(function _callee11$(_context11) {
9529
+ var _ref10 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee11(controller, goods) {
9530
+ return _regeneratorRuntime().wrap(function _callee11$(_context11) {
9052
9531
  while (1) {
9053
9532
  switch (_context11.prev = _context11.next) {
9054
9533
  case 0:
@@ -9062,9 +9541,9 @@ var endowCode = /*#__PURE__*/function () {
9062
9541
  case 4:
9063
9542
  _context11.next = 6;
9064
9543
  return controller.pipeline( /*#__PURE__*/function () {
9065
- var _ref11 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee10(s) {
9544
+ var _ref11 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee10(s) {
9066
9545
  var err, key, g, i;
9067
- return regeneratorRuntime.wrap(function _callee10$(_context10) {
9546
+ return _regeneratorRuntime().wrap(function _callee10$(_context10) {
9068
9547
  while (1) {
9069
9548
  switch (_context10.prev = _context10.next) {
9070
9549
  case 0:
@@ -9074,7 +9553,7 @@ var endowCode = /*#__PURE__*/function () {
9074
9553
  }
9075
9554
 
9076
9555
  err = s.goodsListState.form.getFieldsError();
9077
- _context10.t0 = regeneratorRuntime.keys(err);
9556
+ _context10.t0 = _regeneratorRuntime().keys(err);
9078
9557
 
9079
9558
  case 3:
9080
9559
  if ((_context10.t1 = _context10.t0()).done) {
@@ -9143,8 +9622,8 @@ var endowCode = /*#__PURE__*/function () {
9143
9622
  var Text$3 = Typography.Text;
9144
9623
  var useEndowCode = (function (goods) {
9145
9624
  var controller = default_1.useInvoiceController();
9146
- var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
9147
- return regeneratorRuntime.wrap(function _callee$(_context) {
9625
+ var onClick = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
9626
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
9148
9627
  while (1) {
9149
9628
  switch (_context.prev = _context.next) {
9150
9629
  case 0:
@@ -9158,17 +9637,17 @@ var useEndowCode = (function (goods) {
9158
9637
  }, _callee);
9159
9638
  })), [controller, goods]);
9160
9639
  return React.useMemo(function () {
9161
- return /*#__PURE__*/React.createElement(Menu.Item, {
9640
+ return React.createElement(Menu.Item, {
9162
9641
  key: "endowCode",
9163
9642
  onClick: onClick
9164
- }, /*#__PURE__*/React.createElement(Text$3, {
9643
+ }, React.createElement(Text$3, {
9165
9644
  strong: true
9166
9645
  }, "\u8D4B\u7801"));
9167
9646
  }, [goods.lineAttribute, onClick]);
9168
9647
  });
9169
9648
 
9170
- var css_248z$5 = ".ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu:focus,\n.ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu:hover,\n.ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu {\n font-size: 16px;\n color: #000;\n text-align: center;\n padding: 0;\n}\n.ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu:hover,\n.ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu.ktsAnt3x-dropdown-open {\n background: #ebebeb;\n border-radius: 9999px;\n}\n";
9171
- styleInject(css_248z$5);
9649
+ var css_248z$6 = ".ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu:focus,\n.ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu:hover,\n.ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu {\n font-size: 16px;\n color: #000;\n text-align: center;\n padding: 0;\n}\n.ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu:hover,\n.ktsAnt3x-btn.kts-invoice-operate-goods-list-columns-row-menu.ktsAnt3x-dropdown-open {\n background: #ebebeb;\n border-radius: 9999px;\n}\n";
9650
+ styleInject(css_248z$6);
9172
9651
 
9173
9652
  var RowMenu = (function (props) {
9174
9653
  var controller = default_1.useInvoiceController();
@@ -9195,7 +9674,7 @@ var RowMenu = (function (props) {
9195
9674
  model !== 'prefab' && delItem && arr.push(delItem); // 删除
9196
9675
 
9197
9676
  if (!goodsMenuExpand || goodsMenuExpand.length === 0) return arr;
9198
- arr.unshift( /*#__PURE__*/React.createElement(Menu.Divider, {
9677
+ arr.unshift(React.createElement(Menu.Divider, {
9199
9678
  key: "divider-1"
9200
9679
  }));
9201
9680
 
@@ -9208,16 +9687,16 @@ var RowMenu = (function (props) {
9208
9687
  }, [controller, endowCode, addDiscount, delItem, goodsMenuExpand, props.goods, model, isAddDiscount]);
9209
9688
 
9210
9689
  if (itemList.length === 0) {
9211
- return /*#__PURE__*/React.createElement(React.Fragment, null);
9690
+ return React.createElement(React.Fragment, null);
9212
9691
  }
9213
9692
 
9214
- return /*#__PURE__*/React.createElement(Dropdown, {
9215
- overlay: /*#__PURE__*/React.createElement(Menu, null, itemList),
9693
+ return React.createElement(Dropdown, {
9694
+ overlay: React.createElement(Menu, null, itemList),
9216
9695
  trigger: ['click']
9217
- }, /*#__PURE__*/React.createElement(Button, {
9696
+ }, React.createElement(Button, {
9218
9697
  className: "kts-invoice-operate-goods-list-columns-row-menu ant-btn-icon-only",
9219
9698
  type: "link"
9220
- }, /*#__PURE__*/React.createElement(Icon, {
9699
+ }, React.createElement(Icon, {
9221
9700
  component: SvgSpot
9222
9701
  })));
9223
9702
  });
@@ -9237,6 +9716,11 @@ var useColumns = (function (form) {
9237
9716
  var editGood = controller.useMemo(function (e) {
9238
9717
  return e.goodsListState.editGood;
9239
9718
  }, []);
9719
+ /** 搜索条件 */
9720
+
9721
+ var searchValue = controller.useMemo(function (e) {
9722
+ return e.goodsListState.searchValue;
9723
+ }, []);
9240
9724
  /** 税率列表 */
9241
9725
 
9242
9726
  var taxRateList = controller.useMemo(function (e) {
@@ -9263,7 +9747,7 @@ var useColumns = (function (form) {
9263
9747
 
9264
9748
  var columns = React.useMemo(function () {
9265
9749
  return [{
9266
- title: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Text$4, {
9750
+ title: React.createElement(React.Fragment, null, React.createElement(Text$4, {
9267
9751
  type: "danger"
9268
9752
  }, "*"), "\u8D27\u7269\u540D\u79F0"),
9269
9753
  dataIndex: 'itemName',
@@ -9272,7 +9756,7 @@ var useColumns = (function (form) {
9272
9756
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9273
9757
  var _editGood$itemName;
9274
9758
 
9275
- return /*#__PURE__*/React.createElement(Form.Item, null, /*#__PURE__*/React.createElement("div", {
9759
+ return React.createElement(Form.Item, null, React.createElement("div", {
9276
9760
  style: {
9277
9761
  display: 'flex'
9278
9762
  }
@@ -9282,26 +9766,26 @@ var useColumns = (function (form) {
9282
9766
  required: true,
9283
9767
  message: '货物名称不能为空'
9284
9768
  }]
9285
- })( /*#__PURE__*/React.createElement(MyInput, {
9769
+ })(React.createElement(MyInput, {
9286
9770
  style: {
9287
9771
  flex: 1
9288
9772
  },
9289
9773
  onChange: function onChange() {
9290
9774
  onSaveEditGood(controller, form, record, 'itemName');
9291
9775
  }
9292
- })), /*#__PURE__*/React.createElement("div", {
9776
+ })), React.createElement("div", {
9293
9777
  className: "kts-invoice-operate-goods-list-able-list-itemName-import"
9294
- }, !((_editGood$itemName = editGood.itemName) === null || _editGood$itemName === void 0 ? void 0 : _editGood$itemName.match(/\*[^*]+\*/)) && /*#__PURE__*/React.createElement(Button, {
9778
+ }, !((_editGood$itemName = editGood.itemName) === null || _editGood$itemName === void 0 ? void 0 : _editGood$itemName.match(/\*[^*]+\*/)) && React.createElement(Button, {
9295
9779
  onClick: function onClick() {
9296
9780
  endowCode(controller, record);
9297
9781
  },
9298
9782
  type: "link",
9299
9783
  icon: "file-add"
9300
- }), controller.getGoodsList && /*#__PURE__*/React.createElement(Button, {
9784
+ }), controller.getGoodsList && React.createElement(Button, {
9301
9785
  onClick: function onClick() {
9302
9786
  controller.pipeline( /*#__PURE__*/function () {
9303
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
9304
- return regeneratorRuntime.wrap(function _callee$(_context) {
9787
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
9788
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
9305
9789
  while (1) {
9306
9790
  switch (_context.prev = _context.next) {
9307
9791
  case 0:
@@ -9324,11 +9808,11 @@ var useColumns = (function (form) {
9324
9808
  icon: "plus-circle"
9325
9809
  }))));
9326
9810
  } else {
9327
- return /*#__PURE__*/React.createElement("span", {
9811
+ return React.createElement("span", {
9328
9812
  style: {
9329
9813
  padding: '0 10px'
9330
9814
  }
9331
- }, value);
9815
+ }, formatSearch(value, searchValue));
9332
9816
  }
9333
9817
  }
9334
9818
  }, {
@@ -9338,19 +9822,19 @@ var useColumns = (function (form) {
9338
9822
  width: 119,
9339
9823
  render: function render(value, record) {
9340
9824
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9341
- return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('itemModelName', {
9825
+ return React.createElement(Form.Item, null, getFieldDecorator('itemModelName', {
9342
9826
  initialValue: editGood.itemModelName
9343
- })( /*#__PURE__*/React.createElement(MyInput, {
9827
+ })(React.createElement(MyInput, {
9344
9828
  onChange: function onChange() {
9345
9829
  onSaveEditGood(controller, form, record, 'itemModelName');
9346
9830
  }
9347
9831
  })));
9348
9832
  } else {
9349
- return /*#__PURE__*/React.createElement("span", {
9833
+ return React.createElement("span", {
9350
9834
  style: {
9351
9835
  padding: '0 10px'
9352
9836
  }
9353
- }, value);
9837
+ }, formatSearch(value, searchValue));
9354
9838
  }
9355
9839
  }
9356
9840
  }, {
@@ -9360,9 +9844,9 @@ var useColumns = (function (form) {
9360
9844
  width: 70,
9361
9845
  render: function render(value, record) {
9362
9846
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9363
- return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('unit', {
9847
+ return React.createElement(Form.Item, null, getFieldDecorator('unit', {
9364
9848
  initialValue: editGood.unit
9365
- })( /*#__PURE__*/React.createElement(AutoComplete, {
9849
+ })(React.createElement(AutoComplete, {
9366
9850
  style: {
9367
9851
  width: '100%'
9368
9852
  },
@@ -9372,7 +9856,7 @@ var useColumns = (function (form) {
9372
9856
  }
9373
9857
  })));
9374
9858
  } else {
9375
- return /*#__PURE__*/React.createElement("span", {
9859
+ return React.createElement("span", {
9376
9860
  style: {
9377
9861
  padding: '0 10px'
9378
9862
  }
@@ -9387,16 +9871,16 @@ var useColumns = (function (form) {
9387
9871
  width: 149,
9388
9872
  render: function render(value, record) {
9389
9873
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9390
- return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('quantity', {
9874
+ return React.createElement(Form.Item, null, getFieldDecorator('quantity', {
9391
9875
  initialValue: editGood.quantity,
9392
9876
  rules: [{
9393
9877
  pattern: /^[+-]?(0|([1-9]\d*))(\.\d+)?$/,
9394
9878
  message: '数量必须为数字'
9395
9879
  }, {
9396
9880
  validator: function () {
9397
- var _validator = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(_, value, callback) {
9881
+ var _validator = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(_, value, callback) {
9398
9882
  var isvalue, isPrice;
9399
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
9883
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
9400
9884
  while (1) {
9401
9885
  switch (_context2.prev = _context2.next) {
9402
9886
  case 0:
@@ -9432,7 +9916,7 @@ var useColumns = (function (form) {
9432
9916
  return validator;
9433
9917
  }()
9434
9918
  }]
9435
- })( /*#__PURE__*/React.createElement(MyInput, {
9919
+ })(React.createElement(MyInput, {
9436
9920
  style: {
9437
9921
  textAlign: 'right'
9438
9922
  },
@@ -9444,7 +9928,7 @@ var useColumns = (function (form) {
9444
9928
  }
9445
9929
  })));
9446
9930
  } else {
9447
- return /*#__PURE__*/React.createElement("span", {
9931
+ return React.createElement("span", {
9448
9932
  style: {
9449
9933
  padding: '0 10px'
9450
9934
  }
@@ -9459,16 +9943,16 @@ var useColumns = (function (form) {
9459
9943
  width: 149,
9460
9944
  render: function render(value, record) {
9461
9945
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9462
- return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('priceIncludeTax', {
9946
+ return React.createElement(Form.Item, null, getFieldDecorator('priceIncludeTax', {
9463
9947
  initialValue: editGood.priceIncludeTax,
9464
9948
  rules: [{
9465
9949
  pattern: /^[+-]?(0|([1-9]\d*))(\.\d+)?$/,
9466
9950
  message: '单价必须为数字'
9467
9951
  }, {
9468
9952
  validator: function () {
9469
- var _validator2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee3(_, value, callback) {
9953
+ var _validator2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(_, value, callback) {
9470
9954
  var isQuantity, isvalue;
9471
- return regeneratorRuntime.wrap(function _callee3$(_context3) {
9955
+ return _regeneratorRuntime().wrap(function _callee3$(_context3) {
9472
9956
  while (1) {
9473
9957
  switch (_context3.prev = _context3.next) {
9474
9958
  case 0:
@@ -9504,7 +9988,7 @@ var useColumns = (function (form) {
9504
9988
  return validator;
9505
9989
  }()
9506
9990
  }]
9507
- })( /*#__PURE__*/React.createElement(MyInput, {
9991
+ })(React.createElement(MyInput, {
9508
9992
  style: {
9509
9993
  textAlign: 'right'
9510
9994
  },
@@ -9516,7 +10000,7 @@ var useColumns = (function (form) {
9516
10000
  }
9517
10001
  })));
9518
10002
  } else {
9519
- return /*#__PURE__*/React.createElement("span", {
10003
+ return React.createElement("span", {
9520
10004
  style: {
9521
10005
  padding: '0 10px'
9522
10006
  }
@@ -9531,16 +10015,16 @@ var useColumns = (function (form) {
9531
10015
  width: 149,
9532
10016
  render: function render(value, record) {
9533
10017
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9534
- return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('priceExcludeTax', {
10018
+ return React.createElement(Form.Item, null, getFieldDecorator('priceExcludeTax', {
9535
10019
  initialValue: editGood.priceExcludeTax,
9536
10020
  rules: [{
9537
10021
  pattern: /^[+-]?(0|([1-9]\d*))(\.\d+)?$/,
9538
10022
  message: '单价必须为数字'
9539
10023
  }, {
9540
10024
  validator: function () {
9541
- var _validator3 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee4(_, value, callback) {
10025
+ var _validator3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(_, value, callback) {
9542
10026
  var isQuantity, isvalue;
9543
- return regeneratorRuntime.wrap(function _callee4$(_context4) {
10027
+ return _regeneratorRuntime().wrap(function _callee4$(_context4) {
9544
10028
  while (1) {
9545
10029
  switch (_context4.prev = _context4.next) {
9546
10030
  case 0:
@@ -9576,7 +10060,7 @@ var useColumns = (function (form) {
9576
10060
  return validator;
9577
10061
  }()
9578
10062
  }]
9579
- })( /*#__PURE__*/React.createElement(MyInput, {
10063
+ })(React.createElement(MyInput, {
9580
10064
  style: {
9581
10065
  textAlign: 'right'
9582
10066
  },
@@ -9588,7 +10072,7 @@ var useColumns = (function (form) {
9588
10072
  }
9589
10073
  })));
9590
10074
  } else {
9591
- return /*#__PURE__*/React.createElement("span", {
10075
+ return React.createElement("span", {
9592
10076
  style: {
9593
10077
  padding: '0 10px'
9594
10078
  }
@@ -9596,7 +10080,7 @@ var useColumns = (function (form) {
9596
10080
  }
9597
10081
  }
9598
10082
  }, {
9599
- title: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Text$4, {
10083
+ title: React.createElement(React.Fragment, null, React.createElement(Text$4, {
9600
10084
  type: "danger"
9601
10085
  }, "*"), "\u91D1\u989D(\u542B\u7A0E)"),
9602
10086
  dataIndex: 'lineAmountIncludeTax',
@@ -9605,7 +10089,7 @@ var useColumns = (function (form) {
9605
10089
  align: 'right',
9606
10090
  render: function render(value, record) {
9607
10091
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9608
- return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('lineAmountIncludeTax', {
10092
+ return React.createElement(Form.Item, null, getFieldDecorator('lineAmountIncludeTax', {
9609
10093
  initialValue: editGood.lineAmountIncludeTax,
9610
10094
  rules: [{
9611
10095
  required: true,
@@ -9615,8 +10099,8 @@ var useColumns = (function (form) {
9615
10099
  message: '金额必须为数字'
9616
10100
  }, {
9617
10101
  validator: function () {
9618
- var _validator4 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee5(_, value, callback) {
9619
- return regeneratorRuntime.wrap(function _callee5$(_context5) {
10102
+ var _validator4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(_, value, callback) {
10103
+ return _regeneratorRuntime().wrap(function _callee5$(_context5) {
9620
10104
  while (1) {
9621
10105
  switch (_context5.prev = _context5.next) {
9622
10106
  case 0:
@@ -9640,8 +10124,8 @@ var useColumns = (function (form) {
9640
10124
  }()
9641
10125
  }, {
9642
10126
  validator: function () {
9643
- var _validator5 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee6(_, value, callback) {
9644
- return regeneratorRuntime.wrap(function _callee6$(_context6) {
10127
+ var _validator5 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(_, value, callback) {
10128
+ return _regeneratorRuntime().wrap(function _callee6$(_context6) {
9645
10129
  while (1) {
9646
10130
  switch (_context6.prev = _context6.next) {
9647
10131
  case 0:
@@ -9664,7 +10148,7 @@ var useColumns = (function (form) {
9664
10148
  return validator;
9665
10149
  }()
9666
10150
  }]
9667
- })( /*#__PURE__*/React.createElement(MyInput, {
10151
+ })(React.createElement(MyInput, {
9668
10152
  style: {
9669
10153
  textAlign: 'right'
9670
10154
  },
@@ -9675,15 +10159,15 @@ var useColumns = (function (form) {
9675
10159
  }
9676
10160
  })));
9677
10161
  } else {
9678
- return /*#__PURE__*/React.createElement("span", {
10162
+ return React.createElement("span", {
9679
10163
  style: {
9680
10164
  padding: '0 10px'
9681
10165
  }
9682
- }, parseFloat(value).toFixed(2));
10166
+ }, formatSearch(parseFloat(value).toFixed(2), searchValue));
9683
10167
  }
9684
10168
  }
9685
10169
  }, {
9686
- title: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Text$4, {
10170
+ title: React.createElement(React.Fragment, null, React.createElement(Text$4, {
9687
10171
  type: "danger"
9688
10172
  }, "*"), "\u91D1\u989D(\u4E0D\u542B\u7A0E)"),
9689
10173
  dataIndex: 'lineAmountExcludeTax',
@@ -9692,7 +10176,7 @@ var useColumns = (function (form) {
9692
10176
  width: 119,
9693
10177
  render: function render(value, record) {
9694
10178
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9695
- return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('lineAmountExcludeTax', {
10179
+ return React.createElement(Form.Item, null, getFieldDecorator('lineAmountExcludeTax', {
9696
10180
  initialValue: editGood.lineAmountExcludeTax,
9697
10181
  rules: [{
9698
10182
  required: true,
@@ -9702,8 +10186,8 @@ var useColumns = (function (form) {
9702
10186
  message: '金额必须为数字'
9703
10187
  }, {
9704
10188
  validator: function () {
9705
- var _validator6 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee7(_, value, callback) {
9706
- return regeneratorRuntime.wrap(function _callee7$(_context7) {
10189
+ var _validator6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee7(_, value, callback) {
10190
+ return _regeneratorRuntime().wrap(function _callee7$(_context7) {
9707
10191
  while (1) {
9708
10192
  switch (_context7.prev = _context7.next) {
9709
10193
  case 0:
@@ -9726,7 +10210,7 @@ var useColumns = (function (form) {
9726
10210
  return validator;
9727
10211
  }()
9728
10212
  }]
9729
- })( /*#__PURE__*/React.createElement(MyInput, {
10213
+ })(React.createElement(MyInput, {
9730
10214
  style: {
9731
10215
  textAlign: 'right'
9732
10216
  },
@@ -9737,7 +10221,7 @@ var useColumns = (function (form) {
9737
10221
  }
9738
10222
  })));
9739
10223
  } else {
9740
- return /*#__PURE__*/React.createElement("span", {
10224
+ return React.createElement("span", {
9741
10225
  style: {
9742
10226
  padding: '0 10px'
9743
10227
  }
@@ -9745,7 +10229,7 @@ var useColumns = (function (form) {
9745
10229
  }
9746
10230
  }
9747
10231
  }, {
9748
- title: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Text$4, {
10232
+ title: React.createElement(React.Fragment, null, React.createElement(Text$4, {
9749
10233
  type: "danger"
9750
10234
  }, "*"), "\u7A0E\u7387"),
9751
10235
  dataIndex: 'taxRate',
@@ -9754,7 +10238,7 @@ var useColumns = (function (form) {
9754
10238
  width: 70,
9755
10239
  render: function render(value, record) {
9756
10240
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9757
- return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('taxRate', {
10241
+ return React.createElement(Form.Item, null, getFieldDecorator('taxRate', {
9758
10242
  initialValue: editGood.taxRate,
9759
10243
  rules: [{
9760
10244
  required: true,
@@ -9763,7 +10247,7 @@ var useColumns = (function (form) {
9763
10247
  pattern: /^[+-]?(0|([1-9]\d*))(\.\d+)?$/,
9764
10248
  message: ' '
9765
10249
  }]
9766
- })( /*#__PURE__*/React.createElement(Select, {
10250
+ })(React.createElement(Select, {
9767
10251
  className: "kts-invoice-operate-goods-list-table-tax-rate",
9768
10252
  dropdownMenuStyle: {
9769
10253
  textAlign: "right"
@@ -9776,13 +10260,13 @@ var useColumns = (function (form) {
9776
10260
  onChangeTaxRate(controller, form, record);
9777
10261
  }
9778
10262
  }, taxRateList.map(function (e, i) {
9779
- return /*#__PURE__*/React.createElement(Select.Option, {
10263
+ return React.createElement(Select.Option, {
9780
10264
  key: i,
9781
10265
  value: e
9782
10266
  }, e, "%");
9783
10267
  }))));
9784
10268
  } else {
9785
- return /*#__PURE__*/React.createElement("span", {
10269
+ return React.createElement("span", {
9786
10270
  style: {
9787
10271
  padding: '0 10px'
9788
10272
  }
@@ -9799,9 +10283,9 @@ var useColumns = (function (form) {
9799
10283
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
9800
10284
  return getFieldDecorator('taxAmount', {
9801
10285
  initialValue: editGood.taxAmount
9802
- })( /*#__PURE__*/React.createElement(MyDiv, null));
10286
+ })(React.createElement(MyDiv, null));
9803
10287
  } else {
9804
- return /*#__PURE__*/React.createElement("span", {
10288
+ return React.createElement("span", {
9805
10289
  style: {
9806
10290
  padding: '0 10px'
9807
10291
  }
@@ -9815,7 +10299,7 @@ var useColumns = (function (form) {
9815
10299
  width: 50,
9816
10300
  align: 'center',
9817
10301
  render: function render(_value, record) {
9818
- return /*#__PURE__*/React.createElement(RowMenu, {
10302
+ return React.createElement(RowMenu, {
9819
10303
  key: record.lineAttribute,
9820
10304
  goods: record
9821
10305
  });
@@ -9831,7 +10315,7 @@ var useColumns = (function (form) {
9831
10315
  ellipsis: true
9832
10316
  });
9833
10317
  });
9834
- }, [isTaxIncluded, editGood, controller, changeField, deduction]);
10318
+ }, [isTaxIncluded, editGood, controller, changeField, deduction, searchValue]);
9835
10319
  React.useEffect(function () {
9836
10320
  if (!changeField) return;
9837
10321
  var t = setTimeout(function () {
@@ -9865,13 +10349,13 @@ var MyInput = /*#__PURE__*/function (_React$Component) {
9865
10349
  key: "render",
9866
10350
  value: function render() {
9867
10351
  if (this.props.loading) {
9868
- return /*#__PURE__*/React.createElement(Spin, {
10352
+ return React.createElement(Spin, {
9869
10353
  size: "small"
9870
- }, /*#__PURE__*/React.createElement(Input, _objectSpread2(_objectSpread2({}, this.props), {}, {
10354
+ }, React.createElement(Input, _objectSpread2(_objectSpread2({}, this.props), {}, {
9871
10355
  autoComplete: "off"
9872
10356
  })));
9873
10357
  } else {
9874
- return /*#__PURE__*/React.createElement(Input, _objectSpread2(_objectSpread2({}, this.props), {}, {
10358
+ return React.createElement(Input, _objectSpread2(_objectSpread2({}, this.props), {}, {
9875
10359
  autoComplete: "off"
9876
10360
  }));
9877
10361
  }
@@ -9895,7 +10379,7 @@ var MyDiv = /*#__PURE__*/function (_React$Component2) {
9895
10379
  _createClass(MyDiv, [{
9896
10380
  key: "render",
9897
10381
  value: function render() {
9898
- return /*#__PURE__*/React.createElement("span", {
10382
+ return React.createElement("span", {
9899
10383
  style: {
9900
10384
  padding: '0 10px'
9901
10385
  }
@@ -9905,6 +10389,38 @@ var MyDiv = /*#__PURE__*/function (_React$Component2) {
9905
10389
 
9906
10390
  return MyDiv;
9907
10391
  }(React.Component);
10392
+ /** 格式搜索结果 */
10393
+
10394
+
10395
+ function formatSearch(value, search) {
10396
+ if (!value || !search) return value;
10397
+
10398
+ var __html = ucoding(value).split(new RegExp(ucoding(search), 'g')).map(function (e) {
10399
+ return dcoding(e);
10400
+ }).join("<span class=\"kts-invoice-operate-goods-list-table-search-protrude\" >".concat(search, "</span>"));
10401
+
10402
+ return React.createElement("span", {
10403
+ dangerouslySetInnerHTML: {
10404
+ __html: __html
10405
+ }
10406
+ });
10407
+ }
10408
+ /** 编码 */
10409
+
10410
+
10411
+ function ucoding(v) {
10412
+ return v.split('').map(function (e) {
10413
+ return "\\U".concat(e.charCodeAt(0));
10414
+ }).join('');
10415
+ }
10416
+ /** 解码 */
10417
+
10418
+
10419
+ function dcoding(v) {
10420
+ return v.split("\\U").map(function (e) {
10421
+ return e ? String.fromCharCode(parseInt(e)) : '';
10422
+ }).join('');
10423
+ }
9908
10424
 
9909
10425
  var useOnRow = (function () {
9910
10426
  /** 控制器 */
@@ -9913,9 +10429,9 @@ var useOnRow = (function () {
9913
10429
  return s.model;
9914
10430
  }, []);
9915
10431
  var onClick = React.useCallback( /*#__PURE__*/function () {
9916
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(record) {
10432
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(record) {
9917
10433
  var editGood;
9918
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
10434
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
9919
10435
  while (1) {
9920
10436
  switch (_context2.prev = _context2.next) {
9921
10437
  case 0:
@@ -9960,8 +10476,8 @@ var useOnRow = (function () {
9960
10476
  case 12:
9961
10477
  _context2.next = 14;
9962
10478
  return controller.pipeline( /*#__PURE__*/function () {
9963
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
9964
- return regeneratorRuntime.wrap(function _callee$(_context) {
10479
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
10480
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
9965
10481
  while (1) {
9966
10482
  switch (_context.prev = _context.next) {
9967
10483
  case 0:
@@ -10022,8 +10538,8 @@ function useDeduction(controller) {
10022
10538
  // 更新 扣除额
10023
10539
  React.useEffect(function () {
10024
10540
  controller.pipeline( /*#__PURE__*/function () {
10025
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
10026
- return regeneratorRuntime.wrap(function _callee$(_context) {
10541
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
10542
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
10027
10543
  while (1) {
10028
10544
  switch (_context.prev = _context.next) {
10029
10545
  case 0:
@@ -10045,8 +10561,8 @@ function useDeduction(controller) {
10045
10561
 
10046
10562
  React.useEffect(function () {
10047
10563
  controller.pipeline( /*#__PURE__*/function () {
10048
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(s) {
10049
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
10564
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(s) {
10565
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
10050
10566
  while (1) {
10051
10567
  switch (_context2.prev = _context2.next) {
10052
10568
  case 0:
@@ -10102,105 +10618,168 @@ var useRowSelection = (function () {
10102
10618
  var goodsList = controller.useMemo(function (s) {
10103
10619
  return s.goodsListState.goodsList;
10104
10620
  }, []);
10621
+ /** 搜索条件 */
10622
+
10623
+ var searchValue = controller.useMemo(function (s) {
10624
+ return s.goodsListState.searchValue;
10625
+ }, []);
10105
10626
  /** 是否全选 */
10627
+ // const isAll = controller.useMemo(s => s.goodsListState.goodsList.length > 0 && s.goodsListState.selectedGoodIndex.length === s.goodsListState.goodsList.length, [])
10106
10628
 
10107
10629
  var isAll = controller.useMemo(function (s) {
10108
- return s.goodsListState.goodsList.length > 0 && s.goodsListState.selectedGoodIndex.length === s.goodsListState.goodsList.length;
10630
+ if (s.goodsListState.selectedGoodIndex.length <= 0) return false;
10631
+ var seeGoodsIndex = controller.getGoodsSearch(s.goodsListState.goodsList, s.goodsListState.searchValue).map(function (e) {
10632
+ return e.$index;
10633
+ });
10634
+ var selectedGoodIndex = s.goodsListState.selectedGoodIndex.filter(function (e) {
10635
+ return seeGoodsIndex.some(function (t) {
10636
+ return e === t;
10637
+ });
10638
+ });
10639
+ return selectedGoodIndex.length === seeGoodsIndex.length;
10640
+ }, []);
10641
+ var indeterminate = controller.useMemo(function (s) {
10642
+ var seeGoodsIndex = controller.getGoodsSearch(s.goodsListState.goodsList, s.goodsListState.searchValue).map(function (e) {
10643
+ return e.$index;
10644
+ });
10645
+ var selectedGoodIndex = s.goodsListState.selectedGoodIndex.filter(function (e) {
10646
+ return seeGoodsIndex.some(function (t) {
10647
+ return e === t;
10648
+ });
10649
+ });
10650
+ if (selectedGoodIndex.length === 0) return false;
10651
+ return selectedGoodIndex.length < seeGoodsIndex.length;
10109
10652
  }, []);
10110
10653
  /** 点击了全选 */
10111
10654
 
10112
- var onClickSelectAll = React.useCallback(function () {
10113
- if (isAll) {
10114
- controller.pipeline( /*#__PURE__*/function () {
10115
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
10116
- return regeneratorRuntime.wrap(function _callee$(_context) {
10117
- while (1) {
10118
- switch (_context.prev = _context.next) {
10119
- case 0:
10120
- s.goodsListState.selectedGoodIndex = [];
10121
-
10122
- case 1:
10123
- case "end":
10124
- return _context.stop();
10125
- }
10655
+ var onClickSelectAll = React.useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
10656
+ return _regeneratorRuntime().wrap(function _callee3$(_context3) {
10657
+ while (1) {
10658
+ switch (_context3.prev = _context3.next) {
10659
+ case 0:
10660
+ if (!isAll) {
10661
+ _context3.next = 5;
10662
+ break;
10126
10663
  }
10127
- }, _callee);
10128
- }));
10129
10664
 
10130
- return function (_x) {
10131
- return _ref.apply(this, arguments);
10132
- };
10133
- }())();
10134
- } else {
10135
- controller.pipeline( /*#__PURE__*/function () {
10136
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(s) {
10137
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
10138
- while (1) {
10139
- switch (_context2.prev = _context2.next) {
10140
- case 0:
10141
- s.goodsListState.selectedGoodIndex = s.goodsListState.goodsList.map(function (e) {
10142
- return e.$index;
10143
- });
10665
+ _context3.next = 3;
10666
+ return controller.pipeline( /*#__PURE__*/function () {
10667
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
10668
+ var seeGoodsIndex;
10669
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
10670
+ while (1) {
10671
+ switch (_context.prev = _context.next) {
10672
+ case 0:
10673
+ seeGoodsIndex = controller.getGoodsSearch(s.goodsListState.goodsList, s.goodsListState.searchValue).map(function (e) {
10674
+ return e.$index;
10675
+ });
10676
+ s.goodsListState.selectedGoodIndex = s.goodsListState.selectedGoodIndex.filter(function (e) {
10677
+ return !seeGoodsIndex.some(function (t) {
10678
+ return e === t;
10679
+ });
10680
+ });
10144
10681
 
10145
- case 1:
10146
- case "end":
10147
- return _context2.stop();
10148
- }
10149
- }
10150
- }, _callee2);
10151
- }));
10682
+ case 2:
10683
+ case "end":
10684
+ return _context.stop();
10685
+ }
10686
+ }
10687
+ }, _callee);
10688
+ }));
10152
10689
 
10153
- return function (_x2) {
10154
- return _ref2.apply(this, arguments);
10155
- };
10156
- }())();
10157
- }
10158
- }, [controller, isAll]);
10690
+ return function (_x) {
10691
+ return _ref2.apply(this, arguments);
10692
+ };
10693
+ }())();
10694
+
10695
+ case 3:
10696
+ _context3.next = 7;
10697
+ break;
10698
+
10699
+ case 5:
10700
+ _context3.next = 7;
10701
+ return controller.pipeline( /*#__PURE__*/function () {
10702
+ var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(s) {
10703
+ var seeGoodsIndex;
10704
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
10705
+ while (1) {
10706
+ switch (_context2.prev = _context2.next) {
10707
+ case 0:
10708
+ seeGoodsIndex = controller.getGoodsSearch(s.goodsListState.goodsList, s.goodsListState.searchValue).map(function (e) {
10709
+ return e.$index;
10710
+ });
10711
+ s.goodsListState.selectedGoodIndex = [].concat(_toConsumableArray(s.goodsListState.selectedGoodIndex), _toConsumableArray(seeGoodsIndex));
10712
+ s.goodsListState.selectedGoodIndex = Array.from(new Set(s.goodsListState.selectedGoodIndex));
10713
+
10714
+ case 3:
10715
+ case "end":
10716
+ return _context2.stop();
10717
+ }
10718
+ }
10719
+ }, _callee2);
10720
+ }));
10721
+
10722
+ return function (_x2) {
10723
+ return _ref3.apply(this, arguments);
10724
+ };
10725
+ }())();
10726
+
10727
+ case 7:
10728
+ _context3.next = 9;
10729
+ return sortOut(true);
10730
+
10731
+ case 9:
10732
+ case "end":
10733
+ return _context3.stop();
10734
+ }
10735
+ }
10736
+ }, _callee3);
10737
+ })), [controller, isAll]);
10159
10738
  var onSelect = React.useCallback( /*#__PURE__*/function () {
10160
- var _ref3 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee5(record, selected) {
10161
- return regeneratorRuntime.wrap(function _callee5$(_context5) {
10739
+ var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(record, selected) {
10740
+ return _regeneratorRuntime().wrap(function _callee6$(_context6) {
10162
10741
  while (1) {
10163
- switch (_context5.prev = _context5.next) {
10742
+ switch (_context6.prev = _context6.next) {
10164
10743
  case 0:
10165
10744
  if (!selected) {
10166
- _context5.next = 5;
10745
+ _context6.next = 5;
10167
10746
  break;
10168
10747
  }
10169
10748
 
10170
- _context5.next = 3;
10749
+ _context6.next = 3;
10171
10750
  return controller.pipeline( /*#__PURE__*/function () {
10172
- var _ref4 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee3(s) {
10173
- return regeneratorRuntime.wrap(function _callee3$(_context3) {
10751
+ var _ref5 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(s) {
10752
+ return _regeneratorRuntime().wrap(function _callee4$(_context4) {
10174
10753
  while (1) {
10175
- switch (_context3.prev = _context3.next) {
10754
+ switch (_context4.prev = _context4.next) {
10176
10755
  case 0:
10177
10756
  s.goodsListState.selectedGoodIndex = [].concat(_toConsumableArray(s.goodsListState.selectedGoodIndex), [record.$index]);
10178
10757
  s.goodsListState = _objectSpread2({}, s.goodsListState);
10179
10758
 
10180
10759
  case 2:
10181
10760
  case "end":
10182
- return _context3.stop();
10761
+ return _context4.stop();
10183
10762
  }
10184
10763
  }
10185
- }, _callee3);
10764
+ }, _callee4);
10186
10765
  }));
10187
10766
 
10188
10767
  return function (_x5) {
10189
- return _ref4.apply(this, arguments);
10768
+ return _ref5.apply(this, arguments);
10190
10769
  };
10191
10770
  }())();
10192
10771
 
10193
10772
  case 3:
10194
- _context5.next = 7;
10773
+ _context6.next = 7;
10195
10774
  break;
10196
10775
 
10197
10776
  case 5:
10198
- _context5.next = 7;
10777
+ _context6.next = 7;
10199
10778
  return controller.pipeline( /*#__PURE__*/function () {
10200
- var _ref5 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee4(s) {
10201
- return regeneratorRuntime.wrap(function _callee4$(_context4) {
10779
+ var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(s) {
10780
+ return _regeneratorRuntime().wrap(function _callee5$(_context5) {
10202
10781
  while (1) {
10203
- switch (_context4.prev = _context4.next) {
10782
+ switch (_context5.prev = _context5.next) {
10204
10783
  case 0:
10205
10784
  s.goodsListState.selectedGoodIndex = s.goodsListState.selectedGoodIndex.filter(function (e) {
10206
10785
  return e !== record.$index;
@@ -10209,64 +10788,63 @@ var useRowSelection = (function () {
10209
10788
 
10210
10789
  case 2:
10211
10790
  case "end":
10212
- return _context4.stop();
10791
+ return _context5.stop();
10213
10792
  }
10214
10793
  }
10215
- }, _callee4);
10794
+ }, _callee5);
10216
10795
  }));
10217
10796
 
10218
10797
  return function (_x6) {
10219
- return _ref5.apply(this, arguments);
10798
+ return _ref6.apply(this, arguments);
10220
10799
  };
10221
10800
  }())();
10222
10801
 
10223
10802
  case 7:
10224
- _context5.next = 9;
10803
+ _context6.next = 9;
10225
10804
  return sortOut(selected);
10226
10805
 
10227
10806
  case 9:
10228
10807
  case "end":
10229
- return _context5.stop();
10808
+ return _context6.stop();
10230
10809
  }
10231
10810
  }
10232
- }, _callee5);
10811
+ }, _callee6);
10233
10812
  }));
10234
10813
 
10235
10814
  return function (_x3, _x4) {
10236
- return _ref3.apply(this, arguments);
10815
+ return _ref4.apply(this, arguments);
10237
10816
  };
10238
10817
  }(), [controller]);
10239
10818
  var columnTitle = React.useMemo(function () {
10240
- return /*#__PURE__*/React.createElement(Checkbox, {
10819
+ return React.createElement(Checkbox, {
10241
10820
  onChange: onClickSelectAll,
10242
- indeterminate: selectedRowKeys.length > 0 && selectedRowKeys.length < goodsList.length,
10821
+ indeterminate: indeterminate,
10243
10822
  checked: isAll
10244
10823
  });
10245
- }, [goodsList, selectedRowKeys, onClickSelectAll, isAll]);
10824
+ }, [goodsList, selectedRowKeys, onClickSelectAll, isAll, indeterminate]);
10246
10825
  /** 选择了商品后 调整 折扣行 和 被折扣行 */
10247
10826
 
10248
10827
  var sortOut = React.useCallback( /*#__PURE__*/function () {
10249
- var _ref6 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee7(selected) {
10250
- return regeneratorRuntime.wrap(function _callee7$(_context7) {
10828
+ var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee8(selected) {
10829
+ return _regeneratorRuntime().wrap(function _callee8$(_context8) {
10251
10830
  while (1) {
10252
- switch (_context7.prev = _context7.next) {
10831
+ switch (_context8.prev = _context8.next) {
10253
10832
  case 0:
10254
- _context7.next = 2;
10833
+ _context8.next = 2;
10255
10834
  return controller.wait();
10256
10835
 
10257
10836
  case 2:
10258
- _context7.next = 4;
10837
+ _context8.next = 4;
10259
10838
  return controller.pipeline( /*#__PURE__*/function () {
10260
- var _ref7 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee6(s) {
10261
- return regeneratorRuntime.wrap(function _callee6$(_context6) {
10839
+ var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee7(s) {
10840
+ return _regeneratorRuntime().wrap(function _callee7$(_context7) {
10262
10841
  while (1) {
10263
- switch (_context6.prev = _context6.next) {
10842
+ switch (_context7.prev = _context7.next) {
10264
10843
  case 0:
10265
10844
  s.goodsListState.selectedGoodIndex.forEach(function ($index) {
10266
10845
  var goods = s.goodsListState.goodsMap.get($index);
10267
10846
  if (!goods || goods.lineAttribute === LineAttributeType$1.正常) return; // 数组位置
10268
10847
 
10269
- // 数组位置
10270
10848
  var t = s.goodsListState.goodsList.indexOf(goods);
10271
10849
  goods.lineAttribute === LineAttributeType$1.折扣行 ? t-- : t++;
10272
10850
  var i = s.goodsListState.goodsList[t].$index;
@@ -10282,27 +10860,27 @@ var useRowSelection = (function () {
10282
10860
 
10283
10861
  case 1:
10284
10862
  case "end":
10285
- return _context6.stop();
10863
+ return _context7.stop();
10286
10864
  }
10287
10865
  }
10288
- }, _callee6);
10866
+ }, _callee7);
10289
10867
  }));
10290
10868
 
10291
10869
  return function (_x8) {
10292
- return _ref7.apply(this, arguments);
10870
+ return _ref8.apply(this, arguments);
10293
10871
  };
10294
10872
  }())();
10295
10873
 
10296
10874
  case 4:
10297
10875
  case "end":
10298
- return _context7.stop();
10876
+ return _context8.stop();
10299
10877
  }
10300
10878
  }
10301
- }, _callee7);
10879
+ }, _callee8);
10302
10880
  }));
10303
10881
 
10304
10882
  return function (_x7) {
10305
- return _ref6.apply(this, arguments);
10883
+ return _ref7.apply(this, arguments);
10306
10884
  };
10307
10885
  }(), [controller]);
10308
10886
  React.useEffect(function () {
@@ -10316,8 +10894,8 @@ var useRowSelection = (function () {
10316
10894
  };
10317
10895
  });
10318
10896
 
10319
- var css_248z$6 = ".kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-table-tax-rate .ktsAnt3x-select-selection-selected-value {\n float: right;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able {\n display: flex;\n padding: 10px;\n border-bottom: 1px solid #dcdcdc;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-list {\n flex: 1;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-list button {\n padding-left: 10px;\n padding-right: 10px;\n border-radius: 12px;\n color: #0074ff;\n border: 1px solid #0074ff;\n margin: 0 10px;\n height: 24px;\n line-height: 22px;\n cursor: pointer;\n font-size: 12px;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-list button[disabled] {\n color: rgba(0, 0, 0, 0.25);\n border: 1px solid;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-extend {\n flex: none;\n display: flex;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-extend label {\n margin-right: 5px;\n}\n.kts-invoice-operate-goods-list-table.kts-invoice-operate-prefab .ktsAnt3x-table-row {\n color: rgba(0, 0, 0, 0.25);\n background: #f5f5f5;\n}\n.kts-invoice-operate-goods-list-table {\n border-bottom: 1px solid #dcdcdc;\n}\n.kts-invoice-operate-goods-list-table .kts-invoice-operate-goods-discount {\n color: rgba(0, 0, 0, 0.25);\n background: #f5f5f5;\n}\n.kts-invoice-operate-goods-list-table .kts-invoice-operate-goods-list-able-list-itemName-import {\n display: flex;\n}\n.kts-invoice-operate-goods-list-table .kts-invoice-operate-goods-list-able-list-itemName-import .ktsAnt3x-btn {\n display: block;\n line-height: 0;\n width: auto;\n padding-right: 5px;\n}\n.kts-invoice-operate-goods-list-table .ktsAnt3x-form-item-children {\n height: 30px;\n display: block;\n}\n.kts-invoice-operate-goods-list-table .ktsAnt3x-table-body {\n height: 263px;\n}\n.kts-invoice-operate-goods-list-table .ktsAnt3x-form-explain {\n position: absolute;\n right: 6px;\n top: 6px;\n}\n.kts-invoice-operate-goods-list-table table {\n border-bottom: 1px solid #d9d9d9 !important;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td {\n padding: 0 !important;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-form-explain {\n display: none;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-form-item {\n padding: 0;\n margin: 0;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-form-item .ktsAnt3x-form-item-control {\n line-height: inherit;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .has-error .ktsAnt3x-select-selection,\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .has-error .ktsAnt3x-input,\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .has-error .ktsAnt3x-input:hover {\n border-right-width: 1px !important;\n border-top-width: 1px;\n border-left-width: 1px;\n border-bottom-width: 1px;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-select-selection--single,\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-select-auto-complete.ktsAnt3x-select .ktsAnt3x-input:hover,\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-input {\n height: 30px;\n border-radius: 0;\n border-right-width: 0 !important;\n border-top-width: 0;\n border-left-width: 0;\n border-bottom-width: 0;\n box-shadow: none;\n}\n";
10320
- styleInject(css_248z$6);
10897
+ var css_248z$7 = ".kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-table-tax-rate .ktsAnt3x-select-selection-selected-value {\n float: right;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able {\n display: flex;\n padding: 10px;\n border-bottom: 1px solid #dcdcdc;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-list {\n flex: 1;\n display: flex;\n gap: 10px;\n padding-right: 10px;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-list button {\n padding-left: 10px;\n padding-right: 10px;\n border-radius: 12px;\n color: #0074ff;\n border: 1px solid #0074ff;\n height: 24px;\n line-height: 22px;\n cursor: pointer;\n font-size: 12px;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-list button[disabled] {\n color: rgba(0, 0, 0, 0.25);\n border: 1px solid;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-extend {\n flex: none;\n display: flex;\n}\n.kts-invoice-operate-goods-list .kts-invoice-operate-goods-list-able-extend label {\n margin-right: 5px;\n}\n.kts-invoice-operate-goods-list-table.kts-invoice-operate-prefab .ktsAnt3x-table-row {\n color: rgba(0, 0, 0, 0.25);\n background: #f5f5f5;\n}\n.kts-invoice-operate-goods-list-table {\n border-bottom: 1px solid #dcdcdc;\n}\n.kts-invoice-operate-goods-list-table .kts-invoice-operate-goods-discount {\n color: rgba(0, 0, 0, 0.25);\n background: #f5f5f5;\n}\n.kts-invoice-operate-goods-list-table .kts-invoice-operate-goods-list-able-list-itemName-import {\n display: flex;\n}\n.kts-invoice-operate-goods-list-table .kts-invoice-operate-goods-list-able-list-itemName-import .ktsAnt3x-btn {\n display: block;\n line-height: 0;\n width: auto;\n padding-right: 5px;\n}\n.kts-invoice-operate-goods-list-table .ktsAnt3x-form-item-children {\n height: 30px;\n display: block;\n}\n.kts-invoice-operate-goods-list-table .ktsAnt3x-table-body {\n height: 263px;\n}\n.kts-invoice-operate-goods-list-table .ktsAnt3x-form-explain {\n position: absolute;\n right: 6px;\n top: 6px;\n}\n.kts-invoice-operate-goods-list-table table {\n border-bottom: 1px solid #d9d9d9 !important;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td {\n padding: 0 !important;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-form-explain {\n display: none;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-form-item {\n padding: 0;\n margin: 0;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-form-item .ktsAnt3x-form-item-control {\n line-height: inherit;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .has-error .ktsAnt3x-select-selection,\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .has-error .ktsAnt3x-input,\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .has-error .ktsAnt3x-input:hover {\n border-right-width: 1px !important;\n border-top-width: 1px;\n border-left-width: 1px;\n border-bottom-width: 1px;\n}\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-select-selection--single,\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-select-auto-complete.ktsAnt3x-select .ktsAnt3x-input:hover,\n.kts-invoice-operate-goods-list-table table > .ktsAnt3x-table-tbody > tr > td .ktsAnt3x-input {\n height: 30px;\n border-radius: 0;\n border-right-width: 0 !important;\n border-top-width: 0;\n border-left-width: 0;\n border-bottom-width: 0;\n box-shadow: none;\n}\n.kts-invoice-operate-goods-list-table-search-protrude {\n background: #ff0;\n color: #000;\n font-weight: bold;\n}\n";
10898
+ styleInject(css_248z$7);
10321
10899
 
10322
10900
  var GoodsList = /*#__PURE__*/function (_React$Component) {
10323
10901
  _inherits(GoodsList, _React$Component);
@@ -10333,7 +10911,7 @@ var GoodsList = /*#__PURE__*/function (_React$Component) {
10333
10911
  _createClass(GoodsList, [{
10334
10912
  key: "render",
10335
10913
  value: function render() {
10336
- return /*#__PURE__*/React.createElement(Main, _objectSpread2({}, this.props));
10914
+ return React.createElement(Main, _objectSpread2({}, this.props));
10337
10915
  }
10338
10916
  }]);
10339
10917
 
@@ -10348,6 +10926,15 @@ var Main = decorator(Form.create())(function (props) {
10348
10926
  var isprefab = controller.useMemo(function (s) {
10349
10927
  return s.model === 'prefab';
10350
10928
  }, []);
10929
+ var dataSource = controller.useMemo(function (s) {
10930
+ return s.goodsListState.goodsList;
10931
+ }, []);
10932
+ var searchValue = controller.useMemo(function (s) {
10933
+ return s.goodsListState.searchValue;
10934
+ }, []);
10935
+ var dataSourceSearch = React.useMemo(function () {
10936
+ return controller.getGoodsSearch(dataSource, searchValue);
10937
+ }, [dataSource, searchValue, controller]);
10351
10938
  /** 表格行事件 */
10352
10939
 
10353
10940
  var _onRow = useOnRow();
@@ -10358,8 +10945,8 @@ var Main = decorator(Form.create())(function (props) {
10358
10945
 
10359
10946
  React.useEffect(function () {
10360
10947
  controller.run( /*#__PURE__*/function () {
10361
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
10362
- return regeneratorRuntime.wrap(function _callee$(_context) {
10948
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
10949
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
10363
10950
  while (1) {
10364
10951
  switch (_context.prev = _context.next) {
10365
10952
  case 0:
@@ -10382,8 +10969,8 @@ var Main = decorator(Form.create())(function (props) {
10382
10969
 
10383
10970
  React.useEffect(function () {
10384
10971
  controller.pipeline( /*#__PURE__*/function () {
10385
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(s, form) {
10386
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
10972
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(s, form) {
10973
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
10387
10974
  while (1) {
10388
10975
  switch (_context2.prev = _context2.next) {
10389
10976
  case 0:
@@ -10407,8 +10994,8 @@ var Main = decorator(Form.create())(function (props) {
10407
10994
 
10408
10995
  React.useEffect(function () {
10409
10996
  controller.pipeline( /*#__PURE__*/function () {
10410
- var _ref3 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee3(s) {
10411
- return regeneratorRuntime.wrap(function _callee3$(_context3) {
10997
+ var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(s) {
10998
+ return _regeneratorRuntime().wrap(function _callee3$(_context3) {
10412
10999
  while (1) {
10413
11000
  switch (_context3.prev = _context3.next) {
10414
11001
  case 0:
@@ -10434,8 +11021,8 @@ var Main = decorator(Form.create())(function (props) {
10434
11021
 
10435
11022
  React.useEffect(function () {
10436
11023
  controller.pipeline( /*#__PURE__*/function () {
10437
- var _ref4 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee4(s) {
10438
- return regeneratorRuntime.wrap(function _callee4$(_context4) {
11024
+ var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(s) {
11025
+ return _regeneratorRuntime().wrap(function _callee4$(_context4) {
10439
11026
  while (1) {
10440
11027
  switch (_context4.prev = _context4.next) {
10441
11028
  case 0:
@@ -10458,8 +11045,8 @@ var Main = decorator(Form.create())(function (props) {
10458
11045
 
10459
11046
  React.useEffect(function () {
10460
11047
  controller.pipeline( /*#__PURE__*/function () {
10461
- var _ref5 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee5(s) {
10462
- return regeneratorRuntime.wrap(function _callee5$(_context5) {
11048
+ var _ref5 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(s) {
11049
+ return _regeneratorRuntime().wrap(function _callee5$(_context5) {
10463
11050
  while (1) {
10464
11051
  switch (_context5.prev = _context5.next) {
10465
11052
  case 0:
@@ -10482,8 +11069,8 @@ var Main = decorator(Form.create())(function (props) {
10482
11069
 
10483
11070
  React.useEffect(function () {
10484
11071
  controller.pipeline( /*#__PURE__*/function () {
10485
- var _ref6 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee6(s) {
10486
- return regeneratorRuntime.wrap(function _callee6$(_context6) {
11072
+ var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(s) {
11073
+ return _regeneratorRuntime().wrap(function _callee6$(_context6) {
10487
11074
  while (1) {
10488
11075
  switch (_context6.prev = _context6.next) {
10489
11076
  case 0:
@@ -10502,22 +11089,22 @@ var Main = decorator(Form.create())(function (props) {
10502
11089
  };
10503
11090
  }())();
10504
11091
  }, [controller, props.isSwitchTax]);
10505
- return /*#__PURE__*/React.createElement("div", {
11092
+ return React.createElement("div", {
10506
11093
  className: "kts-invoice-operate-goods-list",
10507
11094
  onClick: function onClick(e) {
10508
11095
  e.stopPropagation();
10509
11096
  }
10510
- }, /*#__PURE__*/React.createElement("div", {
11097
+ }, React.createElement("div", {
10511
11098
  className: "kts-invoice-operate-goods-list-able"
10512
- }, /*#__PURE__*/React.createElement("div", {
11099
+ }, React.createElement("div", {
10513
11100
  className: "kts-invoice-operate-goods-list-able-list"
10514
- }, /*#__PURE__*/React.createElement(AddRowButton, null), /*#__PURE__*/React.createElement(DelRowButton, null), /*#__PURE__*/React.createElement(AddDiscountRowButton, null), /*#__PURE__*/React.createElement(EndowCodeButton, null)), /*#__PURE__*/React.createElement("div", {
11101
+ }, React.createElement(AddRowButton, null), React.createElement(DelRowButton, null), React.createElement(AddDiscountRowButton, null), React.createElement(EndowCodeButton, null), React.createElement(Search, null)), React.createElement("div", {
10515
11102
  className: "kts-invoice-operate-goods-list-able-extend"
10516
- }, props.menuExpansion, /*#__PURE__*/React.createElement(TaxIncludedSwitch, null))), /*#__PURE__*/React.createElement("div", {
11103
+ }, props.menuExpansion, React.createElement(TaxIncludedSwitch, null))), React.createElement("div", {
10517
11104
  className: classnames('kts-invoice-operate-goods-list-table', {
10518
11105
  'kts-invoice-operate-prefab': isprefab
10519
11106
  })
10520
- }, /*#__PURE__*/React.createElement(TableVirtual, {
11107
+ }, React.createElement(TableVirtual, {
10521
11108
  bordered: true,
10522
11109
  size: "small",
10523
11110
  rowKey: "$index",
@@ -10530,9 +11117,7 @@ var Main = decorator(Form.create())(function (props) {
10530
11117
  row: TableRow
10531
11118
  }
10532
11119
  },
10533
- dataSource: controller.useMemo(function (s) {
10534
- return s.goodsListState.goodsList;
10535
- }, [controller]),
11120
+ dataSource: dataSourceSearch,
10536
11121
  columns: useColumns(props.form),
10537
11122
  rowSelection: useRowSelection(),
10538
11123
  onRow: function onRow(record) {
@@ -10542,11 +11127,11 @@ var Main = decorator(Form.create())(function (props) {
10542
11127
  }
10543
11128
  };
10544
11129
  }
10545
- })), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Statistics, null)));
11130
+ })), React.createElement("div", null, React.createElement(Statistics, null)));
10546
11131
  });
10547
11132
 
10548
- var css_248z$7 = ".kts-invoice-operate-seller {\n display: flex;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message {\n flex: 1;\n display: flex;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .ktsAnt3x-descriptions-item-label {\n width: 179px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list {\n width: 100%;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-view {\n border: none;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-label {\n padding: 0 10px;\n font-size: 12px;\n background-color: #fff;\n line-height: 30px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-label::before {\n content: '*';\n position: relative;\n color: red;\n font-weight: bold;\n margin-right: 2px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content {\n padding: 0;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content .ktsAnt3x-input {\n box-shadow: none;\n border-color: #fff;\n border-radius: 0;\n padding: 0 10px;\n font-size: 12px;\n line-height: 30px;\n width: 100%;\n height: 30px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content .ktsAnt3x-input:hover {\n border: 1 solid;\n border-color: #40a9ff;\n border-right-width: 1px !important;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content .has-error .ktsAnt3x-input,\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content .has-error .ktsAnt3x-input:hover {\n background-color: #fff;\n border: 1 solid;\n border-color: #f5222d;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-form-item {\n margin: 0;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-form-item-control {\n line-height: 0;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-form-explain {\n position: absolute;\n right: 5px;\n top: 6px;\n z-index: 10;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-remarks {\n border-left: 1px solid #dcdcdc;\n display: flex;\n flex: none;\n width: 458px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-remarks-value {\n flex: 1;\n display: flex;\n flex-direction: column;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-remarks-value textarea {\n flex: 1;\n margin-bottom: 0;\n border: none;\n border-radius: 0;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-title {\n flex: none;\n width: 30px;\n height: 100%;\n text-align: center;\n border-right: 1px solid #dcdcdc;\n display: table;\n padding: 0 5px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-title label {\n display: table-cell;\n vertical-align: middle;\n}\n";
10549
- styleInject(css_248z$7);
11133
+ var css_248z$8 = ".kts-invoice-operate-seller {\n display: flex;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message {\n flex: 1;\n display: flex;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .ktsAnt3x-descriptions-item-label {\n width: 179px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list {\n width: 100%;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-view {\n border: none;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-label {\n padding: 0 10px;\n font-size: 12px;\n background-color: #fff;\n line-height: 30px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-label::before {\n content: '*';\n position: relative;\n color: red;\n font-weight: bold;\n margin-right: 2px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content {\n padding: 0;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content .ktsAnt3x-input {\n box-shadow: none;\n border-color: #fff;\n border-radius: 0;\n padding: 0 10px;\n font-size: 12px;\n line-height: 30px;\n width: 100%;\n height: 30px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content .ktsAnt3x-input:hover {\n border: 1 solid;\n border-color: #40a9ff;\n border-right-width: 1px !important;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content .has-error .ktsAnt3x-input,\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-descriptions-item-content .has-error .ktsAnt3x-input:hover {\n background-color: #fff;\n border: 1 solid;\n border-color: #f5222d;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-form-item {\n margin: 0;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-form-item-control {\n line-height: 0;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-message .kts-invoice-operate-seller-message-list .ktsAnt3x-form-explain {\n position: absolute;\n right: 5px;\n top: 6px;\n z-index: 10;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-remarks {\n border-left: 1px solid #dcdcdc;\n display: flex;\n flex: none;\n width: 458px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-remarks-value {\n flex: 1;\n display: flex;\n flex-direction: column;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-remarks-value textarea {\n flex: 1;\n margin-bottom: 0;\n border: none;\n border-radius: 0;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-title {\n flex: none;\n width: 30px;\n height: 100%;\n text-align: center;\n border-right: 1px solid #dcdcdc;\n display: table;\n padding: 0 5px;\n}\n.kts-invoice-operate-seller .kts-invoice-operate-seller-title label {\n display: table-cell;\n vertical-align: middle;\n}\n";
11134
+ styleInject(css_248z$8);
10550
11135
 
10551
11136
  var TextArea = Input.TextArea;
10552
11137
 
@@ -10567,13 +11152,13 @@ var Buyer = /*#__PURE__*/function (_React$Component) {
10567
11152
  _this = _super.call.apply(_super, [this].concat(args));
10568
11153
 
10569
11154
  _this.render = function () {
10570
- return /*#__PURE__*/React.createElement(Main$1, _objectSpread2({}, _this.props));
11155
+ return React.createElement(Main$1, _objectSpread2({}, _this.props));
10571
11156
  };
10572
11157
 
10573
11158
  return _this;
10574
11159
  }
10575
11160
 
10576
- return Buyer;
11161
+ return _createClass(Buyer);
10577
11162
  }(React.Component);
10578
11163
  var Main$1 = decorator(Form.create())(function (props) {
10579
11164
  var form = props.form;
@@ -10598,7 +11183,7 @@ var Main$1 = decorator(Form.create())(function (props) {
10598
11183
  return [{
10599
11184
  id: 'sellerName',
10600
11185
  label: '销售方名称',
10601
- node: /*#__PURE__*/React.createElement(Input, {
11186
+ node: React.createElement(Input, {
10602
11187
  readOnly: model === 'prefab',
10603
11188
  size: "small"
10604
11189
  }),
@@ -10611,7 +11196,7 @@ var Main$1 = decorator(Form.create())(function (props) {
10611
11196
  }, {
10612
11197
  id: 'sellerNo',
10613
11198
  label: '销售方纳税人识别号',
10614
- node: /*#__PURE__*/React.createElement(Input, {
11199
+ node: React.createElement(Input, {
10615
11200
  readOnly: model === 'prefab',
10616
11201
  size: "small"
10617
11202
  }),
@@ -10624,7 +11209,7 @@ var Main$1 = decorator(Form.create())(function (props) {
10624
11209
  }, {
10625
11210
  id: 'sellerAddress',
10626
11211
  label: '销售方地址及电话',
10627
- node: /*#__PURE__*/React.createElement(Input, {
11212
+ node: React.createElement(Input, {
10628
11213
  readOnly: model === 'prefab',
10629
11214
  size: "small"
10630
11215
  }),
@@ -10637,7 +11222,7 @@ var Main$1 = decorator(Form.create())(function (props) {
10637
11222
  }, {
10638
11223
  id: 'sellerBank',
10639
11224
  label: '销售方开户行及账号',
10640
- node: /*#__PURE__*/React.createElement(Input, {
11225
+ node: React.createElement(Input, {
10641
11226
  readOnly: model === 'prefab',
10642
11227
  size: "small"
10643
11228
  }),
@@ -10663,35 +11248,35 @@ var Main$1 = decorator(Form.create())(function (props) {
10663
11248
  return getFieldDecorator(e.id, e.options)(e.node);
10664
11249
  }
10665
11250
  }, [props.formRender]);
10666
- return /*#__PURE__*/React.createElement(Form, null, /*#__PURE__*/React.createElement("div", {
11251
+ return React.createElement(Form, null, React.createElement("div", {
10667
11252
  className: "kts-invoice-operate-seller"
10668
- }, /*#__PURE__*/React.createElement("div", {
11253
+ }, React.createElement("div", {
10669
11254
  className: "kts-invoice-operate-seller-message"
10670
- }, /*#__PURE__*/React.createElement("div", {
11255
+ }, React.createElement("div", {
10671
11256
  className: "kts-invoice-operate-seller-title"
10672
- }, /*#__PURE__*/React.createElement("label", null, "\u9500\u552E\u65B9")), /*#__PURE__*/React.createElement(Descriptions, {
11257
+ }, React.createElement("label", null, "\u9500\u552E\u65B9")), React.createElement(Descriptions, {
10673
11258
  className: "kts-invoice-operate-seller-message-list",
10674
11259
  size: "small",
10675
11260
  column: 1,
10676
11261
  bordered: true
10677
11262
  }, formItem.map(function (e, i) {
10678
- return /*#__PURE__*/React.createElement(Descriptions.Item, {
11263
+ return React.createElement(Descriptions.Item, {
10679
11264
  key: i,
10680
11265
  label: e.label
10681
- }, /*#__PURE__*/React.createElement(Form.Item, null, createFormItem(e)));
10682
- }))), /*#__PURE__*/React.createElement("div", {
11266
+ }, React.createElement(Form.Item, null, createFormItem(e)));
11267
+ }))), React.createElement("div", {
10683
11268
  className: "kts-invoice-operate-seller-remarks"
10684
- }, /*#__PURE__*/React.createElement("div", {
11269
+ }, React.createElement("div", {
10685
11270
  className: "kts-invoice-operate-seller-title"
10686
- }, /*#__PURE__*/React.createElement("label", null, "\u5907\u6CE8")), /*#__PURE__*/React.createElement("div", {
11271
+ }, React.createElement("label", null, "\u5907\u6CE8")), React.createElement("div", {
10687
11272
  className: "kts-invoice-operate-seller-remarks-value"
10688
11273
  }, getFieldDecorator('remarks', {
10689
11274
  initialValue: props.defaultsellerRemarks
10690
- })( /*#__PURE__*/React.createElement(TextArea, null))))));
11275
+ })(React.createElement(TextArea, null))))));
10691
11276
  });
10692
11277
 
10693
- var css_248z$8 = ".kts-invoice-operate-sign form {\n display: flex;\n}\n.kts-invoice-operate-sign form .ktsAnt3x-row.ktsAnt3x-form-item {\n margin: 0;\n}\n.kts-invoice-operate-sign form > div {\n flex: 1;\n text-align: center;\n}\n";
10694
- styleInject(css_248z$8);
11278
+ var css_248z$9 = ".kts-invoice-operate-sign form {\n display: flex;\n}\n.kts-invoice-operate-sign form .ktsAnt3x-row.ktsAnt3x-form-item {\n margin: 0;\n}\n.kts-invoice-operate-sign form > div {\n flex: 1;\n text-align: center;\n}\n";
11279
+ styleInject(css_248z$9);
10695
11280
 
10696
11281
  var Sign = decorator(Form.create())(function (props) {
10697
11282
  var form = props.form;
@@ -10704,21 +11289,21 @@ var Sign = decorator(Form.create())(function (props) {
10704
11289
  }, []); // 注册 form
10705
11290
 
10706
11291
  controller.useForm('sign', form);
10707
- return /*#__PURE__*/React.createElement("div", {
11292
+ return React.createElement("div", {
10708
11293
  className: "kts-invoice-operate-sign"
10709
- }, /*#__PURE__*/React.createElement(Form, _objectSpread2({}, formItemLayout), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Form.Item, {
11294
+ }, React.createElement(Form, _objectSpread2({}, formItemLayout), React.createElement("div", null, React.createElement(Form.Item, {
10710
11295
  label: "\u6536\u6B3E\u4EBA"
10711
11296
  }, getFieldDecorator('payee', {
10712
11297
  initialValue: props.defaultPayee
10713
- })( /*#__PURE__*/React.createElement(Input, {
11298
+ })(React.createElement(Input, {
10714
11299
  size: "small"
10715
- })))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Form.Item, {
11300
+ })))), React.createElement("div", null, React.createElement(Form.Item, {
10716
11301
  label: "\u590D\u6838\u4EBA"
10717
11302
  }, getFieldDecorator('reviewer', {
10718
11303
  initialValue: props.defaultReviewer
10719
- })( /*#__PURE__*/React.createElement(Input, {
11304
+ })(React.createElement(Input, {
10720
11305
  size: "small"
10721
- })))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Form.Item, {
11306
+ })))), React.createElement("div", null, React.createElement(Form.Item, {
10722
11307
  label: "\u5F00\u7968\u4EBA"
10723
11308
  }, getFieldDecorator('issuer', {
10724
11309
  initialValue: props.defaultIssuer,
@@ -10726,7 +11311,7 @@ var Sign = decorator(Form.create())(function (props) {
10726
11311
  required: true,
10727
11312
  message: '请输入开票人'
10728
11313
  }]
10729
- })( /*#__PURE__*/React.createElement(Input, {
11314
+ })(React.createElement(Input, {
10730
11315
  size: "small"
10731
11316
  }))))));
10732
11317
  });
@@ -10743,8 +11328,8 @@ var ImportBuyerButton = (function () {
10743
11328
  var controller = default_1.useInvoiceController();
10744
11329
  var onClick = React.useCallback(function () {
10745
11330
  controller.pipeline( /*#__PURE__*/function () {
10746
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
10747
- return regeneratorRuntime.wrap(function _callee$(_context) {
11331
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
11332
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
10748
11333
  while (1) {
10749
11334
  switch (_context.prev = _context.next) {
10750
11335
  case 0:
@@ -10763,7 +11348,7 @@ var ImportBuyerButton = (function () {
10763
11348
  };
10764
11349
  }())();
10765
11350
  }, [controller]);
10766
- return /*#__PURE__*/React.createElement(React.Fragment, null, controller.getBuyerList && /*#__PURE__*/React.createElement(Button, {
11351
+ return React.createElement(React.Fragment, null, controller.getBuyerList && React.createElement(Button, {
10767
11352
  type: "link",
10768
11353
  icon: "plus-circle",
10769
11354
  onClick: onClick
@@ -10802,29 +11387,29 @@ var BuyerNameInput = (function (props) {
10802
11387
  var content = React.useMemo(function () {
10803
11388
  var _dataSource$recent;
10804
11389
 
10805
- return /*#__PURE__*/React.createElement("div", {
11390
+ return React.createElement("div", {
10806
11391
  className: 'kts-invoice-operate-buyer-name-content'
10807
- }, loading ? /*#__PURE__*/React.createElement("div", {
11392
+ }, loading ? React.createElement("div", {
10808
11393
  style: {
10809
11394
  textAlign: 'center'
10810
11395
  }
10811
- }, /*#__PURE__*/React.createElement(Spin, null)) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
11396
+ }, React.createElement(Spin, null)) : React.createElement(React.Fragment, null, React.createElement("div", {
10812
11397
  className: 'kts-invoice-operate-buyer-name-content-block',
10813
11398
  style: {
10814
11399
  padding: '14px 10px'
10815
11400
  }
10816
- }, /*#__PURE__*/React.createElement("label", {
11401
+ }, React.createElement("label", {
10817
11402
  style: {
10818
11403
  marginBottom: 10
10819
11404
  }
10820
- }, "\u6700\u8FD1\u5F00\u5177"), /*#__PURE__*/React.createElement("ul", {
11405
+ }, "\u6700\u8FD1\u5F00\u5177"), React.createElement("ul", {
10821
11406
  className: 'kts-invoice-operate-buyer-name-content-recently-issued'
10822
- }, !dataSource.recent || dataSource.recent.length <= 0 ? /*#__PURE__*/React.createElement(Empty, {
11407
+ }, !dataSource.recent || dataSource.recent.length <= 0 ? React.createElement(Empty, {
10823
11408
  image: Empty.PRESENTED_IMAGE_SIMPLE
10824
11409
  }) : (_dataSource$recent = dataSource.recent) === null || _dataSource$recent === void 0 ? void 0 : _dataSource$recent.map(function (e, i) {
10825
11410
  var _dataSource$recent$le, _dataSource$recent2;
10826
11411
 
10827
- return /*#__PURE__*/React.createElement("li", {
11412
+ return React.createElement("li", {
10828
11413
  key: i,
10829
11414
  onClick: function onClick() {
10830
11415
  onClickItem(e);
@@ -10832,37 +11417,37 @@ var BuyerNameInput = (function (props) {
10832
11417
  style: {
10833
11418
  marginBottom: interval(i, (_dataSource$recent$le = (_dataSource$recent2 = dataSource.recent) === null || _dataSource$recent2 === void 0 ? void 0 : _dataSource$recent2.length) !== null && _dataSource$recent$le !== void 0 ? _dataSource$recent$le : 0)
10834
11419
  }
10835
- }, /*#__PURE__*/React.createElement(MyTag, null, e.buyerName));
10836
- }))), /*#__PURE__*/React.createElement(Divider, {
11420
+ }, React.createElement(MyTag, null, e.buyerName));
11421
+ }))), React.createElement(Divider, {
10837
11422
  style: {
10838
11423
  margin: "0 6px"
10839
11424
  }
10840
- }), /*#__PURE__*/React.createElement("div", {
11425
+ }), React.createElement("div", {
10841
11426
  className: 'kts-invoice-operate-buyer-name-content-block',
10842
11427
  style: {
10843
11428
  padding: '14px 10px 4px'
10844
11429
  }
10845
- }, /*#__PURE__*/React.createElement("label", {
11430
+ }, React.createElement("label", {
10846
11431
  style: {
10847
11432
  padding: '0 10px'
10848
11433
  }
10849
- }, "\u9009\u62E9\u516C\u53F8"), /*#__PURE__*/React.createElement("div", {
11434
+ }, "\u9009\u62E9\u516C\u53F8"), React.createElement("div", {
10850
11435
  style: {
10851
11436
  maxHeight: 200,
10852
11437
  overflow: "auto"
10853
11438
  }
10854
- }, !dataSource.list || dataSource.list.length <= 0 ? /*#__PURE__*/React.createElement(Empty, {
11439
+ }, !dataSource.list || dataSource.list.length <= 0 ? React.createElement(Empty, {
10855
11440
  image: Empty.PRESENTED_IMAGE_SIMPLE
10856
11441
  }) : dataSource.list.map(function (e, i) {
10857
- return /*#__PURE__*/React.createElement("ul", {
11442
+ return React.createElement("ul", {
10858
11443
  key: i,
10859
11444
  onClick: function onClick() {
10860
11445
  onClickItem(e);
10861
11446
  },
10862
11447
  className: 'kts-invoice-operate-buyer-name-content-select-company'
10863
- }, /*#__PURE__*/React.createElement("li", {
11448
+ }, React.createElement("li", {
10864
11449
  title: e.buyerName
10865
- }, e.buyerName), /*#__PURE__*/React.createElement("li", {
11450
+ }, e.buyerName), React.createElement("li", {
10866
11451
  title: e.buyerNo
10867
11452
  }, e.buyerNo));
10868
11453
  })))));
@@ -10870,10 +11455,10 @@ var BuyerNameInput = (function (props) {
10870
11455
  /** 点击了选择项 */
10871
11456
 
10872
11457
  var onClickItem = React.useCallback( /*#__PURE__*/function () {
10873
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(e) {
11458
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(e) {
10874
11459
  var _controller$formList$;
10875
11460
 
10876
- return regeneratorRuntime.wrap(function _callee$(_context) {
11461
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
10877
11462
  while (1) {
10878
11463
  switch (_context.prev = _context.next) {
10879
11464
  case 0:
@@ -10903,7 +11488,7 @@ var BuyerNameInput = (function (props) {
10903
11488
  }, [visible, props.value]);
10904
11489
 
10905
11490
  if (model === 'prefab' || !autoContainer) {
10906
- return /*#__PURE__*/React.createElement(Input, {
11491
+ return React.createElement(Input, {
10907
11492
  size: "small",
10908
11493
  autoComplete: "off",
10909
11494
  value: props.value,
@@ -10914,14 +11499,14 @@ var BuyerNameInput = (function (props) {
10914
11499
  });
10915
11500
  }
10916
11501
 
10917
- return /*#__PURE__*/React.createElement(Popover, {
11502
+ return React.createElement(Popover, {
10918
11503
  onVisibleChange: setVisible,
10919
11504
  overlayClassName: 'kts-invoice-operate-buyer-name-popover',
10920
11505
  placement: "bottomLeft",
10921
11506
  trigger: "click",
10922
11507
  visible: visible,
10923
11508
  content: content
10924
- }, /*#__PURE__*/React.createElement(Input, {
11509
+ }, React.createElement(Input, {
10925
11510
  size: "small",
10926
11511
  autoComplete: "off",
10927
11512
  value: props.value,
@@ -10951,8 +11536,8 @@ function useDataSource() {
10951
11536
  return s.buyerState.autoContainer;
10952
11537
  }, []);
10953
11538
  var onBuyNameChange = React.useCallback( /*#__PURE__*/function () {
10954
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(e) {
10955
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
11539
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(e) {
11540
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
10956
11541
  while (1) {
10957
11542
  switch (_context2.prev = _context2.next) {
10958
11543
  case 0:
@@ -10999,7 +11584,7 @@ function useDataSource() {
10999
11584
  }
11000
11585
 
11001
11586
  function MyTag(props) {
11002
- return /*#__PURE__*/React.createElement("span", {
11587
+ return React.createElement("span", {
11003
11588
  className: 'kts-invoice-operate-buyer-name-content-tag',
11004
11589
  title: props.children
11005
11590
  }, props.children);
@@ -11013,8 +11598,8 @@ function interval(i, t) {
11013
11598
  }
11014
11599
  }
11015
11600
 
11016
- var css_248z$9 = ".kts-invoice-operate-buyer {\n display: flex;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message {\n flex: 1;\n display: flex;\n position: relative;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .ktsAnt3x-descriptions-item-label {\n width: 179px;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list {\n width: 100%;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-view {\n border: none;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-label {\n padding: 0 10px;\n font-size: 12px;\n background-color: #fff;\n line-height: 30px;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content {\n padding: 0;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content .ktsAnt3x-input {\n box-shadow: none;\n border-color: #fff;\n border-radius: 0;\n padding: 0 10px;\n font-size: 12px;\n line-height: 30px;\n width: 100%;\n height: 100%;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content .ktsAnt3x-input:hover {\n border: 1 solid;\n border-color: #40a9ff;\n border-right-width: 1px !important;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content .has-error .ktsAnt3x-input,\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content .has-error .ktsAnt3x-input:hover {\n background-color: #fff;\n border: 1 solid;\n border-color: #f5222d;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-item {\n margin: 0;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-item-control {\n line-height: 0;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-item-children {\n height: 30px;\n display: block;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-item-children .ktsAnt3x-btn {\n line-height: 0;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-explain {\n position: absolute;\n left: 5px;\n top: 6px;\n z-index: 10;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-Import {\n position: absolute;\n right: 0px;\n top: 0px;\n z-index: 10;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-password {\n border-left: 1px solid #dcdcdc;\n display: flex;\n flex: none;\n width: 458px;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-title {\n flex: none;\n width: 30px;\n height: 100%;\n text-align: center;\n border-right: 1px solid #dcdcdc;\n display: table;\n padding: 0 5px;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-title label {\n display: table-cell;\n vertical-align: middle;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover {\n padding-top: 0;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .ktsAnt3x-popover-inner-content {\n padding: 6px 0;\n display: flex;\n flex-direction: column;\n overflow-y: auto;\n overflow-x: hidden;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .ktsAnt3x-popover-arrow {\n display: none;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content {\n width: 567px;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-block {\n padding: 14px 0;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-block label {\n display: block;\n font-size: 12px;\n color: #666666;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-recently-issued {\n padding: 0;\n margin: 0;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-recently-issued li {\n list-style: none;\n width: 50%;\n float: left;\n margin-bottom: 20px;\n padding: 0 10px;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-recently-issued::after {\n content: \".\";\n display: block;\n height: 0;\n clear: left;\n visibility: hidden;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company {\n padding: 0;\n margin: 0;\n font-size: 12px;\n padding: 10px;\n font-weight: bold;\n color: #000000;\n cursor: pointer;\n transition: background 0.4s;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company:hover {\n background: #e6e6e6e6;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company:last-child {\n margin-bottom: 0;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company li {\n list-style: none;\n width: 50%;\n float: left;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n padding-right: 10px;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company::after {\n content: \".\";\n display: block;\n height: 0;\n clear: left;\n visibility: hidden;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content-tag {\n line-height: 1;\n padding: 4px 12px;\n background: #F3F3F3;\n border-radius: 9999px;\n font-size: 12px;\n font-weight: bold;\n color: #000;\n cursor: pointer;\n transition: background 0.4s;\n display: inline-block;\n max-width: 100%;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content-tag:hover {\n background: #e6e6e6e6;\n}\n";
11017
- styleInject(css_248z$9);
11601
+ var css_248z$a = ".kts-invoice-operate-buyer {\n display: flex;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message {\n flex: 1;\n display: flex;\n position: relative;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .ktsAnt3x-descriptions-item-label {\n width: 179px;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list {\n width: 100%;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-view {\n border: none;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-label {\n padding: 0 10px;\n font-size: 12px;\n background-color: #fff;\n line-height: 30px;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content {\n padding: 0;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content .ktsAnt3x-input {\n box-shadow: none;\n border-color: #fff;\n border-radius: 0;\n padding: 0 10px;\n font-size: 12px;\n line-height: 30px;\n width: 100%;\n height: 100%;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content .ktsAnt3x-input:hover {\n border: 1 solid;\n border-color: #40a9ff;\n border-right-width: 1px !important;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content .has-error .ktsAnt3x-input,\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-descriptions-item-content .has-error .ktsAnt3x-input:hover {\n background-color: #fff;\n border: 1 solid;\n border-color: #f5222d;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-item {\n margin: 0;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-item-control {\n line-height: 0;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-item-children {\n height: 30px;\n display: block;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-item-children .ktsAnt3x-btn {\n line-height: 0;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-list .ktsAnt3x-form-explain {\n position: absolute;\n left: 5px;\n top: 6px;\n z-index: 10;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-message .kts-invoice-operate-buyer-message-Import {\n position: absolute;\n right: 0px;\n top: 0px;\n z-index: 10;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-password {\n border-left: 1px solid #dcdcdc;\n display: flex;\n flex: none;\n width: 458px;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-title {\n flex: none;\n width: 30px;\n height: 100%;\n text-align: center;\n border-right: 1px solid #dcdcdc;\n display: table;\n padding: 0 5px;\n}\n.kts-invoice-operate-buyer .kts-invoice-operate-buyer-title label {\n display: table-cell;\n vertical-align: middle;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover {\n padding-top: 0;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .ktsAnt3x-popover-inner-content {\n padding: 6px 0;\n display: flex;\n flex-direction: column;\n overflow-y: auto;\n overflow-x: hidden;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .ktsAnt3x-popover-arrow {\n display: none;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content {\n width: 567px;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-block {\n padding: 14px 0;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-block label {\n display: block;\n font-size: 12px;\n color: #666666;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-recently-issued {\n padding: 0;\n margin: 0;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-recently-issued li {\n list-style: none;\n width: 50%;\n float: left;\n margin-bottom: 20px;\n padding: 0 10px;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-recently-issued::after {\n content: \".\";\n display: block;\n height: 0;\n clear: left;\n visibility: hidden;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company {\n padding: 0;\n margin: 0;\n font-size: 12px;\n padding: 10px;\n font-weight: bold;\n color: #000000;\n cursor: pointer;\n transition: background 0.4s;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company:hover {\n background: #e6e6e6e6;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company:last-child {\n margin-bottom: 0;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company li {\n list-style: none;\n width: 50%;\n float: left;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n padding-right: 10px;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content .kts-invoice-operate-buyer-name-content-select-company::after {\n content: \".\";\n display: block;\n height: 0;\n clear: left;\n visibility: hidden;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content-tag {\n line-height: 1;\n padding: 4px 12px;\n background: #F3F3F3;\n border-radius: 9999px;\n font-size: 12px;\n font-weight: bold;\n color: #000;\n cursor: pointer;\n transition: background 0.4s;\n display: inline-block;\n max-width: 100%;\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n}\n.ktsAnt3x-popover.kts-invoice-operate-buyer-name-popover .kts-invoice-operate-buyer-name-content-tag:hover {\n background: #e6e6e6e6;\n}\n";
11602
+ styleInject(css_248z$a);
11018
11603
 
11019
11604
  var Text$5 = Typography.Text;
11020
11605
 
@@ -11035,13 +11620,13 @@ var Buyer$1 = /*#__PURE__*/function (_React$Component) {
11035
11620
  _this = _super.call.apply(_super, [this].concat(args));
11036
11621
 
11037
11622
  _this.render = function () {
11038
- return /*#__PURE__*/React.createElement(Main$2, _objectSpread2({}, _this.props));
11623
+ return React.createElement(Main$2, _objectSpread2({}, _this.props));
11039
11624
  };
11040
11625
 
11041
11626
  return _this;
11042
11627
  }
11043
11628
 
11044
- return Buyer;
11629
+ return _createClass(Buyer);
11045
11630
  }(React.Component);
11046
11631
  var Main$2 = decorator(Form.create())(function (props) {
11047
11632
  var form = props.form;
@@ -11066,7 +11651,7 @@ var Main$2 = decorator(Form.create())(function (props) {
11066
11651
  return [{
11067
11652
  id: 'buyerName',
11068
11653
  label: '购买方名称',
11069
- node: /*#__PURE__*/React.createElement(Input, {
11654
+ node: React.createElement(Input, {
11070
11655
  size: "small",
11071
11656
  autoComplete: "off",
11072
11657
  readOnly: model === 'prefab'
@@ -11080,7 +11665,7 @@ var Main$2 = decorator(Form.create())(function (props) {
11080
11665
  }, {
11081
11666
  id: 'buyerNo',
11082
11667
  label: '购买方纳税人识别号',
11083
- node: /*#__PURE__*/React.createElement(Input, {
11668
+ node: React.createElement(Input, {
11084
11669
  size: "small",
11085
11670
  autoComplete: "off",
11086
11671
  readOnly: model === 'prefab'
@@ -11094,7 +11679,7 @@ var Main$2 = decorator(Form.create())(function (props) {
11094
11679
  }, {
11095
11680
  id: 'buyerAddress',
11096
11681
  label: '购买方地址及电话',
11097
- node: /*#__PURE__*/React.createElement(Input, {
11682
+ node: React.createElement(Input, {
11098
11683
  size: "small",
11099
11684
  autoComplete: "off",
11100
11685
  readOnly: model === 'prefab'
@@ -11108,7 +11693,7 @@ var Main$2 = decorator(Form.create())(function (props) {
11108
11693
  }, {
11109
11694
  id: 'buyerBank',
11110
11695
  label: '购买方开户行及账号',
11111
- node: /*#__PURE__*/React.createElement(Input, {
11696
+ node: React.createElement(Input, {
11112
11697
  size: "small",
11113
11698
  autoComplete: "off",
11114
11699
  readOnly: model === 'prefab'
@@ -11130,7 +11715,7 @@ var Main$2 = decorator(Form.create())(function (props) {
11130
11715
  if (e.options.rules.some(function (e) {
11131
11716
  return e.required;
11132
11717
  })) {
11133
- return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Text$5, {
11718
+ return React.createElement(React.Fragment, null, React.createElement(Text$5, {
11134
11719
  type: "danger"
11135
11720
  }, "*"), e.label);
11136
11721
  } else {
@@ -11140,29 +11725,29 @@ var Main$2 = decorator(Form.create())(function (props) {
11140
11725
  return e.label;
11141
11726
  }
11142
11727
  }, []);
11143
- return /*#__PURE__*/React.createElement(Form, null, /*#__PURE__*/React.createElement("div", {
11728
+ return React.createElement(Form, null, React.createElement("div", {
11144
11729
  className: "kts-invoice-operate-buyer"
11145
- }, /*#__PURE__*/React.createElement("div", {
11730
+ }, React.createElement("div", {
11146
11731
  className: "kts-invoice-operate-buyer-message"
11147
- }, /*#__PURE__*/React.createElement("div", {
11732
+ }, React.createElement("div", {
11148
11733
  className: "kts-invoice-operate-buyer-title"
11149
- }, /*#__PURE__*/React.createElement("label", null, "\u8D2D\u4E70\u65B9")), /*#__PURE__*/React.createElement("div", {
11734
+ }, React.createElement("label", null, "\u8D2D\u4E70\u65B9")), React.createElement("div", {
11150
11735
  className: "kts-invoice-operate-buyer-message-Import"
11151
- }, model !== 'prefab' && /*#__PURE__*/React.createElement(ImportBuyerButton, null)), /*#__PURE__*/React.createElement(Descriptions, {
11736
+ }, model !== 'prefab' && React.createElement(ImportBuyerButton, null)), React.createElement(Descriptions, {
11152
11737
  className: "kts-invoice-operate-buyer-message-list",
11153
11738
  size: "small",
11154
11739
  column: 1,
11155
11740
  bordered: true
11156
11741
  }, formItem.map(function (item, i) {
11157
- return /*#__PURE__*/React.createElement(Descriptions.Item, {
11742
+ return React.createElement(Descriptions.Item, {
11158
11743
  key: i,
11159
11744
  label: getlabel(item)
11160
- }, /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator(item.id, item.options)(autoContainer ? item.id === 'buyerName' ? /*#__PURE__*/React.createElement(BuyerNameInput, null) : item.node : item.node)));
11161
- }))), /*#__PURE__*/React.createElement("div", {
11745
+ }, React.createElement(Form.Item, null, getFieldDecorator(item.id, item.options)(autoContainer ? item.id === 'buyerName' ? React.createElement(BuyerNameInput, null) : item.node : item.node)));
11746
+ }))), React.createElement("div", {
11162
11747
  className: "kts-invoice-operate-buyer-password"
11163
- }, /*#__PURE__*/React.createElement("div", {
11748
+ }, React.createElement("div", {
11164
11749
  className: "kts-invoice-operate-buyer-title"
11165
- }, /*#__PURE__*/React.createElement("label", null, "\u5BC6\u7801\u533A")), /*#__PURE__*/React.createElement("div", null))));
11750
+ }, React.createElement("label", null, "\u5BC6\u7801\u533A")), React.createElement("div", null))));
11166
11751
  });
11167
11752
 
11168
11753
  var ImportBuyerDrawer = (function () {
@@ -11176,8 +11761,8 @@ var ImportBuyerDrawer = (function () {
11176
11761
 
11177
11762
  var onClose = React.useCallback(function () {
11178
11763
  controller.pipeline( /*#__PURE__*/function () {
11179
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
11180
- return regeneratorRuntime.wrap(function _callee$(_context) {
11764
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
11765
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
11181
11766
  while (1) {
11182
11767
  switch (_context.prev = _context.next) {
11183
11768
  case 0:
@@ -11196,7 +11781,7 @@ var ImportBuyerDrawer = (function () {
11196
11781
  };
11197
11782
  }())();
11198
11783
  }, [controller]);
11199
- return /*#__PURE__*/React.createElement(Drawer, {
11784
+ return React.createElement(Drawer, {
11200
11785
  title: "\u8D2D\u65B9\u5217\u8868",
11201
11786
  placement: "right",
11202
11787
  // closable={false}
@@ -11204,7 +11789,7 @@ var ImportBuyerDrawer = (function () {
11204
11789
  width: 983,
11205
11790
  onClose: onClose,
11206
11791
  visible: visible
11207
- }, topExpand, /*#__PURE__*/React.createElement(DrawerBody$1, null));
11792
+ }, topExpand, React.createElement(DrawerBody$1, null));
11208
11793
  });
11209
11794
 
11210
11795
  var DrawerBody$1 = function DrawerBody() {
@@ -11225,7 +11810,7 @@ var DrawerBody$1 = function DrawerBody() {
11225
11810
  }
11226
11811
  });
11227
11812
  }, [controller]);
11228
- return /*#__PURE__*/React.createElement(Table, {
11813
+ return React.createElement(Table, {
11229
11814
  bordered: true,
11230
11815
  size: "small",
11231
11816
  columns: columns,
@@ -11239,10 +11824,10 @@ var DrawerBody$1 = function DrawerBody() {
11239
11824
  onRow: function onRow(record) {
11240
11825
  return {
11241
11826
  onClick: function () {
11242
- var _onClick = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee3() {
11827
+ var _onClick = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
11243
11828
  var re, _controller$formList$;
11244
11829
 
11245
- return regeneratorRuntime.wrap(function _callee3$(_context3) {
11830
+ return _regeneratorRuntime().wrap(function _callee3$(_context3) {
11246
11831
  while (1) {
11247
11832
  switch (_context3.prev = _context3.next) {
11248
11833
  case 0:
@@ -11255,8 +11840,8 @@ var DrawerBody$1 = function DrawerBody() {
11255
11840
  if (re) {
11256
11841
  (_controller$formList$ = controller.formList.get('buyer')) === null || _controller$formList$ === void 0 ? void 0 : _controller$formList$.setFieldsValue(re);
11257
11842
  controller.pipeline( /*#__PURE__*/function () {
11258
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(s) {
11259
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
11843
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(s) {
11844
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
11260
11845
  while (1) {
11261
11846
  switch (_context2.prev = _context2.next) {
11262
11847
  case 0:
@@ -11306,8 +11891,8 @@ var ImportGoodsDrawer = (function () {
11306
11891
  var onClose = React.useCallback(function () {
11307
11892
  console.log('===> 关闭抽屉');
11308
11893
  controller.pipeline( /*#__PURE__*/function () {
11309
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
11310
- return regeneratorRuntime.wrap(function _callee$(_context) {
11894
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
11895
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
11311
11896
  while (1) {
11312
11897
  switch (_context.prev = _context.next) {
11313
11898
  case 0:
@@ -11326,7 +11911,7 @@ var ImportGoodsDrawer = (function () {
11326
11911
  };
11327
11912
  }())();
11328
11913
  }, [controller]);
11329
- return /*#__PURE__*/React.createElement(Drawer, {
11914
+ return React.createElement(Drawer, {
11330
11915
  title: "\u5546\u54C1\u5217\u8868",
11331
11916
  placement: "right",
11332
11917
  // closable={false}
@@ -11334,11 +11919,11 @@ var ImportGoodsDrawer = (function () {
11334
11919
  width: 983,
11335
11920
  onClose: onClose,
11336
11921
  visible: visible
11337
- }, topExpand && /*#__PURE__*/React.createElement("div", {
11922
+ }, topExpand && React.createElement("div", {
11338
11923
  style: {
11339
11924
  marginBottom: 10
11340
11925
  }
11341
- }, topExpand), /*#__PURE__*/React.createElement(DrawerBody$2, null));
11926
+ }, topExpand), React.createElement(DrawerBody$2, null));
11342
11927
  });
11343
11928
 
11344
11929
  var DrawerBody$2 = function DrawerBody() {
@@ -11360,7 +11945,7 @@ var DrawerBody$2 = function DrawerBody() {
11360
11945
  }
11361
11946
  });
11362
11947
  }, [controller]);
11363
- return /*#__PURE__*/React.createElement(Table, {
11948
+ return React.createElement(Table, {
11364
11949
  bordered: true,
11365
11950
  size: "small",
11366
11951
  columns: columns,
@@ -11375,8 +11960,8 @@ var DrawerBody$2 = function DrawerBody() {
11375
11960
  return {
11376
11961
  onClick: function onClick() {
11377
11962
  controller.run( /*#__PURE__*/function () {
11378
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(s) {
11379
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
11963
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(s) {
11964
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
11380
11965
  while (1) {
11381
11966
  switch (_context2.prev = _context2.next) {
11382
11967
  case 0:
@@ -11522,8 +12107,8 @@ function cutStr(str, L) {
11522
12107
  }
11523
12108
  }
11524
12109
 
11525
- var css_248z$a = ".kts-invoice-operate-goods-endow-code-button-list {\n display: flex;\n flex-direction: column;\n}\n.kts-invoice-operate-goods-endow-code-button-list > button {\n margin-bottom: 10px;\n}\n";
11526
- styleInject(css_248z$a);
12110
+ var css_248z$b = ".kts-invoice-operate-goods-endow-code-button-list {\n display: flex;\n flex-direction: column;\n}\n.kts-invoice-operate-goods-endow-code-button-list > button {\n margin-bottom: 10px;\n}\n";
12111
+ styleInject(css_248z$b);
11527
12112
 
11528
12113
  var TreeNode = Tree.TreeNode;
11529
12114
  var confirm = Modal.confirm;
@@ -11540,8 +12125,8 @@ var EndowCodeDrawer = (function () {
11540
12125
 
11541
12126
  var onClose = React.useCallback(function () {
11542
12127
  controller.pipeline( /*#__PURE__*/function () {
11543
- var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(s) {
11544
- return regeneratorRuntime.wrap(function _callee$(_context) {
12128
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(s) {
12129
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
11545
12130
  while (1) {
11546
12131
  switch (_context.prev = _context.next) {
11547
12132
  case 0:
@@ -11564,9 +12149,9 @@ var EndowCodeDrawer = (function () {
11564
12149
  React.useEffect(function () {
11565
12150
  if (visible) {
11566
12151
  controller.pipeline( /*#__PURE__*/function () {
11567
- var _ref2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee2(s) {
12152
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(s) {
11568
12153
  var endowcodeGoodIndex, good, getDefaultValue;
11569
- return regeneratorRuntime.wrap(function _callee2$(_context2) {
12154
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
11570
12155
  while (1) {
11571
12156
  switch (_context2.prev = _context2.next) {
11572
12157
  case 0:
@@ -11627,7 +12212,7 @@ var EndowCodeDrawer = (function () {
11627
12212
  setDefaultValue(undefined);
11628
12213
  }
11629
12214
  }, [visible]);
11630
- return /*#__PURE__*/React.createElement(Drawer, {
12215
+ return React.createElement(Drawer, {
11631
12216
  title: "\u8D4B\u7801",
11632
12217
  placement: "right",
11633
12218
  destroyOnClose: true,
@@ -11635,7 +12220,7 @@ var EndowCodeDrawer = (function () {
11635
12220
  width: 383,
11636
12221
  onClose: onClose,
11637
12222
  visible: visible
11638
- }, defaultValue && /*#__PURE__*/React.createElement(DrawerBody$3, {
12223
+ }, defaultValue && React.createElement(DrawerBody$3, {
11639
12224
  defaultValue: defaultValue
11640
12225
  }));
11641
12226
  });
@@ -11696,9 +12281,9 @@ var DrawerBody$3 = function DrawerBody(props) {
11696
12281
  setDataSource = _React$useState6[1];
11697
12282
 
11698
12283
  var onSearch = React.useCallback( /*#__PURE__*/function () {
11699
- var _ref3 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee3(e) {
12284
+ var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(e) {
11700
12285
  var arr;
11701
- return regeneratorRuntime.wrap(function _callee3$(_context3) {
12286
+ return _regeneratorRuntime().wrap(function _callee3$(_context3) {
11702
12287
  while (1) {
11703
12288
  switch (_context3.prev = _context3.next) {
11704
12289
  case 0:
@@ -11731,8 +12316,8 @@ var DrawerBody$3 = function DrawerBody(props) {
11731
12316
  })[0];
11732
12317
  if (!info) return;
11733
12318
  !readOnlyTaxRate && actions.setFieldState('taxRate', /*#__PURE__*/function () {
11734
- var _ref4 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee4(s) {
11735
- return regeneratorRuntime.wrap(function _callee4$(_context4) {
12319
+ var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4(s) {
12320
+ return _regeneratorRuntime().wrap(function _callee4$(_context4) {
11736
12321
  while (1) {
11737
12322
  switch (_context4.prev = _context4.next) {
11738
12323
  case 0:
@@ -11753,8 +12338,8 @@ var DrawerBody$3 = function DrawerBody(props) {
11753
12338
  };
11754
12339
  }());
11755
12340
  actions.setFieldState('shorthand', /*#__PURE__*/function () {
11756
- var _ref5 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee5(s) {
11757
- return regeneratorRuntime.wrap(function _callee5$(_context5) {
12341
+ var _ref5 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(s) {
12342
+ return _regeneratorRuntime().wrap(function _callee5$(_context5) {
11758
12343
  while (1) {
11759
12344
  switch (_context5.prev = _context5.next) {
11760
12345
  case 0:
@@ -11775,7 +12360,7 @@ var DrawerBody$3 = function DrawerBody(props) {
11775
12360
  };
11776
12361
  }());
11777
12362
  }, [actions, dataSource, readOnlyTaxRate]);
11778
- return /*#__PURE__*/React.createElement(Select, _objectSpread2(_objectSpread2({}, props), {}, {
12363
+ return React.createElement(Select, _objectSpread2(_objectSpread2({}, props), {}, {
11779
12364
  showSearch: true,
11780
12365
  showArrow: false,
11781
12366
  notFoundContent: null,
@@ -11783,7 +12368,7 @@ var DrawerBody$3 = function DrawerBody(props) {
11783
12368
  onSearch: onSearch,
11784
12369
  onChange: onChange
11785
12370
  }), dataSource.map(function (e) {
11786
- return /*#__PURE__*/React.createElement(Select.Option, {
12371
+ return React.createElement(Select.Option, {
11787
12372
  key: e.value,
11788
12373
  value: e.value
11789
12374
  }, e.label);
@@ -11813,14 +12398,14 @@ var DrawerBody$3 = function DrawerBody(props) {
11813
12398
 
11814
12399
 
11815
12400
  var createTreeNode = React.useCallback(function () {
11816
- if (!list) return /*#__PURE__*/React.createElement(React.Fragment, null);
12401
+ if (!list) return React.createElement(React.Fragment, null);
11817
12402
  return ctn(list);
11818
12403
 
11819
12404
  function title(label) {
11820
12405
  if (!filter) return label;
11821
12406
  label = (filter.taxCategoryCode ? label.split(new RegExp(filter.taxCategoryCode, 'g')) : [label]).join("<span style=\"color: #1890ff;\">".concat(filter.taxCategoryCode, "</span>"));
11822
12407
  label = (filter.val ? label.split(new RegExp(filter.val, 'g')) : [label]).join("<span style=\"color: #1890ff;\">".concat(filter.val, "</span>"));
11823
- return /*#__PURE__*/React.createElement("span", {
12408
+ return React.createElement("span", {
11824
12409
  dangerouslySetInnerHTML: {
11825
12410
  __html: label
11826
12411
  }
@@ -11829,11 +12414,11 @@ var DrawerBody$3 = function DrawerBody(props) {
11829
12414
 
11830
12415
  function ctn(l) {
11831
12416
  var p = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '0';
11832
- if (!l || !l.length) return [/*#__PURE__*/React.createElement(React.Fragment, null)];
12417
+ if (!l || !l.length) return [React.createElement(React.Fragment, null)];
11833
12418
  return l.filter(function (e) {
11834
12419
  return e.pid === p;
11835
12420
  }).map(function (e) {
11836
- return /*#__PURE__*/React.createElement(TreeNode, {
12421
+ return React.createElement(TreeNode, {
11837
12422
  title: title(e.label),
11838
12423
  key: e.id
11839
12424
  }, ctn(l, e.id));
@@ -11855,8 +12440,8 @@ var DrawerBody$3 = function DrawerBody(props) {
11855
12440
  return e.id === id;
11856
12441
  })[0];
11857
12442
  !readOnlyTaxRate && actions.setFieldState('taxRate', /*#__PURE__*/function () {
11858
- var _ref6 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee6(s) {
11859
- return regeneratorRuntime.wrap(function _callee6$(_context6) {
12443
+ var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6(s) {
12444
+ return _regeneratorRuntime().wrap(function _callee6$(_context6) {
11860
12445
  while (1) {
11861
12446
  switch (_context6.prev = _context6.next) {
11862
12447
  case 0:
@@ -11877,8 +12462,8 @@ var DrawerBody$3 = function DrawerBody(props) {
11877
12462
  };
11878
12463
  }());
11879
12464
  actions.setFieldState('taxClassificationCode', /*#__PURE__*/function () {
11880
- var _ref7 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee7(s) {
11881
- return regeneratorRuntime.wrap(function _callee7$(_context7) {
12465
+ var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee7(s) {
12466
+ return _regeneratorRuntime().wrap(function _callee7$(_context7) {
11882
12467
  while (1) {
11883
12468
  switch (_context7.prev = _context7.next) {
11884
12469
  case 0:
@@ -11899,8 +12484,8 @@ var DrawerBody$3 = function DrawerBody(props) {
11899
12484
  };
11900
12485
  }());
11901
12486
  actions.setFieldState('shorthand', /*#__PURE__*/function () {
11902
- var _ref8 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee8(s) {
11903
- return regeneratorRuntime.wrap(function _callee8$(_context8) {
12487
+ var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee8(s) {
12488
+ return _regeneratorRuntime().wrap(function _callee8$(_context8) {
11904
12489
  while (1) {
11905
12490
  switch (_context8.prev = _context8.next) {
11906
12491
  case 0:
@@ -11923,14 +12508,14 @@ var DrawerBody$3 = function DrawerBody(props) {
11923
12508
  setVisible(false);
11924
12509
  }, [list, actions, readOnlyTaxRate]);
11925
12510
  React.useEffect(function () {
11926
- _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee10() {
12511
+ _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee10() {
11927
12512
  var fn, list;
11928
- return regeneratorRuntime.wrap(function _callee10$(_context10) {
12513
+ return _regeneratorRuntime().wrap(function _callee10$(_context10) {
11929
12514
  while (1) {
11930
12515
  switch (_context10.prev = _context10.next) {
11931
12516
  case 0:
11932
- fn = controller.state.goodsListState.endowCode.getTaxCategoryCodeTree || /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee9() {
11933
- return regeneratorRuntime.wrap(function _callee9$(_context9) {
12517
+ fn = controller.state.goodsListState.endowCode.getTaxCategoryCodeTree || /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee9() {
12518
+ return _regeneratorRuntime().wrap(function _callee9$(_context9) {
11934
12519
  while (1) {
11935
12520
  switch (_context9.prev = _context9.next) {
11936
12521
  case 0:
@@ -11963,46 +12548,46 @@ var DrawerBody$3 = function DrawerBody(props) {
11963
12548
  setList([]);
11964
12549
  }
11965
12550
  }, [visible]);
11966
- return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Input, {
12551
+ return React.createElement(React.Fragment, null, React.createElement(Input, {
11967
12552
  readOnly: true,
11968
12553
  value: props.value,
11969
- addonAfter: /*#__PURE__*/React.createElement(Button, {
12554
+ addonAfter: React.createElement(Button, {
11970
12555
  size: "small",
11971
12556
  type: "link",
11972
12557
  onClick: function onClick() {
11973
12558
  setVisible(true);
11974
12559
  }
11975
12560
  }, "\u70B9\u51FB\u9009\u62E9")
11976
- }), /*#__PURE__*/React.createElement(Drawer, {
12561
+ }), React.createElement(Drawer, {
11977
12562
  title: "\u7A0E\u6536\u5206\u7C7B\u7F16\u7801",
11978
12563
  visible: visible,
11979
12564
  width: 500,
11980
12565
  onClose: function onClose() {
11981
12566
  setVisible(false);
11982
12567
  }
11983
- }, /*#__PURE__*/React.createElement(Form, {
12568
+ }, React.createElement(Form, {
11984
12569
  key: "".concat(visible)
11985
- }, /*#__PURE__*/React.createElement(Form.Item, {
12570
+ }, React.createElement(Form.Item, {
11986
12571
  label: "\u4EA7\u54C1\u6216\u670D\u52A1\u7B80\u79F0"
11987
- }, /*#__PURE__*/React.createElement(Input, {
12572
+ }, React.createElement(Input, {
11988
12573
  onChange: function onChange(e) {
11989
12574
  setFilter(_objectSpread2(_objectSpread2({}, filter), {}, {
11990
12575
  val: e.target.value
11991
12576
  }));
11992
12577
  }
11993
- })), /*#__PURE__*/React.createElement(Form.Item, {
12578
+ })), React.createElement(Form.Item, {
11994
12579
  label: "\u7A0E\u6536\u5206\u7C7B\u7F16\u7801"
11995
- }, /*#__PURE__*/React.createElement(Input, {
12580
+ }, React.createElement(Input, {
11996
12581
  onChange: function onChange(e) {
11997
12582
  setFilter(_objectSpread2(_objectSpread2({}, filter), {}, {
11998
12583
  taxCategoryCode: e.target.value
11999
12584
  }));
12000
12585
  }
12001
- }))), list && list.length > 0 ? /*#__PURE__*/React.createElement(Tree, {
12586
+ }))), list && list.length > 0 ? React.createElement(Tree, {
12002
12587
  defaultExpandAll: true,
12003
12588
  selectedKeys: [],
12004
12589
  onSelect: onSelect
12005
- }, createTreeNode()) : /*#__PURE__*/React.createElement("span", {
12590
+ }, createTreeNode()) : React.createElement("span", {
12006
12591
  style: {
12007
12592
  color: '#00000073'
12008
12593
  }
@@ -12017,9 +12602,9 @@ var DrawerBody$3 = function DrawerBody(props) {
12017
12602
 
12018
12603
  var onSubmit = React.useCallback(function (values) {
12019
12604
  controller.pipeline( /*#__PURE__*/function () {
12020
- var _ref11 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee11(s) {
12605
+ var _ref11 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee11(s) {
12021
12606
  var endowCodeGood;
12022
- return regeneratorRuntime.wrap(function _callee11$(_context11) {
12607
+ return _regeneratorRuntime().wrap(function _callee11$(_context11) {
12023
12608
  while (1) {
12024
12609
  switch (_context11.prev = _context11.next) {
12025
12610
  case 0:
@@ -12039,17 +12624,20 @@ var DrawerBody$3 = function DrawerBody(props) {
12039
12624
  good.favouredPolicyName = values.favouredPolicyName;
12040
12625
  var taxRate = chain$1(bignumber(values.taxRate)).dotDivide(bignumber(100)).add(bignumber(1)).done(); // 是否含税
12041
12626
 
12042
- if (s.goodsListState.isTaxIncluded) {
12043
- var lineAmountExcludeTax = chain$1(bignumber(good.lineAmountIncludeTax)).dotDivide(taxRate).done();
12044
- var priceExcludeTax = good.priceIncludeTax ? chain$1(bignumber(good.priceIncludeTax)).dotDivide(taxRate).done() : undefined;
12045
- good.lineAmountExcludeTax = lineAmountExcludeTax.toNumber().toFixed(2);
12046
- good.priceExcludeTax = (priceExcludeTax ? format15(priceExcludeTax.toNumber()) : undefined) || undefined;
12047
- } else {
12048
- var lineAmountIncludeTax = chain$1(bignumber(good.lineAmountExcludeTax)).multiply(taxRate).done();
12049
- var priceIncludeTax = good.priceExcludeTax ? chain$1(bignumber(good.priceExcludeTax)).multiply(taxRate).done() : undefined;
12050
- good.lineAmountIncludeTax = lineAmountIncludeTax.toNumber().toFixed(2);
12051
- good.priceIncludeTax = (priceIncludeTax ? format15(priceIncludeTax.toNumber()) : undefined) || undefined;
12052
- }
12627
+ var lineAmountExcludeTax = chain$1(bignumber(good.lineAmountIncludeTax)).dotDivide(taxRate).done();
12628
+ var priceExcludeTax = good.priceIncludeTax ? chain$1(bignumber(good.priceIncludeTax)).dotDivide(taxRate).done() : undefined;
12629
+ good.lineAmountExcludeTax = lineAmountExcludeTax.toNumber().toFixed(2);
12630
+ good.priceExcludeTax = (priceExcludeTax ? format15(priceExcludeTax.toNumber()) : undefined) || undefined; // if (s.goodsListState.isTaxIncluded) {
12631
+ // const lineAmountExcludeTax = chain(bignumber(good.lineAmountIncludeTax)).dotDivide(taxRate).done();
12632
+ // const priceExcludeTax = good.priceIncludeTax ? chain(bignumber(good.priceIncludeTax)).dotDivide(taxRate).done() : undefined
12633
+ // good.lineAmountExcludeTax = lineAmountExcludeTax.toNumber().toFixed(2);
12634
+ // good.priceExcludeTax = (priceExcludeTax ? format15(priceExcludeTax.toNumber()) : undefined) || undefined;
12635
+ // } else {
12636
+ // const lineAmountIncludeTax = chain(bignumber(good.lineAmountExcludeTax)).multiply(taxRate).done();
12637
+ // const priceIncludeTax = good.priceExcludeTax ? chain(bignumber(good.priceExcludeTax)).multiply(taxRate).done() : undefined
12638
+ // good.lineAmountIncludeTax = lineAmountIncludeTax.toNumber().toFixed(2);
12639
+ // good.priceIncludeTax = (priceIncludeTax ? format15(priceIncludeTax.toNumber()) : undefined) || undefined;
12640
+ // }
12053
12641
 
12054
12642
  good.taxAmount = countTaxAmount(good.lineAmountIncludeTax || 0, s.goodsListState.deduction, values.taxRate);
12055
12643
  }); //截取名称
@@ -12107,8 +12695,8 @@ var DrawerBody$3 = function DrawerBody(props) {
12107
12695
  FormEffectHooks.onFieldValueChange$('taxRate').subscribe(function (e) {
12108
12696
  setTaxRate(e.value);
12109
12697
  actions.setFieldState('taxFreeType', /*#__PURE__*/function () {
12110
- var _ref12 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee12(s) {
12111
- return regeneratorRuntime.wrap(function _callee12$(_context12) {
12698
+ var _ref12 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee12(s) {
12699
+ return _regeneratorRuntime().wrap(function _callee12$(_context12) {
12112
12700
  while (1) {
12113
12701
  switch (_context12.prev = _context12.next) {
12114
12702
  case 0:
@@ -12131,8 +12719,8 @@ var DrawerBody$3 = function DrawerBody(props) {
12131
12719
  FormEffectHooks.onFieldValueChange$('favouredPolicyMark').subscribe(function (e) {
12132
12720
  setFavouredPolicyMark(e.value);
12133
12721
  actions.setFieldState('favouredPolicyName', /*#__PURE__*/function () {
12134
- var _ref13 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee13(s) {
12135
- return regeneratorRuntime.wrap(function _callee13$(_context13) {
12722
+ var _ref13 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee13(s) {
12723
+ return _regeneratorRuntime().wrap(function _callee13$(_context13) {
12136
12724
  while (1) {
12137
12725
  switch (_context13.prev = _context13.next) {
12138
12726
  case 0:
@@ -12156,13 +12744,13 @@ var DrawerBody$3 = function DrawerBody(props) {
12156
12744
  React.useEffect(function () {
12157
12745
  if (controller.getTaxCategoryCodeList) controller.getTaxCategoryCodeList();
12158
12746
  }, [controller]);
12159
- return /*#__PURE__*/React.createElement(SchemaForm, {
12747
+ return React.createElement(SchemaForm, {
12160
12748
  actions: actions,
12161
12749
  components: _objectSpread2(_objectSpread2({}, components), {}, {
12162
12750
  showSearch: !!controller.state.goodsListState.endowCode.getTaxCategoryCodeTree ? ShowSearch2 : ShowSearch
12163
12751
  }),
12164
12752
  effects: effects
12165
- }, /*#__PURE__*/React.createElement(FormButtonGroup, null, /*#__PURE__*/React.createElement(SchemaMarkupField, {
12753
+ }, React.createElement(FormButtonGroup, null, React.createElement(SchemaMarkupField, {
12166
12754
  name: "taxClassificationCode",
12167
12755
  type: "showSearch",
12168
12756
  title: "\u7A0E\u6536\u5206\u7C7B\u7F16\u7801",
@@ -12172,12 +12760,12 @@ var DrawerBody$3 = function DrawerBody(props) {
12172
12760
  message: '请选择税收分类编码',
12173
12761
  required: true
12174
12762
  }]
12175
- }), /*#__PURE__*/React.createElement(SchemaMarkupField, {
12763
+ }), React.createElement(SchemaMarkupField, {
12176
12764
  name: "shorthand",
12177
12765
  type: "string",
12178
12766
  default: getShorthand(defaultValue === null || defaultValue === void 0 ? void 0 : defaultValue.itemName),
12179
12767
  title: "\u5546\u54C1\u548C\u670D\u52A1\u5206\u7C7B\u7B80\u79F0"
12180
- }), /*#__PURE__*/React.createElement(SchemaMarkupField, {
12768
+ }), React.createElement(SchemaMarkupField, {
12181
12769
  name: "taxRate",
12182
12770
  type: "string",
12183
12771
  title: "\u7A0E\u7387",
@@ -12190,7 +12778,7 @@ var DrawerBody$3 = function DrawerBody(props) {
12190
12778
  message: '请选择税率',
12191
12779
  required: true
12192
12780
  }]
12193
- }), taxRate === 0 && /*#__PURE__*/React.createElement(SchemaMarkupField, {
12781
+ }), taxRate === 0 && React.createElement(SchemaMarkupField, {
12194
12782
  name: "taxFreeType",
12195
12783
  type: "string",
12196
12784
  title: "\u514D\u7A0E\u7C7B\u578B",
@@ -12200,7 +12788,7 @@ var DrawerBody$3 = function DrawerBody(props) {
12200
12788
  message: '请选择免税类型',
12201
12789
  required: true
12202
12790
  }]
12203
- }), /*#__PURE__*/React.createElement(SchemaMarkupField, {
12791
+ }), React.createElement(SchemaMarkupField, {
12204
12792
  name: "favouredPolicyMark",
12205
12793
  type: "number",
12206
12794
  title: "\u662F\u5426\u4EAB\u53D7\u4F18\u60E0\u653F\u7B56",
@@ -12216,7 +12804,7 @@ var DrawerBody$3 = function DrawerBody(props) {
12216
12804
  message: '请选择是否享受优惠政策',
12217
12805
  required: true
12218
12806
  }]
12219
- }), favouredPolicyMark === 1 && /*#__PURE__*/React.createElement(SchemaMarkupField, {
12807
+ }), favouredPolicyMark === 1 && React.createElement(SchemaMarkupField, {
12220
12808
  name: "favouredPolicyName",
12221
12809
  type: "string",
12222
12810
  title: "\u4F18\u60E0\u653F\u7B56\u7C7B\u578B",
@@ -12226,18 +12814,18 @@ var DrawerBody$3 = function DrawerBody(props) {
12226
12814
  message: '请选择是否享受优惠政策',
12227
12815
  required: true
12228
12816
  }]
12229
- })), /*#__PURE__*/React.createElement("span", {
12817
+ })), React.createElement("span", {
12230
12818
  className: "kts-invoice-operate-goods-endow-code-button-list"
12231
- }, /*#__PURE__*/React.createElement(Button, {
12819
+ }, React.createElement(Button, {
12232
12820
  onClick: function onClick() {
12233
12821
  actions.submit(onSubmit);
12234
12822
  },
12235
12823
  type: "primary"
12236
- }, "\u786E\u5B9A"), /*#__PURE__*/React.createElement(Button, {
12824
+ }, "\u786E\u5B9A"), React.createElement(Button, {
12237
12825
  onClick: function onClick() {
12238
12826
  controller.pipeline( /*#__PURE__*/function () {
12239
- var _ref14 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee14(s) {
12240
- return regeneratorRuntime.wrap(function _callee14$(_context14) {
12827
+ var _ref14 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee14(s) {
12828
+ return _regeneratorRuntime().wrap(function _callee14$(_context14) {
12241
12829
  while (1) {
12242
12830
  switch (_context14.prev = _context14.next) {
12243
12831
  case 0:
@@ -12296,7 +12884,7 @@ var getItemName$1 = function getItemName(value, shorthand) {
12296
12884
 
12297
12885
  /** 发票组件的上下文 */
12298
12886
 
12299
- var InvoiceContext = /*#__PURE__*/React.createContext(undefined);
12887
+ var InvoiceContext = React.createContext(undefined);
12300
12888
 
12301
12889
  var default_1 = /*#__PURE__*/function (_React$PureComponent) {
12302
12890
  _inherits(default_1, _React$PureComponent);
@@ -12328,7 +12916,7 @@ var default_1 = /*#__PURE__*/function (_React$PureComponent) {
12328
12916
 
12329
12917
  /** 获取控制器钩子 */
12330
12918
  function render() {
12331
- return /*#__PURE__*/React.createElement(Main$3, _objectSpread2({}, this.props));
12919
+ return React.createElement(Main$3, _objectSpread2({}, this.props));
12332
12920
  }
12333
12921
  }]);
12334
12922
 
@@ -12360,22 +12948,22 @@ var Main$3 = function Main(props) {
12360
12948
  React.useEffect(function () {
12361
12949
  setKey(key + 1);
12362
12950
  }, [controller]);
12363
- return /*#__PURE__*/React.createElement(InvoiceContext.Provider, {
12951
+ return React.createElement(InvoiceContext.Provider, {
12364
12952
  key: key,
12365
12953
  value: controller
12366
- }, /*#__PURE__*/React.createElement("div", {
12954
+ }, React.createElement("div", {
12367
12955
  className: "kts-invoice-operate"
12368
- }, props.invoiceHeader || /*#__PURE__*/React.createElement(InvoiceHeader, null)
12956
+ }, props.invoiceHeader || React.createElement(InvoiceHeader, null)
12369
12957
  /** 发票头 */
12370
- , props.buyer || /*#__PURE__*/React.createElement(Buyer$1, null)
12958
+ , props.buyer || React.createElement(Buyer$1, null)
12371
12959
  /** 购买方 */
12372
- , props.goodsList || /*#__PURE__*/React.createElement(GoodsList, null)
12960
+ , props.goodsList || React.createElement(GoodsList, null)
12373
12961
  /** 货物列表 */
12374
- , props.seller || /*#__PURE__*/React.createElement(Buyer, null)
12962
+ , props.seller || React.createElement(Buyer, null)
12375
12963
  /** 销售方 */
12376
- , props.sign || /*#__PURE__*/React.createElement(Sign, null)
12964
+ , props.sign || React.createElement(Sign, null)
12377
12965
  /** 落款 */
12378
- , props.footExpand), /*#__PURE__*/React.createElement(ImportBuyerDrawer, null), /*#__PURE__*/React.createElement(ImportGoodsDrawer, null), /*#__PURE__*/React.createElement(EndowCodeDrawer, null));
12966
+ , props.footExpand), React.createElement(ImportBuyerDrawer, null), React.createElement(ImportGoodsDrawer, null), React.createElement(EndowCodeDrawer, null));
12379
12967
  };
12380
12968
 
12381
12969
  export { default_1 as Invoice, InvoiceController };