/** @format */ import { EventEmitter, OnDestroy, OnInit } from "@angular/core"; import { AbstractControl, FormGroup } from "@angular/forms"; import { ToastService } from "mis-crystal-design-system/toast"; import { Subject, Subscription } from "rxjs"; import { NsWISConfigurations } from "../../../models/configurations.model"; import { NsEmpWebExpData } from "../../../models/emp-web-exp.model"; import { ApiService } from "../../../services/api.service"; import { BookingDataService } from "../../../services/booking-data.service"; import { CommuteService } from "../../../services/commute.service"; import { SeatService } from "../../../services/seat.service"; import { PreferenceDataService } from "../../../services/preference-data.service"; import { MealService } from "../../../modules/meal-module/meal.service"; import { ConfigurationService } from "../../../services/configuration.service"; import { ModalService } from "mis-design-system/mis-modal"; import { IDatePickerConfig, IDatePickerToastText } from "mis-crystal-design-system/datepicker_v2"; export declare class BookingFormComponent implements OnInit, OnDestroy { bookingSvc: BookingDataService; private preferenceSvc; private apiService; private toasts; configSvc: ConfigurationService; private commuteSvc; private seatSvc; private mealService; private modals; Assets: { IMAGES: { EMPTY_HERO: string; MOBILE_EMPTY_HERO: string; NO_UPCOMING: string; HERO_BG: string; EMPTY_PLATE: string; PARKING_BG: string; CERTIFICATE: string; BOOKING_SUCCESS: string; HISTORY_EMPTY: string; }; ICONS: { MORE: string; CANCELLED: string; CANCEL_INFO: string; DOWN_ARROW: string; HERO_RIGHT: string; SEAT: string; CLOSE: string; CALENDAR: string; CAB: string; CAB_DARK: string; TICK_GREEN: string; SUCCESS_TICK: string; ARROW: string; EDIT: string; EDIT_DARK: string; CANCEL: string; IC_RADIO: string; IC_RADIO_ACTIVE: string; IC_ADD: string; IC_CLOSE: string; IC_WFO: string; IC_WFH: string; DESK: string; DESK_BULE: string; DESK_GREY: string; CHEVRON_RIGHT: string; CANCEL_BIN: string; WFH: string; WFO_CONVERT: string; WFH_CONVERT: string; WFO_CONVERT_DARK: string; WFH_CONVERT_DARK: string; QUICK_WFH: string; QUICK_WFO: string; CLOCK: string; PARKING: string; PARKING_ACTIVE: string; TRANSPORT: string; TRANSPORT_ACTIVE: string; TRANSPORT_UNAVAILABILTY: string; TRANSPORT_AVAILABILTY: string; INFO: string; CHOICE_CHIP: string; MEAL: string; MEAL_DARK: string; MEAL_CHECK: string; AVATAR: string; PARKING_MODULE: string; APPROVAL_STATUS: string; SUCCESS_RECURRENCE: string; FAILED_BOOKINGS: string; MORE_STATUS: string; }; }; loginShiftList: NsEmpWebExpData.IShiftData[]; logoutShiftList: NsEmpWebExpData.IShiftData[]; nextDaylogoutShiftList: NsEmpWebExpData.IShiftData[]; offices: NsEmpWebExpData.IOffice[]; preferenceData: NsEmpWebExpData.IPreference; mealMapValue: NsEmpWebExpData.IMealsEntity[]; meal: NsEmpWebExpData.IMeal[]; private endObs; bookingForm: FormGroup; prefOfc: NsEmpWebExpData.IOffice; dateFormat: string; startDatepickerConfig: Partial; endDatepickerConfig: Partial; formReset: Subject; formHeading: string; loader: boolean; parkingOptions: NsEmpWebExpData.IPremise[]; availableAddons: NsEmpWebExpData.IAddon[]; addonConfigurations: NsEmpWebExpData.IAddon; addonDataSubscription: Subscription; maxDuration: number; bookingReasons: string | any[]; disableOfficeChange: boolean; formConfigs: NsEmpWebExpData.IBookingFormConfig; create: EventEmitter<[NsEmpWebExpData.IBookingRequestObject | NsEmpWebExpData.IBookingRequest[], boolean]>; update: EventEmitter; close: EventEmitter; expand: EventEmitter<{ addon: NsEmpWebExpData.IAddon; shiftValid: boolean; }>; configurations: NsWISConfigurations.IConfigurations; drawerExpanded: boolean; datesDisabled: string[]; weeklyOffs: number[]; datepickerMessages: IDatePickerToastText[]; adhocEnabled: boolean; checkoutList: any[]; startTimeInMinutes: number; recurrenceBookingEnabled: boolean; mealCutOff: boolean; constructor(bookingSvc: BookingDataService, preferenceSvc: PreferenceDataService, apiService: ApiService, toasts: ToastService, configSvc: ConfigurationService, commuteSvc: CommuteService, seatSvc: SeatService, mealService: MealService, modals: ModalService); ngOnInit(): void; handleRecurrenceData(data: FormGroup): void; openAdhoc(data: string): void; handleRecurrenceEvent(): void; private setDatepickerDates; ngOnDestroy(): void; closeForm(): void; private buildForm; getControl(name: string): AbstractControl; private setChangelisteners; private setFormFieldStates; onOfficeChange(office: NsEmpWebExpData.IOffice, external?: boolean): void; expandAddon(addon: NsEmpWebExpData.IAddon): void; updateAddon(addon: NsEmpWebExpData.IAddon): Promise; checkAndGetShifts(start?: AbstractControl, end?: AbstractControl, officeChange?: boolean, updatePreferences?: boolean, updateShifts?: boolean): Promise; setdatepickerConfigs(office: NsEmpWebExpData.IOffice): void; setMealCutoffInMinutes(start: any, end: any): void; showCutOffMsg(): void; private setParkingAndPremises; private setShifts; private setCommute; onShiftChange(type: string | "login" | "logout", shift: NsEmpWebExpData.IShiftData): void; private updateSeat; handleCommuteChange([login, logout, registrationNumber]: [NsEmpWebExpData.ICommuteOption?, NsEmpWebExpData.ICommuteOption?, string?]): void; handleMealChange(data: NsEmpWebExpData.IMeal[]): void; saveBooking(): void; setBookingReasons(): Subscription; removeAddon(opt: NsEmpWebExpData.IAddon, data?: NsEmpWebExpData.IMealsEntity): void; }