mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2024-11-29 13:21:54 +00:00
Add odt and ods mime types to our list.
Maybe this should just be read in from the real list...
This commit is contained in:
parent
0a70039dee
commit
b4b060a962
@ -84,6 +84,8 @@ def getmimetype(path):
|
|||||||
if path.endswith(".3d"): return "application/x-survex-3d"
|
if path.endswith(".3d"): return "application/x-survex-3d"
|
||||||
if path.endswith(".pos"): return "application/x-survex-pos"
|
if path.endswith(".pos"): return "application/x-survex-pos"
|
||||||
if path.endswith(".err"): return "application/x-survex-err"
|
if path.endswith(".err"): return "application/x-survex-err"
|
||||||
|
if path.endswith(".odt"): return "application/vnd.oasis.opendocument.text"
|
||||||
|
if path.endswith(".ods"): return "application/vnd.oasis.opendocument.spreadsheet"
|
||||||
return ""
|
return ""
|
||||||
|
|
||||||
@login_required_if_public
|
@login_required_if_public
|
||||||
|
@ -122,6 +122,7 @@ def LoadCaveTab():
|
|||||||
addToDefaultArgs(header,"description_file")
|
addToDefaultArgs(header,"description_file")
|
||||||
break
|
break
|
||||||
|
|
||||||
|
|
||||||
#The following checks if this cave is non-public i.e. we don't have rights to display it online.
|
#The following checks if this cave is non-public i.e. we don't have rights to display it online.
|
||||||
#Noinfo was the name of the old password protected directory, so if it has that then we will
|
#Noinfo was the name of the old password protected directory, so if it has that then we will
|
||||||
#set the non_public field of the model instance to true.
|
#set the non_public field of the model instance to true.
|
||||||
@ -227,7 +228,6 @@ def LoadCaveTab():
|
|||||||
newCaveAndEntrance.save()
|
newCaveAndEntrance.save()
|
||||||
|
|
||||||
logging.info("Added CaveAndEntrance "+str(newCaveAndEntrance)+"\n")
|
logging.info("Added CaveAndEntrance "+str(newCaveAndEntrance)+"\n")
|
||||||
if line[AutogenFile] != "":
|
|
||||||
f = flatpages.models.EntranceRedirect(originalURL = line[AutogenFile], entrance = newEntrance)
|
f = flatpages.models.EntranceRedirect(originalURL = line[AutogenFile], entrance = newEntrance)
|
||||||
f.save()
|
f.save()
|
||||||
|
|
||||||
|
2
urls.py
2
urls.py
@ -17,7 +17,7 @@ admin.autodiscover()
|
|||||||
|
|
||||||
actualurlpatterns = patterns('',
|
actualurlpatterns = patterns('',
|
||||||
|
|
||||||
url(r'^troggle$', views_other.frontpage, name="frontpage"),
|
url(r'^$', views_other.frontpage, name="frontpage"),
|
||||||
url(r'^todo/$', views_other.todo, name="todo"),
|
url(r'^todo/$', views_other.todo, name="todo"),
|
||||||
|
|
||||||
url(r'^caves/?$', views_caves.caveindex, name="caveindex"),
|
url(r'^caves/?$', views_caves.caveindex, name="caveindex"),
|
||||||
|
Loading…
Reference in New Issue
Block a user