kts-component-invoice-operate 1.0.87 → 1.0.88
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +30 -12
- package/dist/index.js +30 -12
- package/docs-dist/umi.js +1 -1
- package/package.json +1 -1
- package/src/Invoice/InvoiceController/InvoiceControllerForm/index.ts +8 -0
- package/src/Invoice/ui/EndowCodeDrawer/index.tsx +1 -0
- package/src/Invoice/ui/GoodsList/hook/useColumns/autoFillFn/index.ts +3 -3
package/dist/index.esm.js
CHANGED
|
@@ -348,7 +348,7 @@ var InvoiceControllerForm = /*#__PURE__*/function (_GreyReactBox) {
|
|
|
348
348
|
var _validateFields2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
|
349
349
|
var _this3 = this;
|
|
350
350
|
|
|
351
|
-
var _errors, _values, arr, i, key, _yield$_validateField, errors, values;
|
|
351
|
+
var _errors, _values, arr, i, key, _yield$_validateField, errors, values, _this$state$goodsList;
|
|
352
352
|
|
|
353
353
|
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
354
354
|
while (1) {
|
|
@@ -382,7 +382,26 @@ var InvoiceControllerForm = /*#__PURE__*/function (_GreyReactBox) {
|
|
|
382
382
|
break;
|
|
383
383
|
|
|
384
384
|
case 16:
|
|
385
|
-
|
|
385
|
+
if (!this.state.goodsListState.form) {
|
|
386
|
+
_context.next = 25;
|
|
387
|
+
break;
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
_context.prev = 17;
|
|
391
|
+
_context.next = 20;
|
|
392
|
+
return (_this$state$goodsList = this.state.goodsListState.form) === null || _this$state$goodsList === void 0 ? void 0 : _this$state$goodsList.validateFields();
|
|
393
|
+
|
|
394
|
+
case 20:
|
|
395
|
+
_context.next = 25;
|
|
396
|
+
break;
|
|
397
|
+
|
|
398
|
+
case 22:
|
|
399
|
+
_context.prev = 22;
|
|
400
|
+
_context.t0 = _context["catch"](17);
|
|
401
|
+
|
|
402
|
+
_errors.set('goodsList', _context.t0.errors);
|
|
403
|
+
|
|
404
|
+
case 25:
|
|
386
405
|
_values.set('goodsList', this.state.goodsListState.goodsList.slice()); // 金额(含税)
|
|
387
406
|
|
|
388
407
|
|
|
@@ -426,12 +445,12 @@ var InvoiceControllerForm = /*#__PURE__*/function (_GreyReactBox) {
|
|
|
426
445
|
values: _values
|
|
427
446
|
});
|
|
428
447
|
|
|
429
|
-
case
|
|
448
|
+
case 30:
|
|
430
449
|
case "end":
|
|
431
450
|
return _context.stop();
|
|
432
451
|
}
|
|
433
452
|
}
|
|
434
|
-
}, _callee, this);
|
|
453
|
+
}, _callee, this, [[17, 22]]);
|
|
435
454
|
}));
|
|
436
455
|
|
|
437
456
|
function validateFields() {
|
|
@@ -2423,14 +2442,13 @@ var lazyFn$1 = function lazyFn(fn) {
|
|
|
2423
2442
|
|
|
2424
2443
|
var promptErr = function promptErr(err) {
|
|
2425
2444
|
if (!err) return false;
|
|
2426
|
-
|
|
2427
|
-
if (err.errors[0].message
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
}
|
|
2433
|
-
|
|
2445
|
+
if (err.errors[0].message === 'lineAmountIncludeTax need to revalidate') return true;
|
|
2446
|
+
if (err.errors[0].message === 'priceIncludeTax need to revalidate') return true;
|
|
2447
|
+
message.error({
|
|
2448
|
+
key: err.errors[0].message,
|
|
2449
|
+
content: err.errors[0].message,
|
|
2450
|
+
duration: 2
|
|
2451
|
+
});
|
|
2434
2452
|
return true;
|
|
2435
2453
|
};
|
|
2436
2454
|
/** 数量改变了 */
|
package/dist/index.js
CHANGED
|
@@ -358,7 +358,7 @@ var InvoiceControllerForm = /*#__PURE__*/function (_GreyReactBox) {
|
|
|
358
358
|
var _validateFields2 = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
|
359
359
|
var _this3 = this;
|
|
360
360
|
|
|
361
|
-
var _errors, _values, arr, i, key, _yield$_validateField, errors, values;
|
|
361
|
+
var _errors, _values, arr, i, key, _yield$_validateField, errors, values, _this$state$goodsList;
|
|
362
362
|
|
|
363
363
|
return regeneratorRuntime.wrap(function _callee$(_context) {
|
|
364
364
|
while (1) {
|
|
@@ -392,7 +392,26 @@ var InvoiceControllerForm = /*#__PURE__*/function (_GreyReactBox) {
|
|
|
392
392
|
break;
|
|
393
393
|
|
|
394
394
|
case 16:
|
|
395
|
-
|
|
395
|
+
if (!this.state.goodsListState.form) {
|
|
396
|
+
_context.next = 25;
|
|
397
|
+
break;
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
_context.prev = 17;
|
|
401
|
+
_context.next = 20;
|
|
402
|
+
return (_this$state$goodsList = this.state.goodsListState.form) === null || _this$state$goodsList === void 0 ? void 0 : _this$state$goodsList.validateFields();
|
|
403
|
+
|
|
404
|
+
case 20:
|
|
405
|
+
_context.next = 25;
|
|
406
|
+
break;
|
|
407
|
+
|
|
408
|
+
case 22:
|
|
409
|
+
_context.prev = 22;
|
|
410
|
+
_context.t0 = _context["catch"](17);
|
|
411
|
+
|
|
412
|
+
_errors.set('goodsList', _context.t0.errors);
|
|
413
|
+
|
|
414
|
+
case 25:
|
|
396
415
|
_values.set('goodsList', this.state.goodsListState.goodsList.slice()); // 金额(含税)
|
|
397
416
|
|
|
398
417
|
|
|
@@ -436,12 +455,12 @@ var InvoiceControllerForm = /*#__PURE__*/function (_GreyReactBox) {
|
|
|
436
455
|
values: _values
|
|
437
456
|
});
|
|
438
457
|
|
|
439
|
-
case
|
|
458
|
+
case 30:
|
|
440
459
|
case "end":
|
|
441
460
|
return _context.stop();
|
|
442
461
|
}
|
|
443
462
|
}
|
|
444
|
-
}, _callee, this);
|
|
463
|
+
}, _callee, this, [[17, 22]]);
|
|
445
464
|
}));
|
|
446
465
|
|
|
447
466
|
function validateFields() {
|
|
@@ -2433,14 +2452,13 @@ var lazyFn$1 = function lazyFn(fn) {
|
|
|
2433
2452
|
|
|
2434
2453
|
var promptErr = function promptErr(err) {
|
|
2435
2454
|
if (!err) return false;
|
|
2436
|
-
|
|
2437
|
-
if (err.errors[0].message
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
}
|
|
2443
|
-
|
|
2455
|
+
if (err.errors[0].message === 'lineAmountIncludeTax need to revalidate') return true;
|
|
2456
|
+
if (err.errors[0].message === 'priceIncludeTax need to revalidate') return true;
|
|
2457
|
+
ktsComponentsAntdX3.message.error({
|
|
2458
|
+
key: err.errors[0].message,
|
|
2459
|
+
content: err.errors[0].message,
|
|
2460
|
+
duration: 2
|
|
2461
|
+
});
|
|
2444
2462
|
return true;
|
|
2445
2463
|
};
|
|
2446
2464
|
/** 数量改变了 */
|