diff --git a/Layout/default/Device/Detail.php b/Layout/default/Device/Detail.php index 26b6a060f..25d83adb0 100644 --- a/Layout/default/Device/Detail.php +++ b/Layout/default/Device/Detail.php @@ -275,7 +275,7 @@ foreach ($devicesall as $deviceall) { } ?> -
+

@@ -338,70 +338,75 @@ foreach ($devicesall as $deviceall) { } ?>
-
-
-

Config Backups

- devicetype->devicemanufactor->config_backup > count()): ?> - - is('Admin')): + is('Admin')) : ?> +
+
+

Config Backups

+ devicetype->devicemanufactor->config_backup > count()): ?> + + is('Admin')): + ?> + + +
+ success == "true" && $devicesconfig->data > count()) { ?> - - -
- success == "true" && $devicesconfig->data > count()) { - ?> -
- - - - - - - - - data as $config) : - $configfileCleartext = trim($config->config_cleartext); - $configfileCompressed = trim($config->config_compressed); - $configid = $config->id; - if ($configfileCleartext && $configfileCompressed) : +
+
Datum/Uhrzeit
+ + + + + + + + data as $config) : + $configfileCleartext = trim($config->config_cleartext); + $configfileCompressed = trim($config->config_compressed); + $configid = $config->id; + if ($configfileCleartext && $configfileCompressed) : - $configLinks = ' 'getconfig', 'id' => $configid, 'format' => 'txt', 'filename' => $configfileCleartext]) . '"> + $configLinks = ' 'getconfig', 'id' => $configid, 'format' => 'txt', 'filename' => $configfileCleartext]) . '"> TXT / 'getconfig', 'id' => $configid, 'format' => 'xml', 'filename' => $configfileCompressed]) . '"> XML'; - elseif ($configfileCleartext || $configfileCompressed) : - $configLinks = ' 'getconfig', 'id' => $configid, 'format' => 'txt', 'filename' => $configfileCleartext . $configfileCompressed]) . '"> + elseif ($configfileCleartext || $configfileCompressed) : + $configLinks = ' 'getconfig', 'id' => $configid, 'format' => 'txt', 'filename' => $configfileCleartext . $configfileCompressed]) . '"> TXT'; - endif; - ?> - - - + endif; + ?> + + + - - + + - -
Datum/Uhrzeit
config_timestamp); ?>
config_timestamp); ?>
-
- + +
+ +
+
Keine Configs vorhanden
+
+ -
-
Keine Configs vorhanden
-
- -
+
+ + devicetype->olt && TT_MBI_API_ENABLE) : diff --git a/Layout/default/menu.php b/Layout/default/menu.php index b670b56fd..75cc6e347 100644 --- a/Layout/default/menu.php +++ b/Layout/default/menu.php @@ -49,7 +49,7 @@ - is(["Admin"]) || ($me->is("netowner") && $me->hasGwrNetworks())): ?> + is(["Admin"]) || ($me->is("netowner","lineplanner","pipeplanner","pipeworker","lineworker","salespartner"))): ?>
  • Stammdaten
    @@ -64,7 +64,11 @@
  • "> Netzgebiete
  • "> Pops
  • + + is(["Admin"]) || ($me->is("netowner","lineplanner","pipeplanner","pipeworker","lineworker","salespartner"))): ?>
  • "> Devices
  • + + is(["Admin"])): ?>
  • "> Benutzer
  • Grundstammdaten
  • diff --git a/application/Device/DeviceController.php b/application/Device/DeviceController.php index 3ca476dfd..f810e44d2 100644 --- a/application/Device/DeviceController.php +++ b/application/Device/DeviceController.php @@ -10,7 +10,7 @@ class DeviceController extends mfBaseController $this->me = $me; $this->layout()->set("me", $me); - if (!$me->is(["Admin"])) { + if (!$me->is(["Admin", "netowner", "lineplanner", "pipeplanner", "pipeworker", "lineworker"])) { $this->redirect("Dashboard"); } @@ -18,7 +18,11 @@ class DeviceController extends mfBaseController $this->allowedPops = null; } else { $networkIds = array_column($this->me->getProperty('my_networks'), 'id'); - $this->allowedPops = array_column(PopNetworkModel::search(['Networks' => $networkIds]), 'pop_id'); + $pops=PopNetworkModel::search(['Networks' => $networkIds]); + foreach ($pops as $pop) { + $popIds[] = $pop->pop_id; + } + $this->allowedPops = $popIds; } } diff --git a/application/PopNetwork/PopNetworkModel.php b/application/PopNetwork/PopNetworkModel.php index 63fe70a2b..0b624f765 100644 --- a/application/PopNetwork/PopNetworkModel.php +++ b/application/PopNetwork/PopNetworkModel.php @@ -146,6 +146,11 @@ class PopNetworkModel $where .= " AND network_id=$networkid"; } } + if (array_key_exists("Networks", $filter)) { + $Networks = $filter['Networks']; + $where .= " AND network_id IN (" . implode(",", $Networks) . ")"; + + } //var_dump($filter, $where);exit; return $where;