diff options
Diffstat (limited to 'core/views')
-rw-r--r-- | core/views/caves.py | 8 | ||||
-rw-r--r-- | core/views/scans.py | 12 | ||||
-rw-r--r-- | core/views/survex.py | 2 |
3 files changed, 11 insertions, 11 deletions
diff --git a/core/views/caves.py b/core/views/caves.py index 856c2cd..2498fb4 100644 --- a/core/views/caves.py +++ b/core/views/caves.py @@ -657,6 +657,8 @@ def edit_entrance(request, path="", caveslug=None, entslug=None): nextletter = chr(ord(letter)+1) return check_new_slugname_ok(slug, nextletter) + entletter = "" # default to stop crashes + entletterform = None if not (cave:= get_cave_from_slug(caveslug)): # walrus operator return render(request, "errors/badslug.html", {"badslug": f"for cave {caveslug} - from edit_entrance()"}) @@ -720,10 +722,10 @@ def edit_entrance(request, path="", caveslug=None, entslug=None): entranceletter="" if not entform.is_valid(): - message = f"- POST INVALID {caveslug=} {entslug=} {path=} entform valid:{entform.is_valid()} entletterform valid:{entletterform.is_valid()}" - entrance = entform.save(commit=False) + message = f"- POST INVALID {caveslug=} {entslug=} {path=} entform valid:{entform.is_valid()} " + # entrance = entform.save(commit=False) print(message) - return render(request, "errors/generic.html", {"message": message}) + # return render(request, "errors/generic.html", {"message": message}) else: print(f"'edit_entrance(): POST is valid {caveslug=} Editing {entslug=} {entranceletter=} {path=}") diff --git a/core/views/scans.py b/core/views/scans.py index 62251de..4263c2c 100644 --- a/core/views/scans.py +++ b/core/views/scans.py @@ -215,13 +215,11 @@ def walletslistperson(request, slug): if w in manywallets: # we already know this is a wallet we need to report on continue + if not w.people(): # bug? skip + # msg = f"{w} no w.people() found " + # print(msg) + continue for n in w.people(): - # if n.lower().startswith("lydia"): - # print(f"{w} {n=} ") - # for x in crew: - # if x.lower()==n.lower(): - # print(f"{w} {n=} {x=}") - if n.lower() in crew: if crew[n.lower()] == person_expo: manywallets.add(w) @@ -248,7 +246,7 @@ def walletslistperson(request, slug): expeditions = Expedition.objects.all() length_ug = 0.0 for w in manywallets: - print(w.persons) + print(f"{w}: no .persons in this wallet but people() is {w.people()}") for sb in w.survexblock_set.all(): length_ug += sb.legslength return render( diff --git a/core/views/survex.py b/core/views/survex.py index 075c426..44fdf45 100644 --- a/core/views/survex.py +++ b/core/views/survex.py @@ -67,7 +67,7 @@ survextemplatefile = """; *** THIS IS A TEMPLATE FILE - NOT WHAT YOU MIGHT BE EX *team [Badger] Notes *team ["Fred Fossa"] insts *team [Grumpy] Pics -instrument [SAP #+Laser Tape/DistoX/Compass # ; Clino #] +[*instrument tape "CUCC Fisco Ranger open reel"] ; <-- CHANGE THIS to actual instrument ; Calibration: [Where, readings] *ref [2040#00] ; <-- CHANGE THIS TOO ; the #number is on the clear pocket containing the original notes |