diff --git a/ScadaWeb/OpenPlugins/PlgSchShapeComp/wwwroot/SchShapeComp/js/shapecomp-render.js b/ScadaWeb/OpenPlugins/PlgSchShapeComp/wwwroot/SchShapeComp/js/shapecomp-render.js index 92e0baba5..48d53a569 100644 --- a/ScadaWeb/OpenPlugins/PlgSchShapeComp/wwwroot/SchShapeComp/js/shapecomp-render.js +++ b/ScadaWeb/OpenPlugins/PlgSchShapeComp/wwwroot/SchShapeComp/js/shapecomp-render.js @@ -573,17 +573,15 @@ scada.scheme.DynamicTextRenderer.prototype.updateData = function ( //add condition textContente to set spanText if (props.conditions && cnlDataExt.d.stat > 0) { var cnlVal = cnlDataExt.d.val; + let isConditionSatisfied = false; for (var cond of props.conditions) { - if (scada.scheme.calc.conditionSatisfied(cond, cnlVal)) { + if (!isConditionSatisfied && scada.scheme.calc.conditionSatisfied(cond, cnlVal)) { + isConditionSatisfied = true; if (cond.textContent) { spanText.text(cond.textContent); } - } - //update font size - if (scada.scheme.calc.conditionSatisfied(cond, cnlVal)) { this.setFontSize(spanComp, cond.fontSize); } - break; } }