Affichage affiné des evts, avec icone pour indiquer leur localité
This commit is contained in:
parent
931bae0b03
commit
dafb52ddf5
@ -10,6 +10,9 @@ header.calendar-header
|
|||||||
&:first-child, &:last-child
|
&:first-child, &:last-child
|
||||||
margin: 0 0.3em
|
margin: 0 0.3em
|
||||||
|
|
||||||
|
em.locality.fa
|
||||||
|
color: gray
|
||||||
|
|
||||||
span.city:after, strong.city:after, em.city:after
|
span.city:after, strong.city:after, em.city:after
|
||||||
content: ':'
|
content: ':'
|
||||||
|
|
||||||
@ -77,14 +80,13 @@ body.events.index table
|
|||||||
margin-left: 0
|
margin-left: 0
|
||||||
padding-left: 0.8em
|
padding-left: 0.8em
|
||||||
margin-bottom: 5px
|
margin-bottom: 5px
|
||||||
list-style-type: none
|
|
||||||
li
|
li
|
||||||
color: #444
|
color: #444
|
||||||
margin: 0
|
margin: 0
|
||||||
padding: 0
|
padding: 0
|
||||||
margin-top: 0.4em
|
margin-top: 0.4em
|
||||||
em.fa
|
&.national
|
||||||
color: gray
|
border-bottom: solid 3px lightgray
|
||||||
em.fa-li
|
em.fa-li
|
||||||
font-size: smaller
|
font-size: smaller
|
||||||
em.fa-li:before
|
em.fa-li:before
|
||||||
|
@ -39,13 +39,13 @@
|
|||||||
%ul.events.fa-ul
|
%ul.events.fa-ul
|
||||||
- events.select { |e| (e.start_time.to_date..e.end_time.to_date).cover? date }
|
- events.select { |e| (e.start_time.to_date..e.end_time.to_date).cover? date }
|
||||||
- .sort_by { |e| e.city }.each do |event|
|
- .sort_by { |e| e.city }.each do |event|
|
||||||
%li.event
|
%li.event(class="#{event.locality? ? 'national' : 'local'}" title="#{display_date(event)}")
|
||||||
- if event.locality?
|
- if event.locality?
|
||||||
%em.fa.fa-li.fa-globe(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_1'}")
|
%em.locality.fa.fa-li.fa-globe(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_1'}")
|
||||||
- else
|
- else
|
||||||
%em.fa.fa-li.fa-shield(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_0'}")
|
%em.locality.fa.fa-li.fa-shield(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_0'}")
|
||||||
= link_to event do
|
= link_to event do
|
||||||
%strong.city= event.city
|
%strong.city(title="#{event.full_address}")= event.city
|
||||||
= event.title
|
= event.title
|
||||||
|
|
||||||
.formats
|
.formats
|
||||||
|
@ -1,7 +1,11 @@
|
|||||||
- set_event_meta
|
- set_event_meta
|
||||||
|
|
||||||
%h2
|
%h2
|
||||||
%em.city= @event.city
|
- if @event.locality?
|
||||||
|
%em.locality.fa.fa-globe(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_1'}")
|
||||||
|
- else
|
||||||
|
%em.locality.fa.fa-shield(title="#{Event.human_attribute_name :locality} #{t 'attributes.locality_0'}")
|
||||||
|
%em.city(title="#{@event.full_address}")= @event.city
|
||||||
= title @event.title
|
= title @event.title
|
||||||
|
|
||||||
- if @event.persisted? && request.format == 'text/html' && controller.controller_name == 'events' && controller.action_name == 'show'
|
- if @event.persisted? && request.format == 'text/html' && controller.controller_name == 'events' && controller.action_name == 'show'
|
||||||
|
@ -4,7 +4,8 @@
|
|||||||
%head
|
%head
|
||||||
= display_meta_tags site: t('.title')
|
= display_meta_tags site: t('.title')
|
||||||
|
|
||||||
%meta(http-equiv='Content-Type' content='text/html; charset=utf-8')
|
%meta(http-equiv='Content-Type' content='text/html')
|
||||||
|
%meta(charset='utf-8')
|
||||||
%meta(name='viewport' content='width=device-width, initial-scale=1.0')
|
%meta(name='viewport' content='width=device-width, initial-scale=1.0')
|
||||||
%meta(name='robots' content='index, follow')
|
%meta(name='robots' content='index, follow')
|
||||||
|
|
||||||
|
@ -33,10 +33,10 @@ fr:
|
|||||||
inseecode: Code INSEE
|
inseecode: Code INSEE
|
||||||
regioncode: Code région
|
regioncode: Code région
|
||||||
lug:
|
lug:
|
||||||
related_region: Région
|
|
||||||
department: Département
|
|
||||||
url: Adresse web
|
|
||||||
city: Ville
|
city: Ville
|
||||||
|
department: Département
|
||||||
|
region: Région
|
||||||
|
url: Adresse web
|
||||||
event:
|
event:
|
||||||
title: Titre
|
title: Titre
|
||||||
start_time: Début
|
start_time: Début
|
||||||
@ -44,7 +44,7 @@ fr:
|
|||||||
description: Description
|
description: Description
|
||||||
address: Adresse
|
address: Adresse
|
||||||
city: Ville
|
city: Ville
|
||||||
related_region: Région
|
region: Région
|
||||||
locality: Portée
|
locality: Portée
|
||||||
url: URL
|
url: URL
|
||||||
contact: Contact
|
contact: Contact
|
||||||
|
Loading…
Reference in New Issue
Block a user