summaryrefslogtreecommitdiffstats
path: root/core/views_caves.py
diff options
context:
space:
mode:
Diffstat (limited to 'core/views_caves.py')
-rw-r--r--core/views_caves.py23
1 files changed, 17 insertions, 6 deletions
diff --git a/core/views_caves.py b/core/views_caves.py
index a785170..302003d 100644
--- a/core/views_caves.py
+++ b/core/views_caves.py
@@ -1,7 +1,7 @@
#!/usr/bin/python
# -*- coding: utf-8 -*-
-from troggle.core.models import CaveSlug, Cave, CaveAndEntrance, Survey, Expedition, QM, CaveDescription, EntranceSlug, Entrance, Area, SurvexStation
+from troggle.core.models import CaveSlug, Cave, CaveAndEntrance, Survey, Expedition, QM, CaveDescription, EntranceSlug, Entrance, Area, SurvexStation, CaveM, Cave_descriptionM
from troggle.core.forms import CaveForm, CaveAndEntranceFormSet, VersionControlCommentForm, EntranceForm, EntranceLetterForm
import troggle.core.models as models
import troggle.settings as settings
@@ -21,6 +21,17 @@ import settings
from PIL import Image, ImageDraw, ImageFont
import string, os, sys, subprocess
+def millenialcaves(request):
+ #RW messing around area
+ caves = CaveM.objects.all()
+ descr = Cave_descriptionM.objects.all()
+ return render_with_context(request,'millenialcaves.html',{'caves': caves,'descriptions' : descr})
+
+def millenialdescription(request, slug):
+ desc = Cave_descriptionM.objects.get(slug=slug)
+ return render_with_context(request,'cave_uground_description.html', {'cave': desc})
+
+
def getCave(cave_id):
"""Returns a cave object when given a cave name or number. It is used by views including cavehref, ent, and qm."""
try:
@@ -54,16 +65,16 @@ def caveindex(request):
caves = Cave.objects.all()
notablecavehrefs = settings.NOTABLECAVESHREFS
notablecaves = [Cave.objects.get(kataster_number=kataster_number) for kataster_number in notablecavehrefs ]
- caves1623 = list(Cave.objects.filter(area__short_name = "1623"))
+ #caves1623 = list(Cave.objects.filter(area__short_name = "1623"))
+ caves1623 = list(Cave.objects.all())
caves1626 = list(Cave.objects.filter(area__short_name = "1626"))
caves1623.sort(caveCmp)
caves1626.sort(caveCmp)
return render_with_context(request,'caveindex.html', {'caves1623': caves1623, 'caves1626': caves1626, 'notablecaves':notablecaves, 'cavepage': True})
-def millenialcaves(request):
- #RW messing around area
- return HttpResponse("Test text", content_type="text/plain")
-
+
+
+
def cave3d(request, cave_id=''):