On peut maintenant consulter un evt par ical
This commit is contained in:
parent
86548c0e1d
commit
542eafc9e6
|
@ -1,3 +1,5 @@
|
||||||
|
- config.time_zone = 'Paris'
|
||||||
|
|
||||||
%form.region_selector
|
%form.region_selector
|
||||||
- if params[:start_date]
|
- if params[:start_date]
|
||||||
= hidden_field_tag :start_date, params[:start_date]
|
= hidden_field_tag :start_date, params[:start_date]
|
||||||
|
|
|
@ -4,7 +4,7 @@ PRODID:-//AgendaDuLibre.org
|
||||||
X-WR-CALNAME:Agenda du Libre
|
X-WR-CALNAME:Agenda du Libre
|
||||||
X-WR-TIMEZONE:Europe/Paris
|
X-WR-TIMEZONE:Europe/Paris
|
||||||
CALSCALE:GREGORIAN
|
CALSCALE:GREGORIAN
|
||||||
X-WR-CALDESC:L'Agenda des évènements autour du Libre
|
X-WR-CALDESC:<%= t 'title', scope: [:layouts, :application] %>
|
||||||
<% @events.each do |event| %>
|
<% @events.each do |event| %>
|
||||||
BEGIN:VEVENT
|
BEGIN:VEVENT
|
||||||
DTSTART;TZID=Europe/Paris:<%= event.start_time.strftime '%Y%m%dT%H%M%S' %>
|
DTSTART;TZID=Europe/Paris:<%= event.start_time.strftime '%Y%m%dT%H%M%S' %>
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
(#{lug.department})
|
(#{lug.department})
|
||||||
|
|
||||||
%h1=t '.actions'
|
%h1=t '.actions'
|
||||||
= link_to root_url do
|
= link_to event_path(@event, protocol: :webcal, format: :ics) do
|
||||||
%em.fa.fa-calendar
|
%em.fa.fa-calendar
|
||||||
=t '.add_to_calendar'
|
=t '.add_to_calendar'
|
||||||
- if user_signed_in?
|
- if user_signed_in?
|
||||||
|
|
|
@ -0,0 +1,18 @@
|
||||||
|
BEGIN:VCALENDAR
|
||||||
|
VERSION:2.0
|
||||||
|
PRODID:-//AgendaDuLibre.org
|
||||||
|
X-WR-CALNAME:Agenda du Libre
|
||||||
|
X-WR-TIMEZONE:Europe/Paris
|
||||||
|
CALSCALE:GREGORIAN
|
||||||
|
X-WR-CALDESC:<%= t 'title', scope: [:layouts, :application] %>
|
||||||
|
<% event = @event %>
|
||||||
|
BEGIN:VEVENT
|
||||||
|
DTSTART;TZID=Europe/Paris:<%= event.start_time.strftime '%Y%m%dT%H%M%S' %>
|
||||||
|
DTEND;TZID=Europe/Paris:<%= event.end_time.strftime '%Y%m%dT%H%M%S' %>
|
||||||
|
UID:<%= event.id %>@agendadulibre.org
|
||||||
|
SUMMARY:<%= event.title %>
|
||||||
|
URL:<%= event_url event %>
|
||||||
|
DESCRIPTION:Un évènement de l'Agenda du Libre
|
||||||
|
LOCATION:<%= event.city.gsub('-', ' ') %>
|
||||||
|
END:VEVENT
|
||||||
|
END:VCALENDAR
|
|
@ -15,7 +15,6 @@ module AgendaDuLibreRails
|
||||||
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
|
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
|
||||||
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
|
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
|
||||||
# config.time_zone = 'Central Time (US & Canada)'
|
# config.time_zone = 'Central Time (US & Canada)'
|
||||||
config.time_zone = 'Paris'
|
|
||||||
|
|
||||||
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
|
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
|
||||||
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
||||||
|
@ -24,7 +23,10 @@ module AgendaDuLibreRails
|
||||||
|
|
||||||
I18n.config.enforce_available_locales = true
|
I18n.config.enforce_available_locales = true
|
||||||
|
|
||||||
config.action_mailer.default_options = {from: 'moderateurs@agendadulibre.org', to: 'moderateurs@agendadulibre.org'}
|
config.action_mailer.default_options = {
|
||||||
|
from: 'moderateurs@agendadulibre.org',
|
||||||
|
to: 'moderateurs@agendadulibre.org'
|
||||||
|
}
|
||||||
|
|
||||||
#config.quiet_assets = false
|
#config.quiet_assets = false
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue