agenda-libre-ruby/app/views/lugs/show.html.haml

86 lines
2.6 KiB
Plaintext
Raw Normal View History

- set_lug_meta
2014-10-13 22:50:59 +02:00
= render 'search'
%h2
= image_tag @lug.url + '/favicon.ico', alt: '', class: :favicon
2014-10-13 22:50:59 +02:00
= title @lug.name
%nav
= link_to lugs_path(q: params[:q], page: params[:page]), class: :back do
%em.fa.fa-arrow-left
= Lug.model_name.human.pluralize
\/
= link_to events_path tag: @lug.name do
2014-10-31 14:24:40 +01:00
%em.fa.fa-calendar
Agenda
\/
= link_to events_path format: :rss, tag: @lug.name do
%em.fa.fa-rss
2014-10-31 14:24:40 +01:00
RSS
\/
= link_to events_path format: :ics, tag: @lug.name do
%em.fa.fa-th-list
2014-10-31 14:24:40 +01:00
iCal
\/
= link_to maps_path tag: @lug.name do
%em.fa.fa-map-marker
2014-10-31 14:24:40 +01:00
OpenStreetMap
\/
= link_to maps_path format: :json, tag: @lug.name do
2014-10-31 14:24:40 +01:00
%em.fa.fa-dot-circle-o
GeoJSON
2014-07-27 01:50:22 +02:00
%dl
- if @lug.city.present?
%dt= Lug.human_attribute_name :city
%dd= @lug.city
- if @lug.department.present?
%dt= Lug.human_attribute_name :department
%dd= @lug.department
- if @lug.region.present?
2014-10-13 22:50:59 +02:00
%dt= Lug.human_attribute_name :region
%dd= @lug.region
- if @lug.url.present?
%dt= Lug.human_attribute_name :url
%dd= link_to @lug.url, @lug.url
2014-07-27 01:50:22 +02:00
%iframe(src="#{@lug.url}" width='1280' height='300' frameborder='none'
allowTransparency='true')
2014-10-13 22:50:59 +02:00
- if @events_future.any? || @events_past.any?
%fieldset
%legend
%em.fa.fa-calendar
= Event.model_name.human.pluralize
2014-10-31 14:24:40 +01:00
- if @events_future.any?
%h3= raw t 'future', count: @events_future.count
%ul.fa-ul
- @events_future.order('start_time asc').each do |event|
%li
= link_to event do
- if event.locality?
%em.locality.fa-li.fa.fa-globe(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_1'}")
- else
%em.locality.fa-li.fa.fa-shield(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_0'}")
%em.city= event.city
= event.title
2014-10-31 14:24:40 +01:00
.date= display_date event
- if @events_past.any?
%h3= raw t 'past', count: @events_past.count
%ul.fa-ul
- @events_past.order('start_time desc').each do |event|
%li
= link_to event do
- if event.locality?
%em.locality.fa-li.fa.fa-globe(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_1'}")
- else
%em.locality.fa-li.fa.fa-shield(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_0'}")
%em.city= event.city
= event.title
2014-10-31 14:24:40 +01:00
.date= display_date event
.events#map(data-url="#{ maps_path format: :json, tag: @lug.name }")