Added support for state in telemetry.

This commit is contained in:
stephb9959
2021-10-21 23:15:16 -07:00
parent 4fa59fdfd2
commit e47feab9ad
107 changed files with 4839 additions and 5302 deletions

View File

@@ -16,7 +16,7 @@ namespace OpenWifi {
void RESTAPI_command::DoGet() {
auto CommandUUID = GetBinding(RESTAPI::Protocol::COMMANDUUID, "");
GWObjects::CommandDetails Command;
if (Storage()->GetCommand(CommandUUID, Command)) {
if (StorageService()->GetCommand(CommandUUID, Command)) {
Poco::JSON::Object RetObj;
Command.to_json(RetObj);
return ReturnObject(RetObj);
@@ -32,11 +32,11 @@ namespace OpenWifi {
}
GWObjects::CommandDetails C;
if(!Storage()->GetCommand(UUID, C)) {
if(!StorageService()->GetCommand(UUID, C)) {
return NotFound();
}
if (Storage()->DeleteCommand(UUID)) {
if (StorageService()->DeleteCommand(UUID)) {
return OK();
}
return InternalError();