diff options
author | Philip Sargent <philip.sargent@gmail.com> | 2023-03-14 16:11:37 +0000 |
---|---|---|
committer | Philip Sargent <philip.sargent@gmail.com> | 2023-03-14 16:11:37 +0000 |
commit | a7660c8ec7d031adf2198725694ca1572269e9c9 (patch) | |
tree | 60b28e962217f0887a3f6d990d5e86439c0dd601 /core/models/logbooks.py | |
parent | 934a19b879aa024ac97e8c935302238fcc5b28bf (diff) | |
download | troggle-a7660c8ec7d031adf2198725694ca1572269e9c9.tar.gz troggle-a7660c8ec7d031adf2198725694ca1572269e9c9.tar.bz2 troggle-a7660c8ec7d031adf2198725694ca1572269e9c9.zip |
QM report updating
Diffstat (limited to 'core/models/logbooks.py')
-rw-r--r-- | core/models/logbooks.py | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/core/models/logbooks.py b/core/models/logbooks.py index 5933848..5f83059 100644 --- a/core/models/logbooks.py +++ b/core/models/logbooks.py @@ -137,6 +137,8 @@ class PersonLogEntry(TroggleModel): class QM(TroggleModel): """This is based on qm.csv in trunk/expoweb/1623/204 which has the fields: "Number","Grade","Area","Description","Page reference","Nearest station","Completion description","Comment" + + All the stuff handling TICK QMs is INCOMPLETE """ cave = models.ForeignKey("Cave", related_name="QMs", blank=True, null=True, on_delete=models.SET_NULL) @@ -193,7 +195,8 @@ class QM(TroggleModel): return f"{cavestr}-{expoyearstr}-{self.number}{self.grade}{blocknamestr}" def get_completion_url(self): - """assumes html file named is in same folder as cave description file""" + """assumes html file named is in same folder as cave description file + WRONG - needs rewriting!""" cd = None if self.completion_description: try: @@ -223,8 +226,8 @@ class QM(TroggleModel): ), ) - def get_next_by_id(self): - return QM.objects.get(id=self.id + 1) + # def get_next_by_id(self): + # return QM.objects.get(id=self.id + 1) - def get_previous_by_id(self): - return QM.objects.get(id=self.id - 1) + # def get_previous_by_id(self): + # return QM.objects.get(id=self.id - 1) |