kts-component-invoice-operate 3.0.10 → 3.0.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.esm.js
CHANGED
|
@@ -1373,6 +1373,8 @@ var addGoodDiscount = /*#__PURE__*/(function () {
|
|
|
1373
1373
|
taxRate: good.taxRate,
|
|
1374
1374
|
itemName: good.itemName,
|
|
1375
1375
|
itemNameSelf: good.itemNameSelf,
|
|
1376
|
+
favouredPolicyMark: good.favouredPolicyMark,
|
|
1377
|
+
favouredPolicyName: good.favouredPolicyName,
|
|
1376
1378
|
discountGroup: discountGroup,
|
|
1377
1379
|
lineAmountIncludeTax: lineAmountIncludeTax,
|
|
1378
1380
|
lineAmountExcludeTax: lineAmountExcludeTax,
|
|
@@ -8855,22 +8857,23 @@ var onChangeTaxRate = lazyFn(function (controller, form, record) {
|
|
|
8855
8857
|
switch (_context6.prev = _context6.next) {
|
|
8856
8858
|
case 0:
|
|
8857
8859
|
err = err || {};
|
|
8860
|
+
debugger;
|
|
8858
8861
|
|
|
8859
8862
|
if (!(promptErr(err.taxRate) || !values.taxRate && values.taxRate !== 0)) {
|
|
8860
|
-
_context6.next =
|
|
8863
|
+
_context6.next = 4;
|
|
8861
8864
|
break;
|
|
8862
8865
|
}
|
|
8863
8866
|
|
|
8864
8867
|
return _context6.abrupt("return");
|
|
8865
8868
|
|
|
8866
|
-
case
|
|
8869
|
+
case 4:
|
|
8867
8870
|
taxRate = parseFloat(values.taxRate);
|
|
8868
|
-
_context6.next =
|
|
8871
|
+
_context6.next = 7;
|
|
8869
8872
|
return controller.setEditGood({
|
|
8870
8873
|
taxRate: taxRate
|
|
8871
8874
|
});
|
|
8872
8875
|
|
|
8873
|
-
case
|
|
8876
|
+
case 7:
|
|
8874
8877
|
// 去掉赋码
|
|
8875
8878
|
(function () {
|
|
8876
8879
|
var cache = controller.state.goodsListState.endowCode.cache;
|
|
@@ -8891,7 +8894,7 @@ var onChangeTaxRate = lazyFn(function (controller, form, record) {
|
|
|
8891
8894
|
updateUnitPriceTax(controller, form);
|
|
8892
8895
|
}
|
|
8893
8896
|
|
|
8894
|
-
case
|
|
8897
|
+
case 9:
|
|
8895
8898
|
case "end":
|
|
8896
8899
|
return _context6.stop();
|
|
8897
8900
|
}
|
|
@@ -8962,7 +8965,7 @@ var updateUnitPriceExcludingTax = function updateUnitPriceExcludingTax(controlle
|
|
|
8962
8965
|
|
|
8963
8966
|
case 5:
|
|
8964
8967
|
// 计算 金额(不含税)
|
|
8965
|
-
if (taxAmount && !promptErr(err.lineAmountIncludeTax)) {
|
|
8968
|
+
if ((taxAmount || taxAmount === 0) && !promptErr(err.lineAmountIncludeTax)) {
|
|
8966
8969
|
lineAmountExcludeTax = countAmountExcludeTax(values.lineAmountIncludeTax, taxAmount);
|
|
8967
8970
|
}
|
|
8968
8971
|
|
package/dist/index.js
CHANGED
|
@@ -1383,6 +1383,8 @@ var addGoodDiscount = /*#__PURE__*/(function () {
|
|
|
1383
1383
|
taxRate: good.taxRate,
|
|
1384
1384
|
itemName: good.itemName,
|
|
1385
1385
|
itemNameSelf: good.itemNameSelf,
|
|
1386
|
+
favouredPolicyMark: good.favouredPolicyMark,
|
|
1387
|
+
favouredPolicyName: good.favouredPolicyName,
|
|
1386
1388
|
discountGroup: discountGroup,
|
|
1387
1389
|
lineAmountIncludeTax: lineAmountIncludeTax,
|
|
1388
1390
|
lineAmountExcludeTax: lineAmountExcludeTax,
|
|
@@ -8865,22 +8867,23 @@ var onChangeTaxRate = lazyFn(function (controller, form, record) {
|
|
|
8865
8867
|
switch (_context6.prev = _context6.next) {
|
|
8866
8868
|
case 0:
|
|
8867
8869
|
err = err || {};
|
|
8870
|
+
debugger;
|
|
8868
8871
|
|
|
8869
8872
|
if (!(promptErr(err.taxRate) || !values.taxRate && values.taxRate !== 0)) {
|
|
8870
|
-
_context6.next =
|
|
8873
|
+
_context6.next = 4;
|
|
8871
8874
|
break;
|
|
8872
8875
|
}
|
|
8873
8876
|
|
|
8874
8877
|
return _context6.abrupt("return");
|
|
8875
8878
|
|
|
8876
|
-
case
|
|
8879
|
+
case 4:
|
|
8877
8880
|
taxRate = parseFloat(values.taxRate);
|
|
8878
|
-
_context6.next =
|
|
8881
|
+
_context6.next = 7;
|
|
8879
8882
|
return controller.setEditGood({
|
|
8880
8883
|
taxRate: taxRate
|
|
8881
8884
|
});
|
|
8882
8885
|
|
|
8883
|
-
case
|
|
8886
|
+
case 7:
|
|
8884
8887
|
// 去掉赋码
|
|
8885
8888
|
(function () {
|
|
8886
8889
|
var cache = controller.state.goodsListState.endowCode.cache;
|
|
@@ -8901,7 +8904,7 @@ var onChangeTaxRate = lazyFn(function (controller, form, record) {
|
|
|
8901
8904
|
updateUnitPriceTax(controller, form);
|
|
8902
8905
|
}
|
|
8903
8906
|
|
|
8904
|
-
case
|
|
8907
|
+
case 9:
|
|
8905
8908
|
case "end":
|
|
8906
8909
|
return _context6.stop();
|
|
8907
8910
|
}
|
|
@@ -8972,7 +8975,7 @@ var updateUnitPriceExcludingTax = function updateUnitPriceExcludingTax(controlle
|
|
|
8972
8975
|
|
|
8973
8976
|
case 5:
|
|
8974
8977
|
// 计算 金额(不含税)
|
|
8975
|
-
if (taxAmount && !promptErr(err.lineAmountIncludeTax)) {
|
|
8978
|
+
if ((taxAmount || taxAmount === 0) && !promptErr(err.lineAmountIncludeTax)) {
|
|
8976
8979
|
lineAmountExcludeTax = countAmountExcludeTax(values.lineAmountIncludeTax, taxAmount);
|
|
8977
8980
|
}
|
|
8978
8981
|
|
package/package.json
CHANGED
|
@@ -110,6 +110,8 @@ export default async (state: InvoiceControllerState, options?: IOptions) => {
|
|
|
110
110
|
taxRate: good.taxRate,
|
|
111
111
|
itemName:good.itemName,
|
|
112
112
|
itemNameSelf:good.itemNameSelf,
|
|
113
|
+
favouredPolicyMark: good.favouredPolicyMark,
|
|
114
|
+
favouredPolicyName: good.favouredPolicyName,
|
|
113
115
|
discountGroup,
|
|
114
116
|
lineAmountIncludeTax,
|
|
115
117
|
lineAmountExcludeTax,
|
|
@@ -257,6 +257,7 @@ export const onChangeTaxRate = lazyFn(
|
|
|
257
257
|
|
|
258
258
|
form.validateFields(async (err, values) => {
|
|
259
259
|
err = err || {};
|
|
260
|
+
debugger;
|
|
260
261
|
if (promptErr(err.taxRate) || (!values.taxRate && values.taxRate !== 0)) return;
|
|
261
262
|
|
|
262
263
|
let taxRate = parseFloat(values.taxRate);
|
|
@@ -338,7 +339,7 @@ export const updateUnitPriceExcludingTax = (controller: InvoiceController, form:
|
|
|
338
339
|
await controller.setEditGood({ taxAmount });
|
|
339
340
|
|
|
340
341
|
// 计算 金额(不含税)
|
|
341
|
-
if (taxAmount && !promptErr(err.lineAmountIncludeTax)) {
|
|
342
|
+
if ((taxAmount || taxAmount===0) && !promptErr(err.lineAmountIncludeTax)) {
|
|
342
343
|
lineAmountExcludeTax = countAmountExcludeTax(values.lineAmountIncludeTax, taxAmount);
|
|
343
344
|
}
|
|
344
345
|
form.setFieldsValue({ lineAmountExcludeTax });
|