瀏覽代碼

highlight history alarm by regexp

Avetisyan Karen 4 年之前
父節點
當前提交
02ea12dfc9
共有 2 個文件被更改,包括 1 次插入1 次删除
  1. 二進制
      web_interface/dist/wui-3-rt/main.js
  2. 1 1
      web_interface/src/wui-3-rt/main.js

二進制
web_interface/dist/wui-3-rt/main.js


+ 1 - 1
web_interface/src/wui-3-rt/main.js

@@ -577,7 +577,7 @@ function getPage(pn){
 
         td.innerHTML = td_value;
         td.id = ctrl_inputs[num] + i;
-        if (num === 1 && (td_value === 'Авария' || td_value === 'Ошибка')) {
+        if (num === 1 && !!td_value.match(/Авария|Ошибка/)) {
           td.style.color = ALARM_RED;
         }
         tr.appendChild(td);