mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2025-12-15 13:47:11 +00:00
catch unknown scotsman error
This commit is contained in:
@@ -373,7 +373,6 @@ class LogbookEntry(TroggleModel):
|
||||
place = models.CharField(max_length=100,blank=True, null=True,help_text="Only use this if you haven't chosen a cave")
|
||||
text = models.TextField()
|
||||
slug = models.SlugField(max_length=50)
|
||||
filename = models.CharField(max_length=200,null=True)
|
||||
entry_type = models.CharField(default="wiki",null=True,choices=LOGBOOK_ENTRY_TYPES,max_length=50)
|
||||
|
||||
class Meta:
|
||||
@@ -412,7 +411,7 @@ class LogbookEntry(TroggleModel):
|
||||
return urljoin(settings.URL_ROOT, reverse('logbookentry',kwargs={'date':self.date,'slug':self.slug}))
|
||||
|
||||
def __str__(self):
|
||||
return "%s: (%s)" % (self.date, self.title)
|
||||
return f'{self.date}: {self.title}'
|
||||
|
||||
def get_next_by_id(self):
|
||||
LogbookEntry.objects.get(id=self.id+1)
|
||||
@@ -507,7 +506,7 @@ class PersonTrip(TroggleModel):
|
||||
return self.logbook_entry.cave and self.logbook_entry.cave or self.logbook_entry.place
|
||||
|
||||
def __str__(self):
|
||||
return "%s (%s)" % (self.personexpedition, self.logbook_entry.date)
|
||||
return f'{self.personexpedition} ({self.logbook_entry.date})'
|
||||
|
||||
scansFileStorage = FileSystemStorage(location=settings.SURVEY_SCANS, base_url=settings.SURVEYS_URL)
|
||||
def get_scan_path(instance, filename):
|
||||
|
||||
Reference in New Issue
Block a user