@almatar/smart-booking-dashboard 0.0.1 → 0.0.2-alpha.3
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/esm2022/lib/components/action-card/action-card.component.mjs +3 -3
- package/esm2022/lib/components/add-note-dialog/add-note-dialog.component.mjs +3 -3
- package/esm2022/lib/components/almatar-aside/aside-back-button.service.mjs +24 -0
- package/esm2022/lib/components/almatar-aside/aside.component.mjs +122 -0
- package/esm2022/lib/components/booking-input/booking-input.component.mjs +4 -3
- package/esm2022/lib/components/cancel-dialog/cancel-dialog.component.mjs +53 -4
- package/esm2022/lib/components/data-search/data-search.component.mjs +3 -3
- package/esm2022/lib/components/hotel-cancel/almatar-hotel-auto-cancellation.component.mjs +544 -0
- package/esm2022/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-refund-method/almatar-hotel-auto-cancellation-refund-method.component.mjs +43 -0
- package/esm2022/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-refund-summary/almatar-hotel-auto-cancellation-refund-summary.component.mjs +296 -0
- package/esm2022/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-select-rooms/almatar-hotel-auto-cancellation-select-rooms.component.mjs +88 -0
- package/esm2022/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-select-rooms/components/almatar-hotel-auto-cancellation-non-refundable-room/almatar-hotel-auto-cancellation-non-refundable-room.component.mjs +242 -0
- package/esm2022/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-select-rooms/components/almatar-hotel-auto-cancellation-refundable-room/almatar-hotel-auto-cancellation-refundable-room.component.mjs +48 -0
- package/esm2022/lib/components/hotel-cancel/components/hotel-content/hotel-content.component.mjs +129 -0
- package/esm2022/lib/components/hotel-cancel/components/hotel-refund-method-selector/hotel-refund-method-selector.component.mjs +321 -0
- package/esm2022/lib/components/hotel-cancel/components/result-overlay/result-overlay.component.mjs +52 -0
- package/esm2022/lib/components/hotel-cancel/enums/almatar-hotel-auto-cancellation-endpoints.enum.mjs +9 -0
- package/esm2022/lib/components/hotel-cancel/enums/almatar-hotel-auto-cancellation-step.enum.mjs +7 -0
- package/esm2022/lib/components/hotel-cancel/interfaces/i-almatar-hotel-auto-cancellation.interface.mjs +2 -0
- package/esm2022/lib/components/hotel-cancel/services/almatar-hotel-auto-cancellation-endpoints.service.mjs +457 -0
- package/esm2022/lib/components/hotel-cancel/services/almatar-hotel-auto-cancellation.service.mjs +55 -0
- package/esm2022/lib/components/hotel-itinerary-card/hotel-itinerary-card.component.mjs +48 -0
- package/esm2022/lib/components/reissue-dialog/reissue-dialog.component.mjs +135 -0
- package/esm2022/lib/components/reissue-dialog/reissue-upgrade.store.mjs +305 -0
- package/esm2022/lib/components/reissue-dialog/reissue.store.mjs +349 -0
- package/esm2022/lib/components/reissue-dialog/steps/reissue-date-step/reissue-date-step.component.mjs +45 -0
- package/esm2022/lib/components/reissue-dialog/steps/reissue-legs-step/reissue-legs-step.component.mjs +140 -0
- package/esm2022/lib/components/reissue-dialog/steps/reissue-notice/reissue-notice.component.mjs +16 -0
- package/esm2022/lib/components/reissue-dialog/steps/reissue-route-step/reissue-route-step.component.mjs +104 -0
- package/esm2022/lib/components/reissue-dialog/steps/reissue-service-step/reissue-service-step.component.mjs +44 -0
- package/esm2022/lib/components/reissue-dialog/steps/reissue-upgrade-confirm-step/reissue-upgrade-confirm-step.component.mjs +193 -0
- package/esm2022/lib/components/reissue-dialog/steps/reissue-upgrade-step/reissue-upgrade-step.component.mjs +88 -0
- package/esm2022/lib/components/result-panel/result-panel.component.mjs +3 -3
- package/esm2022/lib/components/shared/components/confirm-modal/confirm-modal.component.mjs +75 -0
- package/esm2022/lib/components/shared/components/manage-booking-failed-modal/manage-booking-failed-modal.component.mjs +46 -0
- package/esm2022/lib/components/shared/enums/hotel-manage-booking-aside-tab.enum.mjs +9 -0
- package/esm2022/lib/components/shared/interfaces/i-flight-refund-details.mjs +86 -0
- package/esm2022/lib/components/shared/models/cancel-hotel-booking.model.mjs +7 -0
- package/esm2022/lib/components/shared/services/hotel-manage-booking/hotel-manage-booking.service.mjs +27 -0
- package/esm2022/lib/components/shared/services/hotel-manage-booking-endpoints/hotel-manage-booking-endpoints.service.mjs +17 -0
- package/esm2022/lib/components/workflow-actions/workflow-actions.component.mjs +5 -3
- package/esm2022/lib/config/dashboard.config.mjs +3 -1
- package/esm2022/lib/config/hotel-actions.config.mjs +21 -1
- package/esm2022/lib/models/booking.types.mjs +73 -2
- package/esm2022/lib/models/reissue.types.mjs +2 -0
- package/esm2022/lib/pages/smart-booking-dashboard/smart-booking-dashboard.component.mjs +31 -7
- package/esm2022/lib/services/booking.service.mjs +6 -2
- package/esm2022/lib/services/reissue.service.mjs +142 -0
- package/esm2022/lib/services/toast.service.mjs +15 -7
- package/esm2022/lib/shared/components/currency-code-icon/currency-code-icon.component.mjs +35 -0
- package/esm2022/lib/shared/enums/brand-enums.enum.mjs +7 -0
- package/esm2022/lib/shared/environments/environment.mjs +10 -0
- package/esm2022/lib/shared/models/index.mjs +6 -0
- package/esm2022/lib/shared/modules/almatar-icon/almatar-icon.module.mjs +36 -0
- package/esm2022/lib/shared/modules/loader/loader.module.mjs +43 -0
- package/esm2022/lib/shared/pipes/exchange.pipe.mjs +49 -0
- package/esm2022/lib/shared/services/api.service.mjs +42 -0
- package/esm2022/lib/shared/services/shared.service.mjs +34 -0
- package/esm2022/lib/shared/services/translation.service.mjs +61 -0
- package/esm2022/lib/shared/services/webengage-tracking.service.mjs +28 -0
- package/esm2022/lib/shared/store/selectors/currency.selectors.mjs +9 -0
- package/esm2022/lib/utils/reissue-format.mjs +64 -0
- package/esm2022/lib/utils/reissue-url.builder.mjs +314 -0
- package/esm2022/public-api.mjs +3 -1
- package/fesm2022/almatar-smart-booking-dashboard.mjs +5387 -395
- package/fesm2022/almatar-smart-booking-dashboard.mjs.map +1 -1
- package/lib/components/action-dialog/action-dialog.component.d.ts +1 -1
- package/lib/components/almatar-aside/aside-back-button.service.d.ts +11 -0
- package/lib/components/almatar-aside/aside.component.d.ts +46 -0
- package/lib/components/cancel-dialog/cancel-dialog.component.d.ts +7 -0
- package/lib/components/hotel-cancel/almatar-hotel-auto-cancellation.component.d.ts +97 -0
- package/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-refund-method/almatar-hotel-auto-cancellation-refund-method.component.d.ts +25 -0
- package/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-refund-summary/almatar-hotel-auto-cancellation-refund-summary.component.d.ts +91 -0
- package/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-select-rooms/almatar-hotel-auto-cancellation-select-rooms.component.d.ts +39 -0
- package/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-select-rooms/components/almatar-hotel-auto-cancellation-non-refundable-room/almatar-hotel-auto-cancellation-non-refundable-room.component.d.ts +44 -0
- package/lib/components/hotel-cancel/components/almatar-hotel-auto-cancellation-select-rooms/components/almatar-hotel-auto-cancellation-refundable-room/almatar-hotel-auto-cancellation-refundable-room.component.d.ts +19 -0
- package/lib/components/hotel-cancel/components/hotel-content/hotel-content.component.d.ts +38 -0
- package/lib/components/hotel-cancel/components/hotel-refund-method-selector/hotel-refund-method-selector.component.d.ts +142 -0
- package/lib/components/hotel-cancel/components/result-overlay/result-overlay.component.d.ts +23 -0
- package/lib/components/hotel-cancel/enums/almatar-hotel-auto-cancellation-endpoints.enum.d.ts +7 -0
- package/lib/components/hotel-cancel/enums/almatar-hotel-auto-cancellation-step.enum.d.ts +5 -0
- package/lib/components/hotel-cancel/interfaces/i-almatar-hotel-auto-cancellation.interface.d.ts +252 -0
- package/lib/components/hotel-cancel/services/almatar-hotel-auto-cancellation-endpoints.service.d.ts +88 -0
- package/lib/components/hotel-cancel/services/almatar-hotel-auto-cancellation.service.d.ts +21 -0
- package/lib/components/hotel-itinerary-card/hotel-itinerary-card.component.d.ts +16 -0
- package/lib/components/reissue-dialog/reissue-dialog.component.d.ts +34 -0
- package/lib/components/reissue-dialog/reissue-upgrade.store.d.ts +96 -0
- package/lib/components/reissue-dialog/reissue.store.d.ts +124 -0
- package/lib/components/reissue-dialog/steps/reissue-date-step/reissue-date-step.component.d.ts +11 -0
- package/lib/components/reissue-dialog/steps/reissue-legs-step/reissue-legs-step.component.d.ts +16 -0
- package/lib/components/reissue-dialog/steps/reissue-notice/reissue-notice.component.d.ts +8 -0
- package/lib/components/reissue-dialog/steps/reissue-route-step/reissue-route-step.component.d.ts +21 -0
- package/lib/components/reissue-dialog/steps/reissue-service-step/reissue-service-step.component.d.ts +17 -0
- package/lib/components/reissue-dialog/steps/reissue-upgrade-confirm-step/reissue-upgrade-confirm-step.component.d.ts +28 -0
- package/lib/components/reissue-dialog/steps/reissue-upgrade-step/reissue-upgrade-step.component.d.ts +13 -0
- package/lib/components/result-panel/result-panel.component.d.ts +1 -1
- package/lib/components/shared/components/confirm-modal/confirm-modal.component.d.ts +17 -0
- package/lib/components/shared/components/manage-booking-failed-modal/manage-booking-failed-modal.component.d.ts +10 -0
- package/lib/components/shared/enums/hotel-manage-booking-aside-tab.enum.d.ts +7 -0
- package/lib/components/shared/interfaces/i-flight-refund-details.d.ts +73 -0
- package/lib/components/shared/models/cancel-hotel-booking.model.d.ts +6 -0
- package/lib/components/shared/services/hotel-manage-booking/hotel-manage-booking.service.d.ts +11 -0
- package/lib/components/shared/services/hotel-manage-booking-endpoints/hotel-manage-booking-endpoints.service.d.ts +7 -0
- package/lib/components/workflow-actions/workflow-actions.component.d.ts +3 -1
- package/lib/config/dashboard.config.d.ts +29 -0
- package/lib/models/booking.types.d.ts +28 -0
- package/lib/models/reissue.types.d.ts +147 -0
- package/lib/pages/smart-booking-dashboard/smart-booking-dashboard.component.d.ts +5 -1
- package/lib/services/reissue.service.d.ts +45 -0
- package/lib/services/toast.service.d.ts +14 -1
- package/lib/shared/components/currency-code-icon/currency-code-icon.component.d.ts +13 -0
- package/lib/shared/enums/brand-enums.enum.d.ts +5 -0
- package/lib/shared/environments/environment.d.ts +7 -0
- package/lib/shared/models/index.d.ts +11 -0
- package/lib/shared/modules/almatar-icon/almatar-icon.module.d.ts +13 -0
- package/lib/shared/modules/loader/loader.module.d.ts +13 -0
- package/lib/shared/pipes/exchange.pipe.d.ts +17 -0
- package/lib/shared/services/api.service.d.ts +43 -0
- package/lib/shared/services/shared.service.d.ts +12 -0
- package/lib/shared/services/translation.service.d.ts +17 -0
- package/lib/shared/services/webengage-tracking.service.d.ts +8 -0
- package/lib/shared/store/selectors/currency.selectors.d.ts +2 -0
- package/lib/utils/reissue-format.d.ts +28 -0
- package/lib/utils/reissue-url.builder.d.ts +24 -0
- package/package.json +9 -24
- package/public-api.d.ts +5 -1
- package/LICENSE +0 -21
- package/README.md +0 -132
package/lib/components/reissue-dialog/steps/reissue-legs-step/reissue-legs-step.component.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ReissueLegRow } from '../../reissue.store';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/** Leg cards in the cancel dialog's "Select Leg" design: checkbox overlay, outline badge, times row. */
|
|
4
|
+
export declare class SbdReissueLegsStepComponent {
|
|
5
|
+
rows: import("@angular/core").InputSignal<ReissueLegRow[]>;
|
|
6
|
+
anyAvailable: import("@angular/core").InputSignal<boolean>;
|
|
7
|
+
unavailableText: import("@angular/core").InputSignal<string>;
|
|
8
|
+
/** Extra info line, e.g. "these flights must be upgraded together". */
|
|
9
|
+
note: import("@angular/core").InputSignal<string>;
|
|
10
|
+
error: import("@angular/core").InputSignal<string>;
|
|
11
|
+
toggled: import("@angular/core").OutputEmitterRef<string>;
|
|
12
|
+
/** The note under a disabled leg. */
|
|
13
|
+
protected reasonText(reason: ReissueLegRow['reason']): string;
|
|
14
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SbdReissueLegsStepComponent, never>;
|
|
15
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SbdReissueLegsStepComponent, "app-sbd-reissue-legs-step", never, { "rows": { "alias": "rows"; "required": true; "isSignal": true; }; "anyAvailable": { "alias": "anyAvailable"; "required": false; "isSignal": true; }; "unavailableText": { "alias": "unavailableText"; "required": false; "isSignal": true; }; "note": { "alias": "note"; "required": false; "isSignal": true; }; "error": { "alias": "error"; "required": false; "isSignal": true; }; }, { "toggled": "toggled"; }, never, never, true, never>;
|
|
16
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
/** Icon + message box used for the info callout, loading / error states and the validation hint. */
|
|
3
|
+
export declare class SbdReissueNoticeComponent {
|
|
4
|
+
icon: import("@angular/core").InputSignal<string>;
|
|
5
|
+
tone: import("@angular/core").InputSignal<"error" | "success" | "info" | "warn" | "muted">;
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SbdReissueNoticeComponent, never>;
|
|
7
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SbdReissueNoticeComponent, "app-sbd-reissue-notice", never, { "icon": { "alias": "icon"; "required": false; "isSignal": true; }; "tone": { "alias": "tone"; "required": false; "isSignal": true; }; }, {}, never, ["*", "[action]"], true, never>;
|
|
8
|
+
}
|
package/lib/components/reissue-dialog/steps/reissue-route-step/reissue-route-step.component.d.ts
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { ReissueAirport } from '../../../../models/reissue.types';
|
|
2
|
+
import { AirportOption, AirportSide, ReissueRouteRow } from '../../reissue.store';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class SbdReissueRouteStepComponent {
|
|
5
|
+
rows: import("@angular/core").InputSignal<ReissueRouteRow[]>;
|
|
6
|
+
options: import("@angular/core").InputSignal<AirportOption[]>;
|
|
7
|
+
airportChanged: import("@angular/core").OutputEmitterRef<{
|
|
8
|
+
legId: string;
|
|
9
|
+
side: AirportSide;
|
|
10
|
+
airport: ReissueAirport | null;
|
|
11
|
+
}>;
|
|
12
|
+
searched: import("@angular/core").OutputEmitterRef<string>;
|
|
13
|
+
swapped: import("@angular/core").OutputEmitterRef<string>;
|
|
14
|
+
readonly compare: (a: ReissueAirport, b: ReissueAirport) => boolean;
|
|
15
|
+
readonly sides: {
|
|
16
|
+
key: AirportSide;
|
|
17
|
+
label: string;
|
|
18
|
+
}[];
|
|
19
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SbdReissueRouteStepComponent, never>;
|
|
20
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SbdReissueRouteStepComponent, "app-sbd-reissue-route-step", never, { "rows": { "alias": "rows"; "required": true; "isSignal": true; }; "options": { "alias": "options"; "required": true; "isSignal": true; }; }, { "airportChanged": "airportChanged"; "searched": "searched"; "swapped": "swapped"; }, never, never, true, never>;
|
|
21
|
+
}
|
package/lib/components/reissue-dialog/steps/reissue-service-step/reissue-service-step.component.d.ts
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ReissueServiceKey } from '../../../../models/reissue.types';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
interface ServiceOption {
|
|
4
|
+
key: ReissueServiceKey;
|
|
5
|
+
icon: string;
|
|
6
|
+
title: string;
|
|
7
|
+
description: string;
|
|
8
|
+
}
|
|
9
|
+
export declare class SbdReissueServiceStepComponent {
|
|
10
|
+
upgradeAvailable: import("@angular/core").InputSignal<boolean>;
|
|
11
|
+
chosen: import("@angular/core").OutputEmitterRef<ReissueServiceKey>;
|
|
12
|
+
/** Upgrade Class is listed only when the upgrade-class API returned options. */
|
|
13
|
+
protected options: import("@angular/core").Signal<ServiceOption[]>;
|
|
14
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SbdReissueServiceStepComponent, never>;
|
|
15
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SbdReissueServiceStepComponent, "app-sbd-reissue-service-step", never, { "upgradeAvailable": { "alias": "upgradeAvailable"; "required": false; "isSignal": true; }; }, { "chosen": "chosen"; }, never, never, true, never>;
|
|
16
|
+
}
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { ReissuePaymentLink } from '../../../../models/reissue.types';
|
|
2
|
+
import { UpgradeSummaryRow } from '../../reissue-upgrade.store';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class SbdReissueUpgradeConfirmStepComponent {
|
|
5
|
+
rows: import("@angular/core").InputSignal<UpgradeSummaryRow[]>;
|
|
6
|
+
total: import("@angular/core").InputSignal<number>;
|
|
7
|
+
totalLabel: import("@angular/core").InputSignal<string>;
|
|
8
|
+
priceChanged: import("@angular/core").InputSignal<boolean>;
|
|
9
|
+
/** `book-now` was sent. */
|
|
10
|
+
booked: import("@angular/core").InputSignal<boolean>;
|
|
11
|
+
link: import("@angular/core").InputSignal<ReissuePaymentLink>;
|
|
12
|
+
error: import("@angular/core").InputSignal<string>;
|
|
13
|
+
/** The link expired and the agent chose to redo the upgrade from the beginning. */
|
|
14
|
+
restart: import("@angular/core").OutputEmitterRef<void>;
|
|
15
|
+
protected copied: import("@angular/core").WritableSignal<boolean>;
|
|
16
|
+
/** Ticks every second so the countdown (and the expired state) update on their own. */
|
|
17
|
+
private now;
|
|
18
|
+
private remainingMs;
|
|
19
|
+
protected expired: import("@angular/core").Signal<boolean>;
|
|
20
|
+
/** `mm:ss` until the link expires; empty when the backend sent no (valid) expiry. */
|
|
21
|
+
protected countdown: import("@angular/core").Signal<string>;
|
|
22
|
+
/** Last two minutes: highlight the countdown. */
|
|
23
|
+
protected soon: import("@angular/core").Signal<boolean>;
|
|
24
|
+
constructor();
|
|
25
|
+
protected copy(url: string): Promise<void>;
|
|
26
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SbdReissueUpgradeConfirmStepComponent, never>;
|
|
27
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SbdReissueUpgradeConfirmStepComponent, "app-sbd-reissue-upgrade-confirm-step", never, { "rows": { "alias": "rows"; "required": true; "isSignal": true; }; "total": { "alias": "total"; "required": false; "isSignal": true; }; "totalLabel": { "alias": "totalLabel"; "required": false; "isSignal": true; }; "priceChanged": { "alias": "priceChanged"; "required": false; "isSignal": true; }; "booked": { "alias": "booked"; "required": false; "isSignal": true; }; "link": { "alias": "link"; "required": false; "isSignal": true; }; "error": { "alias": "error"; "required": false; "isSignal": true; }; }, { "restart": "restart"; }, never, never, true, never>;
|
|
28
|
+
}
|
package/lib/components/reissue-dialog/steps/reissue-upgrade-step/reissue-upgrade-step.component.d.ts
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { UpgradeSectionRow } from '../../reissue-upgrade.store';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/** New-class options as radio cards, in the look of the cancel dialog's refund-method options. */
|
|
4
|
+
export declare class SbdReissueUpgradeStepComponent {
|
|
5
|
+
sections: import("@angular/core").InputSignal<UpgradeSectionRow[]>;
|
|
6
|
+
error: import("@angular/core").InputSignal<string>;
|
|
7
|
+
picked: import("@angular/core").OutputEmitterRef<{
|
|
8
|
+
sectionId: string;
|
|
9
|
+
key: string;
|
|
10
|
+
}>;
|
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SbdReissueUpgradeStepComponent, never>;
|
|
12
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SbdReissueUpgradeStepComponent, "app-sbd-reissue-upgrade-step", never, { "sections": { "alias": "sections"; "required": true; "isSignal": true; }; "error": { "alias": "error"; "required": false; "isSignal": true; }; }, { "picked": "picked"; }, never, never, true, never>;
|
|
13
|
+
}
|
|
@@ -4,7 +4,7 @@ export declare class SbdResultPanelComponent {
|
|
|
4
4
|
private toast;
|
|
5
5
|
actionLabel: import("@angular/core").InputSignal<string>;
|
|
6
6
|
elapsedMs: import("@angular/core").InputSignal<number>;
|
|
7
|
-
status: import("@angular/core").InputSignal<"error" | "
|
|
7
|
+
status: import("@angular/core").InputSignal<"error" | "success" | "idle" | "loading">;
|
|
8
8
|
result: import("@angular/core").InputSignal<ResultContent>;
|
|
9
9
|
feedbackGiven: import("@angular/core").OutputEmitterRef<"up" | "down">;
|
|
10
10
|
get elapsedSeconds(): string;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { EventEmitter } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare class ConfirmModalComponent {
|
|
4
|
+
visible: boolean;
|
|
5
|
+
title: string;
|
|
6
|
+
message: string;
|
|
7
|
+
confirmLabel: string;
|
|
8
|
+
cancelLabel: string;
|
|
9
|
+
visibleChange: EventEmitter<boolean>;
|
|
10
|
+
confirm: EventEmitter<void>;
|
|
11
|
+
cancel: EventEmitter<void>;
|
|
12
|
+
onConfirm(): void;
|
|
13
|
+
onCancel(): void;
|
|
14
|
+
private close;
|
|
15
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ConfirmModalComponent, never>;
|
|
16
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ConfirmModalComponent, "confirm-modal", never, { "visible": { "alias": "visible"; "required": false; }; "title": { "alias": "title"; "required": false; }; "message": { "alias": "message"; "required": false; }; "confirmLabel": { "alias": "confirmLabel"; "required": false; }; "cancelLabel": { "alias": "cancelLabel"; "required": false; }; }, { "visibleChange": "visibleChange"; "confirm": "confirm"; "cancel": "cancel"; }, never, never, true, never>;
|
|
17
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { EventEmitter } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare class ManageBookingFailedModalComponent {
|
|
4
|
+
visible: boolean;
|
|
5
|
+
message: string;
|
|
6
|
+
visibleChange: EventEmitter<boolean>;
|
|
7
|
+
close(): void;
|
|
8
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ManageBookingFailedModalComponent, never>;
|
|
9
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ManageBookingFailedModalComponent, "manage-booking-failed-modal", never, { "visible": { "alias": "visible"; "required": false; }; "message": { "alias": "message"; "required": false; }; }, { "visibleChange": "visibleChange"; }, never, never, true, never>;
|
|
10
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
export interface IRefundDetailsData {
|
|
2
|
+
bookingId?: string | number;
|
|
3
|
+
refundAmount?: number;
|
|
4
|
+
totalRefundAmount?: number;
|
|
5
|
+
walletRefundAmount?: number;
|
|
6
|
+
totalCardRefundAmount?: number;
|
|
7
|
+
totalLoyaltyPointsRefundAmount?: number;
|
|
8
|
+
totalLoyaltyPoints?: number;
|
|
9
|
+
currency?: string;
|
|
10
|
+
refundMethod?: RefundPreferredMethod | string;
|
|
11
|
+
paymentGateway?: PaymentGatewayCode | LoyaltyPaymentType | string;
|
|
12
|
+
loyaltyPaymentType?: LoyaltyPaymentType | string;
|
|
13
|
+
isFullWalletRefundAllowed?: boolean;
|
|
14
|
+
paymentMethodCustomerUsed?: string;
|
|
15
|
+
isRefundable?: boolean;
|
|
16
|
+
}
|
|
17
|
+
export type RefundPreferredMethod = 'ORIGINAL_PAYMENT_METHOD' | 'WALLET' | 'wallet' | 'originalPaymentMethod' | 'BANK_TRANSFER' | 'LOYALTY_POINTS';
|
|
18
|
+
export type LoyaltyPaymentType = 'ALMATAR_POINTS' | 'ALFURSAN' | 'AlRajhiMokafaa' | 'Qitaf' | 'Wala';
|
|
19
|
+
export declare enum PaymentGatewayCode {
|
|
20
|
+
MADA = "MADA",
|
|
21
|
+
VISA = "VISA",
|
|
22
|
+
MASTERCARD = "MASTERCARD",
|
|
23
|
+
AMEX = "AMEX",
|
|
24
|
+
APPLE_PAY = "APPLE_PAY",
|
|
25
|
+
AlRajhiMokafaa = "RAJHI",
|
|
26
|
+
Qitaf = "QITAF",
|
|
27
|
+
Wala = "WALA",
|
|
28
|
+
Tamara = "TM",
|
|
29
|
+
Tabby = "TB",
|
|
30
|
+
Stc = "STC",
|
|
31
|
+
CH = "CH",
|
|
32
|
+
HP = "HP",
|
|
33
|
+
MF = "MF",
|
|
34
|
+
WT = "WT",
|
|
35
|
+
TM = "TM",
|
|
36
|
+
TB = "TB",
|
|
37
|
+
RAJHI = "RAJHI",
|
|
38
|
+
STC = "STC",
|
|
39
|
+
PPB = "PPB",
|
|
40
|
+
PP = "PP",
|
|
41
|
+
TAMAM = "TAMAM",
|
|
42
|
+
QITAF = "QITAF",
|
|
43
|
+
WALA = "WALA"
|
|
44
|
+
}
|
|
45
|
+
/** Labels for `paymentMethodCustomerUsed` gateway codes returned by the backend. */
|
|
46
|
+
export declare const PAYMENT_GATEWAY_LABELS: Record<string, {
|
|
47
|
+
en: string;
|
|
48
|
+
ar: string;
|
|
49
|
+
}>;
|
|
50
|
+
/** Gateway codes that refund to an installment plan rather than the original card. */
|
|
51
|
+
export declare const INSTALLMENT_GATEWAY_CODES: string[];
|
|
52
|
+
/** Gateway codes that refund to a loyalty-program account rather than the original card. */
|
|
53
|
+
export declare const LOYALTY_GATEWAY_CODES: string[];
|
|
54
|
+
/**
|
|
55
|
+
* Internal payment-processor/gateway names, never customer-recognizable
|
|
56
|
+
* brands — must not be surfaced verbatim (e.g. a card refund processed
|
|
57
|
+
* through Hyperpay must read as "Card"/"Original Payment Method", never
|
|
58
|
+
* "Hyperpay"). Callers fall back to a generic label whenever the normalized
|
|
59
|
+
* lookup returns ''.
|
|
60
|
+
*/
|
|
61
|
+
export declare const INTERNAL_GATEWAY_CODES: string[];
|
|
62
|
+
/**
|
|
63
|
+
* Result/confirmation-screen-only override: these gateways process card
|
|
64
|
+
* payments through Mada — shown specifically as "Mada Card" instead of
|
|
65
|
+
* falling back to the generic "Original Payment Method" label used
|
|
66
|
+
* everywhere else `INTERNAL_GATEWAY_CODES` applies.
|
|
67
|
+
*/
|
|
68
|
+
export declare const MADA_GATEWAY_CODES: string[];
|
|
69
|
+
/**
|
|
70
|
+
* Normalizes a raw payment gateway code from the backend to a standardized code.
|
|
71
|
+
* Handles both uppercase codes (e.g. 'HP') and labels (e.g. 'Hyperpay').
|
|
72
|
+
*/
|
|
73
|
+
export declare function normalizePaymentGatewayCode(raw?: string | null): PaymentGatewayCode | '';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Observable, BehaviorSubject } from 'rxjs';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare class HotelManageBookingService {
|
|
4
|
+
private activeAsideTab;
|
|
5
|
+
selectedHotelBooking: BehaviorSubject<any>;
|
|
6
|
+
getActiveAsideTab(): string;
|
|
7
|
+
setActiveAsideTab(tab: string): void;
|
|
8
|
+
getBookingDetails(bookingId: string): Observable<any>;
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<HotelManageBookingService, never>;
|
|
10
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<HotelManageBookingService>;
|
|
11
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare class HotelManageBookingEndpointsService {
|
|
4
|
+
cancelBookingRequest(payload: any): Observable<any>;
|
|
5
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<HotelManageBookingEndpointsService, never>;
|
|
6
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<HotelManageBookingEndpointsService>;
|
|
7
|
+
}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class SbdWorkflowActionsComponent {
|
|
3
3
|
bookingId: import("@angular/core").InputSignal<string>;
|
|
4
|
+
showReissue: import("@angular/core").InputSignal<boolean>;
|
|
4
5
|
cancelBooking: import("@angular/core").OutputEmitterRef<void>;
|
|
6
|
+
reissue: import("@angular/core").OutputEmitterRef<void>;
|
|
5
7
|
static ɵfac: i0.ɵɵFactoryDeclaration<SbdWorkflowActionsComponent, never>;
|
|
6
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SbdWorkflowActionsComponent, "app-sbd-workflow-actions", never, { "bookingId": { "alias": "bookingId"; "required": true; "isSignal": true; }; }, { "cancelBooking": "cancelBooking"; }, never, never, true, never>;
|
|
8
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SbdWorkflowActionsComponent, "app-sbd-workflow-actions", never, { "bookingId": { "alias": "bookingId"; "required": true; "isSignal": true; }; "showReissue": { "alias": "showReissue"; "required": false; "isSignal": true; }; }, { "cancelBooking": "cancelBooking"; "reissue": "reissue"; }, never, never, true, never>;
|
|
7
9
|
}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { EnvironmentProviders, InjectionToken } from '@angular/core';
|
|
2
|
+
import type { Observable } from 'rxjs';
|
|
3
|
+
/** Query/hash parameters (name -> value) the host adds to the link that opens the consumer web, e.g. its auth token. */
|
|
4
|
+
export type SbdRedirectAuthParams = Record<string, string>;
|
|
2
5
|
/**
|
|
3
6
|
* Host-app configuration for the Smart Booking Dashboard.
|
|
4
7
|
* Every field is optional; the defaults match the Almatar backoffice.
|
|
@@ -8,6 +11,32 @@ export interface SbdConfig {
|
|
|
8
11
|
apiBase: string;
|
|
9
12
|
/** Value of the `platform` header sent with FCR requests. Default: 'BO' */
|
|
10
13
|
platform: string;
|
|
14
|
+
/**
|
|
15
|
+
* Base URL of the consumer web app the Reissue search redirects to, INCLUDING the language/country
|
|
16
|
+
* prefix the web requires, e.g. 'https://prelive-alpha.alm6ar.com/en/sa'. Without the prefix the web answers 404.
|
|
17
|
+
*/
|
|
18
|
+
webBaseUrl: string;
|
|
19
|
+
/**
|
|
20
|
+
* Base of the customer payment page, WITHOUT the payment id, e.g. 'https://alpha3.alm6ar.com/en/payment'. The cart
|
|
21
|
+
* returns the link as a path only (`/<paymentId>`); this base is put in front of it to get the URL the agent sends.
|
|
22
|
+
* Not set (default) = a relative link is rejected instead of guessing a host.
|
|
23
|
+
*/
|
|
24
|
+
paymentLinkBase?: string;
|
|
25
|
+
/**
|
|
26
|
+
* Auth parameters added to the web link that Change Date / Change Route open, so the web can call its APIs for the
|
|
27
|
+
* agent. The host decides the names and the values, for example Backoffice `{ 'bo-token': token }` and Helix
|
|
28
|
+
* `{ 'x-helix-token': token }`. It runs in an injection context (the host can `inject()` its auth service first) and
|
|
29
|
+
* may return the object, a Promise or an Observable. Not set = nothing is added. If it fails, the web still opens
|
|
30
|
+
* without the token.
|
|
31
|
+
*/
|
|
32
|
+
redirectAuthParams?: () => SbdRedirectAuthParams | Promise<SbdRedirectAuthParams> | Observable<SbdRedirectAuthParams>;
|
|
33
|
+
/** Where `redirectAuthParams` go in the URL: the query string (default) or the `#fragment` (not sent to servers). */
|
|
34
|
+
redirectAuthIn?: 'query' | 'hash';
|
|
35
|
+
/**
|
|
36
|
+
* Show the Reissue button. Off by default so upgrading the package does not expose Reissue to agents before the host's
|
|
37
|
+
* backend serves the Reissue APIs; the host turns it on when they are ready.
|
|
38
|
+
*/
|
|
39
|
+
reissueEnabled: boolean;
|
|
11
40
|
}
|
|
12
41
|
export declare const SBD_DEFAULT_CONFIG: SbdConfig;
|
|
13
42
|
export declare const SBD_CONFIG: InjectionToken<SbdConfig>;
|
|
@@ -1,6 +1,34 @@
|
|
|
1
|
+
import { IBookingPackage } from '../components/hotel-cancel/interfaces/i-almatar-hotel-auto-cancellation.interface';
|
|
1
2
|
export type ProductType = 'flight' | 'hotel';
|
|
2
3
|
export type BookingStatus = 'idle' | 'loading' | 'success' | 'error';
|
|
3
4
|
export interface BookingResponse {
|
|
4
5
|
data: any;
|
|
5
6
|
elapsedMs: number;
|
|
6
7
|
}
|
|
8
|
+
export interface IHotelBookingData {
|
|
9
|
+
hotelId?: string | number;
|
|
10
|
+
bookingId?: string | number;
|
|
11
|
+
hotelName?: string;
|
|
12
|
+
coverImage?: string;
|
|
13
|
+
dateFrom?: string;
|
|
14
|
+
dateTo?: string;
|
|
15
|
+
from?: {
|
|
16
|
+
_i?: string;
|
|
17
|
+
};
|
|
18
|
+
to?: {
|
|
19
|
+
_i?: string;
|
|
20
|
+
};
|
|
21
|
+
packages?: IBookingPackage[];
|
|
22
|
+
rooms?: number;
|
|
23
|
+
numberOfNights?: number;
|
|
24
|
+
nightNumber?: number;
|
|
25
|
+
checkInTime?: string;
|
|
26
|
+
checkOutTime?: string;
|
|
27
|
+
price?: number;
|
|
28
|
+
data?: any;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Maps raw API response to IHotelBookingData interface
|
|
32
|
+
* This function handles the actual API response format from the booking endpoint
|
|
33
|
+
*/
|
|
34
|
+
export declare function mapToHotelBookingData(apiResponse: any): IHotelBookingData | null;
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
/** Services that end in a web search redirect. */
|
|
2
|
+
export type ReissueSearchService = 'change_date' | 'change_route';
|
|
3
|
+
export type ReissueServiceKey = ReissueSearchService | 'upgrade_class';
|
|
4
|
+
export type ReissueTripType = 'OneWay' | 'RoundTrip' | 'MultiCity';
|
|
5
|
+
export interface ReissueAirport {
|
|
6
|
+
id: string;
|
|
7
|
+
name: string;
|
|
8
|
+
city_name: string;
|
|
9
|
+
country_name: string;
|
|
10
|
+
type: 'airport' | 'city';
|
|
11
|
+
}
|
|
12
|
+
/** One leg of the original booking, normalized from `booking_info.leg_info`. */
|
|
13
|
+
export interface ReissueLeg {
|
|
14
|
+
legId: string;
|
|
15
|
+
direction: string;
|
|
16
|
+
originCode: string;
|
|
17
|
+
originName: string;
|
|
18
|
+
originCityName: string;
|
|
19
|
+
originCountryName: string;
|
|
20
|
+
destinationCode: string;
|
|
21
|
+
destinationName: string;
|
|
22
|
+
destinationCityName: string;
|
|
23
|
+
destinationCountryName: string;
|
|
24
|
+
/** Original departure, ISO-like string as the backend returns it. */
|
|
25
|
+
departure: string;
|
|
26
|
+
arrival: string;
|
|
27
|
+
airline: string;
|
|
28
|
+
/** Number of stops (layovers) on the leg. */
|
|
29
|
+
stops: number;
|
|
30
|
+
flightNo: string;
|
|
31
|
+
}
|
|
32
|
+
/** Everything the web search URL needs from the original booking. */
|
|
33
|
+
export interface ReissueBookingContext {
|
|
34
|
+
bookingId: string;
|
|
35
|
+
tripType: ReissueTripType;
|
|
36
|
+
legs: ReissueLeg[];
|
|
37
|
+
adults: number;
|
|
38
|
+
children: number;
|
|
39
|
+
infants: number;
|
|
40
|
+
cabinName: string;
|
|
41
|
+
cabinCode: string;
|
|
42
|
+
currency: string;
|
|
43
|
+
airlineCode: string;
|
|
44
|
+
flightNumber: string;
|
|
45
|
+
airlineName: string;
|
|
46
|
+
totalStops: number;
|
|
47
|
+
}
|
|
48
|
+
export interface ReissueLegAvailability {
|
|
49
|
+
legId: string;
|
|
50
|
+
available: boolean;
|
|
51
|
+
isWhatsapp?: boolean;
|
|
52
|
+
}
|
|
53
|
+
export interface ReissueAvailabilityResponse {
|
|
54
|
+
data?: {
|
|
55
|
+
legs?: ReissueLegAvailability[];
|
|
56
|
+
/** `false` = a round trip must be upgraded as a whole (the web's `allowCustomerToSelectSingleLeg`). Missing = allowed. */
|
|
57
|
+
allowCustomerToSelectSingleLeg?: boolean;
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
/** What the agent picked on the edit step. */
|
|
61
|
+
export interface ReissueSelection {
|
|
62
|
+
service: ReissueSearchService;
|
|
63
|
+
legs: ReissueLegChange[];
|
|
64
|
+
}
|
|
65
|
+
export interface ReissueLegChange {
|
|
66
|
+
legId: string;
|
|
67
|
+
/** change_date: new departure date, `YYYY-MM-DD`. */
|
|
68
|
+
departDate?: string;
|
|
69
|
+
/** change_route: new airports. */
|
|
70
|
+
origin?: ReissueAirport;
|
|
71
|
+
destination?: ReissueAirport;
|
|
72
|
+
}
|
|
73
|
+
export interface ReissueUpgradeOption {
|
|
74
|
+
/** Sent back to choose-flight (`ItineraryId` for booking scope, `legId` for leg scope). */
|
|
75
|
+
referenceKey: string;
|
|
76
|
+
code: string;
|
|
77
|
+
name: string;
|
|
78
|
+
providerType: string;
|
|
79
|
+
type?: string;
|
|
80
|
+
fareDetails?: {
|
|
81
|
+
totalAdditionalFare?: number;
|
|
82
|
+
};
|
|
83
|
+
priceDifference?: number;
|
|
84
|
+
}
|
|
85
|
+
export interface ReissueUpgradeExistingLeg {
|
|
86
|
+
legIndex?: number;
|
|
87
|
+
origin: string;
|
|
88
|
+
destination: string;
|
|
89
|
+
departureDateTime?: string;
|
|
90
|
+
airlineCode?: string;
|
|
91
|
+
flightNumber?: string;
|
|
92
|
+
class?: string;
|
|
93
|
+
bookingClass?: string;
|
|
94
|
+
fareBrand?: {
|
|
95
|
+
code?: string;
|
|
96
|
+
name?: string;
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
export interface ReissueUpgradeLeg {
|
|
100
|
+
legIndex: number;
|
|
101
|
+
origin?: string;
|
|
102
|
+
destination?: string;
|
|
103
|
+
options?: ReissueUpgradeOption[];
|
|
104
|
+
existingLeg: ReissueUpgradeExistingLeg;
|
|
105
|
+
}
|
|
106
|
+
export interface ReissueUpgradeOptionsResponse {
|
|
107
|
+
fareOptionScope?: 'leg' | 'booking';
|
|
108
|
+
/** scope `leg`: options per leg. */
|
|
109
|
+
legs?: ReissueUpgradeLeg[];
|
|
110
|
+
/** scope `booking`: options for the whole booking. */
|
|
111
|
+
options?: ReissueUpgradeOption[];
|
|
112
|
+
existingLegs?: ReissueUpgradeExistingLeg[];
|
|
113
|
+
originalLegs?: ReissueUpgradeExistingLeg[];
|
|
114
|
+
}
|
|
115
|
+
/** Body of `POST .../reissue/choose-flight/{bookingId}/{postBookingId}` (same shape the web sends for Upgrade Class). */
|
|
116
|
+
export interface ReissueChooseFlightRequest {
|
|
117
|
+
fareOptionScope: 'leg' | 'booking';
|
|
118
|
+
/** scope `booking`: the chosen itinerary. */
|
|
119
|
+
ItineraryId?: string;
|
|
120
|
+
/** scope `leg`: the chosen option per leg. */
|
|
121
|
+
onwardLeg?: {
|
|
122
|
+
legId: string;
|
|
123
|
+
providerType: string;
|
|
124
|
+
};
|
|
125
|
+
returnLeg?: {
|
|
126
|
+
legId: string;
|
|
127
|
+
providerType: string;
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
/** `data` of the choose-flight response (fields the web reads). */
|
|
131
|
+
export interface ReissueChooseFlightResponse {
|
|
132
|
+
itineraryAvailable?: boolean;
|
|
133
|
+
priceChanged?: boolean;
|
|
134
|
+
price?: number;
|
|
135
|
+
currency?: string;
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Payment link of a reissue. There is no separate API: it comes from the cart of the post-booking
|
|
139
|
+
* (`GET /v2/manage-booking/flight/cart/{postBookingId}`), see `ReissueService.getPaymentLink`. The agent copies it and
|
|
140
|
+
* sends it to the customer; the dialog does not follow the payment afterwards.
|
|
141
|
+
*/
|
|
142
|
+
export interface ReissuePaymentLink {
|
|
143
|
+
url: string;
|
|
144
|
+
amount: number;
|
|
145
|
+
currency: string;
|
|
146
|
+
expiresAt?: string;
|
|
147
|
+
}
|
|
@@ -3,13 +3,17 @@ import * as i0 from "@angular/core";
|
|
|
3
3
|
export declare class SmartBookingDashboardComponent {
|
|
4
4
|
private bookingService;
|
|
5
5
|
private toast;
|
|
6
|
+
/** The Reissue button is shown for flights only, and only when the host enabled the feature. */
|
|
7
|
+
protected readonly reissueEnabled: boolean;
|
|
6
8
|
product: import("@angular/core").WritableSignal<ProductType>;
|
|
7
9
|
bookingId: import("@angular/core").WritableSignal<string>;
|
|
8
|
-
bookingStatus: import("@angular/core").WritableSignal<"error" | "
|
|
10
|
+
bookingStatus: import("@angular/core").WritableSignal<"error" | "success" | "idle" | "loading">;
|
|
9
11
|
bookingData: import("@angular/core").WritableSignal<any>;
|
|
10
12
|
cancelDialogOpen: import("@angular/core").WritableSignal<boolean>;
|
|
13
|
+
hotelAutoCancelDialogOpen: import("@angular/core").WritableSignal<boolean>;
|
|
11
14
|
actionDialogOpen: import("@angular/core").WritableSignal<boolean>;
|
|
12
15
|
addNoteDialogOpen: import("@angular/core").WritableSignal<boolean>;
|
|
16
|
+
reissueDialogOpen: import("@angular/core").WritableSignal<boolean>;
|
|
13
17
|
selectedActionKey: import("@angular/core").WritableSignal<string>;
|
|
14
18
|
activeContextTab: import("@angular/core").WritableSignal<"notes" | "changes">;
|
|
15
19
|
availableActions: import("@angular/core").Signal<import("../../models/action.types").ActionConfig[]>;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { ReissueAirport, ReissueAvailabilityResponse, ReissueBookingContext, ReissueChooseFlightRequest, ReissueChooseFlightResponse, ReissuePaymentLink, ReissueUpgradeOptionsResponse } from '../models/reissue.types';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
* Reissue APIs — the same endpoints the consumer web uses (the backend opens them for BO).
|
|
6
|
+
*/
|
|
7
|
+
export declare class SbdReissueService {
|
|
8
|
+
private http;
|
|
9
|
+
private config;
|
|
10
|
+
private base;
|
|
11
|
+
private get headers();
|
|
12
|
+
/** `POST /v2/manage-booking/flight/create-post-booking/{bookingId}` -> `postBookingId`. */
|
|
13
|
+
createPostBooking(bookingId: string): Observable<string>;
|
|
14
|
+
/** `GET /v3/manage-booking/flight/reissue/availability/{bookingId}/{postBookingId}` -> `data.legs[]`. */
|
|
15
|
+
getAvailability(bookingId: string, postBookingId: string, ctx?: ReissueBookingContext): Observable<ReissueAvailabilityResponse>;
|
|
16
|
+
/**
|
|
17
|
+
* `POST /v3/manage-booking/flight/reissue/upgrade-class/{bookingId}/{postBookingId}` — same call (and body) the
|
|
18
|
+
* web makes to decide whether the "Upgrade Class" option is shown. Returns the unwrapped `data`.
|
|
19
|
+
*/
|
|
20
|
+
getUpgradeClassOptions(bookingId: string, postBookingId: string, ctx: ReissueBookingContext): Observable<ReissueUpgradeOptionsResponse | null>;
|
|
21
|
+
/** Same rule as the web's `hasUpgradeOptions()`: at least one option in any section. */
|
|
22
|
+
hasUpgradeOptions(data: ReissueUpgradeOptionsResponse | null): boolean;
|
|
23
|
+
/**
|
|
24
|
+
* Airport picker for Change Route. Same typeahead endpoint the web and the backoffice already use
|
|
25
|
+
* (`StaticDataService.getAirports`) — no extra backend work needed. Response: `data[].items[].items[]`.
|
|
26
|
+
* An empty term makes no request (the dialog lists the booking's own airports meanwhile).
|
|
27
|
+
*/
|
|
28
|
+
searchAirports(term: string): Observable<ReissueAirport[]>;
|
|
29
|
+
/**
|
|
30
|
+
* `POST /v3/manage-booking/flight/reissue/choose-flight/{bookingId}/{postBookingId}` — prices the chosen upgrade
|
|
31
|
+
* option. Same endpoint/body the web uses; response `data` carries `itineraryAvailable`, `priceChanged`, `price`, `currency`.
|
|
32
|
+
*/
|
|
33
|
+
chooseFlight(bookingId: string, postBookingId: string, body: ReissueChooseFlightRequest): Observable<ReissueChooseFlightResponse>;
|
|
34
|
+
/** `POST /v2/manage-booking/flight/book-now` — places a zero-total reissue (no payment needed). */
|
|
35
|
+
bookNow(postBookingId: string): Observable<unknown>;
|
|
36
|
+
/**
|
|
37
|
+
* Payment link of a reissue with an amount to pay. There is no separate API: the backend puts the link in the
|
|
38
|
+
* cart of the post-booking (`GET /v2/manage-booking/flight/cart/{postBookingId}`, the call the web checkout reads).
|
|
39
|
+
* The name of the field is not final yet: the first of the names below that exists is used, and the call fails
|
|
40
|
+
* with a clear message when the cart has none.
|
|
41
|
+
*/
|
|
42
|
+
getPaymentLink(postBookingId: string, amount?: number, currency?: string): Observable<ReissuePaymentLink>;
|
|
43
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SbdReissueService, never>;
|
|
44
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<SbdReissueService>;
|
|
45
|
+
}
|
|
@@ -1,10 +1,23 @@
|
|
|
1
|
+
import { InjectionToken } from '@angular/core';
|
|
1
2
|
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* How the dashboard shows messages. The backoffice uses ngx-toastr (the default); a host that has its own toast
|
|
5
|
+
* system (e.g. Helix with PrimeNG's `MessageService`) provides this token and the dashboard uses it instead.
|
|
6
|
+
*/
|
|
7
|
+
export interface SbdToastHandler {
|
|
8
|
+
success(message: string): void;
|
|
9
|
+
error(message: string): void;
|
|
10
|
+
info(message: string): void;
|
|
11
|
+
warning(message: string): void;
|
|
12
|
+
}
|
|
13
|
+
export declare const SBD_TOAST_HANDLER: InjectionToken<SbdToastHandler>;
|
|
2
14
|
export declare class SbdToastService {
|
|
3
|
-
private
|
|
15
|
+
private handler;
|
|
4
16
|
success(msg: string): void;
|
|
5
17
|
error(msg: string): void;
|
|
6
18
|
info(msg: string): void;
|
|
7
19
|
warning(msg: string): void;
|
|
20
|
+
private show;
|
|
8
21
|
static ɵfac: i0.ɵɵFactoryDeclaration<SbdToastService, never>;
|
|
9
22
|
static ɵprov: i0.ɵɵInjectableDeclaration<SbdToastService>;
|
|
10
23
|
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare enum CurrencySizeEnum {
|
|
3
|
+
SMALL = "small",
|
|
4
|
+
MEDIUM = "medium",
|
|
5
|
+
LARGE = "large",
|
|
6
|
+
LG = "large"
|
|
7
|
+
}
|
|
8
|
+
export declare class CurrencyCodeIconComponent {
|
|
9
|
+
currencyCode: string;
|
|
10
|
+
size: CurrencySizeEnum;
|
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CurrencyCodeIconComponent, never>;
|
|
12
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CurrencyCodeIconComponent, "currency-code-icon", never, { "currencyCode": { "alias": "currencyCode"; "required": false; }; "size": { "alias": "size"; "required": false; }; }, {}, never, never, true, never>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export interface ICurrency {
|
|
2
|
+
code: string;
|
|
3
|
+
name?: string;
|
|
4
|
+
symbol?: string;
|
|
5
|
+
rate?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare const loyaltyPointsMethods: {
|
|
8
|
+
readonly ALMATAR_POINTS: "ALMATAR_POINTS";
|
|
9
|
+
readonly ALFURSAN: "ALFURSAN";
|
|
10
|
+
};
|
|
11
|
+
export type LoyaltyPointsMethod = typeof loyaltyPointsMethods[keyof typeof loyaltyPointsMethods];
|