From b36d48307d26699960fcad35951b5b9d9dbdb093 Mon Sep 17 00:00:00 2001 From: Dan Nixon Date: Thu, 28 May 2015 10:02:31 +0100 Subject: [PATCH] Add param to ISIS instruments Refs #11861 --- .../WorkflowAlgorithms/ElasticWindowMultiple.py | 8 ++++---- .../inc/MantidQtCustomInterfaces/Indirect/Elwin.ui | 2 +- Code/Mantid/instrument/IRIS_Parameters.xml | 3 +++ Code/Mantid/instrument/OSIRIS_Parameters.xml | 3 +++ 4 files changed, 11 insertions(+), 5 deletions(-) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ElasticWindowMultiple.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ElasticWindowMultiple.py index ed0e74c2e29c..72462e88a5e0 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ElasticWindowMultiple.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ElasticWindowMultiple.py @@ -57,7 +57,7 @@ def PyInit(self): self.declareProperty(name='SampleEnvironmentLogName', defaultValue='sample', doc='Name of the sample environment log entry') - sampEnvLogVal_type = ['last value', 'average'] + sampEnvLogVal_type = ['last_value', 'average'] self.declareProperty('SampleEnvironmentLogValue', 'last value', StringListValidator(sampEnvLogVal_type), doc='Value selection of the sample environment log entry') @@ -323,9 +323,9 @@ def _get_temperature(self, ws_name): if self._sample_log_name in run: # Look for temperature in logs in workspace tmp = run[self._sample_log_name].value - value_action = {'last value': lambda x: x[len(x)-1], - 'average': lambda x: x.mean() - } + value_action = {'last_value': lambda x: x[len(x)-1], + 'average': lambda x: x.mean() + } temp = value_action[self._sample_log_value](tmp) logger.debug('Temperature %d K found for run: %s' % (temp, run_name)) return temp diff --git a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Indirect/Elwin.ui b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Indirect/Elwin.ui index 6cae8fdba688..af30980cac5e 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Indirect/Elwin.ui +++ b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Indirect/Elwin.ui @@ -125,7 +125,7 @@ - last value + last_value diff --git a/Code/Mantid/instrument/IRIS_Parameters.xml b/Code/Mantid/instrument/IRIS_Parameters.xml index 9c0ba3b1958a..05d8cf2f1440 100644 --- a/Code/Mantid/instrument/IRIS_Parameters.xml +++ b/Code/Mantid/instrument/IRIS_Parameters.xml @@ -81,6 +81,9 @@ + + + diff --git a/Code/Mantid/instrument/OSIRIS_Parameters.xml b/Code/Mantid/instrument/OSIRIS_Parameters.xml index e74511bb3df6..68246e3e76b1 100644 --- a/Code/Mantid/instrument/OSIRIS_Parameters.xml +++ b/Code/Mantid/instrument/OSIRIS_Parameters.xml @@ -73,6 +73,9 @@ + + +