[svn] * Added non-public field for protecting copyright info etc. Field is on all models but needs to be checked for in views. So far, only the cave view checks.

* Added the Person wiki syntax which looks like [[person:John Doe]]
This commit is contained in:
substantialnoninfringinguser
2009-06-10 06:34:50 +01:00
parent 1d421b2d7c
commit 484a17d496
3 changed files with 11 additions and 4 deletions

View File

@@ -24,7 +24,11 @@ def caveindex(request):
return render_response(request,'caveindex.html', {'caves': caves, 'notablecaves':notablecaves})
def cave(request, cave_id='', offical_name=''):
return render_response(request,'cave.html', {'cave': getCave(cave_id),})
cave=getCave(cave_id)
if cave.non_public:
return render_response(request,'nonpublic.html', {'instance': cave})
else:
return render_response(request,'cave.html', {'cave': cave})
def qm(request,cave_id,qm_id,year,grade=None):
year=int(year)