historyOffer method

OfferModel historyOffer()

Implementation

OfferModel historyOffer() {
  return OfferModel(
    tripType: tripType,
    taxUsd: totalTaxAmount,
    onlinePrice: departureOnlinePrice + returnOnlinePrice,
    discountedPrice: departureDiscountedPrice + returnDiscountedPrice,
    discountedPercentage: discountPercentage,
    totalOnlinePrice: bookingTotalOnlinePrice,
    totalDiscountedPrice: bookingTotalDiscountedPrice,
    isDiscounted: !isNonDiscounted,
    totalDiscountedPriceBTC: totalDiscountedPriceBTC,
    trips: List.generate(bookingTrips.length, (i) => FlightUtils.convertBookingTripToTripModel(bookingTrips[i])!),
  );
}