Projekt

Obecné

Profil

« Předchozí | Další » 

Revize 1839

Přidáno uživatelem Ondřej Fibich před více než 11 roky(ů)

Upravy:
- #311: Sprava DHCP - chybove hlaseni detekujici nenastaveni bran subnetu s DHCP

Zobrazit rozdíly:

freenetis/branches/1.1/application/i18n/cs_CZ/texts.php
'there is already some vlan with this tag' => 'Již existuje nějaký VLAN s tímto tagem.',
'there is at least one ip address of subnet which not belong to subnet range' => 'Existuje alespoň jedna IP adresa podsítě, která nepatří do rozsahu podsítě.',
'there is no e-mail filled in your account' => 'Vašemu účtu není přiřazen žádný e-mail',
'these subnets have not configured gateway (%s), set them please' => 'Tyto podsítě nemají nastavenu bránu (%s), nastavte je prosím.',
'third-degree certified engineers' => 'Certifikovaní technici třetího stupně',
'this account does not exist' => 'Tento účet neexistuje.',
'this approval template already contains approval type with the same priority' => 'Tato hlasovací šablona již obsahuje hlasovací typ se stejnou prioritou.',
freenetis/branches/1.1/application/models/subnet.php
");
}
/**
* Return all subnets on which DHCP is running and has no gateway.
*
* @return Mysql_Result
*/
public function get_all_dhcp_subnets_without_gateway()
{
return $this->db->query("
SELECT s.*
FROM subnets s
WHERE s.dhcp > 0 AND s.id NOT IN (
SELECT s2.id
FROM subnets s2
JOIN ip_addresses ip ON ip.subnet_id = s2.id
AND ip.gateway = 1
)
");
}
}
freenetis/branches/1.1/application/controllers/subnets.php
Controller::error(ACCESS);
}
// check if subnets with DHCP server has set uped gateway
$subnets = ORM::factory('subnet')->get_all_dhcp_subnets_without_gateway();
if (count($subnets))
{
$subnet_links = array();
foreach ($subnets as $s)
{
$subnet_links[] = html::anchor('subnets/show/' . $s->id, $s->name);
}
$m = 'These subnets have not configured gateway (%s), set them please.';
status::mwarning($m, TRUE, implode(', ', $subnet_links));
}
$filter_form = new Filter_form('s');
$filter_form->add('subnet_name')
freenetis/branches/1.1/application/controllers/devices.php
if (!$this->acl_check_view(get_class($this), 'devices'))
Controller::error(ACCESS);
// check if subnets with DHCP server has set uped gateway
$subnets = ORM::factory('subnet')->get_all_dhcp_subnets_without_gateway();
if (count($subnets))
{
$subnet_links = array();
foreach ($subnets as $s)
{
$subnet_links[] = html::anchor('subnets/show/' . $s->id, $s->name);
}
$m = 'These subnets have not configured gateway (%s), set them please.';
status::mwarning($m, TRUE, implode(', ', $subnet_links));
}
$filter_form = new Filter_form('d');
$filter_form->add('access_time')

Také k dispozici: Unified diff