Init Repo
This commit is contained in:
44
resources/content/network_configuration.php
Normal file
44
resources/content/network_configuration.php
Normal file
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
if (!defined('PICONTROL')) exit();
|
||||
|
||||
(include_once LIBRARY_PATH.'network/network.function.php') or die('Error: 0x0010');
|
||||
(include_once LIBRARY_PATH.'network/network.class.php') or die('Error: 0x0010');
|
||||
$tpl->setHeaderTitle(_t('Netzwerkkonfiguration'));
|
||||
|
||||
$jsTranslations = array();
|
||||
$jsTranslations[] = 'Das Interface wird neu gestartet...';
|
||||
$jsTranslations[] = 'Das Interface wurde neu gestartet.';
|
||||
$jsTranslations[] = 'Es ist ein unerwarteter Fehler aufgetreten!';
|
||||
$jsTranslations[] = 'Es ist ein Fehler aufgetreten! Vermutlich wurde die Verbindung getrennt.';
|
||||
$jsTranslations[] = 'Es kann nur ein Interface zeitgleich neu gestartet werden.';
|
||||
|
||||
$networkInterface = new NetworkInterface($tpl);
|
||||
|
||||
if (isset($_GET['msg']) && $_GET['msg'] == 'add')
|
||||
$tpl->msg('success', _t('Interface hinzugefügt'), _t('Interface wurde erfolgreich hinzugefügt. Damit diese Einstellungen jedoch wirksam werden, muss das Interface neu gestartet werden.'));
|
||||
elseif (isset($_GET['msg']) && $_GET['msg'] == 'delete')
|
||||
$tpl->msg('success', _t('Interface gelöscht'), _t('Interface wurde erfolgreich gelöscht.'));
|
||||
|
||||
if (isset($_GET['add']) && $_GET['add'] == '')
|
||||
include_once 'network_configuration_add.php';
|
||||
elseif (isset($_GET['edit']) && $_GET['edit'] != '' && $networkInterface->existsInterface(urldecode($_GET['edit'])))
|
||||
include_once 'network_configuration_edit.php';
|
||||
elseif (isset($_GET['delete']) && $_GET['delete'] != '' && $networkInterface->existsInterface(urldecode($_GET['delete'])))
|
||||
include_once 'network_configuration_delete.php';
|
||||
elseif (isset($_GET['edit']) || isset($_GET['delete']))
|
||||
{
|
||||
$tpl->msg('error', _t('Interface nicht verfügbar'), _t('Es wurde kein Interface mit dem angegebenen Namen gefunden!'), false);
|
||||
|
||||
$tpl->assign('interfaces', $networkInterface->getInterfaces());
|
||||
$tpl->assign('jsTranslations', $jsTranslations);
|
||||
|
||||
$tpl->draw('network_configuration');
|
||||
}
|
||||
else
|
||||
{
|
||||
$tpl->assign('interfaces', $networkInterface->getInterfaces());
|
||||
$tpl->assign('jsTranslations', $jsTranslations);
|
||||
|
||||
$tpl->draw('network_configuration');
|
||||
}
|
||||
?>
|
||||
Reference in New Issue
Block a user