update:完成Python部分的“动态更新web端的配置”

This commit is contained in:
CGD
2025-04-29 10:36:20 +08:00
parent f9f6a69c89
commit 361defc348
2 changed files with 27 additions and 0 deletions
@@ -61,5 +61,8 @@ async def handleTextMessage(conn, message):
asyncio.create_task(handleIotDescriptors(conn, msg_json["descriptors"]))
if "states" in msg_json:
asyncio.create_task(handleIotStatus(conn, msg_json["states"]))
elif msg_json["type"] == "server":
if "model" in msg_json:
await conn.handle_config_update(msg_json)
except json.JSONDecodeError:
await conn.websocket.send(message)