Rapide correction sur les flux rss et ical

This commit is contained in:
echarp 2014-08-08 00:33:39 +02:00
parent b35255d363
commit a3c9c4e0bb
2 changed files with 14 additions and 2 deletions

View File

@ -8,9 +8,16 @@ class EventsController < ApplicationController
def index
respond_to do |format|
format.html
format.html do
if params[:year]
# Whole year calendar
@events = @events.year params[:year].to_i
else
@events = @events.month params[:start_date].try(:to_date) || Date.today
end
end
format.rss do
@events = @events.future_30.includes :related_city
@events = @events.future.includes :related_city
@events = @events.limit params[:daylimit] if params[:daylimit]
end
format.ics { @events = @events.last_year.order :id }

View File

@ -126,6 +126,11 @@ fr:
actions: Actions
edit: Éditer événement
cancel: Annuler événement
html:
at: À
dateAndPlace: Date et lieu
description: Description
infos: Informations
new:
title: Soumettre un événement
create: