diff options
author | Martin Green <martin.speleo@gmail.com> | 2022-06-25 23:17:19 +0100 |
---|---|---|
committer | Martin Green <martin.speleo@gmail.com> | 2022-06-25 23:17:19 +0100 |
commit | 20583b04c0c1a826aaddbf0342f4369a206dae2d (patch) | |
tree | a1ef507b3f8827e70d0233cbb17191ec4f463e40 /urls.py | |
parent | b3d9e814997ab8f83e8e441ed48625c66ed68d51 (diff) | |
download | troggle-20583b04c0c1a826aaddbf0342f4369a206dae2d.tar.gz troggle-20583b04c0c1a826aaddbf0342f4369a206dae2d.tar.bz2 troggle-20583b04c0c1a826aaddbf0342f4369a206dae2d.zip |
Allowed user to select/upload images when editing. When uploaded thumbnails and description pages are automatically created. Git commiting can now handle multiple files at once.
Diffstat (limited to 'urls.py')
-rw-r--r-- | urls.py | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -23,6 +23,7 @@ from troggle.core.views.statistics import pathsreport, stats, dataissues from troggle.core.views.expo import expofiles_redirect, expofilessingle, expopage, editexpopage, mediapage, map, mapfile from troggle.core.views.survex import survexcaveslist, survexcavesingle, svx from troggle.core.views.auth import expologin, expologout +from troggle.core.views.editor_helpers import image_selector, new_image_form """This sets the actualurlpatterns[] and urlpatterns[] lists which django uses to resolve urls - in both directions as these are declarative. @@ -190,6 +191,11 @@ trogglepatterns = [ re_path(r'^/loser/(?P<subpath>.*)$', mediapage, {'doc_root': settings.SURVEX_DATA}, name="mediapage"), # Oddly not working !? re_path(r'^map/map.html', map, name="map"), # Redirects to OpenStreetMap JavaScript re_path(r'^map/(?P<path>.*)$', mapfile, name="mapfile"), # css, js, gpx + +# Helpers to edit HTML + re_path(r'^image_selector/(?P<path>.*)', image_selector, name = 'image_selector'), + re_path(r'^new_image_form/(?P<path>.*)', new_image_form, name = 'new_image_form'), + # Final catchall which also serves expoweb handbook pages and images re_path(r'^(.*)$', expopage, name="expopage"), # CATCHALL assumed relative to EXPOWEB |