summaryrefslogtreecommitdiffstats
path: root/core/models/wallets.py
diff options
context:
space:
mode:
authorPhilip Sargent <philip.sargent@gmail.com>2025-07-16 13:59:16 +0200
committerPhilip Sargent <philip.sargent@gmail.com>2025-07-16 13:59:16 +0200
commit0c97c11d827f7cbd1a51cd5eb49f9de401624add (patch)
tree34ece0458e19148fe3ce4e7771faa23d82c72d1d /core/models/wallets.py
parentae6e8205a13e91bb4cd2d90cd59969482fb4c035 (diff)
downloadtroggle-0c97c11d827f7cbd1a51cd5eb49f9de401624add.tar.gz
troggle-0c97c11d827f7cbd1a51cd5eb49f9de401624add.tar.bz2
troggle-0c97c11d827f7cbd1a51cd5eb49f9de401624add.zip
tick boxes meddling
Diffstat (limited to 'core/models/wallets.py')
-rw-r--r--core/models/wallets.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/core/models/wallets.py b/core/models/wallets.py
index d9a140d..9e54f4e 100644
--- a/core/models/wallets.py
+++ b/core/models/wallets.py
@@ -380,8 +380,10 @@ class Wallet(models.Model):
if waldata["survex not required"]:
survexok = "green"
ticks["S"] = "green"
- else:
- if waldata["survex file"]:
+ else:
+ if "survex file" not in waldata:
+ ticks["S"] = "darkred"
+ else:
if not type(waldata["survex file"]) == list: # a string also is a sequence type, so do it this way
waldata["survex file"] = [waldata["survex file"]]
ngood = 0
@@ -403,7 +405,7 @@ class Wallet(models.Model):
elif nbad >= 1 and ngood == 0: # all bad
ticks["S"] = "red"
elif nbad == 0 and ngood == 0: # list of blank strings
- ticks["S"] = "red"
+ ticks["S"] = "crimson"
else:
ticks["S"] = "fuchsia" # have fun working out what this means