@unimaze/billing 0.1.2-rc.7 → 0.1.2-rc.9
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/lib/common/components/attachments/Attachment.d.ts +4 -1
- package/lib/common/components/attachments/Attachment.js +5 -2
- package/lib/common/components/attachments/index.d.ts +5 -1
- package/lib/common/components/attachments/index.js +4 -3
- package/lib/common/components/base-information/index.js +68 -78
- package/lib/common/components/billing-lines/BillingLIneFormData.d.ts +6 -0
- package/lib/common/components/billing-lines/BillingLIneFormData.js +6 -0
- package/lib/common/components/delivery-location/index.js +13 -7
- package/lib/common/components/form-item/index.d.ts +18 -0
- package/lib/common/components/form-item/index.js +20 -0
- package/lib/common/components/supplier/index.js +31 -25
- package/lib/common/types/ReceiverRequirements.d.ts +71 -15
- package/lib/common/types/ReceiverRequirements.js +410 -8
- package/lib/create-credit-note/index.js +1 -2
- package/lib/create-invoice/index.js +47 -6
- package/lib/src/common/components/attachments/Attachment.d.ts +4 -1
- package/lib/src/common/components/attachments/index.d.ts +5 -1
- package/lib/src/common/components/billing-lines/BillingLIneFormData.d.ts +6 -0
- package/lib/src/common/components/form-item/index.d.ts +18 -0
- package/lib/src/common/types/ReceiverRequirements.d.ts +71 -15
- package/lib/src/utils/ApiUtility.d.ts +8 -1
- package/lib/src/utils/ConversionUtility.d.ts +2 -1
- package/lib/src/utils/RequirementsUtility.d.ts +3 -1
- package/lib/src/utils/index.d.ts +1 -1
- package/lib/style/index.css +0 -1222
- package/lib/utils/ApiUtility.d.ts +8 -1
- package/lib/utils/ApiUtility.js +17 -1
- package/lib/utils/ConversionUtility.d.ts +2 -1
- package/lib/utils/ConversionUtility.js +98 -50
- package/lib/utils/RequirementsUtility.d.ts +3 -1
- package/lib/utils/RequirementsUtility.js +15 -5
- package/lib/utils/index.d.ts +1 -1
- package/lib/utils/index.js +1 -0
- package/package.json +1 -1
- package/lib/common/components/component-container/style/index.d.ts +0 -1
- package/lib/common/components/component-container/style/index.js +0 -3
- package/lib/common/components/issuer/index.d.ts +0 -7
- package/lib/common/components/issuer/index.js +0 -28
- package/lib/common/components/payer/index.d.ts +0 -3
- package/lib/common/components/payer/index.js +0 -51
- package/lib/src/common/components/issuer/index.d.ts +0 -7
- package/lib/src/common/components/payer/index.d.ts +0 -3
- package/lib/style/index.d.ts +0 -1
- package/lib/style/index.js +0 -3
|
@@ -1,25 +1,81 @@
|
|
|
1
|
-
interface
|
|
2
|
-
key
|
|
3
|
-
value: string;
|
|
4
|
-
}
|
|
5
|
-
interface FieldRequirement {
|
|
1
|
+
interface Values {
|
|
2
|
+
key?: string;
|
|
6
3
|
label?: string;
|
|
7
|
-
|
|
4
|
+
values?: Values[];
|
|
5
|
+
}
|
|
6
|
+
interface FieldRequirement extends Values {
|
|
8
7
|
isRequired: boolean;
|
|
9
|
-
values?: KeyValuePair[];
|
|
10
8
|
}
|
|
11
9
|
declare type ReceiverRequirements = {
|
|
12
10
|
[key in AvailableFields]?: FieldRequirement;
|
|
13
11
|
};
|
|
14
12
|
export declare enum AvailableFields {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
13
|
+
"invoiceNo" = "invoiceNo",
|
|
14
|
+
"issueDate" = "issueDate",
|
|
15
|
+
"dueDate" = "dueDate",
|
|
16
|
+
"graceDate" = "graceDate",
|
|
17
|
+
"currencyCode" = "currencyCode",
|
|
18
|
+
"notes" = "notes",
|
|
19
|
+
"accountingCost" = "accountingCost",
|
|
20
|
+
"buyerReference" = "buyerReference",
|
|
21
|
+
"orderReference.documentNo" = "orderReference.documentNo",
|
|
22
|
+
"billingReferences.invoices" = "billingReferences.invoices",
|
|
23
|
+
"billingReferences.documentNo" = "billingReferences.documentNo",
|
|
24
|
+
"billingReferences.issueDate" = "billingReferences.issueDate",
|
|
25
|
+
"billingReferences.creditNotes" = "billingReferences.creditNotes",
|
|
26
|
+
"referenceIdentifiers.type" = "referenceIdentifiers.type",
|
|
27
|
+
"referenceIdentifiers.code" = "referenceIdentifiers.code",
|
|
28
|
+
"referenceIdentifiers.value" = "referenceIdentifiers.value",
|
|
29
|
+
"referenceIdentifiers" = "referenceIdentifiers",
|
|
30
|
+
"supplier.vatNumber" = "supplier.vatNumber",
|
|
31
|
+
"supplier.address.streetNameAndNumber" = "supplier.address.streetNameAndNumber",
|
|
32
|
+
"supplier.address.city" = "supplier.address.city",
|
|
33
|
+
"supplier.address.postalZone" = "supplier.address.postalZone",
|
|
34
|
+
"supplier.address.countryCode" = "supplier.address.countryCode",
|
|
35
|
+
"supplier.contact.name" = "supplier.contact.name",
|
|
36
|
+
"supplier.contact.electronicMail" = "supplier.contact.electronicMail",
|
|
37
|
+
"supplier.contact.telephone" = "supplier.contact.telephone",
|
|
38
|
+
"supplier.name" = "supplier.name",
|
|
39
|
+
"supplier.identifier" = "supplier.identifier",
|
|
40
|
+
"customer.address.streetNameAndNumber" = "customer.address.streetNameAndNumber",
|
|
41
|
+
"customer.address.city" = "customer.address.city",
|
|
42
|
+
"customer.address.postalZone" = "customer.address.postalZone",
|
|
43
|
+
"customer.address.countryCode" = "customer.address.countryCode",
|
|
44
|
+
"customer.contact.name" = "customer.contact.name",
|
|
45
|
+
"customer.contact.electronicMail" = "customer.contact.electronicMail",
|
|
46
|
+
"customer.contact.telephone" = "customer.contact.telephone",
|
|
47
|
+
"customer.name" = "customer.name",
|
|
48
|
+
"customer.identifier" = "customer.identifier",
|
|
49
|
+
"customer.locationIdentifier" = "customer.locationIdentifier",
|
|
50
|
+
"payee.name" = "payee.name",
|
|
51
|
+
"payee.identifier" = "payee.identifier",
|
|
52
|
+
"payee.sepaBankIdentification" = "payee.sepaBankIdentification",
|
|
53
|
+
"invoiceLines.itemNo" = "invoiceLines.itemNo",
|
|
54
|
+
"invoiceLines.name" = "invoiceLines.name",
|
|
55
|
+
"invoiceLines.quantity" = "invoiceLines.quantity",
|
|
56
|
+
"invoiceLines.uniteOfMeasure.unit" = "invoiceLines.unitOfMeasure.unit",
|
|
57
|
+
"invoiceLines.uniteOfMeasure.code" = "invoiceLines.unitOfMeasure.code",
|
|
58
|
+
"invoiceLines.priceAmount" = "invoiceLines.priceAmount",
|
|
59
|
+
"invoiceLines.taxCategoryType" = "invoiceLines.taxCategoryType",
|
|
60
|
+
"invoiceLines.taxableAmount" = "invoiceLines.taxableAmount",
|
|
61
|
+
"invoiceLines.taxAmount" = "invoiceLines.taxAmount",
|
|
62
|
+
"invoiceLines.taxPercentage" = "invoiceLines.taxPercentage",
|
|
63
|
+
"invoiceLines.discountValue" = "invoiceLines.discountValue",
|
|
64
|
+
"paymentTerms.note" = "paymentTerms.note",
|
|
65
|
+
"paymentMeans.type" = "paymentMeans.type",
|
|
66
|
+
"paymentMeans.internationalTransfer" = "paymentMeans.internationalTransfer",
|
|
67
|
+
"paymentMeans.domesticTransfer" = "paymentMeans.domesticTransfer",
|
|
68
|
+
"paymentMeans.domesticClaim" = "paymentMeans.domesticClaim",
|
|
69
|
+
"delivery.partyName" = "delivery.partyName",
|
|
70
|
+
"delivery.locationIdentifier" = "delivery.locationIdentifier",
|
|
71
|
+
"delivery.address.streetNameAndNumber" = "delivery.address.streetNameAndNumber",
|
|
72
|
+
"delivery.address.city" = "delivery.address.city",
|
|
73
|
+
"delivery.address.postalZone" = "delivery.address.postalZone",
|
|
74
|
+
"delivery.address.countryCode" = "delivery.address.countryCode",
|
|
75
|
+
"delivery.actualDeliveryDate" = "delivery.actualDeliveryDate",
|
|
76
|
+
"prepaidAmount" = "prepaidAmount",
|
|
77
|
+
"payableAmount" = "payableAmount",
|
|
78
|
+
"payableRoundingAmount" = "payableRoundingAmount"
|
|
23
79
|
}
|
|
24
80
|
export { ReceiverRequirements, FieldRequirement };
|
|
25
81
|
export declare const receiverRequirementsObject: ReceiverRequirements;
|
|
@@ -10,5 +10,12 @@ interface CreateSubmitInvoice {
|
|
|
10
10
|
services?: string[];
|
|
11
11
|
invoiceMetadataInput?: InvoiceMetadataInput;
|
|
12
12
|
}
|
|
13
|
+
interface AttachDocument {
|
|
14
|
+
messageId: string;
|
|
15
|
+
name: string;
|
|
16
|
+
contentType: string;
|
|
17
|
+
more: boolean;
|
|
18
|
+
}
|
|
19
|
+
declare const submitDocument: (data: any, attachDocument: AttachDocument, mapiBaseUrl: string, apiKey?: string | undefined) => AxiosPromise<mapi.MessageOutput>;
|
|
13
20
|
declare const submitInvoice: (createSubmitInvoice: CreateSubmitInvoice, mapiBaseUrl: string, apiKey?: string | undefined, callName?: string | undefined, language?: LanguageProp) => AxiosPromise<mapi.MessageOutput>;
|
|
14
|
-
export { submitInvoice, CreateSubmitInvoice };
|
|
21
|
+
export { submitInvoice, CreateSubmitInvoice, submitDocument, AttachDocument };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { InvoiceMetadataInput } from "@unimaze/api-clients/lib/mapi";
|
|
2
2
|
import { Store } from "antd/es/form/interface";
|
|
3
3
|
import { ProfileOutput } from "@unimaze/api-clients/lib/wapi2";
|
|
4
|
-
|
|
4
|
+
import { IBillingLinesMetadata } from "../common/components/billing-lines/BillingLIneFormData";
|
|
5
|
+
declare const convertToInvoiceMetadataInput: (formValues: Store, billingLines: IBillingLinesMetadata, customer: ProfileOutput) => InvoiceMetadataInput;
|
|
5
6
|
export { /*convertToCreditNoteMetadataInput,*/ convertToInvoiceMetadataInput };
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import { AvailableFields, FieldRequirement, ReceiverRequirements } from "../common/types/ReceiverRequirements";
|
|
2
3
|
export declare const getReceiverRequirements: (recRequirements: ReceiverRequirements, key: AvailableFields) => FieldRequirement;
|
|
3
|
-
export declare const
|
|
4
|
+
export declare const getReceiverRequirementsIsRequired: (recRequirements: ReceiverRequirements, key: AvailableFields, defaultIsRequired: boolean) => boolean;
|
|
5
|
+
export declare const getReceiverRequirementsLabelWithDefault: (recRequirements: ReceiverRequirements, key: AvailableFields, defaultLabel: React.ReactNode) => React.ReactNode;
|
package/lib/src/utils/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { convertToInvoiceMetadataInput } from "./ConversionUtility";
|
|
2
|
-
export { submitInvoice, CreateSubmitInvoice } from "./ApiUtility";
|
|
2
|
+
export { submitInvoice, CreateSubmitInvoice, submitDocument, AttachDocument } from "./ApiUtility";
|