kts-component-invoice-operate 3.0.12 → 3.0.14
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
|
@@ -1375,6 +1375,7 @@ var addGoodDiscount = /*#__PURE__*/(function () {
|
|
|
1375
1375
|
itemNameSelf: good.itemNameSelf,
|
|
1376
1376
|
favouredPolicyMark: good.favouredPolicyMark,
|
|
1377
1377
|
favouredPolicyName: good.favouredPolicyName,
|
|
1378
|
+
taxFreeType: good.taxFreeType,
|
|
1378
1379
|
discountGroup: discountGroup,
|
|
1379
1380
|
lineAmountIncludeTax: lineAmountIncludeTax,
|
|
1380
1381
|
lineAmountExcludeTax: lineAmountExcludeTax,
|
package/dist/index.js
CHANGED
|
@@ -1385,6 +1385,7 @@ var addGoodDiscount = /*#__PURE__*/(function () {
|
|
|
1385
1385
|
itemNameSelf: good.itemNameSelf,
|
|
1386
1386
|
favouredPolicyMark: good.favouredPolicyMark,
|
|
1387
1387
|
favouredPolicyName: good.favouredPolicyName,
|
|
1388
|
+
taxFreeType: good.taxFreeType,
|
|
1388
1389
|
discountGroup: discountGroup,
|
|
1389
1390
|
lineAmountIncludeTax: lineAmountIncludeTax,
|
|
1390
1391
|
lineAmountExcludeTax: lineAmountExcludeTax,
|
package/package.json
CHANGED
|
@@ -30,7 +30,7 @@ export interface IOptions {
|
|
|
30
30
|
*/
|
|
31
31
|
export default async (state: InvoiceControllerState, options?: IOptions) => {
|
|
32
32
|
if (!options) return;
|
|
33
|
-
|
|
33
|
+
|
|
34
34
|
const { indexList = [] } = options;
|
|
35
35
|
const discount = chain(bignumber(options.discount || 0)).dotDivide(bignumber(100)).done();
|
|
36
36
|
const goodsMap = state.goodsListState.goodsMap;
|
|
@@ -94,13 +94,14 @@ export default async (state: InvoiceControllerState, options?: IOptions) => {
|
|
|
94
94
|
.multiply(chain(bignumber(1)).add(taxRate).done())
|
|
95
95
|
.done().toNumber()) as number
|
|
96
96
|
}
|
|
97
|
-
|
|
97
|
+
|
|
98
98
|
/** 税额 */
|
|
99
99
|
const taxAmount = chain(bignumber(lineAmountIncludeTax))
|
|
100
100
|
.subtract(bignumber(lineAmountExcludeTax))
|
|
101
101
|
.done()
|
|
102
102
|
.toNumber();
|
|
103
103
|
|
|
104
|
+
|
|
104
105
|
good.discountGroup = discountGroup;
|
|
105
106
|
good.lineAttribute = LineAttributeType.被折扣行;
|
|
106
107
|
goodsList.splice(i + 1, 0, {
|
|
@@ -108,10 +109,11 @@ export default async (state: InvoiceControllerState, options?: IOptions) => {
|
|
|
108
109
|
lineAttribute: LineAttributeType.折扣行,
|
|
109
110
|
taxClassificationCode: good.taxClassificationCode,
|
|
110
111
|
taxRate: good.taxRate,
|
|
111
|
-
itemName:good.itemName,
|
|
112
|
-
itemNameSelf:good.itemNameSelf,
|
|
112
|
+
itemName: good.itemName,
|
|
113
|
+
itemNameSelf: good.itemNameSelf,
|
|
113
114
|
favouredPolicyMark: good.favouredPolicyMark,
|
|
114
115
|
favouredPolicyName: good.favouredPolicyName,
|
|
116
|
+
taxFreeType: good.taxFreeType,
|
|
115
117
|
discountGroup,
|
|
116
118
|
lineAmountIncludeTax,
|
|
117
119
|
lineAmountExcludeTax,
|
|
@@ -176,7 +176,7 @@ const lines: any[] = [
|
|
|
176
176
|
"taxDiscount": 576.38,
|
|
177
177
|
"taxRate": 13,
|
|
178
178
|
"unit": "件",
|
|
179
|
-
"zeroTaxRateFlag":
|
|
179
|
+
"zeroTaxRateFlag": 'dddddd'
|
|
180
180
|
},
|
|
181
181
|
{
|
|
182
182
|
"buyersItemCode": null,
|
|
@@ -1093,4 +1093,4 @@ const moke = [
|
|
|
1093
1093
|
"zzstsgl": "",
|
|
1094
1094
|
"zzszcyj": ""
|
|
1095
1095
|
}
|
|
1096
|
-
]
|
|
1096
|
+
].map(e => ({ ...e, "zeroTaxRateFlag": 'dddddd' }))
|