diff options
Diffstat (limited to 'core/views/survex.py')
-rw-r--r-- | core/views/survex.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/core/views/survex.py b/core/views/survex.py index e91d228..edc3b1f 100644 --- a/core/views/survex.py +++ b/core/views/survex.py @@ -350,6 +350,10 @@ def svx(request, survex_file): svxblocks = [] try: svxblocksall = svxfile.survexblock_set.all() + svxlength = 0.0 + for b in svxblocksall: + svxlength += b.legslength + print(svxlength,b) except AttributeError: # some survexfiles just *include files and have no blocks themselves svxblocksall = [] else: @@ -366,6 +370,7 @@ def svx(request, survex_file): "warning": warning, "has_3d": (Path(survexdatasetpath) / Path(survex_file + ".3d")).is_file(), "title": survex_file, + "svxlength": svxlength, "svxblocks": svxblocks, "svxincludes": svxincludes, "difflist": difflist, |