diff options
| author | Zog | 2018-01-29 16:25:08 +0100 |
|---|---|---|
| committer | Zog | 2018-02-01 14:40:24 +0100 |
| commit | 82de76f0efce7558a3fe240edf4e2293a8788ee1 (patch) | |
| tree | 3c9c70b904d989a4b8e0d8b2d0db03314465a410 /app/helpers | |
| parent | d896ba8753f9877dfd29a97cf1310d54d0b25874 (diff) | |
| download | chouette-core-82de76f0efce7558a3fe240edf4e2293a8788ee1.tar.bz2 | |
Refs #5758 @1h; Add localized names to StopAreas
Diffstat (limited to 'app/helpers')
| -rw-r--r-- | app/helpers/stop_areas_helper.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app/helpers/stop_areas_helper.rb b/app/helpers/stop_areas_helper.rb index 3e04fac7d..05ae042f5 100644 --- a/app/helpers/stop_areas_helper.rb +++ b/app/helpers/stop_areas_helper.rb @@ -11,6 +11,10 @@ module StopAreasHelper ( "<img src='#{stop_area_picture_url(stop_area)}'/>" + " <span style='height:25px; line-height:25px; margin-left: 5px; '>" + name + " <small style='height:25px; line-height:25px; margin-left: 10px; color: #555;'>" + localization + "</small></span>").html_safe end + def label_for_country country, txt=nil + "#{txt} <span title='#{ISO3166::Country[country]&.translation(I18n.locale)}' class='flag-icon flag-icon-#{country}'></span>".html_safe + end + def genealogical_title return t("stop_areas.genealogical.genealogical_routing") if @stop_area.stop_area_type == 'itl' t("stop_areas.genealogical.genealogical") @@ -33,12 +37,10 @@ module StopAreasHelper @stop_area.stop_area_type == 'stop_place' || @stop_area.stop_area_type == 'commercial_stop_point' end - def pair_key(access_link) "#{access_link.access_point.id}-#{access_link.stop_area.id}" end - def geo_data(sa, sar) if sa.long_lat_type.nil? content_tag :span, '-' |
