@unimaze/billing 0.9.0 → 0.10.0
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.
|
@@ -7,4 +7,4 @@ export declare const calculateTaxableAmount: (discountValue: string | null | und
|
|
|
7
7
|
export declare const calculateTaxAmount: (taxableAmount: number, taxPercentage: number) => number;
|
|
8
8
|
export declare const calculateTaxPercentage: (taxCategoryType: TaxCategoryTypeEnum) => number;
|
|
9
9
|
export declare const generateTaxCategoryLabel: (taxCategoryType: TaxCategoryTypeEnum, taxCategoryTypeTranslated: string) => string;
|
|
10
|
-
export declare const getCorrectInputNode: (dataIdx: "key" | "name" | "description" | "referenceIdentifiers" | "notes" | "accountingCost" | "billingPeriod" | "unitOfMeasure" | "taxCategoryType" | "itemNo" | "quantity" | "unitPriceAmount" | "taxableAmount" | "taxAmount" | "taxPercentage" | "discountValue" | "discountReason" | "
|
|
10
|
+
export declare const getCorrectInputNode: (dataIdx: "key" | "name" | "description" | "referenceIdentifiers" | "notes" | "accountingCost" | "billingPeriod" | "unitOfMeasure" | "taxCategoryType" | "itemNo" | "quantity" | "unitPriceAmount" | "taxableAmount" | "taxAmount" | "taxPercentage" | "discountValue" | "discountReason" | "buyersItemNo" | "standardItemNo" | "originCountryCode" | "commodityClassification" | "additionalItemProperties" | "orderLineReference") => React.ReactChild;
|
|
@@ -35,15 +35,16 @@ var isEmpty = function (map) {
|
|
|
35
35
|
};
|
|
36
36
|
var getIdentifierWithPrefix = function (identifier) {
|
|
37
37
|
if (!identifier.startsWith("0196:")) {
|
|
38
|
-
return "0196:" + identifier
|
|
38
|
+
return "0196:" + cleanIdentifier(identifier);
|
|
39
39
|
}
|
|
40
40
|
else {
|
|
41
|
-
return
|
|
41
|
+
return cleanIdentifier(identifier);
|
|
42
42
|
}
|
|
43
43
|
};
|
|
44
|
-
|
|
45
|
-
//
|
|
46
|
-
//
|
|
44
|
+
var cleanIdentifier = function (identifier) {
|
|
45
|
+
// return identifier.replace(/[^0-9]/g, "") // replace anything that isn't a numeric character
|
|
46
|
+
return identifier.replace("-", ""); // remove the '-'
|
|
47
|
+
};
|
|
47
48
|
var convertToInvoiceMetadataInput = function (formValues, billingLines, paymentMethod, chosenCustomer) {
|
|
48
49
|
var issueDate = convertDates(formValues.invoice.issueDate);
|
|
49
50
|
var dueDate = convertDates(formValues.invoice.dueDate);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unimaze/billing",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@ant-design/compatible": "latest",
|
|
12
12
|
"@types/react-google-recaptcha": "^2.1.0",
|
|
13
|
-
"@unimaze/api-clients": "
|
|
13
|
+
"@unimaze/api-clients": "1.2.1",
|
|
14
14
|
"antd-mask-input": "^0.1.13",
|
|
15
15
|
"react-google-recaptcha": "^2.1.0",
|
|
16
16
|
"react-hot-loader": "^4.12.20",
|