From df79bdb71158f11c0217243eaaded89499ed7134 Mon Sep 17 00:00:00 2001 From: Philip Sargent Date: Sun, 5 Nov 2023 22:59:02 +0200 Subject: fine tuning search for SRTM point --- core/models/survex.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'core/models/survex.py') diff --git a/core/models/survex.py b/core/models/survex.py index a27ed45..cb5c26e 100644 --- a/core/models/survex.py +++ b/core/models/survex.py @@ -7,7 +7,7 @@ from pathlib import Path from django.conf import settings from django.db import models from django.urls import reverse -from troggle.core.utils import height_from_utm +from troggle.core.utils import height_from_utm, throw # from troggle.core.models.troggle import DataIssue # circular import. Hmm @@ -100,8 +100,16 @@ class SurvexStation(models.Model): weight = "bold" else: weight = "normal" + diff_str = f"{sign}{diff:.0f}" - + + if ref >= throw: + colour = "grey" + weight = "normal" + diff = "XX" + ref = float("nan") + diff_str = f"XX" + return diff_str, ref -- cgit v1.2.3