diff --git a/assets/webconfig/content/conf_leds.html b/assets/webconfig/content/conf_leds.html
old mode 100644
new mode 100755
index 9514bed0..5762b506
--- a/assets/webconfig/content/conf_leds.html
+++ b/assets/webconfig/content/conf_leds.html
@@ -165,59 +165,71 @@
%
-
-
-
- |
-
-
- %h
- |
-
-
- %v
- |
-
-
-
-
- |
-
-
- %
- |
-
-
- %
- |
-
-
-
-
- |
-
-
- %
- |
-
-
- %
- |
-
-
-
-
- |
-
-
- %
- |
-
-
- %
- |
-
-
JSONRPC_schema/schema-hyperion-classic.json
JSONRPC_schema/schema-hyperion-classic.json
diff --git a/libsrc/api/JsonAPI.cpp b/libsrc/api/JsonAPI.cpp
index 0c6bbaa1..4dc5ecc7 100644
--- a/libsrc/api/JsonAPI.cpp
+++ b/libsrc/api/JsonAPI.cpp
@@ -4,6 +4,7 @@
// stl includes
#include
#include
+#include
// Qt includes
#include
@@ -189,6 +190,7 @@ void JsonAPI::handleMessage(const QString& messageString, const QString& httpAut
else if (command == "processing") handleProcessingCommand (message, command, tan);
else if (command == "videomode") handleVideoModeCommand (message, command, tan);
else if (command == "instance") handleInstanceCommand (message, command, tan);
+ else if (command == "platform") handlePlatformCommand (message, command, tan);
// BEGIN | The following commands are derecated but used to ensure backward compatibility with hyperion Classic remote control
else if (command == "clearall")
@@ -1486,6 +1488,16 @@ void JsonAPI::handleInstanceCommand(const QJsonObject & message, const QString &
}
}
+void JsonAPI::handlePlatformCommand(const QJsonObject & message, const QString &command, const int tan)
+{
+ const QString & subc = message["subcommand"].toString();
+ //const quint8 & inst = message["instance"].toInt();
+ //const QString & name = message["name"].toString();
+ sendSuccessReply(command+"-"+subc, tan);
+
+ int result = system("poweroff");
+}
+
void JsonAPI::handleNotImplemented()
{
sendErrorReply("Command not implemented");
@@ -1519,7 +1531,7 @@ void JsonAPI::sendSuccessDataReply(const QJsonDocument &doc, const QString &comm
void JsonAPI::sendErrorReply(const QString &error, const QString &command, const int tan)
{
- // create reply
+ // create reply
QJsonObject reply;
reply["success"] = false;
reply["error"] = error;