@bisondesk/core-sdk 1.0.544 → 1.0.546
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 -2
- package/lib/constants.d.ts.map +1 -1
- package/lib/constants.js +0 -2
- package/lib/constants.js.map +1 -1
- package/lib/types/delivery-settings.d.ts +10 -5
- package/lib/types/delivery-settings.d.ts.map +1 -1
- package/lib/types/delivery-settings.js.map +1 -1
- package/lib/types/opportunities.d.ts +0 -3
- package/lib/types/opportunities.d.ts.map +1 -1
- package/lib/types/opportunities.js.map +1 -1
- package/lib/types/quotes.d.ts +2 -3
- package/lib/types/quotes.d.ts.map +1 -1
- package/lib/types/quotes.js +0 -1
- package/lib/types/quotes.js.map +1 -1
- package/lib/types/tenants.d.ts +1 -2
- package/lib/types/tenants.d.ts.map +1 -1
- package/lib/types/tenants.js +0 -1
- package/lib/types/tenants.js.map +1 -1
- package/lib/types/vehicle-performance.d.ts +2 -0
- package/lib/types/vehicle-performance.d.ts.map +1 -1
- package/lib/types/vehicle-performance.js.map +1 -1
- package/lib/types/vehicles.d.ts +1 -11
- package/lib/types/vehicles.d.ts.map +1 -1
- package/lib/types/vehicles.js +0 -1
- package/lib/types/vehicles.js.map +1 -1
- package/lib/utils/vehicles.d.ts +5 -1
- package/lib/utils/vehicles.d.ts.map +1 -1
- package/lib/utils/vehicles.js +2 -1
- package/lib/utils/vehicles.js.map +1 -1
- package/package.json +1 -1
- package/src/constants.ts +0 -2
- package/src/types/delivery-settings.ts +13 -6
- package/src/types/opportunities.ts +0 -3
- package/src/types/quotes.ts +1 -2
- package/src/types/tenants.ts +0 -1
- package/src/types/vehicle-performance.ts +4 -0
- package/src/types/vehicles.ts +0 -12
- package/src/utils/vehicles.ts +10 -2
- package/tsconfig.tsbuildinfo +1 -1
- package/lib/types/transports.d.ts +0 -110
- package/lib/types/transports.d.ts.map +0 -1
- package/lib/types/transports.js +0 -44
- package/lib/types/transports.js.map +0 -1
- package/src/types/activities.js +0 -13
- package/src/types/activities.js.map +0 -1
- package/src/types/comparables.js +0 -2
- package/src/types/comparables.js.map +0 -1
- package/src/types/crm.js +0 -58
- package/src/types/crm.js.map +0 -1
- package/src/types/dashboard.js +0 -2
- package/src/types/dashboard.js.map +0 -1
- package/src/types/definitions.js +0 -2
- package/src/types/definitions.js.map +0 -1
- package/src/types/fields.js +0 -2
- package/src/types/fields.js.map +0 -1
- package/src/types/insights.js +0 -2
- package/src/types/insights.js.map +0 -1
- package/src/types/interests.js +0 -6
- package/src/types/interests.js.map +0 -1
- package/src/types/internal-events.js +0 -18
- package/src/types/internal-events.js.map +0 -1
- package/src/types/internet-opportunities.js +0 -2
- package/src/types/internet-opportunities.js.map +0 -1
- package/src/types/internet-vehicles.js +0 -2
- package/src/types/internet-vehicles.js.map +0 -1
- package/src/types/leasing-administration.js +0 -2
- package/src/types/leasing-administration.js.map +0 -1
- package/src/types/leasing-debtors.js +0 -2
- package/src/types/leasing-debtors.js.map +0 -1
- package/src/types/leasing-search.js +0 -2
- package/src/types/leasing-search.js.map +0 -1
- package/src/types/leasing-settings.js +0 -7
- package/src/types/leasing-settings.js.map +0 -1
- package/src/types/leasing.js +0 -38
- package/src/types/leasing.js.map +0 -1
- package/src/types/marketing.js +0 -35
- package/src/types/marketing.js.map +0 -1
- package/src/types/offers.js +0 -56
- package/src/types/opportunities.js +0 -107
- package/src/types/opportunities.js.map +0 -1
- package/src/types/payments.js +0 -7
- package/src/types/picklists.js +0 -2
- package/src/types/picklists.js.map +0 -1
- package/src/types/quotes.js +0 -42
- package/src/types/recently-viewed.js +0 -2
- package/src/types/recently-viewed.js.map +0 -1
- package/src/types/reservations.js +0 -5
- package/src/types/reservations.js.map +0 -1
- package/src/types/roi-ratings.js +0 -5
- package/src/types/roi-ratings.js.map +0 -1
- package/src/types/saved-filters.js +0 -9
- package/src/types/saved-filters.js.map +0 -1
- package/src/types/search.js +0 -2
- package/src/types/search.js.map +0 -1
- package/src/types/settings.js +0 -2
- package/src/types/settings.js.map +0 -1
- package/src/types/templates.js +0 -2
- package/src/types/templates.js.map +0 -1
- package/src/types/tenants.js +0 -21
- package/src/types/tenants.js.map +0 -1
- package/src/types/transports.ts +0 -149
- package/src/types/user-performance.js +0 -7
- package/src/types/user-performance.js.map +0 -1
- package/src/types/utils.js +0 -2
- package/src/types/validation.js +0 -2
- package/src/types/validation.js.map +0 -1
- package/src/types/vehicle-sales.js +0 -6
- package/src/types/vehicle-sales.js.map +0 -1
- package/src/types/vehicles.js +0 -98
- package/src/types/vehicles.js.map +0 -1
- package/src/utils/leasing.js +0 -6
- package/src/utils/leasing.js.map +0 -1
- package/src/utils/opportunities.js +0 -48
- package/src/utils/opportunities.js.map +0 -1
package/src/constants.ts
CHANGED
|
@@ -80,8 +80,6 @@ export const HEIGTHENED_PICKLIST_ID = 'extended_height_dimension';
|
|
|
80
80
|
export const EXTENDED_PICKLIST_ID = 'extended_length_dimension';
|
|
81
81
|
export const JOB_CATEGORIES_PICKLIST_ID = 'job_category';
|
|
82
82
|
export const DOCUMENT_TYPES_PICKLIST_ID = 'document_types';
|
|
83
|
-
export const DESTINATION_PORTS_PICKLIST_ID = 'destination_ports';
|
|
84
|
-
export const SOURCE_PORTS_PICKLIST_ID = 'source_ports';
|
|
85
83
|
|
|
86
84
|
//
|
|
87
85
|
// STATIC VALUES FOR VEHICLE CATEGORIES
|
|
@@ -6,6 +6,19 @@ export enum TransitPlateCountries {
|
|
|
6
6
|
AT = 'at',
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
+
type BaseDeliveryPort = {
|
|
10
|
+
name: string;
|
|
11
|
+
address: LocationValue;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export type NewDeliveryPort = BaseDeliveryPort & {
|
|
15
|
+
id: undefined;
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
export type DeliveryPort = BaseDeliveryPort & {
|
|
19
|
+
id: string;
|
|
20
|
+
};
|
|
21
|
+
|
|
9
22
|
type BaseTransportationToPort = {
|
|
10
23
|
portId: string;
|
|
11
24
|
branchId: string;
|
|
@@ -63,12 +76,6 @@ export type EnabledDeliveryParams = BaseDeliveryParams & {
|
|
|
63
76
|
|
|
64
77
|
export type DeliveryParams = DisabledDeliveryParams | EnabledDeliveryParams;
|
|
65
78
|
|
|
66
|
-
export type DeliveryPort = {
|
|
67
|
-
id: string;
|
|
68
|
-
name: string;
|
|
69
|
-
address: LocationValue;
|
|
70
|
-
};
|
|
71
|
-
|
|
72
79
|
export type QuotePortDelivery = {
|
|
73
80
|
transportationToPort: TransportationToPort;
|
|
74
81
|
originPort: DeliveryPort;
|
|
@@ -8,7 +8,6 @@ import { Payment } from './payments.js';
|
|
|
8
8
|
import { Quote, QuoteStatus } from './quotes.js';
|
|
9
9
|
import { OpportunityReservation } from './reservations.js';
|
|
10
10
|
import { BaseSearchRequest } from './search.js';
|
|
11
|
-
import { Transport } from './transports.js';
|
|
12
11
|
import { DataRecord, ReferenceData } from './utils.js';
|
|
13
12
|
import { Vehicle } from './vehicles.js';
|
|
14
13
|
|
|
@@ -271,7 +270,6 @@ export type OpportunityBFF = {
|
|
|
271
270
|
contact: DataRecord<Contact, ContactMetdata>;
|
|
272
271
|
org?: DataRecord<Organization>;
|
|
273
272
|
};
|
|
274
|
-
transport?: Transport;
|
|
275
273
|
};
|
|
276
274
|
|
|
277
275
|
type BaseOpportunityEvent = BaseEvent & {
|
|
@@ -315,7 +313,6 @@ export type SearchOpportunity = {
|
|
|
315
313
|
opportunity: Opportunity;
|
|
316
314
|
org?: Organization;
|
|
317
315
|
vehicle?: Vehicle;
|
|
318
|
-
transport?: Transport;
|
|
319
316
|
quote?: QuoteInfo;
|
|
320
317
|
custom: {
|
|
321
318
|
web2Lead: boolean;
|
package/src/types/quotes.ts
CHANGED
|
@@ -37,7 +37,6 @@ export enum DeliveryTypes {
|
|
|
37
37
|
PICK_UP = 'pickUp',
|
|
38
38
|
ADDRESS = 'address',
|
|
39
39
|
PORT = 'port',
|
|
40
|
-
PORT_AND_SHIP = 'portAndShip',
|
|
41
40
|
}
|
|
42
41
|
|
|
43
42
|
export enum SpoilerInfo {
|
|
@@ -164,7 +163,7 @@ export type AddressDeliveryType = BaseDeliveryType & {
|
|
|
164
163
|
};
|
|
165
164
|
|
|
166
165
|
export type PortDeliverytype = BaseDeliveryType & {
|
|
167
|
-
type: DeliveryTypes.PORT
|
|
166
|
+
type: DeliveryTypes.PORT;
|
|
168
167
|
portOriginId: string;
|
|
169
168
|
portDestination?: string;
|
|
170
169
|
shippingCompany?: string;
|
package/src/types/tenants.ts
CHANGED
|
@@ -55,6 +55,10 @@ export type VehicleSaleOverview = {
|
|
|
55
55
|
// is there an invoice with line categories related to the purchase of commercial vehicle?
|
|
56
56
|
hasMainInvoice?: boolean;
|
|
57
57
|
mainInvoicesAmount?: string;
|
|
58
|
+
|
|
59
|
+
// is there a sale invoice with leasing line categories (capital, rent, deposit, residual) and amount > 0?
|
|
60
|
+
hasLeasingInvoices?: boolean;
|
|
61
|
+
leasingInvoicesAmount?: string;
|
|
58
62
|
};
|
|
59
63
|
|
|
60
64
|
export type VehiclePurchaseOverview = {
|
package/src/types/vehicles.ts
CHANGED
|
@@ -8,11 +8,9 @@ import {
|
|
|
8
8
|
ShareEmailRequest,
|
|
9
9
|
ShareWhatsappRequest,
|
|
10
10
|
} from '@bisondesk/commons-sdk/types';
|
|
11
|
-
import { ReferenceData } from '@bisondesk/commons-sdk/utils';
|
|
12
11
|
import { BaseEvent } from './internal-events.js';
|
|
13
12
|
import { VehicleSaleLogisticsStatus } from './opportunities.js';
|
|
14
13
|
import { OpportunityReservation } from './reservations.js';
|
|
15
|
-
import { Transport } from './transports.js';
|
|
16
14
|
import { DataRecord } from './utils.js';
|
|
17
15
|
import { VehicleBusinessOverviewXL } from './vehicle-performance.js';
|
|
18
16
|
import { VehicleSaleInfo } from './vehicle-sales.js';
|
|
@@ -264,7 +262,6 @@ export type SearchVehicle = {
|
|
|
264
262
|
arrivedAt?: string;
|
|
265
263
|
};
|
|
266
264
|
reservation?: Pick<OpportunityReservation, 'expiresAt' | 'opportunityId' | 'createdBy'>;
|
|
267
|
-
transports: Transport[];
|
|
268
265
|
vehicle: Vehicle;
|
|
269
266
|
sale: {
|
|
270
267
|
opportunityId?: string;
|
|
@@ -647,7 +644,6 @@ export enum VehiclePurchaseLogisticsStatus {
|
|
|
647
644
|
AtOrigin = 'AT_ORIGIN',
|
|
648
645
|
Arrived = 'ARRIVED',
|
|
649
646
|
CheckedIn = 'CHECKED_IN',
|
|
650
|
-
NotApplicable = 'NOT_APPLICABLE',
|
|
651
647
|
}
|
|
652
648
|
|
|
653
649
|
export enum VehiclePurchaseDeliveryType {
|
|
@@ -759,14 +755,6 @@ export type VehiclePurchase = {
|
|
|
759
755
|
};
|
|
760
756
|
};
|
|
761
757
|
|
|
762
|
-
export type PurchaseRecordMeta = ReferenceData & {
|
|
763
|
-
allowedLogisticsTransitions?: VehiclePurchaseLogisticsStatus[];
|
|
764
|
-
};
|
|
765
|
-
|
|
766
|
-
export type SaveVehiclePurchaseOpts = {
|
|
767
|
-
skipTransportValidation?: boolean;
|
|
768
|
-
};
|
|
769
|
-
|
|
770
758
|
export enum VehicleActions {
|
|
771
759
|
EditAdminDocs = 'edit_admin_docs',
|
|
772
760
|
EditEngineeringDocs = 'edit_engineering_docs',
|
package/src/utils/vehicles.ts
CHANGED
|
@@ -121,8 +121,15 @@ export const getNextRelatedStockNumber = (stockNumber: string): string => {
|
|
|
121
121
|
|
|
122
122
|
export const getVehicleDescription = (
|
|
123
123
|
external: VehicleExternalInfo,
|
|
124
|
-
|
|
125
|
-
|
|
124
|
+
{
|
|
125
|
+
showStockNumber = false,
|
|
126
|
+
showAxleConfiguration = false,
|
|
127
|
+
lang,
|
|
128
|
+
}: {
|
|
129
|
+
showStockNumber?: boolean;
|
|
130
|
+
showAxleConfiguration?: boolean;
|
|
131
|
+
lang?: string;
|
|
132
|
+
}
|
|
126
133
|
) => {
|
|
127
134
|
const dimensions = [
|
|
128
135
|
external.superstructure?.dimensions?.extended,
|
|
@@ -143,6 +150,7 @@ export const getVehicleDescription = (
|
|
|
143
150
|
: undefined,
|
|
144
151
|
external.powertrain?.emissions?.subclass ?? external.powertrain?.emissions?.class,
|
|
145
152
|
dimensions,
|
|
153
|
+
showAxleConfiguration ? external.powertrain?.axles?.configuration : undefined,
|
|
146
154
|
]);
|
|
147
155
|
|
|
148
156
|
return text;
|