mts-booking-library 1.2.9 → 1.2.10
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.
@@ -1,6 +1,5 @@
|
|
1
1
|
import { MTSEnvs } from "../config";
|
2
2
|
import { ErrorResponse } from "../types/ErrorResponse";
|
3
|
-
import { Cart } from "../types/common/Cart";
|
4
3
|
import { EditPassengersDetailsRequest, GetBuyerPassengersDetailsResponse, Person } from "../types/common/Person";
|
5
4
|
import { GetSubscriptionAvailabilityRequest, GetSubscriptionAvailabilityResponse } from "../types/subscriptions/SubscriptionAvailabilities";
|
6
5
|
import { CreateSubscriptionCartRequest, SubscriptionCart } from "../types/subscriptions/SubscriptionCart";
|
@@ -21,10 +20,10 @@ export declare class SubscriptionBooking extends Booking {
|
|
21
20
|
* @param {number} [resellerId=undefined] The id of the reseller.
|
22
21
|
*/
|
23
22
|
constructor(env: MTSEnvs, sub_key: string, onCartExpiration: () => void, debug?: boolean, language?: string, access_token?: string, sellerId?: number, resellerId?: number);
|
24
|
-
getCart():
|
23
|
+
getCart(): SubscriptionCart | undefined;
|
25
24
|
fetchAndSetCart(cartId: number): Promise<void>;
|
26
25
|
private createCartTimer;
|
27
|
-
fetchCart(cartId: number): Promise<
|
26
|
+
fetchCart(cartId: number): Promise<SubscriptionCart>;
|
28
27
|
/**
|
29
28
|
* This method allows to delete a cart, thus allowing the user to exit from the booking process.
|
30
29
|
* @returns An {@link ErrorResponse} object in case of error, nothing otherwise. Note that also in case of error, all
|
package/lib/index.d.ts
CHANGED
@@ -21,4 +21,4 @@ export { ServiceCart, ServiceBookingType, CreateServiceCartRequest } from "./typ
|
|
21
21
|
export { ServiceInfo } from "./types/services/ServiceInfo";
|
22
22
|
export { Subscription } from "./types/subscriptions/Subscriptions";
|
23
23
|
export { GetSubscriptionAvailabilityRequest, GetSubscriptionAvailabilityResponse, SubscriptionCalendarDayPeriodInfo } from "./types/subscriptions/SubscriptionAvailabilities";
|
24
|
-
export { CreateSubscriptionCartRequest, SubscriptionPeriod } from "./types/subscriptions/SubscriptionCart";
|
24
|
+
export { SubscriptionCart, SubscriptionBookingType, CreateSubscriptionCartRequest, SubscriptionPeriod } from "./types/subscriptions/SubscriptionCart";
|