WIP RTR Reporting

This commit is contained in:
Frank Schubert
2024-12-06 13:45:20 +01:00
parent 3a7b356b30
commit 33d7a4e5f1
12 changed files with 604 additions and 10 deletions

View File

@@ -47,6 +47,37 @@ class AdminController extends mfBaseController {
$this->layout()->set("xinon_active_customers_total", $xinon_active_customers_total);
}
protected function rtrReporting() {
require_once(realpath(dirname(__FILE__)."/functions")."/RtrReporting.php");
$this->layout()->setTemplate("Admin/RtrReporting/Index");
$rtrreporting = new Admin_RtrReporting($this->request);
$response = $rtrreporting->runRequest();
foreach(["info", "success", "warning", "error"] as $level) {
if(array_key_exists($level, $response) && $response[$level]) {
$this->layout()->setFlash($response[$level], $level);
}
}
if($response["redirect"]) {
$this->redirect($response["redirect"]);
}
if($response["template"]) {
$this->layout()->setTemplate($response["template"]);
}
if(is_array($response["templateVars"]) && count($response["templateVars"])) {
foreach($response["templateVars"] as $key => $value) {
$this->layout()->set($key, $value);
}
}
}
protected function createNetworkAddressForNetowner() {