@opencxh/domain 1.291.0 → 1.292.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.
- package/dist/entities/bank/types.d.ts +2 -0
- package/dist/entities/company/identifiers.d.ts +1 -0
- package/dist/entities/company/index.d.ts +1 -1
- package/dist/entities/company/types.d.ts +1 -1
- package/dist/entities/reports/vat.d.ts +6 -0
- package/dist/index.cjs +10 -10
- package/dist/index.js +517 -508
- package/package.json +1 -1
|
@@ -141,10 +141,12 @@ export interface BankRule {
|
|
|
141
141
|
descriptionContains?: string;
|
|
142
142
|
direction?: "in" | "out";
|
|
143
143
|
};
|
|
144
|
+
/** With `financingItemId` the line goes onto that current account; `accountId` is then its account. */
|
|
144
145
|
action: {
|
|
145
146
|
accountId: string;
|
|
146
147
|
taxCode?: string;
|
|
147
148
|
description?: string;
|
|
149
|
+
financingItemId?: string;
|
|
148
150
|
};
|
|
149
151
|
/** High lands in "Klaar om te bevestigen", medium in "Controleren". */
|
|
150
152
|
confidence: "high" | "medium";
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* normalised on write, compared normalised everywhere: `NL91 abna 0417 1643 00` and
|
|
4
4
|
* `NL91ABNA0417164300` are one account.
|
|
5
5
|
*/
|
|
6
|
+
/** Both are letters and digits only: spaces, dots, dashes and the like are layout. */
|
|
6
7
|
export declare function normalizeIban(value: string): string;
|
|
7
8
|
export declare function normalizeVatNumber(value: string): string;
|
|
8
9
|
/** Normalised, blanks dropped, duplicates removed, order kept. */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { PostalAddress } from '../organization/types';
|
|
2
1
|
import { LifecycleStage } from '../contact/lifecycle';
|
|
2
|
+
import { PostalAddress } from '../organization/types';
|
|
3
3
|
import { OwnerScope } from '../scope/types';
|
|
4
4
|
/** Same meaning as {@link ContactOrigin}: `shadow` is a lazily cached hit, a landed row is `own`. */
|
|
5
5
|
export type CompanyOrigin = "own" | "shadow";
|
|
@@ -14,6 +14,8 @@ export interface VatLine {
|
|
|
14
14
|
taxCents: Cents;
|
|
15
15
|
taxPointDate: string;
|
|
16
16
|
counterpartyCompanyId?: string;
|
|
17
|
+
/** The journal line it came from: the drill-down from a box back to the bookings. */
|
|
18
|
+
ref?: string;
|
|
17
19
|
}
|
|
18
20
|
export declare const NL_VAT_BOXES: readonly ["1a", "1b", "1c", "1d", "1e", "2a", "3a", "3b", "3c", "4a", "4b", "5a", "5b", "5c", "5g"];
|
|
19
21
|
export type VatBox = (typeof NL_VAT_BOXES)[number];
|
|
@@ -35,6 +37,8 @@ export interface VatReturnFigures {
|
|
|
35
37
|
}[];
|
|
36
38
|
/** Lines whose code is unknown: they are in no box, and the checklist says so. */
|
|
37
39
|
unknownCodes: string[];
|
|
40
|
+
/** With `trace`: per box, the `ref` of every line that counted in it. */
|
|
41
|
+
refs?: Partial<Record<VatBox, string[]>>;
|
|
38
42
|
}
|
|
39
43
|
/**
|
|
40
44
|
* The boxes for one period. Reverse charge on purchase (`selfAssessed`) is owed in its own box
|
|
@@ -49,6 +53,8 @@ export declare function vatReturn(input: {
|
|
|
49
53
|
taxonomy?: string;
|
|
50
54
|
/** The code a self-assessed purchase is taxed at: the standard rate. */
|
|
51
55
|
standardKey?: string;
|
|
56
|
+
/** Also say which lines counted in which box (`refs`). */
|
|
57
|
+
trace?: boolean;
|
|
52
58
|
}): VatReturnFigures;
|
|
53
59
|
/** The periods a return is filed over, and when it is due: the month after, at its end. */
|
|
54
60
|
export declare function vatPeriods(year: number, cadence?: "quarter" | "month" | "year"): {
|