forked from expo/troggle
avoiding problem with WSGI populate() error
This commit is contained in:
parent
1523586b37
commit
28130de9cb
@ -26,9 +26,12 @@ def frontpage(request):
|
|||||||
expeditions = Expedition.objects.order_by("-year")
|
expeditions = Expedition.objects.order_by("-year")
|
||||||
logbookentry = LogbookEntry
|
logbookentry = LogbookEntry
|
||||||
cave = Cave
|
cave = Cave
|
||||||
from django.contrib.admin.templatetags import log
|
#from django.contrib.admin.templatetags import log
|
||||||
return render(request,'frontpage.html', locals())
|
return render(request,'frontpage.html', locals())
|
||||||
|
|
||||||
|
print(" - controlPanel() is next in troggle/core/views_other.py")
|
||||||
|
|
||||||
|
|
||||||
def controlPanel(request):
|
def controlPanel(request):
|
||||||
jobs_completed=[]
|
jobs_completed=[]
|
||||||
if request.method=='POST':
|
if request.method=='POST':
|
||||||
@ -51,6 +54,9 @@ def controlPanel(request):
|
|||||||
|
|
||||||
return render(request,'controlPanel.html', {'caves':Cave.objects.all(),'expeditions':Expedition.objects.all(),'jobs_completed':jobs_completed})
|
return render(request,'controlPanel.html', {'caves':Cave.objects.all(),'expeditions':Expedition.objects.all(),'jobs_completed':jobs_completed})
|
||||||
|
|
||||||
|
print(" - downloadLogbook() is next in troggle/core/views_other.py")
|
||||||
|
|
||||||
|
|
||||||
def downloadLogbook(request,year=None,extension=None,queryset=None):
|
def downloadLogbook(request,year=None,extension=None,queryset=None):
|
||||||
|
|
||||||
if year:
|
if year:
|
||||||
@ -83,6 +89,8 @@ def downloadLogbook(request,year=None,extension=None,queryset=None):
|
|||||||
response.write(t.render(c))
|
response.write(t.render(c))
|
||||||
return response
|
return response
|
||||||
|
|
||||||
|
print(" - downloadQMs() is next in troggle/core/views_other.py")
|
||||||
|
|
||||||
|
|
||||||
def downloadQMs(request):
|
def downloadQMs(request):
|
||||||
# Note to self: use get_cave method for the below
|
# Note to self: use get_cave method for the below
|
||||||
@ -118,6 +126,9 @@ def ajax_QM_number(request):
|
|||||||
|
|
||||||
return HttpResponse(res)
|
return HttpResponse(res)
|
||||||
|
|
||||||
|
print(" - logbook_entry_suggestions() is next in troggle/core/views_other.py")
|
||||||
|
|
||||||
|
|
||||||
def logbook_entry_suggestions(request):
|
def logbook_entry_suggestions(request):
|
||||||
"""
|
"""
|
||||||
Generates a html box with suggestions about what to do with QMs
|
Generates a html box with suggestions about what to do with QMs
|
||||||
@ -175,6 +186,8 @@ def logbook_entry_suggestions(request):
|
|||||||
'any_suggestions':any_suggestions
|
'any_suggestions':any_suggestions
|
||||||
})
|
})
|
||||||
|
|
||||||
|
print(" - newFile() is next in troggle/core/views_other.py")
|
||||||
|
|
||||||
@login_required_if_public
|
@login_required_if_public
|
||||||
def newFile(request, pslug = None):
|
def newFile(request, pslug = None):
|
||||||
if pslug:
|
if pslug:
|
||||||
@ -229,3 +242,5 @@ def delFile(f):
|
|||||||
pt.delete()
|
pt.delete()
|
||||||
lbe.delete()
|
lbe.delete()
|
||||||
os.remove(lbe.filename)
|
os.remove(lbe.filename)
|
||||||
|
|
||||||
|
print("** Finished importing troggle/core/views_other.py")
|
Loading…
Reference in New Issue
Block a user