mts-booking-library 1.2.29 → 1.2.30
Sign up to get free protection for your applications and to get access to all the features.
- package/lib/types/common/Cart.d.ts +14 -2
- package/package.json +1 -1
@@ -12,6 +12,8 @@ import { Extra } from "./Extra";
|
|
12
12
|
* @property {boolean} hasIssuedTickets - A boolean telling whether the cart has issued tickets. Note that if this is the case,
|
13
13
|
* the cart will be null because it is not possible to add tickets to an issued cart. Thus, all data should be reset.
|
14
14
|
* @property {number} sellerId The id of the seller of the tickets in the cart
|
15
|
+
* @property {string} sellerPrivacyUrl The url redirecting to the privacy policy of the seller
|
16
|
+
* @property {string} sellerTermsUrl The url redirecting to the terms and conditions of the seller
|
15
17
|
* @property {Map<string, boolean[]>} stepsToStatus This data structure describes the steps of the booking process.
|
16
18
|
* The keys of this dictionary represent the booking steps. See ... for the list of possible steps. If the
|
17
19
|
* key is present, then the booking step shall be displayed. The value is a list of 3 booleans:
|
@@ -20,23 +22,33 @@ import { Extra } from "./Extra";
|
|
20
22
|
* - The third tells whether the section is required.
|
21
23
|
* @property {Booking.Currencies} currency The currency of the cart. See {@link Booking.Currencies}
|
22
24
|
* @property {string} bookingDueDate The date and time when the cart expires
|
25
|
+
* @property {Reduction[]} reductions The list of reductions applied to the cart
|
26
|
+
* @property {Extra[]} extras The list of extras services of the cart
|
27
|
+
* @property {string} sellingMethod The selling method of the cart (LinkAvel, Backoffice)
|
28
|
+
* @property {number} totalValue The total value of the cart, meaning the sum of the nominal prices of all tickets. It is expressed in the currency of the cart.
|
29
|
+
* @property {number} totalResellerFee The total reseller fee of the cart, meaning the sum of the reseller fees of all tickets. It is expressed in the currency of the cart.
|
30
|
+
* @property {number} totalCreditFromChange The total credit from change of the cart. This is non zero only during the change process, and represents
|
31
|
+
* the credit that the user has from the previous cart. It is expressed in the currency of the cart.
|
32
|
+
* @property {number} totalAmountToPay The total amount to pay of the cart, meaning the amount that the user has to pay to complete the booking. This is
|
33
|
+
* what is displayed in the payment page. It is expressed in the currency of the cart.
|
23
34
|
*/
|
24
35
|
export type Cart = {
|
25
36
|
id: number;
|
26
37
|
sellerId: number;
|
38
|
+
sellerPrivacyUrl: string;
|
39
|
+
sellerTermsUrl: string;
|
27
40
|
cartCode: string;
|
28
41
|
hasIssuedTickets: boolean;
|
29
42
|
stepsToStatus: Map<string, boolean[]>;
|
30
43
|
currency: Booking.Currencies;
|
31
44
|
bookingDueDate: string;
|
32
|
-
buyerId: number;
|
33
45
|
reductions: Reduction[];
|
46
|
+
extras: Extra[];
|
34
47
|
sellingMethod: string;
|
35
48
|
totalValue: number;
|
36
49
|
totalResellerFee?: number;
|
37
50
|
totalCreditFromChange: number;
|
38
51
|
totalAmountToPay: number;
|
39
|
-
extras: Extra[];
|
40
52
|
};
|
41
53
|
/**
|
42
54
|
* Base response type for the booking process. All APIs that update the cart, share this.
|