From cecbb25857e716844e2c5149a4e90db9c973fe6e Mon Sep 17 00:00:00 2001 From: Proddy Date: Sat, 22 Apr 2023 21:00:29 +0200 Subject: [PATCH] device_id and type_id sent as numbers --- src/web/WebEntityService.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/web/WebEntityService.cpp b/src/web/WebEntityService.cpp index 8687f20be..7ed4c4afd 100644 --- a/src/web/WebEntityService.cpp +++ b/src/web/WebEntityService.cpp @@ -64,8 +64,8 @@ StateUpdateResult WebEntity::update(JsonObject & root, WebEntity & webEntity) { if (root["entity"].is()) { for (const JsonObject ei : root["entity"].as()) { auto entityItem = EntityItem(); - entityItem.device_id = Helpers::hextoint(ei["device_id"]); // TODO don't need - entityItem.type_id = Helpers::hextoint(ei["type_id"]); + entityItem.device_id = ei["device_id"]; // send as numeric, will be converted to string in web + entityItem.type_id = ei["type_id"]; entityItem.offset = ei["offset"]; entityItem.factor = ei["factor"]; entityItem.name = ei["name"].as();