mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2025-12-15 07:47:13 +00:00
use new upload page for most wallets
This commit is contained in:
20
urls.py
20
urls.py
@@ -8,7 +8,7 @@ from django.contrib import auth
|
||||
from django.urls import path, reverse, resolve
|
||||
|
||||
from troggle.core.views import caves, statistics, survex
|
||||
from troggle.core.views.scans import scansingle, singlewallet, allwallets
|
||||
from troggle.core.views.scans import scansingle, allwallets
|
||||
from troggle.core.views.drawings import dwgallfiles, dwgfilesingle
|
||||
from troggle.core.views.uploads import dwgupload, scanupload, photoupload
|
||||
from troggle.core.views.other import troggle404, frontpage, todos, controlpanel, frontpage
|
||||
@@ -86,7 +86,8 @@ trogglepatterns = [
|
||||
re_path(r'^admin/', admin.site.urls), # includes admin login & logout urls
|
||||
|
||||
# Uploads - uploading a file
|
||||
path('scanupload/<wallet>', scanupload, name='scanupload'), # wallet=2020#01, not a path
|
||||
path('scanupload/', scanupload, name='scanupload'), # path=2020#01
|
||||
path('scanupload/<path:path>', scanupload, name='scanupload'), # path=2020#01
|
||||
path('photoupload/', photoupload, name='photoupload'), # restricted to current year
|
||||
path('photoupload/<path:folder>', photoupload, name='photoupload'), # restricted to current year
|
||||
path('dwgupload/<path:folder>', dwgupload, name='dwgupload'),
|
||||
@@ -94,7 +95,8 @@ trogglepatterns = [
|
||||
path('dwguploadnogit/', dwgupload, {'gitdisable': 'yes'}, name='dwguploadnogit'), # used in testing
|
||||
path('dwguploadnogit/<path:folder>', dwgupload, {'gitdisable': 'yes'}, name='dwguploadnogit'), # used in testing
|
||||
|
||||
# setting LOGIN_URL = '/accounts/login/' is default
|
||||
# setting LOGIN_URL = '/accounts/login/' is default.
|
||||
# NB setting url pattern name to 'login' instea dof 'expologin' with override Django, see https://docs.djangoproject.com/en/4.0/topics/http/urls/#naming-url-patterns
|
||||
path('accounts/logout/', expologout, name='expologout'), # same as in django.contrib.auth.urls
|
||||
path('accounts/login/', expologin, name='expologin'), # same as in django.contrib.auth.urls
|
||||
#re_path(r'^accounts/', include('django.contrib.auth.urls')), # see site-packages\registration\auth_urls_classes.py
|
||||
@@ -124,13 +126,13 @@ trogglepatterns = [
|
||||
re_path(r'^newcave/$', caves.edit_cave, name="newcave"),
|
||||
re_path(r'^cave/3d/(?P<cave_id>[^/]+)$', caves.cave3d, name="cave3d"),
|
||||
|
||||
re_path(r'^cave/description/([^/]+)/?$', caves.caveDescription),
|
||||
re_path(r'^cave/description/([^/]+)/?$', caves.caveDescription), #!!!BAD, local links fail..
|
||||
re_path(r'^cave/(?P<cave_id>[^/]+)/?$', caves.cave, name="cave"), #!!!BAD, local links fail.. to be checked..
|
||||
re_path(r'^cave/(?P<cave_id>[^/]+)/?(?P<ent_letter>[^/])$', ent), # view_caves.ent
|
||||
re_path(r'^cave/(?P<slug>[^/]+)/edit/$', caves.edit_cave, name="edit_cave"),
|
||||
re_path(r'^cave/(?P<cave_id>[^/]+)/?(?P<ent_letter>[^/])$', ent), #!!!BAD, local links fail..# view_caves.ent
|
||||
re_path(r'^cave/(?P<slug>[^/]+)/edit/$', caves.edit_cave, name="edit_cave"),
|
||||
re_path(r'^(?P<karea>\d\d\d\d)(?P<subpath>.*)$', cavepage, name="cavepage"), # shorthand /1623/264 BUT url links break! Stop this..
|
||||
# Note that urls eg '1623/161/l/rl89a.htm' are handled by cavepage which redirects them to 'expopage'
|
||||
# Note that _edit$ for a cave description page in a subfolder e.g. /1623/via204.html_edit gets caught here and breaks with 404
|
||||
# Note that urls eg '/1623/161/l/rl89a.htm' are handled by cavepage which redirects them to 'expopage'
|
||||
# Note that _edit$ for a cave description page in a subfolder e.g. /1623/204/204.html_edit gets caught here and breaks with 404
|
||||
|
||||
# Entrances
|
||||
re_path(r'^cave/entrance/([^/]+)/?$', caves.caveEntrance), # lists all entrances !!!BAD, local links fail
|
||||
@@ -163,7 +165,7 @@ trogglepatterns = [
|
||||
|
||||
# The survey scans in the wallets
|
||||
path('survey_scans/', allwallets, name="allwallets"),
|
||||
path('survey_scans/<path:path>/', singlewallet, name="singlewallet"),
|
||||
path('survey_scans/<path:path>/', scanupload, name="singlewallet"), # replaced singlewallet()
|
||||
path('survey_scans/<path:path>/<file>', scansingle, name="scansingle"),
|
||||
|
||||
# The tunnel and therion drawings files pages
|
||||
|
||||
Reference in New Issue
Block a user