fix: not able to save QC (#42371)

This commit is contained in:
rohitwaghchaure
2024-07-17 19:49:53 +05:30
committed by GitHub
parent c8dad976e2
commit 62fb495a65

View File

@@ -242,6 +242,9 @@ class QualityInspection(Document):
# numeric readings
for i in range(1, 11):
field = "reading_" + str(i)
if reading.get(field) is None:
continue
data[field] = parse_float(reading.get(field))
data["mean"] = self.calculate_mean(reading)