From c945c0395e64915812b356efefd5dc47ea673125 Mon Sep 17 00:00:00 2001 From: Conor Finn <conor.finn@stfc.ac.uk> Date: Mon, 27 Jan 2020 09:03:11 +0000 Subject: [PATCH] RE #27188 Fix validation if custom selected then closed If custom spectra was selected from the dropdown and then the tick box was deselected, the GUI would still check the validity of the spectrum numbers. As this was usually empty, the calibration would fail to run. --- .../gui/engineering_diffraction/tabs/calibration/presenter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/Engineering/gui/engineering_diffraction/tabs/calibration/presenter.py b/scripts/Engineering/gui/engineering_diffraction/tabs/calibration/presenter.py index 7e81c200e4b..6517bf5b020 100644 --- a/scripts/Engineering/gui/engineering_diffraction/tabs/calibration/presenter.py +++ b/scripts/Engineering/gui/engineering_diffraction/tabs/calibration/presenter.py @@ -125,7 +125,7 @@ class CalibrationPresenter(object): if not self.validate_run_numbers(): create_error_message(self.view, "Check run numbers/path is valid.") return False - if not self.cropping_widget.is_valid(): + if self.view.get_crop_checked() and not self.cropping_widget.is_valid(): create_error_message(self.view, "Check cropping values are valid.") return False return True -- GitLab