@bisondesk/core-sdk 1.0.23-B → 1.0.25
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/constants.d.ts +0 -77
- package/lib/constants.d.ts.map +1 -1
- package/lib/constants.js +1 -924
- package/lib/constants.js.map +1 -1
- package/lib/types/crm.d.ts +30 -102
- package/lib/types/crm.d.ts.map +1 -1
- package/lib/types/crm.js +0 -16
- package/lib/types/crm.js.map +1 -1
- package/lib/types/definitions.d.ts +13 -15
- package/lib/types/definitions.d.ts.map +1 -1
- package/lib/types/fields.d.ts +25 -26
- package/lib/types/fields.d.ts.map +1 -1
- package/lib/types/fields.js +0 -4
- package/lib/types/fields.js.map +1 -1
- package/lib/types/interests.d.ts +31 -0
- package/lib/types/interests.d.ts.map +1 -0
- package/lib/types/{settings.js → interests.js} +1 -1
- package/lib/types/interests.js.map +1 -0
- package/lib/types/picklists.d.ts +4 -15
- package/lib/types/picklists.d.ts.map +1 -1
- package/lib/types/search.d.ts +4 -26
- package/lib/types/search.d.ts.map +1 -1
- package/lib/types/search.js.map +1 -1
- package/lib/types/storage.d.ts +11 -1
- package/lib/types/storage.d.ts.map +1 -1
- package/lib/types/storage.js +0 -15
- package/lib/types/storage.js.map +1 -1
- package/lib/types/tenants.d.ts +9 -32
- package/lib/types/tenants.d.ts.map +1 -1
- package/lib/types/tenants.js +0 -11
- package/lib/types/tenants.js.map +1 -1
- package/lib/types/users.d.ts +3 -11
- package/lib/types/users.d.ts.map +1 -1
- package/lib/types/utils.d.ts +0 -20
- package/lib/types/utils.d.ts.map +1 -1
- package/lib/types/utils.js +0 -6
- package/lib/types/utils.js.map +1 -1
- package/lib/types/vehicles.d.ts +92 -406
- package/lib/types/vehicles.d.ts.map +1 -1
- package/lib/types/vehicles.js +1 -54
- package/lib/types/vehicles.js.map +1 -1
- package/package.json +6 -8
- package/src/constants.ts +1 -930
- package/src/types/crm.ts +30 -117
- package/src/types/definitions.ts +12 -19
- package/src/types/fields.ts +31 -72
- package/src/types/interests.ts +28 -0
- package/src/types/picklists.ts +7 -26
- package/src/types/search.ts +4 -34
- package/src/types/storage.ts +12 -1
- package/src/types/tenants.ts +11 -37
- package/src/types/users.ts +3 -17
- package/src/types/utils.ts +0 -25
- package/src/types/vehicles.ts +93 -461
- package/tsconfig.tsbuildinfo +2995 -1
- package/lib/apis/crm.d.ts +0 -39
- package/lib/apis/crm.d.ts.map +0 -1
- package/lib/apis/crm.js +0 -201
- package/lib/apis/crm.js.map +0 -1
- package/lib/apis/documents.d.ts +0 -4
- package/lib/apis/documents.d.ts.map +0 -1
- package/lib/apis/documents.js +0 -47
- package/lib/apis/documents.js.map +0 -1
- package/lib/apis/internet-vehicles.d.ts +0 -3
- package/lib/apis/internet-vehicles.d.ts.map +0 -1
- package/lib/apis/internet-vehicles.js +0 -27
- package/lib/apis/internet-vehicles.js.map +0 -1
- package/lib/apis/leasing-administration.d.ts +0 -8
- package/lib/apis/leasing-administration.d.ts.map +0 -1
- package/lib/apis/leasing-administration.js +0 -49
- package/lib/apis/leasing-administration.js.map +0 -1
- package/lib/apis/leasing.d.ts +0 -19
- package/lib/apis/leasing.d.ts.map +0 -1
- package/lib/apis/leasing.js +0 -168
- package/lib/apis/leasing.js.map +0 -1
- package/lib/apis/opportunities.d.ts +0 -9
- package/lib/apis/opportunities.d.ts.map +0 -1
- package/lib/apis/opportunities.js +0 -94
- package/lib/apis/opportunities.js.map +0 -1
- package/lib/apis/picklists.d.ts +0 -5
- package/lib/apis/picklists.d.ts.map +0 -1
- package/lib/apis/picklists.js +0 -44
- package/lib/apis/picklists.js.map +0 -1
- package/lib/apis/tenants.d.ts +0 -7
- package/lib/apis/tenants.d.ts.map +0 -1
- package/lib/apis/tenants.js +0 -80
- package/lib/apis/tenants.js.map +0 -1
- package/lib/apis/users.d.ts +0 -3
- package/lib/apis/users.d.ts.map +0 -1
- package/lib/apis/users.js +0 -26
- package/lib/apis/users.js.map +0 -1
- package/lib/apis/utils.d.ts +0 -9
- package/lib/apis/utils.d.ts.map +0 -1
- package/lib/apis/utils.js +0 -23
- package/lib/apis/utils.js.map +0 -1
- package/lib/apis/vehicles.d.ts +0 -18
- package/lib/apis/vehicles.d.ts.map +0 -1
- package/lib/apis/vehicles.js +0 -159
- package/lib/apis/vehicles.js.map +0 -1
- package/lib/ddb-entities.d.ts +0 -2
- package/lib/ddb-entities.d.ts.map +0 -1
- package/lib/ddb-entities.js +0 -5
- package/lib/ddb-entities.js.map +0 -1
- package/lib/types/activities.d.ts +0 -38
- package/lib/types/activities.d.ts.map +0 -1
- package/lib/types/activities.js +0 -16
- package/lib/types/activities.js.map +0 -1
- package/lib/types/documents.d.ts +0 -105
- package/lib/types/documents.d.ts.map +0 -1
- package/lib/types/documents.js +0 -3
- package/lib/types/documents.js.map +0 -1
- package/lib/types/internet-vehicles.d.ts +0 -64
- package/lib/types/internet-vehicles.d.ts.map +0 -1
- package/lib/types/internet-vehicles.js +0 -3
- package/lib/types/internet-vehicles.js.map +0 -1
- package/lib/types/leads.d.ts +0 -134
- package/lib/types/leads.d.ts.map +0 -1
- package/lib/types/leads.js +0 -3
- package/lib/types/leads.js.map +0 -1
- package/lib/types/leasing-administration.d.ts +0 -107
- package/lib/types/leasing-administration.d.ts.map +0 -1
- package/lib/types/leasing-administration.js +0 -3
- package/lib/types/leasing-administration.js.map +0 -1
- package/lib/types/leasing-search.d.ts +0 -22
- package/lib/types/leasing-search.d.ts.map +0 -1
- package/lib/types/leasing-search.js +0 -3
- package/lib/types/leasing-search.js.map +0 -1
- package/lib/types/leasing-settings.d.ts +0 -113
- package/lib/types/leasing-settings.d.ts.map +0 -1
- package/lib/types/leasing-settings.js +0 -10
- package/lib/types/leasing-settings.js.map +0 -1
- package/lib/types/leasing.d.ts +0 -322
- package/lib/types/leasing.d.ts.map +0 -1
- package/lib/types/leasing.js +0 -24
- package/lib/types/leasing.js.map +0 -1
- package/lib/types/machines.d.ts +0 -38
- package/lib/types/machines.d.ts.map +0 -1
- package/lib/types/machines.js +0 -3
- package/lib/types/machines.js.map +0 -1
- package/lib/types/opportunities.d.ts +0 -448
- package/lib/types/opportunities.d.ts.map +0 -1
- package/lib/types/opportunities.js +0 -68
- package/lib/types/opportunities.js.map +0 -1
- package/lib/types/payments.d.ts +0 -38
- package/lib/types/payments.d.ts.map +0 -1
- package/lib/types/payments.js +0 -9
- package/lib/types/payments.js.map +0 -1
- package/lib/types/quotes.d.ts +0 -173
- package/lib/types/quotes.d.ts.map +0 -1
- package/lib/types/quotes.js +0 -26
- package/lib/types/quotes.js.map +0 -1
- package/lib/types/recently-viewed.d.ts +0 -33
- package/lib/types/recently-viewed.d.ts.map +0 -1
- package/lib/types/recently-viewed.js +0 -3
- package/lib/types/recently-viewed.js.map +0 -1
- package/lib/types/saved-filters.d.ts +0 -20
- package/lib/types/saved-filters.d.ts.map +0 -1
- package/lib/types/saved-filters.js +0 -3
- package/lib/types/saved-filters.js.map +0 -1
- package/lib/types/settings.d.ts +0 -50
- package/lib/types/settings.d.ts.map +0 -1
- package/lib/types/settings.js.map +0 -1
- package/lib/types/templates.d.ts +0 -35
- package/lib/types/templates.d.ts.map +0 -1
- package/lib/types/templates.js +0 -9
- package/lib/types/templates.js.map +0 -1
- package/lib/types/website.d.ts +0 -24
- package/lib/types/website.d.ts.map +0 -1
- package/lib/types/website.js +0 -3
- package/lib/types/website.js.map +0 -1
- package/lib/utils/forms.d.ts +0 -6
- package/lib/utils/forms.d.ts.map +0 -1
- package/lib/utils/forms.js +0 -33
- package/lib/utils/forms.js.map +0 -1
- package/lib/utils/leasing.d.ts +0 -3
- package/lib/utils/leasing.d.ts.map +0 -1
- package/lib/utils/leasing.js +0 -10
- package/lib/utils/leasing.js.map +0 -1
- package/lib/utils/slug.d.ts +0 -3
- package/lib/utils/slug.d.ts.map +0 -1
- package/lib/utils/slug.js +0 -23
- package/lib/utils/slug.js.map +0 -1
- package/lib/utils/tenants.d.ts +0 -4
- package/lib/utils/tenants.d.ts.map +0 -1
- package/lib/utils/tenants.js +0 -16
- package/lib/utils/tenants.js.map +0 -1
- package/lib/utils/vehicles.d.ts +0 -12
- package/lib/utils/vehicles.d.ts.map +0 -1
- package/lib/utils/vehicles.js +0 -73
- package/lib/utils/vehicles.js.map +0 -1
- package/src/apis/crm.ts +0 -302
- package/src/apis/documents.ts +0 -54
- package/src/apis/internet-vehicles.ts +0 -23
- package/src/apis/leasing-administration.ts +0 -70
- package/src/apis/leasing.ts +0 -257
- package/src/apis/opportunities.ts +0 -133
- package/src/apis/picklists.ts +0 -50
- package/src/apis/tenants.ts +0 -100
- package/src/apis/users.ts +0 -22
- package/src/apis/utils.ts +0 -23
- package/src/apis/vehicles.ts +0 -229
- package/src/ddb-entities.ts +0 -1
- package/src/environment.d.ts +0 -6
- package/src/types/activities.ts +0 -41
- package/src/types/documents.ts +0 -110
- package/src/types/internet-vehicles.ts +0 -67
- package/src/types/leads.ts +0 -144
- package/src/types/leasing-administration.ts +0 -131
- package/src/types/leasing-search.ts +0 -24
- package/src/types/leasing-settings.ts +0 -111
- package/src/types/leasing.ts +0 -360
- package/src/types/machines.ts +0 -40
- package/src/types/opportunities.ts +0 -496
- package/src/types/payments.ts +0 -40
- package/src/types/quotes.ts +0 -186
- package/src/types/recently-viewed.ts +0 -45
- package/src/types/saved-filters.ts +0 -21
- package/src/types/settings.ts +0 -51
- package/src/types/templates.ts +0 -40
- package/src/types/website.ts +0 -28
- package/src/utils/forms.ts +0 -32
- package/src/utils/leasing.ts +0 -14
- package/src/utils/slug.ts +0 -19
- package/src/utils/tenants.ts +0 -14
- package/src/utils/vehicles.ts +0 -92
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
import { AttachmentValue } from '@bisondesk/commons-sdk/lib/types';
|
|
2
|
-
import { LeasingAdminUploadHandlers } from '../constants';
|
|
3
|
-
|
|
4
|
-
export type LeasingAdminUploadStatus = 'success' | 'processing' | 'error';
|
|
5
|
-
|
|
6
|
-
export type LeasingAdminUploadMetadata = { [key in string]?: unknown };
|
|
7
|
-
export type LeasingAdminUploadAttachments = { [key in string]?: AttachmentValue };
|
|
8
|
-
|
|
9
|
-
export type LeasingAdminUploadEvent<
|
|
10
|
-
M extends LeasingAdminUploadMetadata = {},
|
|
11
|
-
A extends LeasingAdminUploadAttachments = {}
|
|
12
|
-
> = LeasingAdminUpload<M, A> & { tenantId: string };
|
|
13
|
-
|
|
14
|
-
export type LeasingAdminUpload<
|
|
15
|
-
M extends LeasingAdminUploadMetadata = {},
|
|
16
|
-
A extends LeasingAdminUploadAttachments = {}
|
|
17
|
-
> = {
|
|
18
|
-
id: string;
|
|
19
|
-
updatedAt: string;
|
|
20
|
-
createdAt: string;
|
|
21
|
-
createdBy: string;
|
|
22
|
-
|
|
23
|
-
status: LeasingAdminUploadStatus;
|
|
24
|
-
attachments: A;
|
|
25
|
-
metadata: M;
|
|
26
|
-
handlerId: LeasingAdminUploadHandlers;
|
|
27
|
-
};
|
|
28
|
-
|
|
29
|
-
export type NewLeasingAdminUploadRequest<
|
|
30
|
-
M extends LeasingAdminUploadMetadata = {},
|
|
31
|
-
A extends LeasingAdminUploadAttachments = {}
|
|
32
|
-
> = {
|
|
33
|
-
attachments: A;
|
|
34
|
-
metadata: M;
|
|
35
|
-
handlerId: LeasingAdminUploadHandlers;
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
export type DhondtAttachments = {
|
|
39
|
-
json: AttachmentValue;
|
|
40
|
-
};
|
|
41
|
-
|
|
42
|
-
export type BelfiusAttachments = {
|
|
43
|
-
xlsx: AttachmentValue;
|
|
44
|
-
json?: AttachmentValue; // json version of the xlsx file
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
export type BelfiusMetadata = {
|
|
48
|
-
totalLines: number;
|
|
49
|
-
totalIncludingVat: string;
|
|
50
|
-
};
|
|
51
|
-
|
|
52
|
-
export type DhondtMetadata = {
|
|
53
|
-
invoiceNumber: string;
|
|
54
|
-
invoiceDate: string;
|
|
55
|
-
};
|
|
56
|
-
|
|
57
|
-
export type DhondtInvoiceLine = {
|
|
58
|
-
BrutoPremie: number;
|
|
59
|
-
Chassisnummer: string;
|
|
60
|
-
Datum: string;
|
|
61
|
-
NettoPremie: number;
|
|
62
|
-
Plaatnummer: string;
|
|
63
|
-
Taksen: number;
|
|
64
|
-
VoertuigVlootNummer: string | undefined;
|
|
65
|
-
};
|
|
66
|
-
|
|
67
|
-
export type INGMetadata = {
|
|
68
|
-
capital: string;
|
|
69
|
-
emailId: string;
|
|
70
|
-
interest: string;
|
|
71
|
-
invoiceDate: string;
|
|
72
|
-
invoiceNumber: string;
|
|
73
|
-
pdfUrl: string;
|
|
74
|
-
stockNumber: string;
|
|
75
|
-
};
|
|
76
|
-
|
|
77
|
-
export type INGAttachments = {
|
|
78
|
-
email: AttachmentValue;
|
|
79
|
-
};
|
|
80
|
-
|
|
81
|
-
export type DiffableDhondtInvoiceLine = DhondtInvoiceLine;
|
|
82
|
-
|
|
83
|
-
export type BelfiusRawInvoiceLine = {
|
|
84
|
-
AMORTIZATION: number;
|
|
85
|
-
AVENANT: number;
|
|
86
|
-
CODE_DEVISE: string;
|
|
87
|
-
CONTRACT: number;
|
|
88
|
-
CUSTOMER: string;
|
|
89
|
-
DATE_INVOICE: number;
|
|
90
|
-
DESCRIPTION: string;
|
|
91
|
-
DUE_DATE: number;
|
|
92
|
-
INTEREST: number;
|
|
93
|
-
INVOICE: number;
|
|
94
|
-
RATE: number;
|
|
95
|
-
RENTAL: number;
|
|
96
|
-
REST_DESCIPT: string;
|
|
97
|
-
VAT: number;
|
|
98
|
-
'VAT INCL': number;
|
|
99
|
-
VAT_NUMBER: string;
|
|
100
|
-
};
|
|
101
|
-
|
|
102
|
-
export type BelfiusInvoiceLine = {
|
|
103
|
-
capital: string;
|
|
104
|
-
contractNr: string;
|
|
105
|
-
interest: string;
|
|
106
|
-
invoiceNr: string;
|
|
107
|
-
invoiceDate: string;
|
|
108
|
-
rentExcl: string;
|
|
109
|
-
rentIncl: string;
|
|
110
|
-
vatAmount: string;
|
|
111
|
-
vehicleId: string;
|
|
112
|
-
stockNumber: string;
|
|
113
|
-
};
|
|
114
|
-
|
|
115
|
-
export type DiffableBelfiusInvoiceLine = Omit<
|
|
116
|
-
BelfiusInvoiceLine,
|
|
117
|
-
'invoiceNr' | 'invoiceDate' | 'capital' | 'interest'
|
|
118
|
-
>;
|
|
119
|
-
|
|
120
|
-
export type LineDiff<T> = {
|
|
121
|
-
[Property in keyof T]: {
|
|
122
|
-
value: T[Property];
|
|
123
|
-
before: T[Property];
|
|
124
|
-
};
|
|
125
|
-
};
|
|
126
|
-
|
|
127
|
-
export type Diff<T> = {
|
|
128
|
-
added: T[];
|
|
129
|
-
removed: T[];
|
|
130
|
-
changed: LineDiff<T>[];
|
|
131
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { InsuranceEntry } from '@bisondesk/commons-sdk/lib/insurance';
|
|
2
|
-
import { SearchPermissions } from '@bisondesk/commons-sdk/lib/types';
|
|
3
|
-
import { Organization } from './crm';
|
|
4
|
-
import { PublicSearchDefinition } from './definitions';
|
|
5
|
-
import { LeasingContract } from './leasing';
|
|
6
|
-
import { Vehicle } from './vehicles';
|
|
7
|
-
|
|
8
|
-
export type LeasingPublicSearchDefinitions = {
|
|
9
|
-
searchLeasingContract: PublicSearchDefinition;
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
export type SearchLeasingContract = {
|
|
13
|
-
contract: LeasingContract;
|
|
14
|
-
org: Organization;
|
|
15
|
-
vehicle: Vehicle;
|
|
16
|
-
custom: {
|
|
17
|
-
active: boolean;
|
|
18
|
-
insurance?: InsuranceEntry;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
export type InputSearchLeasingContract = SearchLeasingContract & {
|
|
23
|
-
permissions: SearchPermissions;
|
|
24
|
-
};
|
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
import { MultiLangValue } from '@bisondesk/commons-sdk/lib/types';
|
|
2
|
-
import { Categories, OpportunityType } from '../constants';
|
|
3
|
-
import { SortFilter } from './search';
|
|
4
|
-
|
|
5
|
-
export type LeasingQuoteParams = { id: string; name: string; modifiedAt: string } & {
|
|
6
|
-
countryCode: 'be';
|
|
7
|
-
insurance: {
|
|
8
|
-
allRisksCost: string;
|
|
9
|
-
allRisksTax: string;
|
|
10
|
-
allRisksFees: string;
|
|
11
|
-
allRisksMinimumCost: string;
|
|
12
|
-
specialTechnicalInsuranceCost: string;
|
|
13
|
-
specialTechnicalInsuranceTax: string;
|
|
14
|
-
specialTechnicalInsuranceFees: string;
|
|
15
|
-
civilLiabilitiesCost: string;
|
|
16
|
-
civilLiabilitiesTax: string;
|
|
17
|
-
civilLiabilitiesFees: string;
|
|
18
|
-
roadAssistanceMonthlySalesPrice: string; // monthly Price
|
|
19
|
-
roadAssistanceMonthlyCostPrice: string; // monthly Price
|
|
20
|
-
margin: string;
|
|
21
|
-
};
|
|
22
|
-
leasing: {
|
|
23
|
-
leasingInterestRate: string;
|
|
24
|
-
leasingDuration: number;
|
|
25
|
-
leasingStartupFeePercentage: string;
|
|
26
|
-
leasingDepositPercentage: string;
|
|
27
|
-
leasingResidualValuePercentage: string;
|
|
28
|
-
};
|
|
29
|
-
taxes: {
|
|
30
|
-
oneTimeRoadTax: string;
|
|
31
|
-
yearlyRoadTax: string;
|
|
32
|
-
margin: string;
|
|
33
|
-
};
|
|
34
|
-
costs: {
|
|
35
|
-
bankDepositPercentage: string;
|
|
36
|
-
bankInterestRate: string;
|
|
37
|
-
bankResidualValuePercentage: string;
|
|
38
|
-
trackAndTrace24Cost: string;
|
|
39
|
-
trackAndTrace36Cost: string;
|
|
40
|
-
trackAndTrace48Cost: string;
|
|
41
|
-
trackAndTraceMaxCost: string;
|
|
42
|
-
};
|
|
43
|
-
};
|
|
44
|
-
|
|
45
|
-
type BaseLeasingQuoteExtraSettings = {
|
|
46
|
-
referenceCode: string;
|
|
47
|
-
active: boolean;
|
|
48
|
-
costPrice: string;
|
|
49
|
-
countryCode: string;
|
|
50
|
-
deliveryPackage: boolean;
|
|
51
|
-
displayByDefault: boolean;
|
|
52
|
-
hint?: MultiLangValue;
|
|
53
|
-
name: MultiLangValue;
|
|
54
|
-
salesPrice: string;
|
|
55
|
-
vehicleCategoryRestrictions: Categories[];
|
|
56
|
-
departments: string[];
|
|
57
|
-
departmentTitles?: { [department: string]: string };
|
|
58
|
-
opportunityTypeRestrictions: OpportunityType[];
|
|
59
|
-
};
|
|
60
|
-
|
|
61
|
-
export type BaseLeasingQuoteExtraInput = {
|
|
62
|
-
agreedPrice: string;
|
|
63
|
-
costPrice: string;
|
|
64
|
-
hint?: MultiLangValue;
|
|
65
|
-
name: MultiLangValue;
|
|
66
|
-
referenceCode: string;
|
|
67
|
-
quantity: number;
|
|
68
|
-
id: string;
|
|
69
|
-
departments: string[];
|
|
70
|
-
departmentTitles?: { [department: string]: string };
|
|
71
|
-
};
|
|
72
|
-
|
|
73
|
-
export type NewLeasingQuoteExtraSettings = BaseLeasingQuoteExtraSettings & {
|
|
74
|
-
id?: undefined;
|
|
75
|
-
};
|
|
76
|
-
|
|
77
|
-
export type LeasingQuoteExtraSettings = BaseLeasingQuoteExtraSettings & {
|
|
78
|
-
id: string;
|
|
79
|
-
};
|
|
80
|
-
|
|
81
|
-
export enum LeasingItemsPaymentSplit {
|
|
82
|
-
Customer = 'customer',
|
|
83
|
-
Split = 'split',
|
|
84
|
-
Company = 'company',
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
export type LeasingDeliveryPackageInput = BaseLeasingQuoteExtraInput & { salesPrice: string };
|
|
88
|
-
|
|
89
|
-
export type CustomLeasingQuoteExtraInput = BaseLeasingQuoteExtraInput & {
|
|
90
|
-
paymentSplit: LeasingItemsPaymentSplit;
|
|
91
|
-
leasingPercentage: string;
|
|
92
|
-
};
|
|
93
|
-
|
|
94
|
-
export type LeasingQuoteExtraInput = BaseLeasingQuoteExtraInput & {
|
|
95
|
-
salesPrice: string;
|
|
96
|
-
paymentSplit: LeasingItemsPaymentSplit;
|
|
97
|
-
leasingPercentage: string;
|
|
98
|
-
};
|
|
99
|
-
|
|
100
|
-
export type LeasingQuoteExtrasRequest = {
|
|
101
|
-
deliveryPackage?: boolean;
|
|
102
|
-
displayByDefault?: boolean;
|
|
103
|
-
vehicleCategory?: Categories;
|
|
104
|
-
country: string;
|
|
105
|
-
name?: string;
|
|
106
|
-
active?: boolean;
|
|
107
|
-
offset?: number;
|
|
108
|
-
limit?: number;
|
|
109
|
-
sortBy?: SortFilter;
|
|
110
|
-
opportunityType?: OpportunityType;
|
|
111
|
-
};
|
package/src/types/leasing.ts
DELETED
|
@@ -1,360 +0,0 @@
|
|
|
1
|
-
import { EmailMessage } from '@bisondesk/commons-sdk/lib/messages';
|
|
2
|
-
import {
|
|
3
|
-
AttachmentValue,
|
|
4
|
-
Document,
|
|
5
|
-
LinkValue,
|
|
6
|
-
PaginatedList,
|
|
7
|
-
} from '@bisondesk/commons-sdk/lib/types';
|
|
8
|
-
import { SortFilter } from './search';
|
|
9
|
-
import { ReferenceData } from './utils';
|
|
10
|
-
|
|
11
|
-
export type LeasingContractEvent = {
|
|
12
|
-
id: string;
|
|
13
|
-
action: 'create' | 'update' | 'delete';
|
|
14
|
-
actionAt: string;
|
|
15
|
-
userId: string;
|
|
16
|
-
tenantId: string;
|
|
17
|
-
contract: LeasingContract;
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
export type LeasingContractImportEvent = {
|
|
21
|
-
tenantId: string;
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
export type LeasingConditionEvent = {
|
|
25
|
-
id: string;
|
|
26
|
-
action: 'create';
|
|
27
|
-
actionAt: string;
|
|
28
|
-
userId: string;
|
|
29
|
-
tenantId: string;
|
|
30
|
-
};
|
|
31
|
-
|
|
32
|
-
export type OverdueDossier = {
|
|
33
|
-
id: string;
|
|
34
|
-
organizationId: string;
|
|
35
|
-
organizationName: string;
|
|
36
|
-
status: 'ONGOING' | 'ERROR' | 'SUCCESS' | 'EXPIRED';
|
|
37
|
-
emails: EmailMessage[];
|
|
38
|
-
createdAt: string;
|
|
39
|
-
modifiedAt: string;
|
|
40
|
-
completedAt?: string;
|
|
41
|
-
nextActionAt: string;
|
|
42
|
-
riskLevel: number;
|
|
43
|
-
};
|
|
44
|
-
|
|
45
|
-
export type LeasingContractClient = {
|
|
46
|
-
organizationId: string;
|
|
47
|
-
contactIds: string[];
|
|
48
|
-
email?: string;
|
|
49
|
-
since: string;
|
|
50
|
-
takeoverId?: string;
|
|
51
|
-
country: string;
|
|
52
|
-
beEntityType?: 'Legal Person' | 'Natural Person';
|
|
53
|
-
beForeignEntity?: boolean;
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* Used to overwrite the startDate in the context of a Becris declaration. This might be necessary
|
|
57
|
-
* when due to some data-quality issue we do not report the contract at the right period and it is no
|
|
58
|
-
* longer possible to resend the declaration for the corresponding month.
|
|
59
|
-
*/
|
|
60
|
-
becrisStartDate?: string;
|
|
61
|
-
};
|
|
62
|
-
|
|
63
|
-
export enum LeasingContractSource {
|
|
64
|
-
HYPERPORTAL = 'hyperportal',
|
|
65
|
-
BISONDESK = 'bisondesk',
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
export enum LeasingContractStatus {
|
|
69
|
-
DRAFT = 'draft',
|
|
70
|
-
DISCARDED = 'discarded',
|
|
71
|
-
PAUSED = 'paused',
|
|
72
|
-
ACTIVE = 'active',
|
|
73
|
-
ENDED = 'ended',
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
export type LeasingContractHyperportal = {
|
|
77
|
-
source: LeasingContractSource.HYPERPORTAL;
|
|
78
|
-
/** oldest first **/
|
|
79
|
-
conditions: ConditionsRef[];
|
|
80
|
-
opportunities?: undefined;
|
|
81
|
-
};
|
|
82
|
-
|
|
83
|
-
export type LeasingContractBisondesk = {
|
|
84
|
-
source: LeasingContractSource.BISONDESK;
|
|
85
|
-
conditions?: undefined;
|
|
86
|
-
/** oldest first **/
|
|
87
|
-
opportunities: OpportunityRef[];
|
|
88
|
-
};
|
|
89
|
-
|
|
90
|
-
export type LeasingContract<T = LeasingContractHyperportal | LeasingContractBisondesk> = {
|
|
91
|
-
id: string;
|
|
92
|
-
createdAt: string;
|
|
93
|
-
updatedAt: string;
|
|
94
|
-
contractNumber?: string;
|
|
95
|
-
startDate: string;
|
|
96
|
-
deliveryDate?: string;
|
|
97
|
-
endDate?: string;
|
|
98
|
-
slbPartner?: string;
|
|
99
|
-
links?: LinkValue[];
|
|
100
|
-
accountManager?: string;
|
|
101
|
-
clients: LeasingContractClient[];
|
|
102
|
-
vehicle: {
|
|
103
|
-
id: string;
|
|
104
|
-
stockNumber: string;
|
|
105
|
-
administrativeNumber?: string;
|
|
106
|
-
};
|
|
107
|
-
status: LeasingContractStatus;
|
|
108
|
-
documents: Document[];
|
|
109
|
-
} & T;
|
|
110
|
-
|
|
111
|
-
type BaseRef = {
|
|
112
|
-
id: string;
|
|
113
|
-
depositAmount: string;
|
|
114
|
-
durationInMonths: number;
|
|
115
|
-
saleAmount: string; // includes the extras
|
|
116
|
-
interestRate: string;
|
|
117
|
-
residualAmount: string;
|
|
118
|
-
leasingMonthlyAmount: string; //Value excluding VAT
|
|
119
|
-
otherMonthlyAmounts: string; //Value excluding VAT
|
|
120
|
-
totalMonthlyAmount: string; //Value excluding VAT
|
|
121
|
-
};
|
|
122
|
-
|
|
123
|
-
export type ConditionsRef = BaseRef & {
|
|
124
|
-
validSince: string;
|
|
125
|
-
};
|
|
126
|
-
|
|
127
|
-
export type OpportunityRef = BaseRef & {
|
|
128
|
-
createdAt: string;
|
|
129
|
-
quoteId: string;
|
|
130
|
-
//Since VAT is client specific and contracts can be transferred between clients, we always handle values without VAT
|
|
131
|
-
};
|
|
132
|
-
|
|
133
|
-
export type ListOverdueRemindersResponse = PaginatedList<OverdueDossier, ReferenceData>;
|
|
134
|
-
export type ListOverdueRemindersRequest = {
|
|
135
|
-
offset: number;
|
|
136
|
-
limit: number;
|
|
137
|
-
sortBy: SortFilter;
|
|
138
|
-
};
|
|
139
|
-
|
|
140
|
-
export type ListBecrisDeclarationsRequest = {
|
|
141
|
-
offset: number;
|
|
142
|
-
limit: number;
|
|
143
|
-
};
|
|
144
|
-
|
|
145
|
-
export type NewLeasingConditions = {
|
|
146
|
-
parameters: {
|
|
147
|
-
yearlyRoadTax: string;
|
|
148
|
-
civilLiability: string;
|
|
149
|
-
oneTimeRoadTax: string;
|
|
150
|
-
specialInsurance: string;
|
|
151
|
-
allRisksPercentage: string;
|
|
152
|
-
allRisksTaxPercentage: string;
|
|
153
|
-
};
|
|
154
|
-
|
|
155
|
-
inputs: {
|
|
156
|
-
deposit: string;
|
|
157
|
-
salesPrice: string;
|
|
158
|
-
bankDeposit: string;
|
|
159
|
-
purchasePrice: string;
|
|
160
|
-
residualValue: string;
|
|
161
|
-
insuranceAmount: string;
|
|
162
|
-
durationInMonths: number;
|
|
163
|
-
includesAllRisks: boolean;
|
|
164
|
-
marginPercentage: string;
|
|
165
|
-
bankResidualValue: string;
|
|
166
|
-
bankDurationInMonths: number;
|
|
167
|
-
startupFeePercentage: string;
|
|
168
|
-
includesYearlyRoadTax: boolean;
|
|
169
|
-
includesCivilLiability: boolean;
|
|
170
|
-
includesOneTimeRoadTax: boolean;
|
|
171
|
-
interestRatePercentage: string;
|
|
172
|
-
includesSpecialInsurance: boolean;
|
|
173
|
-
monthlyAdministrationFee: string;
|
|
174
|
-
bankInterestRatePercentage: string;
|
|
175
|
-
};
|
|
176
|
-
|
|
177
|
-
outputs: {
|
|
178
|
-
ROI: string;
|
|
179
|
-
ROITarget: string;
|
|
180
|
-
ROIPerYear: string;
|
|
181
|
-
cashDeficit: string;
|
|
182
|
-
totalProfit: string;
|
|
183
|
-
ROIDifference: string;
|
|
184
|
-
leasingAmount: string;
|
|
185
|
-
leasingProfit: string;
|
|
186
|
-
vehicleProfit: string;
|
|
187
|
-
oneTimeTaxCost: string;
|
|
188
|
-
financingAmount: string;
|
|
189
|
-
bankContractValue: string;
|
|
190
|
-
bankLeasingAmount: string;
|
|
191
|
-
totalMonthlyPayment: string;
|
|
192
|
-
leasingContractValue: string;
|
|
193
|
-
monthlyTaxRetailPrice: string;
|
|
194
|
-
allRisksInsuranceAmount: string;
|
|
195
|
-
};
|
|
196
|
-
|
|
197
|
-
cashIn: Array<{
|
|
198
|
-
time: string;
|
|
199
|
-
cashIn: string;
|
|
200
|
-
deposit: string;
|
|
201
|
-
startupFee: string;
|
|
202
|
-
taxPayment: string;
|
|
203
|
-
residualValue: string;
|
|
204
|
-
cumulativeCash: string;
|
|
205
|
-
insurancePayment: string;
|
|
206
|
-
monthlyAdministrationFee: string;
|
|
207
|
-
leasingAmountWithoutAdminFee: string;
|
|
208
|
-
}>;
|
|
209
|
-
|
|
210
|
-
cashOut: Array<{
|
|
211
|
-
time: string;
|
|
212
|
-
cashOut: string;
|
|
213
|
-
deposit: string;
|
|
214
|
-
taxPayment: string;
|
|
215
|
-
leasingAmount: string;
|
|
216
|
-
residualValue: string;
|
|
217
|
-
cumulativeCash: string;
|
|
218
|
-
insurancePayment: string;
|
|
219
|
-
}>;
|
|
220
|
-
};
|
|
221
|
-
|
|
222
|
-
export type LeasingConditions = NewLeasingConditions & {
|
|
223
|
-
id: string;
|
|
224
|
-
createdAt: string;
|
|
225
|
-
createdBy: string;
|
|
226
|
-
amortization: AmortizationTable;
|
|
227
|
-
};
|
|
228
|
-
|
|
229
|
-
export type AmortizationRow = {
|
|
230
|
-
period: number;
|
|
231
|
-
/* An estimate of the date in which the period will happen
|
|
232
|
-
based on the contract start date. Empty for period zero. */
|
|
233
|
-
expectedPeriodDate?: string;
|
|
234
|
-
buyOff: string;
|
|
235
|
-
payment: string;
|
|
236
|
-
capital: string;
|
|
237
|
-
interest: string;
|
|
238
|
-
totalInterest: string;
|
|
239
|
-
balance: string;
|
|
240
|
-
};
|
|
241
|
-
|
|
242
|
-
export type AmortizationTable = {
|
|
243
|
-
annualInterestRate?: string;
|
|
244
|
-
monthlyInterestRate?: string;
|
|
245
|
-
rows: AmortizationRow[];
|
|
246
|
-
};
|
|
247
|
-
|
|
248
|
-
export type AmortizationDocsEvent = {
|
|
249
|
-
contractId: string;
|
|
250
|
-
changedDocumentIds: string[];
|
|
251
|
-
actionAt: string;
|
|
252
|
-
userId: string;
|
|
253
|
-
tenantId: string;
|
|
254
|
-
};
|
|
255
|
-
|
|
256
|
-
export type AmortizationDocs = {
|
|
257
|
-
contractId: string;
|
|
258
|
-
period: number;
|
|
259
|
-
documents: AmortizationDoc[];
|
|
260
|
-
};
|
|
261
|
-
|
|
262
|
-
export type AmortizationDoc = {
|
|
263
|
-
amount: string;
|
|
264
|
-
bookingNumber: string;
|
|
265
|
-
branchId: string;
|
|
266
|
-
documentId: string;
|
|
267
|
-
issueDate: string;
|
|
268
|
-
subtype: 'Invoice' | 'Credit Note';
|
|
269
|
-
clientExternalId: number;
|
|
270
|
-
};
|
|
271
|
-
|
|
272
|
-
export type BecrisDeclaration = {
|
|
273
|
-
createdAt: string;
|
|
274
|
-
endDate: string;
|
|
275
|
-
endingInstruments: number;
|
|
276
|
-
existingInstruments: number;
|
|
277
|
-
file: AttachmentValue;
|
|
278
|
-
id: string;
|
|
279
|
-
newInstruments: number;
|
|
280
|
-
startDate: string;
|
|
281
|
-
};
|
|
282
|
-
|
|
283
|
-
export type LeasingReportingSettings = {
|
|
284
|
-
active: boolean;
|
|
285
|
-
branchId: string;
|
|
286
|
-
tenantId: string;
|
|
287
|
-
};
|
|
288
|
-
|
|
289
|
-
export enum LeasingRemindersSortableColumns {
|
|
290
|
-
NextActionAt = 'next_action_at',
|
|
291
|
-
OrganizationName = 'organization_name',
|
|
292
|
-
RemindersCount = 'reminders_count',
|
|
293
|
-
Status = 'status',
|
|
294
|
-
}
|
|
295
|
-
|
|
296
|
-
export type AmortizationTableRequest = {
|
|
297
|
-
leasingAmount: string; // monthly amount
|
|
298
|
-
deposit: string;
|
|
299
|
-
salesPrice: string;
|
|
300
|
-
duration: number; // in months
|
|
301
|
-
residual: string;
|
|
302
|
-
monthlyInterestRate: string; // the annual interest rate divided by 12
|
|
303
|
-
startDate?: string; // should be filled in if you want an amortization table with expected period dates
|
|
304
|
-
};
|
|
305
|
-
|
|
306
|
-
export type AmortizationTableTemplateData = {
|
|
307
|
-
opportunity: {
|
|
308
|
-
id: string;
|
|
309
|
-
};
|
|
310
|
-
v: {
|
|
311
|
-
make: string;
|
|
312
|
-
model: string;
|
|
313
|
-
category: string;
|
|
314
|
-
type?: string;
|
|
315
|
-
vin: string;
|
|
316
|
-
year?: string | number;
|
|
317
|
-
stockNumber: string;
|
|
318
|
-
};
|
|
319
|
-
c: {
|
|
320
|
-
clientNumber: number;
|
|
321
|
-
company: string;
|
|
322
|
-
fullName: string;
|
|
323
|
-
vatNumber?: string;
|
|
324
|
-
email?: string;
|
|
325
|
-
phone?: string;
|
|
326
|
-
address?: string;
|
|
327
|
-
};
|
|
328
|
-
leasing: {
|
|
329
|
-
salesPrice: string;
|
|
330
|
-
salesPriceVat: string;
|
|
331
|
-
salesPriceExclVat: string;
|
|
332
|
-
deposit: string;
|
|
333
|
-
depositExclVat: string;
|
|
334
|
-
depositVat: string;
|
|
335
|
-
installment: string;
|
|
336
|
-
installmentVat: string;
|
|
337
|
-
installmentExclVat: string;
|
|
338
|
-
duration: number;
|
|
339
|
-
monthlyInsurance: string;
|
|
340
|
-
monthlyTax: string;
|
|
341
|
-
monthlyTaxesInsurance: string;
|
|
342
|
-
residual: string;
|
|
343
|
-
residualVat: string;
|
|
344
|
-
residualExclVat: string;
|
|
345
|
-
offerNumber: string;
|
|
346
|
-
contractNumber: string;
|
|
347
|
-
vatPercentage: string;
|
|
348
|
-
};
|
|
349
|
-
amortization: {
|
|
350
|
-
period: number;
|
|
351
|
-
periodStartDate: string;
|
|
352
|
-
periodEndDate: string;
|
|
353
|
-
deposit: string;
|
|
354
|
-
startUpFee: string;
|
|
355
|
-
monthlyAmount: string;
|
|
356
|
-
insurance: string;
|
|
357
|
-
expirationDate: string;
|
|
358
|
-
total: string;
|
|
359
|
-
}[];
|
|
360
|
-
};
|
package/src/types/machines.ts
DELETED
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
export type Machine = {
|
|
2
|
-
axlesConfiguration?: string;
|
|
3
|
-
bodywork?: string;
|
|
4
|
-
category: string;
|
|
5
|
-
vin?: string;
|
|
6
|
-
cocPvg?: string;
|
|
7
|
-
emptyWeightKg?: number;
|
|
8
|
-
euronorm?: string;
|
|
9
|
-
firstRegistration?: string;
|
|
10
|
-
gearbox?: string;
|
|
11
|
-
kilometers?: number;
|
|
12
|
-
make?: string;
|
|
13
|
-
makeModel?: string;
|
|
14
|
-
makeModelText?: string;
|
|
15
|
-
makeModelType?: string;
|
|
16
|
-
makeModelTypeText?: string;
|
|
17
|
-
powerHp?: number;
|
|
18
|
-
productionYear?: number;
|
|
19
|
-
suspension?: string;
|
|
20
|
-
totalWeightKg?: number;
|
|
21
|
-
wheelbaseCm?: number;
|
|
22
|
-
|
|
23
|
-
references: MachineReference[];
|
|
24
|
-
id: string;
|
|
25
|
-
};
|
|
26
|
-
|
|
27
|
-
export type MachineReference = {
|
|
28
|
-
administrativeNumber?: string;
|
|
29
|
-
metaId: string;
|
|
30
|
-
stockNumber: string;
|
|
31
|
-
tenantId: string;
|
|
32
|
-
vehicleId: string;
|
|
33
|
-
};
|
|
34
|
-
|
|
35
|
-
export type MachineEvent = {
|
|
36
|
-
machine: Machine;
|
|
37
|
-
action: 'upsert' | 'delete';
|
|
38
|
-
actionAt: string;
|
|
39
|
-
namespace: string;
|
|
40
|
-
};
|