@bisondesk/core-sdk 1.0.21 → 1.0.23-B

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.
Files changed (225) hide show
  1. package/lib/apis/crm.d.ts +39 -0
  2. package/lib/apis/crm.d.ts.map +1 -0
  3. package/lib/apis/crm.js +201 -0
  4. package/lib/apis/crm.js.map +1 -0
  5. package/lib/apis/documents.d.ts +4 -0
  6. package/lib/apis/documents.d.ts.map +1 -0
  7. package/lib/apis/documents.js +47 -0
  8. package/lib/apis/documents.js.map +1 -0
  9. package/lib/apis/internet-vehicles.d.ts +3 -0
  10. package/lib/apis/internet-vehicles.d.ts.map +1 -0
  11. package/lib/apis/internet-vehicles.js +27 -0
  12. package/lib/apis/internet-vehicles.js.map +1 -0
  13. package/lib/apis/leasing-administration.d.ts +8 -0
  14. package/lib/apis/leasing-administration.d.ts.map +1 -0
  15. package/lib/apis/leasing-administration.js +49 -0
  16. package/lib/apis/leasing-administration.js.map +1 -0
  17. package/lib/apis/leasing.d.ts +19 -0
  18. package/lib/apis/leasing.d.ts.map +1 -0
  19. package/lib/apis/leasing.js +168 -0
  20. package/lib/apis/leasing.js.map +1 -0
  21. package/lib/apis/opportunities.d.ts +9 -0
  22. package/lib/apis/opportunities.d.ts.map +1 -0
  23. package/lib/apis/opportunities.js +94 -0
  24. package/lib/apis/opportunities.js.map +1 -0
  25. package/lib/apis/picklists.d.ts +5 -0
  26. package/lib/apis/picklists.d.ts.map +1 -0
  27. package/lib/apis/picklists.js +44 -0
  28. package/lib/apis/picklists.js.map +1 -0
  29. package/lib/apis/tenants.d.ts +7 -0
  30. package/lib/apis/tenants.d.ts.map +1 -0
  31. package/lib/apis/tenants.js +80 -0
  32. package/lib/apis/tenants.js.map +1 -0
  33. package/lib/apis/users.d.ts +3 -0
  34. package/lib/apis/users.d.ts.map +1 -0
  35. package/lib/apis/users.js +26 -0
  36. package/lib/apis/users.js.map +1 -0
  37. package/lib/apis/utils.d.ts +9 -0
  38. package/lib/apis/utils.d.ts.map +1 -0
  39. package/lib/apis/utils.js +23 -0
  40. package/lib/apis/utils.js.map +1 -0
  41. package/lib/apis/vehicles.d.ts +18 -0
  42. package/lib/apis/vehicles.d.ts.map +1 -0
  43. package/lib/apis/vehicles.js +159 -0
  44. package/lib/apis/vehicles.js.map +1 -0
  45. package/lib/constants.d.ts +77 -0
  46. package/lib/constants.d.ts.map +1 -1
  47. package/lib/constants.js +924 -1
  48. package/lib/constants.js.map +1 -1
  49. package/lib/ddb-entities.d.ts +2 -0
  50. package/lib/ddb-entities.d.ts.map +1 -0
  51. package/lib/ddb-entities.js +5 -0
  52. package/lib/ddb-entities.js.map +1 -0
  53. package/lib/types/activities.d.ts +38 -0
  54. package/lib/types/activities.d.ts.map +1 -0
  55. package/lib/types/activities.js +16 -0
  56. package/lib/types/activities.js.map +1 -0
  57. package/lib/types/crm.d.ts +103 -30
  58. package/lib/types/crm.d.ts.map +1 -1
  59. package/lib/types/crm.js +16 -0
  60. package/lib/types/crm.js.map +1 -1
  61. package/lib/types/definitions.d.ts +15 -13
  62. package/lib/types/definitions.d.ts.map +1 -1
  63. package/lib/types/documents.d.ts +105 -0
  64. package/lib/types/documents.d.ts.map +1 -0
  65. package/lib/types/{interests.js → documents.js} +1 -1
  66. package/lib/types/documents.js.map +1 -0
  67. package/lib/types/fields.d.ts +26 -25
  68. package/lib/types/fields.d.ts.map +1 -1
  69. package/lib/types/fields.js +4 -0
  70. package/lib/types/fields.js.map +1 -1
  71. package/lib/types/internet-vehicles.d.ts +64 -0
  72. package/lib/types/internet-vehicles.d.ts.map +1 -0
  73. package/lib/types/internet-vehicles.js +3 -0
  74. package/lib/types/internet-vehicles.js.map +1 -0
  75. package/lib/types/leads.d.ts +134 -0
  76. package/lib/types/leads.d.ts.map +1 -0
  77. package/lib/types/leads.js +3 -0
  78. package/lib/types/leads.js.map +1 -0
  79. package/lib/types/leasing-administration.d.ts +107 -0
  80. package/lib/types/leasing-administration.d.ts.map +1 -0
  81. package/lib/types/leasing-administration.js +3 -0
  82. package/lib/types/leasing-administration.js.map +1 -0
  83. package/lib/types/leasing-search.d.ts +22 -0
  84. package/lib/types/leasing-search.d.ts.map +1 -0
  85. package/lib/types/leasing-search.js +3 -0
  86. package/lib/types/leasing-search.js.map +1 -0
  87. package/lib/types/leasing-settings.d.ts +113 -0
  88. package/lib/types/leasing-settings.d.ts.map +1 -0
  89. package/lib/types/leasing-settings.js +10 -0
  90. package/lib/types/leasing-settings.js.map +1 -0
  91. package/lib/types/leasing.d.ts +322 -0
  92. package/lib/types/leasing.d.ts.map +1 -0
  93. package/lib/types/leasing.js +24 -0
  94. package/lib/types/leasing.js.map +1 -0
  95. package/lib/types/machines.d.ts +38 -0
  96. package/lib/types/machines.d.ts.map +1 -0
  97. package/lib/types/machines.js +3 -0
  98. package/lib/types/machines.js.map +1 -0
  99. package/lib/types/opportunities.d.ts +448 -0
  100. package/lib/types/opportunities.d.ts.map +1 -0
  101. package/lib/types/opportunities.js +68 -0
  102. package/lib/types/opportunities.js.map +1 -0
  103. package/lib/types/payments.d.ts +38 -0
  104. package/lib/types/payments.d.ts.map +1 -0
  105. package/lib/types/payments.js +9 -0
  106. package/lib/types/payments.js.map +1 -0
  107. package/lib/types/picklists.d.ts +15 -4
  108. package/lib/types/picklists.d.ts.map +1 -1
  109. package/lib/types/quotes.d.ts +173 -0
  110. package/lib/types/quotes.d.ts.map +1 -0
  111. package/lib/types/quotes.js +26 -0
  112. package/lib/types/quotes.js.map +1 -0
  113. package/lib/types/recently-viewed.d.ts +33 -0
  114. package/lib/types/recently-viewed.d.ts.map +1 -0
  115. package/lib/types/recently-viewed.js +3 -0
  116. package/lib/types/recently-viewed.js.map +1 -0
  117. package/lib/types/saved-filters.d.ts +20 -0
  118. package/lib/types/saved-filters.d.ts.map +1 -0
  119. package/lib/types/saved-filters.js +3 -0
  120. package/lib/types/saved-filters.js.map +1 -0
  121. package/lib/types/search.d.ts +26 -4
  122. package/lib/types/search.d.ts.map +1 -1
  123. package/lib/types/search.js.map +1 -1
  124. package/lib/types/settings.d.ts +50 -0
  125. package/lib/types/settings.d.ts.map +1 -0
  126. package/lib/types/settings.js +3 -0
  127. package/lib/types/settings.js.map +1 -0
  128. package/lib/types/storage.d.ts +1 -11
  129. package/lib/types/storage.d.ts.map +1 -1
  130. package/lib/types/storage.js +15 -0
  131. package/lib/types/storage.js.map +1 -1
  132. package/lib/types/templates.d.ts +35 -0
  133. package/lib/types/templates.d.ts.map +1 -0
  134. package/lib/types/templates.js +9 -0
  135. package/lib/types/templates.js.map +1 -0
  136. package/lib/types/tenants.d.ts +32 -9
  137. package/lib/types/tenants.d.ts.map +1 -1
  138. package/lib/types/tenants.js +11 -0
  139. package/lib/types/tenants.js.map +1 -1
  140. package/lib/types/users.d.ts +11 -3
  141. package/lib/types/users.d.ts.map +1 -1
  142. package/lib/types/utils.d.ts +20 -0
  143. package/lib/types/utils.d.ts.map +1 -1
  144. package/lib/types/utils.js +6 -0
  145. package/lib/types/utils.js.map +1 -1
  146. package/lib/types/vehicles.d.ts +406 -92
  147. package/lib/types/vehicles.d.ts.map +1 -1
  148. package/lib/types/vehicles.js +54 -1
  149. package/lib/types/vehicles.js.map +1 -1
  150. package/lib/types/website.d.ts +24 -0
  151. package/lib/types/website.d.ts.map +1 -0
  152. package/lib/types/website.js +3 -0
  153. package/lib/types/website.js.map +1 -0
  154. package/lib/utils/forms.d.ts +6 -0
  155. package/lib/utils/forms.d.ts.map +1 -0
  156. package/lib/utils/forms.js +33 -0
  157. package/lib/utils/forms.js.map +1 -0
  158. package/lib/utils/leasing.d.ts +3 -0
  159. package/lib/utils/leasing.d.ts.map +1 -0
  160. package/lib/utils/leasing.js +10 -0
  161. package/lib/utils/leasing.js.map +1 -0
  162. package/lib/utils/slug.d.ts +3 -0
  163. package/lib/utils/slug.d.ts.map +1 -0
  164. package/lib/utils/slug.js +23 -0
  165. package/lib/utils/slug.js.map +1 -0
  166. package/lib/utils/tenants.d.ts +4 -0
  167. package/lib/utils/tenants.d.ts.map +1 -0
  168. package/lib/utils/tenants.js +16 -0
  169. package/lib/utils/tenants.js.map +1 -0
  170. package/lib/utils/vehicles.d.ts +12 -0
  171. package/lib/utils/vehicles.d.ts.map +1 -0
  172. package/lib/utils/vehicles.js +73 -0
  173. package/lib/utils/vehicles.js.map +1 -0
  174. package/package.json +8 -6
  175. package/src/apis/crm.ts +302 -0
  176. package/src/apis/documents.ts +54 -0
  177. package/src/apis/internet-vehicles.ts +23 -0
  178. package/src/apis/leasing-administration.ts +70 -0
  179. package/src/apis/leasing.ts +257 -0
  180. package/src/apis/opportunities.ts +133 -0
  181. package/src/apis/picklists.ts +50 -0
  182. package/src/apis/tenants.ts +100 -0
  183. package/src/apis/users.ts +22 -0
  184. package/src/apis/utils.ts +23 -0
  185. package/src/apis/vehicles.ts +229 -0
  186. package/src/constants.ts +930 -1
  187. package/src/ddb-entities.ts +1 -0
  188. package/src/environment.d.ts +6 -0
  189. package/src/types/activities.ts +41 -0
  190. package/src/types/crm.ts +118 -30
  191. package/src/types/definitions.ts +19 -12
  192. package/src/types/documents.ts +110 -0
  193. package/src/types/fields.ts +72 -31
  194. package/src/types/internet-vehicles.ts +67 -0
  195. package/src/types/leads.ts +144 -0
  196. package/src/types/leasing-administration.ts +131 -0
  197. package/src/types/leasing-search.ts +24 -0
  198. package/src/types/leasing-settings.ts +111 -0
  199. package/src/types/leasing.ts +360 -0
  200. package/src/types/machines.ts +40 -0
  201. package/src/types/opportunities.ts +496 -0
  202. package/src/types/payments.ts +40 -0
  203. package/src/types/picklists.ts +26 -7
  204. package/src/types/quotes.ts +186 -0
  205. package/src/types/recently-viewed.ts +45 -0
  206. package/src/types/saved-filters.ts +21 -0
  207. package/src/types/search.ts +34 -4
  208. package/src/types/settings.ts +51 -0
  209. package/src/types/storage.ts +1 -12
  210. package/src/types/templates.ts +40 -0
  211. package/src/types/tenants.ts +37 -11
  212. package/src/types/users.ts +17 -3
  213. package/src/types/utils.ts +25 -0
  214. package/src/types/vehicles.ts +461 -93
  215. package/src/types/website.ts +28 -0
  216. package/src/utils/forms.ts +32 -0
  217. package/src/utils/leasing.ts +14 -0
  218. package/src/utils/slug.ts +19 -0
  219. package/src/utils/tenants.ts +14 -0
  220. package/src/utils/vehicles.ts +92 -0
  221. package/tsconfig.tsbuildinfo +1 -2995
  222. package/lib/types/interests.d.ts +0 -23
  223. package/lib/types/interests.d.ts.map +0 -1
  224. package/lib/types/interests.js.map +0 -1
  225. package/src/types/interests.ts +0 -20
@@ -0,0 +1,144 @@
1
+ import {
2
+ PhoneNumberRawValue,
3
+ PhoneNumberValue,
4
+ SearchPermissions,
5
+ } from '@bisondesk/commons-sdk/lib/types';
6
+ import { PublicSearchDefinition } from './definitions';
7
+ import { ReferenceData } from './utils';
8
+ import { SearchVehicle } from './vehicles';
9
+
10
+ export type SearchLead = Lead;
11
+
12
+ export type InputSearchLead = SearchLead & {
13
+ permissions: SearchPermissions;
14
+ };
15
+
16
+ export type RankedSearchLead = SearchLead & { score: number };
17
+
18
+ export type LeadPublicSearchDefinitions = {
19
+ searchLead: PublicSearchDefinition;
20
+ };
21
+
22
+ export type LeadEvent = {
23
+ id: string;
24
+ action: 'upsert' | 'delete';
25
+ actionAt: string;
26
+ userId: string;
27
+ tenantId: string;
28
+ };
29
+
30
+ export type LeadContact = {
31
+ accountManager?: string;
32
+ companyName?: string;
33
+ country: string;
34
+ email?: string;
35
+ name: string;
36
+ phone?: PhoneNumberValue | PhoneNumberRawValue;
37
+ remarks?: string;
38
+
39
+ // Fields used to link lead to existing org and contact.
40
+ organizationId?: string;
41
+ contactId?: string;
42
+ orgNumber?: number;
43
+ };
44
+
45
+ export type LeadScore = {
46
+ leadId: string;
47
+ score: number;
48
+ scores: { name: string; value: number }[];
49
+ };
50
+
51
+ export type VehicleScore = {
52
+ vehicleId: string;
53
+ score: number;
54
+ };
55
+
56
+ export type LeadVehicles = {
57
+ vehicles: VehicleScore[];
58
+ };
59
+
60
+ export type VehicleLeads = {
61
+ leads: LeadScore[];
62
+ };
63
+
64
+ export type VehicleLeadsResponse = VehicleLeads & {
65
+ leadsById: { [leadId: string]: Lead };
66
+ };
67
+
68
+ export type LeadVehiclesResponse = LeadVehicles & {
69
+ vehiclesById: { [vehicleId: string]: SearchVehicle };
70
+ };
71
+
72
+ export type LeadStats = {
73
+ lastClientConversation?: string;
74
+ lastClientTx?: string;
75
+ clientTxs?: number;
76
+ };
77
+
78
+ export type LeadVehicle = {
79
+ createdAt: string;
80
+ vehicleId: string;
81
+ saleId?: string;
82
+ };
83
+
84
+ export type Lead = {
85
+ id: string;
86
+ createdAt: string;
87
+ contact: LeadContact;
88
+ interests: Interest[];
89
+ vehicles: LeadVehicle[];
90
+ stats?: LeadStats;
91
+ };
92
+
93
+ export type InterestVersion = {
94
+ make: string;
95
+ models?: string[];
96
+ };
97
+
98
+ export type Interest = {
99
+ id: string;
100
+ modifiedAt: string;
101
+ modifiedBy: string;
102
+ extended?: string[];
103
+ heightened?: string[];
104
+ adr?: boolean;
105
+ age?: number;
106
+ axleConfigurations?: string[];
107
+ bodystyle?: string;
108
+ cabins?: string[];
109
+ category: string;
110
+ crane?: boolean;
111
+ damaged?: boolean;
112
+ euronorms?: string[];
113
+ horsepower?: number;
114
+ used?: boolean;
115
+ kilometers?: number;
116
+ versions?: InterestVersion[];
117
+ price?: number;
118
+ leasing?: boolean;
119
+ retarderIntarder?: boolean;
120
+ suspensions?: string[];
121
+ tailgate?: boolean;
122
+ transmissions?: string[];
123
+ autoGenerated?: boolean;
124
+
125
+ remarks?: string;
126
+ };
127
+
128
+ export type InterestResponse = {
129
+ interest: Interest;
130
+ meta: ReferenceData;
131
+ };
132
+
133
+ export type InterestSearchRequest = { interest: Interest; offset: number; limit: number };
134
+
135
+ export type VehicleLeadsSearchRequest = { vehicleId: string };
136
+
137
+ export type InterestAutocompleteRequest = { vehicleId: string };
138
+
139
+ export type LeadVehiclesSearchRequest = { leadId: string };
140
+
141
+ export type SimilarVehiclesRequest = {
142
+ offset: number;
143
+ limit: number;
144
+ };
@@ -0,0 +1,131 @@
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
+ };
@@ -0,0 +1,24 @@
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
+ };
@@ -0,0 +1,111 @@
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
+ };