From 0843a279660b9dd76a68164b60140d0a0e14f39a Mon Sep 17 00:00:00 2001 From: Philip Sargent Date: Wed, 25 Oct 2023 01:56:30 +0300 Subject: Revised (faster, less brain damaged) wallet pages --- parsers/scans.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'parsers/scans.py') diff --git a/parsers/scans.py b/parsers/scans.py index b9bae25..ad9c110 100644 --- a/parsers/scans.py +++ b/parsers/scans.py @@ -7,6 +7,9 @@ from troggle.core.models.troggle import DataIssue from troggle.core.models.wallets import Wallet """Searches through all the survey scans directories (wallets) in expofiles, looking for images to be referenced. Loads all the wallets . + +todo - update the survexblock scanswallet field to refer to the wallet, if it isn't already. +But we can't do that, we only have the survexfile, not the blcok. But we could set it for ALL the blocks? Hmm. """ contentsjson = "contents.json" @@ -25,7 +28,7 @@ def set_JSONwalletdate(wallet): def set_caves(wallet): _ = wallet.allcaves() # don't need return value. Just calling this saves it as w.caves This ONLY gets the list on the wallet JSON - + def load_all_scans(): """This iterates through the scans directories (either here or on the remote server) and builds up the models we can access later. @@ -173,6 +176,7 @@ def load_all_scans(): for wallet in Wallet.objects.all(): # this reads JSON wallet.check_survexlist() + -- cgit v1.2.3