events
This commit is contained in:
parent
be25103b63
commit
f0171d336f
@ -547,7 +547,10 @@ article{
|
|||||||
.image{
|
.image{
|
||||||
width:15%;
|
width:15%;
|
||||||
float:left;
|
float:left;
|
||||||
background:#757575;
|
background: #757575 center center no-repeat;
|
||||||
|
background-size:100%;
|
||||||
|
background-size:cover;
|
||||||
|
|
||||||
height:80px;
|
height:80px;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
margin-bottom:5px;
|
margin-bottom:5px;
|
||||||
@ -586,14 +589,29 @@ h1{
|
|||||||
|
|
||||||
|
|
||||||
.event{
|
.event{
|
||||||
|
margin-bottom:2em;
|
||||||
|
%strong{
|
||||||
|
|
||||||
|
color:#E5383A;
|
||||||
|
}
|
||||||
|
.date{
|
||||||
|
font-weight: 400;
|
||||||
|
font-family:$header_font, Arial, sans-serif;
|
||||||
|
|
||||||
|
}
|
||||||
.image{
|
.image{
|
||||||
max-width:150px;
|
width:200px;
|
||||||
max-height:100px;
|
img{
|
||||||
height:500px;
|
max-width:200px;
|
||||||
|
max-height:300px;
|
||||||
|
|
||||||
width:100%;
|
width:100%;
|
||||||
|
float:left;
|
||||||
|
|
||||||
background:#757575;
|
background:#757575;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
@ -4,22 +4,22 @@ module EventsHelper
|
|||||||
if event.entire_day?
|
if event.entire_day?
|
||||||
if event.stop_date?
|
if event.stop_date?
|
||||||
if event.start_at.strftime('%d/%m/%Y') == event.stop_at.strftime('%d/%m/%Y')
|
if event.start_at.strftime('%d/%m/%Y') == event.stop_at.strftime('%d/%m/%Y')
|
||||||
"le #{l(event.start_at, :format => date_format)}"
|
"le <strong>#{l(event.start_at, :format => date_format)}</strong>"
|
||||||
else
|
else
|
||||||
"du #{l(event.start_at, :format => date_format)} au #{l(event.stop_at, :format => date_format)}"
|
"du <strong>#{l(event.start_at, :format => date_format)}</strong> au <strong>#{l(event.stop_at, :format => date_format)}</strong>"
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
"le #{l(event.start_at, :format => date_format)}"
|
"le <strong>#{l(event.start_at, :format => date_format)}</strong>"
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
if event.stop_date?
|
if event.stop_date?
|
||||||
if event.start_at.strftime('%d/%m/%Y') == event.stop_at.strftime('%d/%m/%Y')
|
if event.start_at.strftime('%d/%m/%Y') == event.stop_at.strftime('%d/%m/%Y')
|
||||||
"le #{l(event.start_at, :format => date_format)} de #{l(event.start_at, :format => time_format)} à #{l(event.stop_at, :format => time_format)} "
|
"le <strong>#{l(event.start_at, :format => date_format)}</strong> de <strong>#{l(event.start_at, :format => time_format)}</strong> à <strong>#{l(event.stop_at, :format => time_format)}</strong> "
|
||||||
else
|
else
|
||||||
"du #{l(event.start_at, :format => date_format)} à #{l(event.start_at, :format => time_format)} au #{l(event.stop_at, :format => date_format)} à #{l(event.stop_at, :format => time_format)} "
|
"du <strong>#{l(event.start_at, :format => date_format)}</strong> à <strong>#{l(event.start_at, :format => time_format)}</strong> au <strong>#{l(event.stop_at, :format => date_format)}</strong> à <strong>#{l(event.stop_at, :format => time_format)}</strong> "
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
"le #{l(event.start_at, :format => date_format)} à #{l(event.start_at, :format => time_format)}"
|
"le <strong>#{l(event.start_at, :format => date_format)}</strong> à <strong>#{l(event.start_at, :format => time_format)}</strong>"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -66,7 +66,7 @@
|
|||||||
|
|
||||||
-if @menu_item and @menu_item.slug and @menu_item.slug == "index"
|
-if @menu_item and @menu_item.slug and @menu_item.slug == "index"
|
||||||
.main_section_title
|
.main_section_title
|
||||||
=link_to "Actualités +", "/blog.html"
|
=link_to "Actualités +", "/actualites.html"
|
||||||
|
|
||||||
-article = Article.before(Date.today).recents.first
|
-article = Article.before(Date.today).recents.first
|
||||||
|
|
||||||
@ -87,7 +87,7 @@
|
|||||||
-articles.each do |article|
|
-articles.each do |article|
|
||||||
%a{:href => public_article_path(:id => article.slug)}
|
%a{:href => public_article_path(:id => article.slug)}
|
||||||
.article
|
.article
|
||||||
.image=image_tag article.image_file.file.large.medium.url if article.image_file
|
.image{:style => "background-image:url('"+(article.image_file.file.large.medium.url if article.image_file).to_s+"');"}
|
||||||
|
|
||||||
|
|
||||||
.description
|
.description
|
||||||
@ -102,7 +102,7 @@
|
|||||||
#sidebar
|
#sidebar
|
||||||
-if @menu_item and @menu_item.slug and @menu_item.slug == "index"
|
-if @menu_item and @menu_item.slug and @menu_item.slug == "index"
|
||||||
.main_section_title
|
.main_section_title
|
||||||
Prochainement +
|
=link_to "Prochainement +", "/agenda.html"
|
||||||
|
|
||||||
|
|
||||||
=#render Event.recents.limit(2)
|
=#render Event.recents.limit(2)
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
= event_human_date(event)
|
|
||||||
|
|
||||||
.event
|
.event
|
||||||
.image=image_tag event.image_file.file.large.medium.url if event.image_file
|
.image=image_tag event.image_file.file.large.medium.url if event.image_file
|
||||||
|
%h2.date=raw event_human_date(event)
|
||||||
%strong=event.title
|
%h1=event.title
|
||||||
|
|
||||||
|
|
||||||
-if event.description and event.description != ""
|
-if event.description and event.description != ""
|
||||||
@ -13,3 +13,4 @@
|
|||||||
%br=link_to "En savoir plus", public_event_path(event)
|
%br=link_to "En savoir plus", public_event_path(event)
|
||||||
|
|
||||||
|
|
||||||
|
.clear
|
@ -8,7 +8,8 @@
|
|||||||
-while the_month <= last_month
|
-while the_month <= last_month
|
||||||
%h2{:class => "month_title"}=l(the_month.to_date, :format => :month_and_year)
|
%h2{:class => "month_title"}=l(the_month.to_date, :format => :month_and_year)
|
||||||
.month_content
|
.month_content
|
||||||
=render :partial => "public/events/event", :collection =>Event.where('start_at < ? AND stop_at > ?',the_month.next_month, the_month.beginning_of_month).order(:start_at)
|
=render :partial => "public/events/event", :collection =>Event.where('(start_at < ? AND start_at > ?) OR (stop_at < ? AND stop_at > ?)',the_month.end_of_month, the_month.beginning_of_month,the_month.end_of_month, the_month.beginning_of_month).order(:start_at)
|
||||||
|
|
||||||
|
|
||||||
-the_month = the_month.next_month
|
-the_month = the_month.next_month
|
||||||
|
|
||||||
|
@ -3,9 +3,14 @@
|
|||||||
-@event = Event.find(params[:id])
|
-@event = Event.find(params[:id])
|
||||||
|
|
||||||
|
|
||||||
%h2=@event.title
|
%h1=@event.title
|
||||||
= event_human_date(@event)
|
=raw event_human_date(@event)
|
||||||
|
%br
|
||||||
|
%br
|
||||||
|
.image=image_tag @event.image_file.file.large.medium.url if @event.image_file
|
||||||
|
|
||||||
|
%br
|
||||||
|
%br
|
||||||
.agenda_description
|
.agenda_description
|
||||||
=simple_format @event.description
|
=simple_format @event.description
|
||||||
|
|
||||||
|
@ -20,9 +20,7 @@
|
|||||||
%ul
|
%ul
|
||||||
-menu_item.children.where(:enabled => true, :visible => true).order(:position).each do |menu_item|
|
-menu_item.children.where(:enabled => true, :visible => true).order(:position).each do |menu_item|
|
||||||
%li=menu_item_link(menu_item)
|
%li=menu_item_link(menu_item)
|
||||||
-if first_level_menu.slug == "livres-eft"
|
|
||||||
%li=link_to "Ebook Maigrir Durablement avec l'EFT", "http://www.maigrir-durablement-avec-eft.com/", :target => "_blank"
|
|
||||||
%li=link_to "Ebook Arrêter de Fumer avec l'EFT", "http://www.arreter-de-fumer-avec-eft.com/", :target => "_blank"
|
|
||||||
|
|
||||||
.breadcrumb
|
.breadcrumb
|
||||||
-if @menu_item.ancestors
|
-if @menu_item.ancestors
|
||||||
|
Loading…
x
Reference in New Issue
Block a user