diff --git a/core/models/caves.py b/core/models/caves.py index 8b23ceb..0001814 100644 --- a/core/models/caves.py +++ b/core/models/caves.py @@ -94,7 +94,7 @@ class Cave(TroggleModel): length = models.CharField(max_length=100, blank=True, null=True) depth = models.CharField(max_length=100, blank=True, null=True) extent = models.CharField(max_length=100, blank=True, null=True) - survex_file = models.CharField(max_length=100, blank=True, null=True) + survex_file = models.CharField(max_length=100, blank=True, null=True) # should be a foreign key description_file = models.CharField(max_length=200, blank=True, null=True) url = models.CharField(max_length=200, blank=True, null=True) filename = models.CharField(max_length=200) @@ -109,6 +109,8 @@ class Cave(TroggleModel): ordering = ("kataster_code", "unofficial_number") def hassurvey(self): + """This is almost certainly a fossil - needs checking... + """ if not self.underground_centre_line: return "No" if ( diff --git a/templates/cave.html b/templates/cave.html index a7faab2..65d43f5 100644 --- a/templates/cave.html +++ b/templates/cave.html @@ -480,17 +480,22 @@ div#scene {
- +{% comment %} The 'cave' object has text field, not forign-key fields, so we cant dereference to get info on the survex file +{% endcomment %}

{% if cave.explorers %}

Explorers

{{ cave.explorers|safe }} {% endif %}

Survex File(s)

- All survexfiles for this cave
+ All survexfiles for this cave {
{% if cave.survex_file %} Primary survex file for this cave

[CaveView display of the .3d file is temporarily disabled while we fix things (Nov.2021).
See /handbook/computing/todo.rst.]

+ Download .3d file caves-{{ cave.area.all.0.kat_area }}/{{cave.kataster_number}}/{{svx3d}}.3d +
+cave ID '{{cave.reference}}'
+cave survex path '{{ cave.area.all.0.kat_area }}/{{cave.kataster_number}}'

{% endif %} {% if cave.underground_description %} diff --git a/templates/qm.html b/templates/qm.html index 0b6a633..c027918 100644 --- a/templates/qm.html +++ b/templates/qm.html @@ -48,14 +48,14 @@ Comment: '{{qm.comment}}'

QM original closest survey station

{% if qm.block %} -Survex block: {{qm.blockname}} +Survex block: {{qm.blockname}}
{% endif %} -QM Nearest station: '{{qm.nearest_station_name}}' {{nearest_station_description}}
-QM page_ref: '{{qm.page_ref|safe}}'
+QM Nearest station: '{{qm.nearest_station_name}}' {{nearest_station_description}}
+QM Page reference: '{{qm.page_ref|safe}}'

QM original description

-{{qm.location_description|safe}} +
{{qm.location_description|safe}}
{% if qm.found_by %}

Creation

@@ -64,11 +64,10 @@ Found by {{qm.found_by}} on {{qm. {% if qm.cave %}

Cave: {{qm.cave|safe }}

-{{ qm.cave|safe }} - All QMs
+{{ qm.cave|safe }} - all QMs for this cave
{{ qm.cave|safe }} - cave description
-{{ qm.cave|safe }} - survexfiles
-{{ qm.cave|safe }} - all survexfiles
-{{ qm.cave|safe }} - primary survexfile +{{ qm.cave|safe }} - all survexfiles for this cave
+{{ qm.cave|safe }} - primary survexfile for this cave

{% endif %}