Mike Phares d9f6ada5cb Assembly Version
WS Result bug fix and Nuget bump, PSN, Reactor and Extra RDS rule
OpenInsightApi and testRunTitle
serializerValue
2023-03-07 11:48:46 -07:00

26 lines
831 B
JavaScript

// (self.length != 0) ?
// self :
// (getContextData('2', 'cds.PRODUCT', '') == '-') ?
// self :
// getContextData('2', 'cds.PRODUCT', '')
getValue(self, self.length, getContextData('2', 'cds.PRODUCT', ''), $('dcp.BIORAD4/Stratus/Recipe', ''));
function getValue(value, length, product, recipe) {
if (recipe.toUpperCase() === 'T-LOW')
return 'T-Low';
else if (recipe.toUpperCase() === 'T-MID')
return 'T-Mid';
else if (recipe.toUpperCase() === 'T-HIGH')
return 'T-High';
else if (recipe.toUpperCase() === 'T_LOW')
return 'T-Low';
else if (recipe.toUpperCase() === 'T_MID')
return 'T-Mid';
else if (recipe.toUpperCase() === 'T_HIGH')
return 'T-High';
else if (length === 0)
return product;
else
return value;
}