From 4e258b398113913ad78766764b24d4928ddca66e Mon Sep 17 00:00:00 2001 From: billz Date: Mon, 19 Feb 2024 10:08:29 +0100 Subject: [PATCH] Add sidebar item, template stubs + page actions --- includes/page_actions.php | 3 +++ includes/restapi.php | 18 ++++++++++++++ includes/sidebar.php | 6 +++++ index.php | 1 + templates/restapi.php | 46 +++++++++++++++++++++++++++++++++++ templates/restapi/general.php | 0 templates/restapi/status.php | 0 7 files changed, 74 insertions(+) create mode 100644 includes/restapi.php create mode 100644 templates/restapi.php create mode 100644 templates/restapi/general.php create mode 100644 templates/restapi/status.php diff --git a/includes/page_actions.php b/includes/page_actions.php index ed64a33e..de4a1cd0 100755 --- a/includes/page_actions.php +++ b/includes/page_actions.php @@ -45,6 +45,9 @@ case "/system_info": DisplaySystem($extraFooterScripts); break; + case "/restapi_conf": + DisplayRestAPI(); + break; case "/about": DisplayAbout(); break; diff --git a/includes/restapi.php b/includes/restapi.php new file mode 100644 index 00000000..370cd02a --- /dev/null +++ b/includes/restapi.php @@ -0,0 +1,18 @@ + + + + + diff --git a/index.php b/index.php index 31a9216a..5b8b4038 100755 --- a/index.php +++ b/index.php @@ -47,6 +47,7 @@ require_once 'includes/about.php'; require_once 'includes/openvpn.php'; require_once 'includes/wireguard.php'; require_once 'includes/provider.php'; +require_once 'includes/restapi.php'; require_once 'includes/torproxy.php'; initializeApp(); diff --git a/templates/restapi.php b/templates/restapi.php new file mode 100644 index 00000000..39743df3 --- /dev/null +++ b/templates/restapi.php @@ -0,0 +1,46 @@ + + + " /> + + class="btn btn-success " name="StartRestAPIservice" value="" /> + + class="btn btn-warning " name="StopRestAPIservice" value="" /> + + + + +
+
+
+
+
+
+ +
+
+
+
+ showMessages(); ?> +
+ + + + + +
+ + +
+ + +
+
+ +
+
+
+ + diff --git a/templates/restapi/general.php b/templates/restapi/general.php new file mode 100644 index 00000000..e69de29b diff --git a/templates/restapi/status.php b/templates/restapi/status.php new file mode 100644 index 00000000..e69de29b