public static Tax ToTripTax(RouteTax routeTax, Flight flight) { var tax = new Tax(); tax.ID = routeTax.IdNumber; tax.ChangeType = routeTax.Tax.ChargeType.Name; tax.Code = routeTax.Tax.Code; tax.Country = routeTax.Route.DepartureAirport.City.Country.ISOCode; tax.SalePrice = PriceHelper.CreatePrice(TaxHelper.GetPrice(flight, routeTax.Tax)); return tax; }
public static string GetFullTaxName(RouteTax routeTax) { return GetFullTaxName(routeTax.Route.DepartureAirport.City.Country, routeTax.Tax); }