2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2026-02-08 09:17:46 +00:00

Adding SUrvexFix class

This commit is contained in:
2025-07-29 19:42:59 +02:00
parent 959c358c09
commit 7a9bcd02f7
3 changed files with 28 additions and 16 deletions

View File

@@ -195,6 +195,22 @@ class SurvexBlockLookUpManager(models.Manager):
block = SurvexBlock.objects.get(parent=block, name__iexact=blockname)
return block
class SurvexFix(models.Model):
"""a *fix line in a survexfile. New at the end of expo in July 2025
This is used to detect *fix stations which are not attached to a *entrance and thus to a cave
i.e. it is used to discover potential cave entrances
But this does not include the virtual *fix locations which are
in locations.py
"""
objects = SurvexBlockLookUpManager() # overwrites Survexfix.objects and enables lookup()
name = models.CharField(max_length=100)
class Meta:
ordering = ("name",)
def __str__(self):
return self.name + str(self.id)
class SurvexBlock(models.Model):
"""One begin..end block within a survex file. The basic element of a survey trip.