Commit 6a833460 authored by Nicolas G.'s avatar Nicolas G.

Déploiement…

parent 33036770
......@@ -16,7 +16,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from django.conf.urls import include, url
from fj.views import liste_villes, Flux
from fj.views import liste_villes
from django.conf import settings
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
......@@ -53,10 +53,13 @@ urlpatterns = [
# Page d'index : la liste des villes
# url(r'^$', ListeVilles.as_view(), name='index'),
url(r'^$', liste_villes, name='index'),
url('^r/', include('ponctu.urls')),
# Flux iCal
#url(r'^flux$', Flux()),
url('^', include('fj.urls')),
]
......
......@@ -37,6 +37,9 @@ locale.setlocale(locale.LC_TIME, "fr_FR.utf8")
# Filtrage par date
import datetime
# Export iCal
from django_ical.views import ICalFeed
# Envoi de courriels
from django.core.mail import send_mail
......@@ -209,25 +212,25 @@ class InscritsDelete(DeleteView):
# ----------- Export iCal -------------------------
class Flux(ICalFeed):
"""
Export des évènements au format iCal
"""
product_id = '-//Firstjeudi.org//Evenements//FR'
timezone = 'UTC'
file_name = "firstjeudi.ics"
def items(self):
return Rencontre.objects.all()
def item_title(self, item):
return item.nom
def item_description(self, item):
return item.description
def item_start_datetime(self, item):
return item.date
#class Flux(ICalFeed):
# """
# Export des évènements au format iCal
# """
# product_id = '-//Firstjeudi.org//Evenements//FR'
# timezone = 'UTC'
# file_name = "firstjeudi.ics"
#
# def items(self):
# return Rencontre.objects.all()
#
# def item_title(self, item):
# return item.nom
#
# def item_description(self, item):
# return item.description
#
# def item_start_datetime(self, item):
# return item.date
# ------- Page des statistiques ----------------
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment