mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-07 08:19:52 +03:00
Change name of entity within WebUI #612
This commit is contained in:
@@ -1052,25 +1052,25 @@ bool EMSESP::add_device(const uint8_t device_id, const uint8_t product_id, const
|
||||
[device_type](const char * value, const int8_t id, JsonObject & output) {
|
||||
return command_info(device_type, output, id, EMSdevice::OUTPUT_TARGET::API_VERBOSE);
|
||||
},
|
||||
F_(info_cmd));
|
||||
uuid::read_flash_string(F_(info_cmd)));
|
||||
Command::add(
|
||||
device_type,
|
||||
F("values"),
|
||||
[device_type](const char * value, const int8_t id, JsonObject & output) {
|
||||
return command_info(device_type, output, id, EMSdevice::OUTPUT_TARGET::API_SHORTNAMES); // HIDDEN command showing short names, used in e.g. /api/boiler
|
||||
},
|
||||
nullptr,
|
||||
"",
|
||||
CommandFlag::HIDDEN); // this command is hidden
|
||||
Command::add(
|
||||
device_type,
|
||||
F_(commands),
|
||||
[device_type](const char * value, const int8_t id, JsonObject & output) { return command_commands(device_type, output, id); },
|
||||
F_(commands_cmd));
|
||||
uuid::read_flash_string(F_(commands_cmd)));
|
||||
Command::add(
|
||||
device_type,
|
||||
F_(entities),
|
||||
[device_type](const char * value, const int8_t id, JsonObject & output) { return command_entities(device_type, output, id); },
|
||||
F_(entities_cmd));
|
||||
uuid::read_flash_string(F_(entities_cmd)));
|
||||
|
||||
// MQTT subscribe to the device e.g. "ems-esp/boiler/#"
|
||||
Mqtt::subscribe(device_type, EMSdevice::device_type_2_device_name(device_type) + "/#", nullptr);
|
||||
|
||||
Reference in New Issue
Block a user