Interface BookingFacade
- All Known Subinterfaces:
ShoppingBookingFacade
- All Known Implementing Classes:
DefaultBookingFacade,DefaultShoppingBookingFacade
public interface BookingFacade
Interface to retrieve the reservation data using a booking reference.
-
Method Summary
Modifier and TypeMethodDescriptionbooleanacceptOrder(String orderCode) Performs the acceptance of the order in case the user accepts the new booking suggested by the systembooleanaddRequestToRoomStayBooking(String request, int roomStayRefNumber, String bookingReference) Add an user request against a room stay bookingvoidaddSpecialRequestsForRoomStayBooking(String requestCode, int roomStayRefNumber, String bookingReference) Remove an user request from a room stay bookingbooleanamendAddRoom(String orderCode) Deprecated.Deprecated since version 3.0.amendOrder(String orderCode, String guid) Creates a cart from order and attaches it to the session to start amendment processbooleanatleastOneAdultTravellerRemaining(String orderCode, String cancelledTravellerCode) Checks if after cancellation of selected traveller, there will still be at least one adult left in the bookingbooleanbeginPartialOrderCancellation(String bookingReference, OrderEntryType orderEntryType, String guid) Creates a cart from the order without entries of type orderEntryTypebooleanbeginTravellerCancellation(String orderCode, String cancelledTravellerCode, String cancelledTravellerUid, String guid) Creates a cart from order without entries related to travellerDefines a queryString needed to access accommodation details page based on selections that are currently in the cart.voidcancelAccommodationReservation(String orderId) Cancel accommodation part of the order.voidcancelBookingForCurrentUser(String orderId) Performs the cancellation of the order.booleancancelOrder(String orderCode) Performs the cancellation of the order with the given orderCodebooleancancelPartialOrder(PriceData totalToRefund, OrderEntryType accommodation) Proceeds with placing an order for cart after the partialCancelOrder has begunvoidcancelTransportReservation(String orderId) Cancel transport part of the order.booleancancelTraveller(PriceData totalToPay) Deprecated.Deprecated since version 2.0.booleancancelTraveller(PriceData totalToPay, PriceData totalToRefund, TravellerData travellerData) Proceeds with placing an order for cart without removed travellerbooleancancelTraveller(PriceData totalToPay, TravellerData travellerData) Deprecated.Deprecated since version 4.0.booleanchangeDatesForAccommodationBooking(String checkInDate, String checkOutDate, AccommodationAvailabilityResponseData accommodationAvailabilityResponse, AccommodationReservationData accommodationReservationData) Methods Changes for dates for accommodation Booking in the cart, create and add RoomRateCartData for each AccommodationAddToCartForm details, and link to the original AccommodationOrderEntryGroupchangeDatesForAccommodationOrderEntryGroup(String checkInDate, String checkOutDate) Changes dates for AccommodationOrderEntryGroups in the cart and returns list of AccommodationOrderEntryGroups in the Cart.booleancheckBookingJourneyType(String orderCode, BookingJourneyType bookingJourneyType) Checks if the order corresponding to the given orderCode has the same BookingJourneyType attribute than the given one.createRefundPaymentTransaction(PriceData totalToPay) Creates a refund payment transaction based on previous details in cart and current total to pay (which is negative in this case)booleanThis method updates all the RoomRate cart entries that are currently active to have quantity zero, status CHANGED and active flag to falseevaluateCancelBooking(String orderCode) Evaluates if it is possible to cancel the booking.evaluateCancelTraveller(String orderCode, String travellerId) Evaluates if it is possible to remove a traveller from an order with transport entries.Retrieves a map of parameters needed to access accommodation details page (accommodation offering, check in date, check out date)getAccommodationOrderEntryGroupFromCart(int roomStayRefNum) Gets accommodation order entry group.Returns List of room stay reference numbers of the added roomsgetAccommodationOrderEntryGroupStartingDate(int roomStayRefNumber) Returns an accommodation reservation data specific for Guest Details Page Controller.getAccommodationRoomNameMapping(List<AccommodationReservationData> accommodationReservationDatas) Gets accommodation room name mapping.Returns an accommodation reservation data without room rates per daygetBookerEmailID(GlobalTravelReservationData globalReservationData, String lastName, String passengerReference) Performs a validation on the booking, to check if the user is one of the travellers in the booking(only checks last name and passengerReference if additional security is enabled) and returns email id of the booker.getBookingByBookingReference(String bookingReference) Returns ReservationData object for the bookingReference.getBookingByBookingReferenceAndAmendingOrder(String bookingReference) Gets booking based on booking reference, then checks status of booking, IF status is amendment in progress, (that means this is amend order flow) , to get latest order details, it gets the booking which has original order code equal to booking reference, version id is null and status is NOT amendment in progress, i.e.getBookingTotal(String bookingReference) Retrieves the total price of the bookinggetBookingTotalByOrderEntryType(String bookingReference, OrderEntryType orderEntryType) Calculates the booking total amount for the orderEntryType in the abstract ordergetBookingTotals(String bookingReference) Populate aRateDatawith all the totals meant to be presented to the usergetChangeDatePaymentResults(AccommodationReservationData accommodationReservationData, AccommodationAvailabilityResponseData accommodationAvailabilityResponse) getChangeDatePaymentResultsMap(AccommodationReservationData accommodationReservationData, AccommodationAvailabilityResponseData accommodationAvailabilityResponse) Provides the payment information for The change date functionality.Deprecated.Deprecated since version 3.0.Deprecated.Deprecated since version 3.0.Deprecated.Deprecated since version 3.0.Gets current user uid.getDisruptedReservation(String bookingReference) Gets disrupted reservation which only has the items that have been disruptedgetFullAccommodationBooking(String bookingReference) Returns an accommodation reservation data fully populated with room rates per daygetFullAccommodationBookingForAmendOrder(String bookingReference) Returns an accommodation reservation data fully populated with room rates per day.getGlobalTravelReservationData(String bookingReference) Returns an global reservation data fully populatedgetGuestOccupanciesFromCart(int roomStayRefNum) Returns guest occupancies from an accommodation or the rate plan if available or returns the minimum of two if both are available using the room stay reference numberReturns List of room stay reference numbers of the newly added roomsReturns only the room stays that have all associated entries with AmendStatus set to NEWReturns the next scheduled transportOffering data from current customer's active bookingsgetNotRefundableAmount(String bookingReference) Returns a {@link PriceData) representing the total amount that has been paid but cannot be refundedReturns List of room stay reference numbers of the old added active roomsReturns only the room stays that have all associated ACTIVE entries with AmendStatus set to SAME.getOrderTotalPaid(String bookingReference) Returns Total Paid for the bookinggetOrderTotalPaidForOrderEntryType(String bookingReference, OrderEntryType orderEntryType) Returns the total amount already paid for the given orderEntryType and the given bookingReferenceCalculates the total to pay for change dates for the order in cartgetOrderTotalToPayForOrderEntryType(String bookingReference, OrderEntryType orderEntryType) Returns the total amount to be paid for the given orderEntryType and the given bookingReferenceCalculates the total to refund for cancelled travellergetRefundTotal(String orderCode) Returns the total amount to be refundedgetRefundTotal(String orderCode, OrderEntryType orderEntryType) Returns the total amount to refund based on the given OrderEntryTypegetRoomStayRefNumberForOrderEntry(Integer entryNumber) Gets room stay ref number for order entry.getRoomStaysGuaranteesFromCart(int roomStayRefNum) Gets guarantees applied to the given room stays in the cart.getRoomStaysPenaltiesFromCart(int roomStayRefNum) Gets cancel penalties applied to the given room stays in the cart.getSpecialRequestsForRoomStayBooking(int roomStayRefNumber, String bookingReference) Get an user request against a room stay bookingConverts current cart to retrieve totalToPay valueDeprecated.Deprecated since version 3.0.Deprecated.Deprecated since version 3.0.booleanisAdditionalSecurityActive(String bookingReference) Checks whether the order has the additional security flag set to trueisAmendment(String bookingReference) Checks whether the order is a result of an amendmentbooleanisCancelPossible(String orderCode) Check if the cancel order is possible for the order with the given orderCodebooleanisCurrentCartOfType(String bookingType) Checks if is current cart of type.booleanisOrderOfType(String bookingReference, String bookingType) Checks if is current cart of type.isRoomStayRefValid(int roomStayRefNumber) Is room stay ref valid boolean.isUserOrderOwner(String bookingReference) Check whether the current user is the owner of the booking referencevoidmapOrderToUserAccount(String bookingReferenceNumber) Maps an order to a user if the user is not an owner and the order hasn't been linked alreadybooleanPlace orderbooleanremoveRequestFromRoomStayBooking(String requestCode, int roomStayRefNumber, String bookingReference) Remove an user request from a room stay bookingvoidremoveSpecialRequestsForRoomStayBooking(String requestCode, int roomStayRefNumber, String bookingReference) Remove an user request from a room stay bookingbooleanunlinkBooking(String orderCode) Flags the booking as not visible to customer accountupdateAccommodationOrderEntryGroup(int roomStayRefNum, GuestData guestData, List<PassengerTypeQuantityData> passengerTypeQuantityData, List<String> roomPreferenceData, String checkInTime) Updates AccommodationOrderEntryGroup with guest detailsupdateAccommodationOrderEntryGroup(int roomStayRefNum, List<String> roomPreferenceData) Updates AccommodationOrderEntryGroup with guest room preferencesvoidvalidateAmendmentAction(String orderId, ActionTypeOption transportAmendmentAction, ActionTypeOption accommodationAmendmentAction, ActionTypeOption globalAmendmentAction, String travellerUid) Returns the valid actions for the given booking reference and global reservation data for the given uservalidateAndReturnBookerEmailId(String bookingReference, String lastName) Deprecated.Deprecated since version 4.0.booleanvalidateB2BUser(CustomerModel currentCustomer, OrderModel orderModel) Validate b 2 b user boolean.booleanvalidateUserForBooking(String bookingReference) For a logged in user, this method validates if the supplied booking reference belongs to one of the reservations made by the customer.booleanvalidateUserForCheckout(String bookingReference) This method validates if the supplied booking reference belongs to one of the reservations made by the customer for logged-in users or if booking reference is valid for current guest user during checkout.
-
Method Details
-
getBookingByBookingReference
Returns ReservationData object for the bookingReference. Extracts the OrderModel using bookingReference and converts to ReservationData.- Parameters:
bookingReference- a String representing bookingReference Number- Returns:
- ReservationData object.
-
validateAndReturnBookerEmailId
Deprecated.Deprecated since version 4.0. useDefaultReservationFacade.retrieveGlobalReservationData(String)andgetBookerEmailID(GlobalTravelReservationData, String, String)Performs a validation on the booking, to check if the user is one of the travellers in the booking(only checks last name) and returns email id of the booker.- Parameters:
bookingReference- a String representing bookingReference NumberlastName- a string representing lastName of the user.- Returns:
- String EmailId.
-
getBookerEmailID
String getBookerEmailID(GlobalTravelReservationData globalReservationData, String lastName, String passengerReference) Performs a validation on the booking, to check if the user is one of the travellers in the booking(only checks last name and passengerReference if additional security is enabled) and returns email id of the booker.- Parameters:
globalReservationData- a GlobalTravelReservationDatalastName- a string representing lastName of the user.passengerReference- a string representing passengerReference.- Returns:
- booker email id
-
amendOrder
Creates a cart from order and attaches it to the session to start amendment process- Parameters:
orderCode- - code of the order which will be amendedguid- the guid- Returns:
- true if there were no errors when starting amendment process
-
createRefundPaymentTransaction
Creates a refund payment transaction based on previous details in cart and current total to pay (which is negative in this case)- Parameters:
totalToPay- the total amount to be refunded- Returns:
- TRUE is refund was successful
-
isCancelPossible
Check if the cancel order is possible for the order with the given orderCode- Parameters:
orderCode- as the code of the order to be cancelled- Returns:
- true if the cancellation is possible, false otherwise
-
getRefundTotal
Returns the total amount to be refunded- Parameters:
orderCode- as the code of the order to be cancelled- Returns:
- the PriceData corresponding to the amount to be refunded
-
getRefundTotal
Returns the total amount to refund based on the given OrderEntryType- Parameters:
orderCode- as the code of the order to cancelorderEntryType- as the orderEntryType- Returns:
- the PriceData corresponding to the amount to refund
-
cancelOrder
Performs the cancellation of the order with the given orderCode- Parameters:
orderCode- as the code of the order to be cancelled- Returns:
- true if the cancellation of the order was successful, false otherwise
-
getCurrentCustomerBookings
Deprecated.Deprecated since version 3.0.Returns a list of reservation data which corresponds to all the bookings of the current customer in session. In future release this method has been moved to {@link= BookingListFacade}- Returns:
- list of current customer's bookings
-
getCurrentCustomerAccommodationBookings
Deprecated.Deprecated since version 3.0.Returns a list of accommodation reservation data which corresponds to all accommodation bookings of the current customer in session In future release this method has been moved to {@link= BookingListFacade}- Returns:
- list of current customer's bookings
-
getCurrentCustomerTravelBookings
Deprecated.Deprecated since version 3.0.Returns a list of global travel reservation data which corresponds to all travel bookings of the current customer in session In future release this method has been moved to {@link= BookingListFacade}- Returns:
- list of current customer's bookings
-
getNextScheduledTransportOfferingData
TransportOfferingData getNextScheduledTransportOfferingData()Returns the next scheduled transportOffering data from current customer's active bookings- Returns:
- current customer's scheduled transportOffering data
-
beginTravellerCancellation
boolean beginTravellerCancellation(String orderCode, String cancelledTravellerCode, String cancelledTravellerUid, String guid) Creates a cart from order without entries related to traveller- Parameters:
orderCode- the order codecancelledTravellerCode- the cancelled traveller codecancelledTravellerUid- the cancelled traveller uidguid- the guid- Returns:
- TRUE if cart creation was correct
-
getTotalToPay
PriceData getTotalToPay()Converts current cart to retrieve totalToPay value- Returns:
- total to pay
-
cancelTraveller
Deprecated.Deprecated since version 2.0. UsecancelTraveller(PriceData, TravellerData)instead.Proceeds with placing an order for cart without removed traveller- Parameters:
totalToPay- the total to pay- Returns:
- true if cancellation is successful and a new order is placed
-
cancelTraveller
Deprecated.Deprecated since version 4.0. UsecancelTraveller(PriceData, PriceData, TravellerData)instead.Proceeds with placing an order for cart without removed traveller- Parameters:
totalToPay- the total to paytravellerData- the travellerData to cancel- Returns:
- true if cancellation is successful and a new order is placed
-
cancelTraveller
Proceeds with placing an order for cart without removed traveller- Parameters:
totalToPay- the total to paytotalToRefund- the total to refundtravellerData- the travellerData to cancel- Returns:
- true if cancellation is successful and a new order is placed
-
getCurrentUserUid
String getCurrentUserUid()Gets current user uid.- Returns:
- String current user uid
-
atleastOneAdultTravellerRemaining
Checks if after cancellation of selected traveller, there will still be at least one adult left in the booking- Parameters:
orderCode- the order codecancelledTravellerCode- the cancelled traveller code- Returns:
- true if one adult will be on the booking after cancellation of the traveller
-
isAmendment
Checks whether the order is a result of an amendment- Parameters:
bookingReference- the booking reference- Returns:
- true if the order is a result of amendment
-
getBookingByBookingReferenceAndAmendingOrder
Gets booking based on booking reference, then checks status of booking, IF status is amendment in progress, (that means this is amend order flow) , to get latest order details, it gets the booking which has original order code equal to booking reference, version id is null and status is NOT amendment in progress, i.e. the clone of original order(new order). ELSE returns booking retrieved based on booking reference- Parameters:
bookingReference- the booking reference- Returns:
- booking by booking reference and amending order
-
validateUserForBooking
For a logged in user, this method validates if the supplied booking reference belongs to one of the reservations made by the customer. For guest users it validates if the given booking reference matches with the booking reference used to login in the Manage My Booking component.- Parameters:
bookingReference- the booking reference- Returns:
- boolean boolean
-
validateUserForCheckout
This method validates if the supplied booking reference belongs to one of the reservations made by the customer for logged-in users or if booking reference is valid for current guest user during checkout.- Parameters:
bookingReference- the booking reference- Returns:
- boolean boolean
-
getDisruptedReservation
Gets disrupted reservation which only has the items that have been disrupted- Parameters:
bookingReference- the booking reference- Returns:
- disrupted reservation
-
acceptOrder
Performs the acceptance of the order in case the user accepts the new booking suggested by the system- Parameters:
orderCode- the order code- Returns:
- boolean boolean
-
mapOrderToUserAccount
Maps an order to a user if the user is not an owner and the order hasn't been linked already- Parameters:
bookingReferenceNumber- the booking reference number
-
isUserOrderOwner
Check whether the current user is the owner of the booking reference- Parameters:
bookingReference- the booking reference- Returns:
- boolean boolean
-
getFullAccommodationBooking
Returns an accommodation reservation data fully populated with room rates per day- Parameters:
bookingReference- the booking reference- Returns:
- full accommodation booking
-
getBasicAccommodationBookingFromCart
AccommodationReservationData getBasicAccommodationBookingFromCart()Returns an accommodation reservation data without room rates per day- Returns:
- basic accommodation booking from cart
-
getAccommodationReservationDataForGuestDetailsFromCart
AccommodationReservationData getAccommodationReservationDataForGuestDetailsFromCart()Returns an accommodation reservation data specific for Guest Details Page Controller.- Returns:
- accommodation booking from cart.
-
getFullAccommodationBookingForAmendOrder
Returns an accommodation reservation data fully populated with room rates per day. IF status is amendment in progress, (that means this is amend order flow) , to get latest order details, it gets the booking which has original order code equal to booking reference, version id is null and status is NOT amendment in progress, i.e. the clone of original order(new order). ELSE returns booking retrieved based on booking reference- Parameters:
bookingReference- the booking reference- Returns:
- booking by booking reference and amending order
-
updateAccommodationOrderEntryGroup
Boolean updateAccommodationOrderEntryGroup(int roomStayRefNum, GuestData guestData, List<PassengerTypeQuantityData> passengerTypeQuantityData, List<String> roomPreferenceData, String checkInTime) Updates AccommodationOrderEntryGroup with guest details- Parameters:
roomStayRefNum- the room stay ref numguestData- the guest datapassengerTypeQuantityData- the passenger type quantity dataroomPreferenceData- the room preference datacheckInTime- the check in time- Returns:
- boolean boolean
-
updateAccommodationOrderEntryGroup
Updates AccommodationOrderEntryGroup with guest room preferences- Parameters:
roomStayRefNum- the room stay ref numroomPreferenceData- the room preference data- Returns:
- boolean true if updated
-
getGuestOccupanciesFromCart
Returns guest occupancies from an accommodation or the rate plan if available or returns the minimum of two if both are available using the room stay reference number- Parameters:
roomStayRefNum- the room stay ref num- Returns:
- guest occupancies from cart
-
getGlobalTravelReservationData
Returns an global reservation data fully populated- Parameters:
bookingReference- the booking reference- Returns:
- global travel reservation data
-
addRequestToRoomStayBooking
Add an user request against a room stay booking- Parameters:
request- the requestroomStayRefNumber- the room stay ref numberbookingReference- the booking reference- Returns:
- true if the operation of adding the request is successfully performed, false otherwise
-
removeRequestFromRoomStayBooking
boolean removeRequestFromRoomStayBooking(String requestCode, int roomStayRefNumber, String bookingReference) Remove an user request from a room stay booking- Parameters:
requestCode- the request coderoomStayRefNumber- the room stay ref numberbookingReference- the booking reference- Returns:
- true if the operation of removing the request is successfully performed, false otherwise
-
amendAddRoom
Deprecated.Deprecated since version 3.0. Please use startAmendment() inAccommodationAmendmentFacadewhich does the same thing.Creates a cart from order and attaches it to the session to start add room amendment process- Parameters:
orderCode- the order code- Returns:
- boolean boolean
-
buildAccommodationDetailsQueryFromCart
String buildAccommodationDetailsQueryFromCart()Defines a queryString needed to access accommodation details page based on selections that are currently in the cart.- Returns:
- string string
-
getNewReservedRoomStays
List<ReservedRoomStayData> getNewReservedRoomStays()Returns only the room stays that have all associated entries with AmendStatus set to NEW- Returns:
- new reserved room stays
-
getOldReservedRoomStays
List<ReservedRoomStayData> getOldReservedRoomStays()Returns only the room stays that have all associated ACTIVE entries with AmendStatus set to SAME.- Returns:
- old reserved room stays
-
isCurrentCartOfType
Checks if is current cart of type.- Parameters:
bookingType- the booking type- Returns:
- true, if current cart is of type
-
isOrderOfType
Checks if is current cart of type.- Parameters:
bookingReference- the booking referencebookingType- the booking type- Returns:
- true, if current cart is of type
-
beginPartialOrderCancellation
boolean beginPartialOrderCancellation(String bookingReference, OrderEntryType orderEntryType, String guid) Creates a cart from the order without entries of type orderEntryType- Parameters:
bookingReference- the booking referenceorderEntryType- the order entry typeguid- the guid- Returns:
- true if cart creation was correct
-
cancelPartialOrder
Proceeds with placing an order for cart after the partialCancelOrder has begun- Parameters:
totalToRefund- the total to refundaccommodation- the accommodation- Returns:
- true if cancellation is successful and a new order is placed
-
changeDatesForAccommodationBooking
boolean changeDatesForAccommodationBooking(String checkInDate, String checkOutDate, AccommodationAvailabilityResponseData accommodationAvailabilityResponse, AccommodationReservationData accommodationReservationData) Methods Changes for dates for accommodation Booking in the cart, create and add RoomRateCartData for each AccommodationAddToCartForm details, and link to the original AccommodationOrderEntryGroup- Parameters:
checkInDate- the check in datecheckOutDate- the check out dateaccommodationAvailabilityResponse- object of accommodationAvailabilityResponseaccommodationReservationData- object of accommodationReservationData- Returns:
- Success /Failure true/false
-
deleteRoomRateEntries
boolean deleteRoomRateEntries()This method updates all the RoomRate cart entries that are currently active to have quantity zero, status CHANGED and active flag to false- Returns:
- boolean to indicate whether update operation was successful
-
changeDatesForAccommodationOrderEntryGroup
List<AccommodationOrderEntryGroupModel> changeDatesForAccommodationOrderEntryGroup(String checkInDate, String checkOutDate) Changes dates for AccommodationOrderEntryGroups in the cart and returns list of AccommodationOrderEntryGroups in the Cart.- Parameters:
checkInDate- the check in datecheckOutDate- the check out date- Returns:
- accommodationOrderEntryGroupModels list of AccommodationOrderEntryGroupModel
-
unlinkBooking
Flags the booking as not visible to customer account- Parameters:
orderCode- the order code- Returns:
- boolean boolean
-
getVisibleCurrentCustomerTravelBookings
Deprecated.Deprecated since version 3.0.Returns only the bookings visible to the current user In future release this method has been moved to {@link= BookingListFacade}- Returns:
- visible current customer travel bookings
-
getVisibleCurrentCustomerAccommodationBookings
Deprecated.Deprecated since version 3.0.Returns only the accommodation bookings visible to the current user In future release this method has been moved to {@link= BookingListFacade}- Returns:
- visible current customer accommodation bookings
-
getBookingTotal
Retrieves the total price of the booking- Parameters:
bookingReference- the booking reference- Returns:
- booking total
-
placeOrder
boolean placeOrder()Place order- Returns:
- orderData representing the order
-
getOrderTotalPaidForOrderEntryType
BigDecimal getOrderTotalPaidForOrderEntryType(String bookingReference, OrderEntryType orderEntryType) Returns the total amount already paid for the given orderEntryType and the given bookingReference- Parameters:
bookingReference- the booking referenceorderEntryType- the order entry type- Returns:
- order total paid for order entry type
-
getOrderTotalToPayForOrderEntryType
BigDecimal getOrderTotalToPayForOrderEntryType(String bookingReference, OrderEntryType orderEntryType) Returns the total amount to be paid for the given orderEntryType and the given bookingReference- Parameters:
bookingReference- the booking referenceorderEntryType- the order entry type- Returns:
- order total to pay for order entry type
-
getOrderTotalToPayForChangeDates
BigDecimal getOrderTotalToPayForChangeDates()Calculates the total to pay for change dates for the order in cart- Returns:
- totalAmountToPay order total to pay for change dates
-
validateB2BUser
Validate b 2 b user boolean.- Parameters:
currentCustomer- the current customerorderModel- the order model- Returns:
- boolean validate b2b user against order to grant access
-
getChangeDatePaymentResultsMap
Map<String,String> getChangeDatePaymentResultsMap(AccommodationReservationData accommodationReservationData, AccommodationAvailabilityResponseData accommodationAvailabilityResponse) Provides the payment information for The change date functionality. It provides amount paid already paid for order, new amount to be paid/refund(if any) , the payment action required(REFUND,PAYABLE or SAME).- Parameters:
accommodationReservationData- the accommodation reservation dataaccommodationAvailabilityResponse- the accommodation availability response- Returns:
- change date payment results map
-
getChangeDatePaymentResults
ChangeDateData getChangeDatePaymentResults(AccommodationReservationData accommodationReservationData, AccommodationAvailabilityResponseData accommodationAvailabilityResponse) - Parameters:
accommodationReservationData- the accommodation reservation dataaccommodationAvailabilityResponse- the accommodation availability response- Returns:
- change date payment Data
-
getAccommodationOrderEntryGroupRefs
Returns List of room stay reference numbers of the added rooms- Returns:
- accommodation order entry group refs
-
getNewAccommodationOrderEntryGroupRefs
Returns List of room stay reference numbers of the newly added rooms- Returns:
- new accommodation order entry group refs
-
getOldAccommodationOrderEntryGroupRefs
Returns List of room stay reference numbers of the old added active rooms- Returns:
- old accommodation order entry group refs
-
getOrderTotalPaid
Returns Total Paid for the booking- Parameters:
bookingReference- the booking reference- Returns:
- order total paid
-
getBookingTotalByOrderEntryType
Calculates the booking total amount for the orderEntryType in the abstract order- Parameters:
bookingReference- the booking referenceorderEntryType- the orderEntryType- Returns:
- totalAmount booking total by order entry type
-
checkBookingJourneyType
Checks if the order corresponding to the given orderCode has the same BookingJourneyType attribute than the given one.- Parameters:
orderCode- as the order codebookingJourneyType- as the bookingJourneyType- Returns:
- true if the order corresponding to the orderCode has the same BookingJourneyType attribute than the given bookingJourneyType, false otherwise.
-
getAccommodationDetailsParametersFromCart
Retrieves a map of parameters needed to access accommodation details page (accommodation offering, check in date, check out date)- Returns:
- accommodation details parameters
-
getNotRefundableAmount
Returns a {@link PriceData) representing the total amount that has been paid but cannot be refunded- Parameters:
bookingReference- the booking referencebookingReference- the booking referencebookingReference- the booking referencebookingReference- the booking reference- Returns:
- the not refundable amount
-
isAdditionalSecurityActive
Checks whether the order has the additional security flag set to true- Parameters:
bookingReference- the booking reference- Returns:
- true if the order has the additional security flag set to true
-
getRefundForCancelledTraveller
PriceData getRefundForCancelledTraveller()Calculates the total to refund for cancelled traveller- Returns:
- refund for cancelled traveller
-
getBookingTotals
Populate aRateDatawith all the totals meant to be presented to the user- Parameters:
bookingReference- the booking reference- Returns:
- booking totals
-
isRoomStayRefValid
Is room stay ref valid boolean.- Parameters:
roomStayRefNumber- the room stay ref number- Returns:
- true if the room stay reference is valid for the given session cart
-
getAccommodationOrderEntryGroupStartingDate
- Parameters:
roomStayRefNumber- the room stay ref number- Returns:
- the starting date of AccommodationOrderEntryGroup corresponding to given roomStayRefNumber
-
cancelBookingForCurrentUser
Performs the cancellation of the order.- Parameters:
orderId- the order id- Throws:
BookingCancelException- in case of errors
-
getAccommodationOrderEntryGroupFromCart
Gets accommodation order entry group.- Parameters:
roomStayRefNum- the room stay ref num- Returns:
- the accommodation order entry group
-
getRoomStayRefNumberForOrderEntry
Gets room stay ref number for order entry.- Parameters:
entryNumber- the entry number- Returns:
- the room stay ref number for order entry
-
getRoomStaysGuaranteesFromCart
Gets guarantees applied to the given room stays in the cart.- Parameters:
roomStayRefNum- the room stay ref num- Returns:
- the list of guarantees
-
getRoomStaysPenaltiesFromCart
Gets cancel penalties applied to the given room stays in the cart.- Parameters:
roomStayRefNum- the room stay ref num- Returns:
- the list of cancel penalties
-
evaluateCancelBooking
Evaluates if it is possible to cancel the booking. Checks if 1) the order exists and the user has the rights to cancel the booking. 2) the action is allowed by validating the booking actions. 3) the cancel booking is possible by verifying the consignments, if the order has been already delivered and if there is some invalid payment.- Parameters:
orderCode- the orderCode- Returns:
- The
EvaluateCancelBookingDatacontaining all the breakdowns for the total to refund and penalties for both transport and accommodation reservation. - Throws:
BookingCancelException- if the additional security data is true in the order but the orderId is a orderGuid, or if there are invalid booking actions.TravelModelNotFoundException- if the order is not found in the system
-
validateAmendmentAction
void validateAmendmentAction(String orderId, ActionTypeOption transportAmendmentAction, ActionTypeOption accommodationAmendmentAction, ActionTypeOption globalAmendmentAction, String travellerUid) throws OrderNotFoundException, TravelOrderValidationException Returns the valid actions for the given booking reference and global reservation data for the given user- Parameters:
orderId- the order idtransportAmendmentAction- the transport amendment actionaccommodationAmendmentAction- the accommodation amendment actionglobalAmendmentAction- the global amendment actiontravellerUid- the uid for the specific traveller to be validated- Throws:
OrderNotFoundException- the order not found exceptionTravelOrderValidationException- the travel order validation exception
-
cancelTransportReservation
Cancel transport part of the order.- Parameters:
orderId- the order id- Throws:
BookingCancelException- in case of errors
-
cancelAccommodationReservation
Cancel accommodation part of the order.- Parameters:
orderId- the order id- Throws:
BookingCancelException- in case of errors
-
evaluateCancelTraveller
EvaluateCancelPriceInfoData evaluateCancelTraveller(String orderCode, String travellerId) throws RemoveTravellerException Evaluates if it is possible to remove a traveller from an order with transport entries. Checks if 1) the order exists and the user has the rights to cancel the booking. 2) the action is allowed by validating the booking actions.- Parameters:
orderCode- the orderCode- Returns:
- The
EvaluateCancelPriceInfoDatacontaining all the breakdowns for the total to refund and penalties for transport reservation section. - Throws:
RemoveTravellerException- if the additional security data is true in the order but the orderId is a orderGuid, or if the operation is not allowed due to some validations.TravelModelNotFoundException- if the order is not found in the system
-
getSpecialRequestsForRoomStayBooking
SpecialRequestDetailData getSpecialRequestsForRoomStayBooking(int roomStayRefNumber, String bookingReference) throws SpecialRequestException Get an user request against a room stay booking- Parameters:
roomStayRefNumber- the room stay ref numberbookingReference- the booking reference- Returns:
- true if the operation of adding the request is successfully performed, false otherwise
- Throws:
SpecialRequestException
-
removeSpecialRequestsForRoomStayBooking
void removeSpecialRequestsForRoomStayBooking(String requestCode, int roomStayRefNumber, String bookingReference) throws SpecialRequestException Remove an user request from a room stay booking- Parameters:
requestCode- the request coderoomStayRefNumber- the room stay ref numberbookingReference- the booking reference- Throws:
SpecialRequestException
-
addSpecialRequestsForRoomStayBooking
void addSpecialRequestsForRoomStayBooking(String requestCode, int roomStayRefNumber, String bookingReference) throws SpecialRequestException Remove an user request from a room stay booking- Parameters:
requestCode- the request coderoomStayRefNumber- the room stay ref numberbookingReference- the booking reference- Throws:
SpecialRequestException
-
getAccommodationRoomNameMapping
Map<String,Map<String, getAccommodationRoomNameMappingInteger>> (List<AccommodationReservationData> accommodationReservationDatas) Gets accommodation room name mapping.- Parameters:
accommodationReservationDatas- the accommodation reservation datas- Returns:
- the accommodation room name mapping
-