Rule Examples/en: различия между версиями

Новая страница: «When you click Save in the web interface, the wb-rules service will be restarted, and the values of the settings will be written to the rules.»
(Новая страница: «7. Let's describe the rules for turning the switch on and off»)
(Новая страница: «When you click Save in the web interface, the wb-rules service will be restarted, and the values of the settings will be written to the rules.»)
Строка 1297: Строка 1297:
   });
   });


   <div lang="ru" dir="ltr" class="mw-content-ltr">
   defineRule("acVegOff", {
defineRule("acVegOff", {
     when: function() {
     when: function() {
       return vegetablesTemperature < 17.8
       return vegetablesTemperature < 17.8
Строка 1304: Строка 1303:
     then: function (newValue, devName, cellName) {
     then: function (newValue, devName, cellName) {
       log("acVegOff  newValue={}, devName={}, cellName={}", newValue, devName, cellName);
       log("acVegOff  newValue={}, devName={}, cellName={}", newValue, devName, cellName);
       dev["wb-mir_76/Play from ROM2"] = true; // выключить
       dev["wb-mir_76/Play from ROM2"] = true; // turn off
     }
     }
   });
   });
Строка 1310: Строка 1309:
</syntaxhighlight>
</syntaxhighlight>
== Полезные ссылки ==
== Полезные ссылки ==
* [[Wb-rules | Краткое описание wb-rules на wiki]]
* [[Wb-rules | Brief description of wb-rules on wiki]]
* [https://github.com/wirenboard/wb-rules Полное описание wb-rules на Github]
* [https://github.com/wirenboard/wb-rules Full description of wb-rules on Github]
</div>
translator, wb_editors
4265

правок