forked from expo/troggle
Populate blank wallet fields with survex data
This commit is contained in:
@@ -191,6 +191,7 @@ class Wallet(models.Model):
|
||||
|
||||
return waldata
|
||||
|
||||
# Yes this is horribly, horribly inefficient, esp. for a page that have date, people and cave in it
|
||||
def date(self):
|
||||
jsondata = self.get_json()
|
||||
return jsondata["date"]
|
||||
@@ -199,12 +200,16 @@ class Wallet(models.Model):
|
||||
jsondata = self.get_json()
|
||||
return jsondata["people"]
|
||||
|
||||
def cave(self):
|
||||
jsondata = self.get_json()
|
||||
return jsondata["cave"]
|
||||
|
||||
def name(self):
|
||||
jsondata = self.get_json()
|
||||
return jsondata["name"]
|
||||
|
||||
def __str__(self):
|
||||
return str(self.walletname) + " (Wallet)"
|
||||
return "[" + str(self.walletname) + " (Wallet)]"
|
||||
|
||||
class SingleScan(models.Model):
|
||||
ffile = models.CharField(max_length=200)
|
||||
|
||||
Reference in New Issue
Block a user