# Election compare view with both candidates (and NO category) url(r'^(?P<username>[-\w]+)/(?P<slug>[-\w]+)/compare/(?P<first_candidate_slug>[-\w]+)/(?P<second_candidate_slug>[-\w]+)/?$', CompareView.as_view(template_name='elections/election_compare.html'), name='election_compare_two_candidates_and_no_category'), # Election compare view with 1 candidate url(r'^(?P<username>[-\w]+)/(?P<slug>[-\w]+)/compare/(?P<first_candidate_slug>[-\w]+)/?$', CompareView.as_view(template_name='elections/election_compare.html'), name='election_compare_one_candidate'), # Asynchronous call for compare view url(r'^(?P<username>[-\w]+)/(?P<slug>[-\w]+)/compare-async/(?P<candidate_slug>[-\w]+)/?$', 'candidator.elections.views.election_compare_asynchronous_call', name='election_compare_asynchronous_call'), # Election description url(r'^(?P<username>[-\w]+)/(?P<slug>[-\w]+)/about/?$', ElectionAboutView.as_view(), name='election_about'), # Election detail view url(r'^(?P<username>[-\w]+)/(?P<slug>[-\w]+)/$', ElectionDetailView.as_view(template_name='elections/election_detail_profiles.html'), name='election_detail'), # Root: login_required (por ahora pues no se ha definido un index) url(r'^$', HomeTemplateView.as_view(), name="home"), #Election redirects to my elections if I have at least one election or to create url(r'^election_redirect/$', login_required(ElectionRedirectView.as_view()), name='election_redirect'), # My Elections url(r'^my_election_list/$', login_required(TemplateView.as_view(template_name="elections/my_election_list.html")), name='my_election_list'), # Associate Candidate url(r'^(?P<election_slug>[-\w]+)/(?P<candidate_slug>[-\w]+)/associate_answers/', associate_answer_to_candidate, name='associate_answer_candidate'), # Create Answer Ajax url(r'answer_create/(?P<question_pk>\d+).json', AnswerCreateAjaxView.as_view(), name='answer_create_ajax'), #Delete Answer Ajax url(r'answer_delete/(?P<pk>\d+)', AnswerDeleteAjaxView.as_view(), \
from django.conf.urls import patterns, include, url from views import HomeTemplateView, EleccionOverview, EleccionIndices, MetodologiaView, QuienesSomosView, ComparadorView, EleccionPreguntales, ReportaView,\ QuePuedoHacerHacerView, NosFaltanDatosView, Ranking, RankingJson, EleccionExtraInfo, EnlacesView, VoluntariosView, SenadoresView, InteresesView,\ PreguntaDetail from django.views.generic import TemplateView, DetailView from django.views.decorators.cache import cache_page from models import Respuesta from django.conf import settings urlpatterns = patterns( '', url(r'^$', HomeTemplateView.as_view(template_name="home.html"), name="home"), #static pages url(r'^metodologia/?$', MetodologiaView.as_view(), name="metodologia"), url(r'^somos/?$', QuienesSomosView.as_view(), name="somos"), url(r'^enlaces/?$', EnlacesView.as_view(), name="enlaces"), url(r'^voluntarios/?$', VoluntariosView.as_view(), name="voluntarios"), url(r'^senadores/?$', SenadoresView.as_view(), name="senadores"), url(r'^fiscaliza/?$', ReportaView.as_view(), name="reporta"), url(r'^que_puedo_hacer/?$', QuePuedoHacerHacerView.as_view(), name="que_puedo_hacer"), url(r'^nos_faltan_datos/?$', NosFaltanDatosView.as_view(), name="nos_faltan_datos"), url(r'^todos/?$', TemplateView.as_view(template_name="todos_los_candidatos.html"), name="todos"),
from django.conf.urls import patterns, include, url from views import HomeTemplateView, ComunaOverview, ComunaIndices, MetodologiaView, QuienesSomosView, ComunaPreguntales, ReportaView from django.views.generic import TemplateView urlpatterns = patterns('', url(r'^$', HomeTemplateView.as_view(template_name="home.html"), name="home"), #static pages url(r'^metodologia/?$', MetodologiaView.as_view(), name="metodologia"), url(r'^somos/?$', QuienesSomosView.as_view(), name="somos"), url(r'^fiscaliza/?$', ReportaView.as_view(), name="reporta"), #pages depending on the comuna url(r'^(?P<slug>[-\w]+)/indices/?$', ComunaIndices.as_view(), name='comuna-index-detail'), url(r'^(?P<slug>[-\w]+)/?$', ComunaOverview.as_view(), name="comuna-overview"), url(r'^(?P<slug>[-\w]+)/preguntales/?$', ComunaPreguntales.as_view(), name="comuna-preguntales"), )
from django.conf.urls import patterns, include, url from views import HomeTemplateView, EleccionOverview, EleccionIndices, MetodologiaView, QuienesSomosView, EleccionPreguntales, ReportaView,\ QuePuedoHacerHacerView, NosFaltanDatosView, Ranking from django.views.generic import TemplateView from django.views.decorators.cache import cache_page urlpatterns = patterns('', url(r'^$', HomeTemplateView.as_view(template_name="extra-content-home.html"), name="home"), #static pages url(r'^metodologia/?$', MetodologiaView.as_view(), name="metodologia"), url(r'^somos/?$', QuienesSomosView.as_view(), name="somos"), url(r'^fiscaliza/?$', ReportaView.as_view(), name="reporta"), url(r'^que_puedo_hacer/?$', QuePuedoHacerHacerView.as_view(), name="que_puedo_hacer"), url(r'^nos_faltan_datos/?$', NosFaltanDatosView.as_view(), name="nos_faltan_datos"), url(r'^ranking/?$', cache_page(Ranking.as_view(), 60 * 15), name="ranking"), #pages depending on the eleccion url(r'^(?P<slug>[-\w]+)/indices/?$', EleccionIndices.as_view(), name='eleccion-index-detail'), url(r'^(?P<slug>[-\w]+)/?$', EleccionOverview.as_view(), name="eleccion-overview"), url(r'^(?P<slug>[-\w]+)/preguntales/?$', EleccionPreguntales.as_view(), name="eleccion-preguntales"), )
from django.conf.urls import patterns, url from views import logout_user, RegisterFormView, HomeTemplateView, LoginFormView, PasswordResetFormView urlpatterns = patterns('', url(r'^$', HomeTemplateView.as_view(), name='home'), url(r'^logout/$', logout_user, name='logout'), url(r'^register/$', RegisterFormView.as_view(), name='register'), url(r'^login/$', LoginFormView.as_view(), name='login'), url(r'^reset/$', PasswordResetFormView.as_view(), name='reset'), )
from django.conf.urls import url, include from django.contrib import admin from views import HomeTemplateView, SkupSrebraTemplateView, SkupZlotaTemplateView, ONasTemplateView from django.conf import settings from django.conf.urls.static import static urlpatterns = [ url(r'^$', HomeTemplateView.as_view(), name='home_page'), url(r'^produkty/', include('produkty.urls', namespace='produkty')), url(r'^skup_zlota/', SkupZlotaTemplateView.as_view(), name='skup_zlota'), url(r'^skup_srebra/', SkupSrebraTemplateView.as_view(), name='skup_srebra'), url(r'^o_nas/', ONasTemplateView.as_view(), name='o_nas'), url(r'^kontakt/', include('formularz_kontaktowy.urls', namespace='kontakt')), url(r'^opinie/', include('opinie.urls', namespace='opinie')), url(r'^accounts/', include('allauth.urls')), url(r'^admin/', admin.site.urls), ] urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)