This repository has been archived by the owner on May 26, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathurls.py
55 lines (45 loc) · 1.97 KB
/
urls.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
from django.conf.urls import patterns, include, url
from django.contrib.gis import admin
import settings
from django.contrib.sitemaps.views import sitemap
from django.contrib.sitemaps import FlatPageSitemap, GenericSitemap
from apps.core.models import Recorrido, Linea, Parada
from apps.catastro.models import Poi
# Uncomment the next two lines to enable the admin:
admin.autodiscover()
sitemaps = {
'flatpages': FlatPageSitemap,
'lineas': GenericSitemap({
'queryset': Linea.objects.all(),
}, priority=0.6),
'recorridos': GenericSitemap({
'queryset': Recorrido.objects.all(),
}, priority=0.6),
'pois': GenericSitemap({
'queryset': Poi.objects.all(),
}, priority=0.6),
'paradas': GenericSitemap({
'queryset': Parada.objects.all(),
}, priority=0.4),
}
urlpatterns = patterns('',
# Archivos estaticos
(r'^media/(?P<path>.*)$', 'django.views.static.serve', {'document_root': settings.MEDIA_ROOT}),
# APPS de CualBondi
url(r'^api/v2/', include('apps.api2.urls')),
url(r'^api/v1/', include('apps.api.urls')),
url(r'^api/', include('apps.api.urls')),
url(r'^admin/', include(admin.site.urls)),
url('', include('social.apps.django_app.urls', namespace='social')),
url(r'^usuarios/', include('apps.usuarios.urls')),
url(r'^widget/', include('apps.widget.urls')),
url(r'^mobile_updates/', include('apps.mobile_updates.urls')),
url(r'^editor/', include('apps.editor.urls')),
url(r'^revision/(?P<id_revision>\d+)/$', 'apps.editor.views.revision', name='revision_externa'),
url(r'^como-llegar/', include('apps.catastro.urls')),
url(r'^contacto/', 'apps.core.views.contacto', name='contacto'),
# Ranking aka agradecimientos
url(r'^agradecimientos/$', 'apps.core.views.agradecimientos', name='agradecimientos'),
url(r'^sitemap\.xml$', sitemap, {'sitemaps': sitemaps}, name='django.contrib.sitemaps.views.sitemap'),
url(r'^', include('apps.core.urls')),
)