From aa464365e5251858fb3c7c099c63cecab782bf29 Mon Sep 17 00:00:00 2001 From: IoT Manager <67171972+IoTManagerProject@users.noreply.github.com> Date: Sat, 11 Nov 2023 23:32:10 +0100 Subject: [PATCH] =?UTF-8?q?=D0=BD=D0=B5=D0=B1=D0=BE=D0=BB=D1=8C=D1=88?= =?UTF-8?q?=D0=B8=D0=B5=20=D0=B8=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=D0=B8=D1=8F=20=D0=B3=D1=80=D0=B0=D1=84=D0=B8=D0=BA=D0=BE?= =?UTF-8?q?=D0=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- data_svelte/items.json | 2 +- src/modules/virtual/LogingDaily/LogingDaily.cpp | 16 ++++++---------- src/modules/virtual/LogingDaily/modinfo.json | 2 +- 3 files changed, 8 insertions(+), 12 deletions(-) diff --git a/data_svelte/items.json b/data_svelte/items.json index 6511d60c..8ee594e1 100644 --- a/data_svelte/items.json +++ b/data_svelte/items.json @@ -60,7 +60,7 @@ "num": 4, "int": 1, "logid": "t", - "points": 365, + "points": 200, "telegram": 0, "test": 0, "btn-defvalue": 0, diff --git a/src/modules/virtual/LogingDaily/LogingDaily.cpp b/src/modules/virtual/LogingDaily/LogingDaily.cpp index 32a0e68d..b6f5b1e0 100644 --- a/src/modules/virtual/LogingDaily/LogingDaily.cpp +++ b/src/modules/virtual/LogingDaily/LogingDaily.cpp @@ -36,12 +36,12 @@ class LogingDaily : public IoTItem { jsonRead(parameters, F("telegram"), telegram); jsonRead(parameters, F("descr"), descr); - if (points > 365) { - points = 365; - SerialPrint("E", F("LogingDaily"), "'" + id + "' user set more points than allowed, value reset to 365"); + if (points > 200) { + points = 200; + SerialPrint("E", F("LogingDaily"), "'" + id + "' user set more points than allowed, value reset to 200"); } long interval; - jsonRead(parameters, F("int"), interval); // в минутах + jsonRead(parameters, F("int"), interval); // в минутах setInterval(interval * 60); } @@ -222,9 +222,7 @@ class LogingDaily : public IoTItem { _wsNum = wsNum; } - String getValue() { - return ""; - } + String getValue() { return ""; } // void loop() { // if (enableDoByInt) { @@ -238,9 +236,7 @@ class LogingDaily : public IoTItem { // } // просто максимальное количество точек - int calculateMaxCount() { - return 86400; - } + int calculateMaxCount() { return 86400; } void onModuleOrder(String &key, String &value) { if (key == "defvalue") { diff --git a/src/modules/virtual/LogingDaily/modinfo.json b/src/modules/virtual/LogingDaily/modinfo.json index 39c82335..4f0a5f09 100644 --- a/src/modules/virtual/LogingDaily/modinfo.json +++ b/src/modules/virtual/LogingDaily/modinfo.json @@ -13,7 +13,7 @@ "num": 1, "int": 1, "logid": "t", - "points": 365, + "points": 200, "telegram": 0, "test": 0, "btn-defvalue": 0,