[search][core] Add Paid/Free indicator to search results

Signed-off-by: David Martinez <47610359+dvdmrtnz@users.noreply.github.com>
This commit is contained in:
David Martinez 2023-11-21 19:33:57 +01:00 committed by Viktor Govako
parent debe86bad6
commit 0af55c7306
2 changed files with 5 additions and 0 deletions

View file

@ -292,6 +292,8 @@ void FillDetails(FeatureType & ft, Result::Details & details)
auto const roadShields = ftypes::GetRoadShieldsNames(ft);
details.m_roadShields = strings::JoinStrings(roadShields, osm::MapObject::kFieldsSeparator);
details.m_fee = feature::GetLocalizedFeeType(feature::TypesHolder(ft));
details.m_isInitialized = true;
}

View file

@ -66,6 +66,8 @@ public:
uint16_t m_minutesUntilOpen = 0;
uint16_t m_minutesUntilClosed = 0;
std::string m_fee;
bool m_isInitialized = false;
};
@ -93,6 +95,7 @@ public:
std::string const & GetAirportIata() const { return m_details.m_airportIata; }
std::string const & GetBrand() const { return m_details.m_brand; }
std::string const & GetRoadShields() const { return m_details.m_roadShields; }
std::string const & GetFee() const { return m_details.m_fee; }
bool IsHotel() const { return m_details.m_isHotel; }
osm::YesNoUnknown IsOpenNow() const { return m_details.m_isOpenNow; }