kts-component-invoice-operate 1.0.55 → 1.0.61

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.
@@ -1,4 +1,5 @@
1
1
  declare const _default: () => {
2
+ columnWidth: number;
2
3
  columnTitle: JSX.Element;
3
4
  onSelect: (record: any, selected: any) => Promise<void>;
4
5
  selectedRowKeys: number[];
package/dist/index.esm.js CHANGED
@@ -2,7 +2,7 @@ import 'kts-components-antd-x3/dist/kts-components-antd-x3.css';
2
2
  import React, { createElement } from 'react';
3
3
  import GreyReactBox, { decorator } from 'grey-react-box';
4
4
  import { chain as chain$1, bignumber, create, all } from 'mathjs';
5
- import { message, Form, Input, Icon, Tag, Select, Row, Col, Table, Button, Switch, Typography, Drawer, Menu, Dropdown, AutoComplete, Checkbox, Descriptions } from 'kts-components-antd-x3';
5
+ import { message, Form, Input, Icon, Tag, Select, Row, Col, Table, Button, Switch, Typography, Drawer, Menu, Dropdown, AutoComplete, Spin, Checkbox, Descriptions } from 'kts-components-antd-x3';
6
6
  import { v4 } from 'uuid';
7
7
  import { createAsyncFormActions, FormEffectHooks, SchemaForm, FormButtonGroup, SchemaMarkupField } from '@formily/antd';
8
8
  import { Input as Input$1, NumberPicker } from '@formily/antd-components';
@@ -2422,32 +2422,46 @@ var onChangeQuantity = lazyFn$1(function (controller, form, record) {
2422
2422
  case 0:
2423
2423
  err = err || {};
2424
2424
 
2425
- if (!(err.quantity || !values.quantity)) {
2426
- _context.next = 3;
2425
+ if (!(!values.quantity && values.quantity !== 0)) {
2426
+ _context.next = 5;
2427
2427
  break;
2428
2428
  }
2429
2429
 
2430
+ _context.next = 4;
2431
+ return controller.setEditGood({
2432
+ quantity: undefined
2433
+ });
2434
+
2435
+ case 4:
2430
2436
  return _context.abrupt("return");
2431
2437
 
2432
- case 3:
2438
+ case 5:
2439
+ if (!err.quantity) {
2440
+ _context.next = 7;
2441
+ break;
2442
+ }
2443
+
2444
+ return _context.abrupt("return");
2445
+
2446
+ case 7:
2433
2447
  quantity = format15(values.quantity);
2434
- _context.next = 6;
2448
+ _context.next = 10;
2435
2449
  return controller.setEditGood({
2436
2450
  quantity: quantity
2437
2451
  });
2438
2452
 
2439
- case 6:
2453
+ case 10:
2440
2454
  form.setFieldsValue({
2441
2455
  quantity: quantity
2442
2456
  }); // 是否含税
2443
2457
 
2444
2458
  if (!controller.state.goodsListState.isTaxIncluded) {
2445
- _context.next = 25;
2459
+ _context.next = 29;
2446
2460
  break;
2447
2461
  }
2448
2462
 
2449
2463
  if (!(!err.priceIncludeTax && values.priceIncludeTax)) {
2450
- _context.next = 16;
2464
+ _context.next = 20;
2451
2465
  break;
2452
2466
  }
2453
2467
 
@@ -2457,18 +2471,18 @@ var onChangeQuantity = lazyFn$1(function (controller, form, record) {
2457
2471
  form.setFieldsValue({
2458
2472
  lineAmountIncludeTax: lineAmountIncludeTax
2459
2473
  });
2460
- _context.next = 14;
2474
+ _context.next = 18;
2461
2475
  return controller.setEditGood({
2462
2476
  lineAmountIncludeTax: lineAmountIncludeTax
2463
2477
  });
2464
2478
 
2465
- case 14:
2466
- _context.next = 22;
2479
+ case 18:
2480
+ _context.next = 26;
2467
2481
  break;
2468
2482
 
2469
- case 16:
2483
+ case 20:
2470
2484
  if (!(!err.lineAmountIncludeTax && values.lineAmountIncludeTax)) {
2471
- _context.next = 22;
2485
+ _context.next = 26;
2472
2486
  break;
2473
2487
  }
2474
2488
 
@@ -2478,20 +2492,20 @@ var onChangeQuantity = lazyFn$1(function (controller, form, record) {
2478
2492
  form.setFieldsValue({
2479
2493
  priceIncludeTax: _priceIncludeTax
2480
2494
  });
2481
- _context.next = 22;
2495
+ _context.next = 26;
2482
2496
  return controller.setEditGood({
2483
2497
  priceIncludeTax: _priceIncludeTax
2484
2498
  });
2485
2499
 
2486
- case 22:
2500
+ case 26:
2487
2501
  // 更新不含税
2488
2502
  updateUnitPriceExcludingTax(controller, form);
2489
- _context.next = 40;
2503
+ _context.next = 44;
2490
2504
  break;
2491
2505
 
2492
- case 25:
2506
+ case 29:
2493
2507
  if (!(!err.priceExcludeTax && values.priceExcludeTax)) {
2494
- _context.next = 33;
2508
+ _context.next = 37;
2495
2509
  break;
2496
2510
  }
2497
2511
 
@@ -2500,19 +2514,19 @@ var onChangeQuantity = lazyFn$1(function (controller, form, record) {
2500
2514
  form.setFieldsValue({
2501
2515
  lineAmountExcludeTax: lineAmountExcludeTax
2502
2516
  });
2503
- _context.next = 31;
2517
+ _context.next = 35;
2504
2518
  return controller.setEditGood({
2505
2519
  lineAmountExcludeTax: lineAmountExcludeTax,
2506
2520
  quantity: quantity
2507
2521
  });
2508
2522
 
2509
- case 31:
2510
- _context.next = 39;
2523
+ case 35:
2524
+ _context.next = 43;
2511
2525
  break;
2512
2526
 
2513
- case 33:
2527
+ case 37:
2514
2528
  if (!(!err.lineAmountExcludeTax && values.lineAmountExcludeTax)) {
2515
- _context.next = 39;
2529
+ _context.next = 43;
2516
2530
  break;
2517
2531
  }
2518
2532
 
@@ -2521,17 +2535,17 @@ var onChangeQuantity = lazyFn$1(function (controller, form, record) {
2521
2535
  form.setFieldsValue({
2522
2536
  priceExcludeTax: _priceExcludeTax
2523
2537
  });
2524
- _context.next = 39;
2538
+ _context.next = 43;
2525
2539
  return controller.setEditGood({
2526
2540
  priceExcludeTax: _priceExcludeTax,
2527
2541
  quantity: quantity
2528
2542
  });
2529
2543
 
2530
- case 39:
2544
+ case 43:
2531
2545
  // 更新含税
2532
2546
  updateUnitPriceTax(controller, form);
2533
2547
 
2534
- case 40:
2548
+ case 44:
2535
2549
  case "end":
2536
2550
  return _context.stop();
2537
2551
  }
@@ -2557,27 +2571,42 @@ var onChangePriceIncludeTax = lazyFn$1(function (controller, form, record) {
2557
2571
  case 0:
2558
2572
  err = err || {};
2559
2573
 
2560
- if (!(err.priceIncludeTax || !values.priceIncludeTax)) {
2561
- _context2.next = 3;
2574
+ if (!(!values.priceIncludeTax && values.priceIncludeTax !== 0)) {
2575
+ _context2.next = 5;
2562
2576
  break;
2563
2577
  }
2564
2578
 
2579
+ _context2.next = 4;
2580
+ return controller.setEditGood({
2581
+ priceIncludeTax: undefined,
2582
+ priceExcludeTax: undefined
2583
+ });
2584
+
2585
+ case 4:
2565
2586
  return _context2.abrupt("return");
2566
2587
 
2567
- case 3:
2588
+ case 5:
2589
+ if (!err.priceIncludeTax) {
2590
+ _context2.next = 7;
2591
+ break;
2592
+ }
2593
+
2594
+ return _context2.abrupt("return");
2595
+
2596
+ case 7:
2568
2597
  priceIncludeTax = format15(values.priceIncludeTax);
2569
- _context2.next = 6;
2598
+ _context2.next = 10;
2570
2599
  return controller.setEditGood({
2571
2600
  priceIncludeTax: priceIncludeTax
2572
2601
  });
2573
2602
 
2574
- case 6:
2603
+ case 10:
2575
2604
  form.setFieldsValue({
2576
2605
  priceIncludeTax: priceIncludeTax
2577
2606
  }); // 是否有数量
2578
2607
 
2579
2608
  if (!(!err.quantity && values.quantity)) {
2580
- _context2.next = 15;
2609
+ _context2.next = 19;
2581
2610
  break;
2582
2611
  }
2583
2612
 
@@ -2586,18 +2615,18 @@ var onChangePriceIncludeTax = lazyFn$1(function (controller, form, record) {
2586
2615
  form.setFieldsValue({
2587
2616
  lineAmountIncludeTax: lineAmountIncludeTax
2588
2617
  });
2589
- _context2.next = 13;
2618
+ _context2.next = 17;
2590
2619
  return controller.setEditGood({
2591
2620
  lineAmountIncludeTax: lineAmountIncludeTax
2592
2621
  });
2593
2622
 
2594
- case 13:
2595
- _context2.next = 21;
2623
+ case 17:
2624
+ _context2.next = 25;
2596
2625
  break;
2597
2626
 
2598
- case 15:
2627
+ case 19:
2599
2628
  if (!(!err.lineAmountIncludeTax && values.lineAmountIncludeTax)) {
2600
- _context2.next = 21;
2629
+ _context2.next = 25;
2601
2630
  break;
2602
2631
  }
2603
2632
 
@@ -2606,16 +2635,16 @@ var onChangePriceIncludeTax = lazyFn$1(function (controller, form, record) {
2606
2635
  form.setFieldsValue({
2607
2636
  quantity: _quantity
2608
2637
  });
2609
- _context2.next = 21;
2638
+ _context2.next = 25;
2610
2639
  return controller.setEditGood({
2611
2640
  quantity: _quantity
2612
2641
  });
2613
2642
 
2614
- case 21:
2643
+ case 25:
2615
2644
  // 更新不含税
2616
2645
  updateUnitPriceExcludingTax(controller, form);
2617
2646
 
2618
- case 22:
2647
+ case 26:
2619
2648
  case "end":
2620
2649
  return _context2.stop();
2621
2650
  }
@@ -2641,27 +2670,42 @@ var onChangePriceExcludeTax = lazyFn$1(function (controller, form, record) {
2641
2670
  case 0:
2642
2671
  err = err || {};
2643
2672
 
2644
- if (!(err.priceExcludeTax || !values.priceExcludeTax)) {
2645
- _context3.next = 3;
2673
+ if (!(!values.priceExcludeTax && values.priceExcludeTax !== 0)) {
2674
+ _context3.next = 5;
2646
2675
  break;
2647
2676
  }
2648
2677
 
2678
+ _context3.next = 4;
2679
+ return controller.setEditGood({
2680
+ priceIncludeTax: undefined,
2681
+ priceExcludeTax: undefined
2682
+ });
2683
+
2684
+ case 4:
2649
2685
  return _context3.abrupt("return");
2650
2686
 
2651
- case 3:
2687
+ case 5:
2688
+ if (!err.priceExcludeTax) {
2689
+ _context3.next = 7;
2690
+ break;
2691
+ }
2692
+
2693
+ return _context3.abrupt("return");
2694
+
2695
+ case 7:
2652
2696
  priceExcludeTax = format15(values.priceExcludeTax);
2653
- _context3.next = 6;
2697
+ _context3.next = 10;
2654
2698
  return controller.setEditGood({
2655
2699
  priceExcludeTax: priceExcludeTax
2656
2700
  });
2657
2701
 
2658
- case 6:
2702
+ case 10:
2659
2703
  form.setFieldsValue({
2660
2704
  priceExcludeTax: priceExcludeTax
2661
2705
  }); // 是否有数量
2662
2706
 
2663
2707
  if (!(!err.quantity && values.quantity)) {
2664
- _context3.next = 15;
2708
+ _context3.next = 19;
2665
2709
  break;
2666
2710
  }
2667
2711
 
@@ -2670,18 +2714,18 @@ var onChangePriceExcludeTax = lazyFn$1(function (controller, form, record) {
2670
2714
  form.setFieldsValue({
2671
2715
  lineAmountExcludeTax: lineAmountExcludeTax
2672
2716
  });
2673
- _context3.next = 13;
2717
+ _context3.next = 17;
2674
2718
  return controller.setEditGood({
2675
2719
  lineAmountExcludeTax: lineAmountExcludeTax
2676
2720
  });
2677
2721
 
2678
- case 13:
2679
- _context3.next = 21;
2722
+ case 17:
2723
+ _context3.next = 25;
2680
2724
  break;
2681
2725
 
2682
- case 15:
2726
+ case 19:
2683
2727
  if (!(!err.lineAmountExcludeTax && values.lineAmountExcludeTax)) {
2684
- _context3.next = 21;
2728
+ _context3.next = 25;
2685
2729
  break;
2686
2730
  }
2687
2731
 
@@ -2690,16 +2734,16 @@ var onChangePriceExcludeTax = lazyFn$1(function (controller, form, record) {
2690
2734
  form.setFieldsValue({
2691
2735
  quantity: _quantity2
2692
2736
  });
2693
- _context3.next = 21;
2737
+ _context3.next = 25;
2694
2738
  return controller.setEditGood({
2695
2739
  quantity: _quantity2
2696
2740
  });
2697
2741
 
2698
- case 21:
2742
+ case 25:
2699
2743
  // 更新含税
2700
2744
  updateUnitPriceTax(controller, form);
2701
2745
 
2702
- case 22:
2746
+ case 26:
2703
2747
  case "end":
2704
2748
  return _context3.stop();
2705
2749
  }
@@ -3212,7 +3256,7 @@ var useEndowCode = (function (goods) {
3212
3256
  }, [goods.lineAttribute, onClick]);
3213
3257
  });
3214
3258
 
3215
- 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}\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";
3259
+ 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";
3216
3260
  styleInject(css_248z$5);
3217
3261
 
3218
3262
  var RowMenu = (function (props) {
@@ -3287,8 +3331,15 @@ var useColumns = (function (form) {
3287
3331
  var unitList = controller.useMemo(function (e) {
3288
3332
  return e.goodsListState.unitList;
3289
3333
  }, []);
3334
+ /** 变动的字段 */
3335
+
3336
+ var _React$useState = React.useState(''),
3337
+ _React$useState2 = _slicedToArray(_React$useState, 2),
3338
+ changeField = _React$useState2[0],
3339
+ setChangeField = _React$useState2[1];
3290
3340
  /** 表头 */
3291
3341
 
3342
+
3292
3343
  var columns = React.useMemo(function () {
3293
3344
  return [{
3294
3345
  title: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Text$4, {
@@ -3409,6 +3460,7 @@ var useColumns = (function (form) {
3409
3460
  title: '数量',
3410
3461
  dataIndex: 'quantity',
3411
3462
  key: 'quantity',
3463
+ align: 'right',
3412
3464
  width: 119,
3413
3465
  render: function render(value, record) {
3414
3466
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
@@ -3458,8 +3510,13 @@ var useColumns = (function (form) {
3458
3510
  }()
3459
3511
  }]
3460
3512
  })( /*#__PURE__*/React.createElement(MyInput, {
3513
+ style: {
3514
+ textAlign: 'right'
3515
+ },
3461
3516
  maxLength: 16,
3517
+ loading: isCipher(changeField, "quantity"),
3462
3518
  onChange: function onChange() {
3519
+ setChangeField('quantity');
3463
3520
  onChangeQuantity(controller, form, record);
3464
3521
  }
3465
3522
  })));
@@ -3475,6 +3532,7 @@ var useColumns = (function (form) {
3475
3532
  title: '单价(含税)',
3476
3533
  dataIndex: 'priceIncludeTax',
3477
3534
  key: 'priceIncludeTax',
3535
+ align: 'right',
3478
3536
  width: 119,
3479
3537
  render: function render(value, record) {
3480
3538
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
@@ -3506,7 +3564,7 @@ var useColumns = (function (form) {
3506
3564
  return _context3.abrupt("return");
3507
3565
 
3508
3566
  case 6:
3509
- callback('请输入数量');
3567
+ callback('请输入单价');
3510
3568
 
3511
3569
  case 7:
3512
3570
  case "end":
@@ -3524,8 +3582,13 @@ var useColumns = (function (form) {
3524
3582
  }()
3525
3583
  }]
3526
3584
  })( /*#__PURE__*/React.createElement(MyInput, {
3585
+ style: {
3586
+ textAlign: 'right'
3587
+ },
3527
3588
  maxLength: 16,
3589
+ loading: isCipher(changeField, 'priceIncludeTax'),
3528
3590
  onChange: function onChange() {
3591
+ setChangeField('priceIncludeTax');
3529
3592
  onChangePriceIncludeTax(controller, form, record);
3530
3593
  }
3531
3594
  })));
@@ -3541,6 +3604,7 @@ var useColumns = (function (form) {
3541
3604
  title: '单价(不含税)',
3542
3605
  dataIndex: 'priceExcludeTax',
3543
3606
  key: 'priceExcludeTax',
3607
+ align: 'right',
3544
3608
  width: 119,
3545
3609
  render: function render(value, record) {
3546
3610
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
@@ -3590,8 +3654,13 @@ var useColumns = (function (form) {
3590
3654
  }()
3591
3655
  }]
3592
3656
  })( /*#__PURE__*/React.createElement(MyInput, {
3657
+ style: {
3658
+ textAlign: 'right'
3659
+ },
3593
3660
  maxLength: 16,
3661
+ loading: isCipher(changeField, 'priceExcludeTax'),
3594
3662
  onChange: function onChange() {
3663
+ setChangeField('priceExcludeTax');
3595
3664
  onChangePriceExcludeTax(controller, form, record);
3596
3665
  }
3597
3666
  })));
@@ -3610,6 +3679,7 @@ var useColumns = (function (form) {
3610
3679
  dataIndex: 'lineAmountIncludeTax',
3611
3680
  key: 'lineAmountIncludeTax',
3612
3681
  width: 119,
3682
+ align: 'right',
3613
3683
  render: function render(value, record) {
3614
3684
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
3615
3685
  return /*#__PURE__*/React.createElement(Form.Item, null, getFieldDecorator('lineAmountIncludeTax', {
@@ -3622,7 +3692,12 @@ var useColumns = (function (form) {
3622
3692
  message: '金额必须为数字'
3623
3693
  }]
3624
3694
  })( /*#__PURE__*/React.createElement(MyInput, {
3695
+ style: {
3696
+ textAlign: 'right'
3697
+ },
3698
+ loading: isCipher(changeField, 'lineAmountIncludeTax'),
3625
3699
  onChange: function onChange() {
3700
+ setChangeField('lineAmountIncludeTax');
3626
3701
  onChangeLineAmountIncludeTax(controller, form, record);
3627
3702
  }
3628
3703
  })));
@@ -3640,6 +3715,7 @@ var useColumns = (function (form) {
3640
3715
  }, "*"), "\u91D1\u989D(\u4E0D\u542B\u7A0E)"),
3641
3716
  dataIndex: 'lineAmountExcludeTax',
3642
3717
  key: 'lineAmountExcludeTax',
3718
+ align: 'right',
3643
3719
  width: 119,
3644
3720
  render: function render(value, record) {
3645
3721
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
@@ -3653,7 +3729,12 @@ var useColumns = (function (form) {
3653
3729
  message: '金额必须为数字'
3654
3730
  }]
3655
3731
  })( /*#__PURE__*/React.createElement(MyInput, {
3732
+ style: {
3733
+ textAlign: 'right'
3734
+ },
3735
+ loading: isCipher(changeField, 'lineAmountExcludeTax'),
3656
3736
  onChange: function onChange() {
3737
+ setChangeField('lineAmountExcludeTax');
3657
3738
  onChangeLineAmountExcludeTax(controller, form, record);
3658
3739
  }
3659
3740
  })));
@@ -3671,6 +3752,7 @@ var useColumns = (function (form) {
3671
3752
  }, "*"), "\u7A0E\u7387"),
3672
3753
  dataIndex: 'taxRate',
3673
3754
  key: 'taxRate',
3755
+ align: 'right',
3674
3756
  width: 70,
3675
3757
  render: function render(value, record) {
3676
3758
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
@@ -3684,6 +3766,12 @@ var useColumns = (function (form) {
3684
3766
  message: ' '
3685
3767
  }]
3686
3768
  })( /*#__PURE__*/React.createElement(Select, {
3769
+ dropdownStyle: {
3770
+ float: "right"
3771
+ },
3772
+ dropdownMenuStyle: {
3773
+ textAlign: "right"
3774
+ },
3687
3775
  showArrow: false,
3688
3776
  style: {
3689
3777
  width: '100%'
@@ -3709,6 +3797,7 @@ var useColumns = (function (form) {
3709
3797
  title: '税额',
3710
3798
  dataIndex: 'taxAmount',
3711
3799
  key: 'taxAmount',
3800
+ align: 'right',
3712
3801
  width: 119,
3713
3802
  render: function render(value, record) {
3714
3803
  if ((editGood === null || editGood === void 0 ? void 0 : editGood.$index) === record.$index) {
@@ -3746,9 +3835,24 @@ var useColumns = (function (form) {
3746
3835
  ellipsis: true
3747
3836
  });
3748
3837
  });
3749
- }, [isTaxIncluded, editGood, controller]);
3838
+ }, [isTaxIncluded, editGood, controller, changeField]);
3839
+ React.useEffect(function () {
3840
+ if (!changeField) return;
3841
+ var t = setTimeout(function () {
3842
+ setChangeField('');
3843
+ }, 1000);
3844
+ return function () {
3845
+ clearTimeout(t);
3846
+ };
3847
+ }, [changeField]);
3750
3848
  return columns;
3751
3849
  });
3850
+ /** 字段 */
3851
+
3852
+ function isCipher(name, field) {
3853
+ if (!name) return false;
3854
+ return name !== field;
3855
+ }
3752
3856
 
3753
3857
  var MyInput = /*#__PURE__*/function (_React$Component) {
3754
3858
  _inherits(MyInput, _React$Component);
@@ -3764,9 +3868,17 @@ var MyInput = /*#__PURE__*/function (_React$Component) {
3764
3868
  _createClass(MyInput, [{
3765
3869
  key: "render",
3766
3870
  value: function render() {
3767
- return /*#__PURE__*/React.createElement(Input, _objectSpread2(_objectSpread2({}, this.props), {}, {
3768
- autoComplete: "off"
3769
- }));
3871
+ if (this.props.loading) {
3872
+ return /*#__PURE__*/React.createElement(Spin, {
3873
+ size: "small"
3874
+ }, /*#__PURE__*/React.createElement(Input, _objectSpread2(_objectSpread2({}, this.props), {}, {
3875
+ autoComplete: "off"
3876
+ })));
3877
+ } else {
3878
+ return /*#__PURE__*/React.createElement(Input, _objectSpread2(_objectSpread2({}, this.props), {}, {
3879
+ autoComplete: "off"
3880
+ }));
3881
+ }
3770
3882
  }
3771
3883
  }]);
3772
3884
 
@@ -4125,6 +4237,7 @@ var useRowSelection = (function () {
4125
4237
  sortOut(true);
4126
4238
  }, [sortOut, goodsList]);
4127
4239
  return {
4240
+ columnWidth: 45,
4128
4241
  columnTitle: columnTitle,
4129
4242
  onSelect: onSelect,
4130
4243
  selectedRowKeys: selectedRowKeys
@@ -4855,40 +4968,46 @@ var DrawerBody$2 = function DrawerBody() {
4855
4968
  while (1) {
4856
4969
  switch (_context2.prev = _context2.next) {
4857
4970
  case 0:
4858
- _context2.next = 2;
4971
+ Object.keys(record).filter(function (e) {
4972
+ return !record[e] && record[e] !== 0;
4973
+ }).forEach(function (e) {
4974
+ delete record[e];
4975
+ });
4976
+ _context2.next = 3;
4859
4977
  return s.goodsListState.importGoods.verifyFn(record);
4860
4978
 
4861
- case 2:
4979
+ case 3:
4862
4980
  _context2.t0 = _context2.sent;
4863
4981
 
4864
4982
  if (!(_context2.t0 === false)) {
4865
- _context2.next = 5;
4983
+ _context2.next = 6;
4866
4984
  break;
4867
4985
  }
4868
4986
 
4869
4987
  return _context2.abrupt("return");
4870
4988
 
4871
- case 5:
4989
+ case 6:
4872
4990
  if (!(!s.goodsListState.editGood || !s.goodsListState.form)) {
4873
- _context2.next = 7;
4991
+ _context2.next = 8;
4874
4992
  break;
4875
4993
  }
4876
4994
 
4877
4995
  return _context2.abrupt("return");
4878
4996
 
4879
- case 7:
4997
+ case 8:
4880
4998
  s.goodsListState.editGood = _objectSpread2(_objectSpread2({}, s.goodsListState.editGood), record);
4881
4999
 
4882
5000
  if (s.goodsListState.editGood) {
4883
- _context2.next = 10;
5001
+ _context2.next = 11;
4884
5002
  break;
4885
5003
  }
4886
5004
 
4887
5005
  return _context2.abrupt("return");
4888
5006
 
4889
- case 10:
5007
+ case 11:
4890
5008
  if ("".concat(s.goodsListState.editGood.priceIncludeTax) === '0') {
4891
5009
  s.goodsListState.editGood.priceIncludeTax = undefined;
5010
+ s.goodsListState.editGood.priceExcludeTax = undefined;
4892
5011
  } else {
4893
5012
  s.goodsListState.editGood.priceExcludeTax = getPriceExcludeTax(s.goodsListState.editGood, record);
4894
5013
  }
@@ -4898,7 +5017,7 @@ var DrawerBody$2 = function DrawerBody() {
4898
5017
  s.goodsListState.importGoods.isVisibleDrawer = false;
4899
5018
  s.goodsListState.isTaxIncluded ? updateUnitPriceExcludingTax(controller, s.goodsListState.form) : updateUnitPriceTax(controller, s.goodsListState.form);
4900
5019
 
4901
- case 15:
5020
+ case 16:
4902
5021
  case "end":
4903
5022
  return _context2.stop();
4904
5023
  }