diff options
author | expo <expo@expobox.potato.hut> | 2011-09-02 03:39:20 +0200 |
---|---|---|
committer | expo <expo@expobox.potato.hut> | 2011-09-02 03:39:20 +0200 |
commit | 77dea07b400876cde999a33260793176f27aed0d (patch) | |
tree | 050a691b4238ce8122e9a96c745b5c62bc4ebef3 /core/views_caves.py | |
parent | 77dcf7f7597dd6f946cfcb12cd8ed1773ac83b61 (diff) | |
parent | 59e7c4d5dfd38aa666f06f5104a9ceaa309818fd (diff) | |
download | troggle-77dea07b400876cde999a33260793176f27aed0d.tar.gz troggle-77dea07b400876cde999a33260793176f27aed0d.tar.bz2 troggle-77dea07b400876cde999a33260793176f27aed0d.zip |
branch merge
Diffstat (limited to 'core/views_caves.py')
-rw-r--r-- | core/views_caves.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/core/views_caves.py b/core/views_caves.py index 4a79652..9fcf9b4 100644 --- a/core/views_caves.py +++ b/core/views_caves.py @@ -30,39 +30,39 @@ def caveindex(request): def cave(request, cave_id='', offical_name=''): cave=getCave(cave_id) - if cave.non_public and not request.user.is_authenticated(): + if cave.non_public and settings.PUBLIC_SITE and not request.user.is_authenticated(): return render_with_context(request,'nonpublic.html', {'instance': cave, 'cavepage': True}) else: return render_with_context(request,'cave.html', {'cave': cave, 'cavepage': True}) def caveEntrance(request, slug): cave = Cave.objects.get(slug = slug) - if cave.non_public and not request.user.is_authenticated(): + if cave.non_public and settings.PUBLIC_SITE and not request.user.is_authenticated(): return render_with_context(request,'nonpublic.html', {'instance': cave}) else: return render_with_context(request,'cave_entrances.html', {'cave': cave}) def caveDescription(request, slug): cave = Cave.objects.get(slug = slug) - if cave.non_public and not request.user.is_authenticated(): + if cave.non_public and settings.PUBLIC_SITE and not request.user.is_authenticated(): return render_with_context(request,'nonpublic.html', {'instance': cave}) else: return render_with_context(request,'cave_uground_description.html', {'cave': cave}) def caveQMs(request, slug): cave = Cave.objects.get(slug = slug) - if cave.non_public and not request.user.is_authenticated(): + if cave.non_public and settings.PUBLIC_SITE and not request.user.is_authenticated(): return render_with_context(request,'nonpublic.html', {'instance': cave}) else: return render_with_context(request,'cave_qms.html', {'cave': cave}) def caveLogbook(request, slug): cave = Cave.objects.get(slug = slug) - if cave.non_public and not request.user.is_authenticated(): + if cave.non_public and settings.PUBLIC_SITE and not request.user.is_authenticated(): return render_with_context(request,'nonpublic.html', {'instance': cave}) else: return render_with_context(request,'cave_logbook.html', {'cave': cave}) def caveSlug(request, slug): cave = Cave.objects.get(slug = slug) - if cave.non_public and not request.user.is_authenticated(): + if cave.non_public and settings.PUBLIC_SITE and not request.user.is_authenticated(): return render_with_context(request,'nonpublic.html', {'instance': cave}) else: return render_with_context(request,'cave.html', {'cave': cave}) |