diff options
| author | Zog | 2018-01-29 16:25:08 +0100 |
|---|---|---|
| committer | cedricnjanga | 2018-02-06 11:10:18 -0800 |
| commit | 47520607ee5a91fbba206aff4e72dd25293e1541 (patch) | |
| tree | 803942f2337c581f3b663146922c57c38200d9ea /app/helpers | |
| parent | 3c4e0b97d2c2502412817b5c99989f98821fc207 (diff) | |
| download | chouette-core-47520607ee5a91fbba206aff4e72dd25293e1541.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, '-' |
