@unimaze/billing 0.1.0 → 0.1.2-rc.10
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/README.md +11 -3
- package/lib/common/components/attachments/Attachment.d.ts +8 -2
- package/lib/common/components/attachments/Attachment.js +33 -8
- package/lib/common/components/attachments/index.d.ts +9 -2
- package/lib/common/components/attachments/index.js +15 -6
- package/lib/common/components/base-information/ReferenceIdentifiers.d.ts +6 -0
- package/lib/common/components/base-information/ReferenceIdentifiers.js +40 -0
- package/lib/common/components/base-information/index.d.ts +6 -3
- package/lib/common/components/base-information/index.js +100 -81
- package/lib/common/components/billing-lines/BillingCalculations.d.ts +11 -0
- package/lib/common/components/billing-lines/BillingCalculations.js +61 -0
- package/lib/common/components/billing-lines/BillingTaxSummary.d.ts +10 -0
- package/lib/common/components/billing-lines/BillingTaxSummary.js +51 -0
- package/lib/common/components/billing-lines/billingLIneFormData.d.ts +7 -0
- package/lib/common/components/billing-lines/billingLIneFormData.js +63 -0
- package/lib/common/components/billing-lines/index.d.ts +10 -24
- package/lib/common/components/billing-lines/index.js +117 -39
- package/lib/common/components/customer/hardCoddedCustomer.d.ts +7 -0
- package/lib/common/components/{issuer/index.js → customer/hardCoddedCustomer.js} +5 -8
- package/lib/common/components/customer/index.d.ts +6 -0
- package/lib/common/components/customer/index.js +93 -0
- package/lib/common/components/delivery-location/index.d.ts +5 -2
- package/lib/common/components/delivery-location/index.js +43 -11
- package/lib/common/components/editable-cell/index.d.ts +1 -1
- package/lib/common/components/editable-cell/index.js +77 -11
- package/lib/common/components/editable-row/index.d.ts +5 -5
- package/lib/common/components/editable-row/index.js +8 -6
- package/lib/common/components/form-item/index.d.ts +21 -0
- package/lib/common/components/form-item/index.js +27 -0
- package/lib/common/components/index.d.ts +10 -5
- package/lib/common/components/index.js +20 -8
- package/lib/common/components/locale-intl/index.d.ts +10 -0
- package/lib/common/components/locale-intl/index.js +45 -0
- package/lib/common/components/payment-method/index.d.ts +6 -3
- package/lib/common/components/payment-method/index.js +67 -27
- package/lib/common/components/supplier/index.d.ts +6 -0
- package/lib/common/components/supplier/index.js +93 -0
- package/lib/common/consts/validationRules.d.ts +2 -3
- package/lib/common/consts/validationRules.js +1 -8
- package/lib/common/enums/index.d.ts +1 -1
- package/lib/common/enums/index.js +2 -4
- package/lib/common/types/BillingLineMetadataOverride.d.ts +2 -1
- package/lib/common/types/ReceiverRequirements.d.ts +81 -0
- package/lib/common/types/ReceiverRequirements.js +379 -0
- package/lib/create-credit-note/index.d.ts +2 -3
- package/lib/create-credit-note/index.js +17 -28
- package/lib/create-invoice/index.d.ts +1 -2
- package/lib/create-invoice/index.js +79 -21
- package/lib/example/src/index.d.ts +1 -1
- package/lib/index.d.ts +2 -3
- package/lib/index.js +8 -5
- package/lib/src/common/components/attachments/Attachment.d.ts +21 -0
- package/lib/src/common/components/attachments/index.d.ts +10 -0
- package/lib/src/common/components/base-information/ReferenceIdentifiers.d.ts +6 -0
- package/lib/src/common/components/base-information/index.d.ts +12 -0
- package/lib/src/common/components/billing-lines/BillingCalculations.d.ts +11 -0
- package/lib/src/common/components/billing-lines/BillingTaxSummary.d.ts +10 -0
- package/lib/src/common/components/billing-lines/billingLIneFormData.d.ts +7 -0
- package/lib/src/common/components/billing-lines/index.d.ts +13 -0
- package/lib/src/common/components/component-container/Content.d.ts +7 -0
- package/lib/src/common/components/component-container/Header.d.ts +9 -0
- package/lib/src/common/components/component-container/index.d.ts +10 -0
- package/lib/src/common/components/customer/index.d.ts +6 -0
- package/lib/src/common/components/delivery-location/index.d.ts +6 -0
- package/lib/src/common/components/editable-cell/index.d.ts +11 -0
- package/lib/src/common/components/editable-row/index.d.ts +6 -0
- package/lib/src/common/components/form-item/index.d.ts +21 -0
- package/lib/src/common/components/index.d.ts +10 -0
- package/lib/src/common/components/locale-intl/index.d.ts +10 -0
- package/lib/src/common/components/payment-method/index.d.ts +6 -0
- package/lib/src/common/components/supplier/index.d.ts +6 -0
- package/lib/src/common/consts/validationRules.d.ts +6 -0
- package/lib/src/common/types/ReceiverRequirements.d.ts +81 -0
- package/lib/src/create-invoice/index.d.ts +14 -0
- package/lib/src/translations/locales.d.ts +74 -0
- package/lib/src/utils/ApiUtility.d.ts +21 -0
- package/lib/src/utils/BillingLineUtility.d.ts +8 -0
- package/lib/src/utils/ConversionUtility.d.ts +5 -0
- package/lib/src/utils/RequirementsUtility.d.ts +5 -0
- package/lib/src/utils/billingLineFormData.d.ts +7 -0
- package/lib/src/utils/index.d.ts +2 -0
- package/lib/style/index.css +0 -1222
- package/lib/translations/locales/is.json +70 -0
- package/lib/translations/locales.d.ts +74 -0
- package/lib/translations/locales.js +10 -0
- package/lib/utils/ApiUtility.d.ts +21 -0
- package/lib/utils/ApiUtility.js +59 -0
- package/lib/utils/BillingLineUtility.d.ts +8 -0
- package/lib/utils/BillingLineUtility.js +66 -0
- package/lib/utils/ConversionUtility.d.ts +5 -0
- package/lib/utils/ConversionUtility.js +146 -0
- package/lib/utils/RequirementsUtility.d.ts +5 -0
- package/lib/utils/RequirementsUtility.js +23 -0
- package/lib/utils/billingLineFormData.d.ts +7 -0
- package/lib/utils/billingLineFormData.js +63 -0
- package/lib/utils/index.d.ts +2 -5
- package/lib/utils/index.js +5 -162
- package/package.json +22 -7
- package/lib/common/components/issuer/index.d.ts +0 -7
- package/lib/common/components/payer/index.d.ts +0 -3
- package/lib/common/components/payer/index.js +0 -50
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { BillingLineMetadata, InvoiceMetadataInput } from "@unimaze/api-clients/lib/mapi";
|
|
2
|
+
import { Store } from "antd/es/form/interface";
|
|
3
|
+
import { ProfileOutput } from "@unimaze/api-clients/lib/wapi2";
|
|
4
|
+
declare const convertToInvoiceMetadataInput: (formValues: Store, billingLines: BillingLineMetadata[], customer?: ProfileOutput | undefined) => InvoiceMetadataInput;
|
|
5
|
+
export { /*convertToCreditNoteMetadataInput,*/ convertToInvoiceMetadataInput };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { AvailableFields, FieldRequirement, ReceiverRequirements } from "../common/types/ReceiverRequirements";
|
|
3
|
+
export declare const getReceiverRequirements: (recRequirements: ReceiverRequirements, key: AvailableFields) => FieldRequirement;
|
|
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;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { BillingLineMetadata } from '@unimaze/api-clients/lib/mapi';
|
|
2
|
+
import { FormInstance } from "antd/es/form";
|
|
3
|
+
import { TaxCategoryTypeEnum } from "@unimaze/api-clients/lib/mapi/api";
|
|
4
|
+
export declare const billingLinesFieldsMetadata: (formInstance: FormInstance) => BillingLineMetadata[];
|
|
5
|
+
export declare const calculateTaxableAmount: (discountValue: string | null | undefined, quantity: number | null, unitPriceAmount: number | null) => number;
|
|
6
|
+
export declare const calculateTaxAmount: (taxableAmount: number, taxPercentage: number) => number;
|
|
7
|
+
export declare const calculateTaxPercentage: (taxCategoryType: TaxCategoryTypeEnum) => number;
|