mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-13 08:09:41 +00:00
fixes #376: add description for static DHCP leases
This commit is contained in:
parent
63d3192156
commit
d7a42b2c29
@ -283,6 +283,7 @@ foreach($config['interfaces'] as $ifname => $ifarr) {
|
||||
$slease['start'] = "";
|
||||
$slease['end'] = "";
|
||||
$slease['hostname'] = htmlentities($static['hostname']);
|
||||
$slease['descr'] = htmlentities($static['descr']);
|
||||
$slease['act'] = "static";
|
||||
$slease['online'] = in_array(strtolower($slease['mac']), $arpdata_mac) ? 'online' : 'offline';
|
||||
$leases[] = $slease;
|
||||
@ -339,6 +340,7 @@ if(count($pools) > 0) {
|
||||
<td class="listhdrr"><?=gettext("IP address"); ?></td>
|
||||
<td class="listhdrr"><?=gettext("MAC address"); ?></td>
|
||||
<td class="listhdrr"><?=gettext("Hostname"); ?></td>
|
||||
<td class="listhdrr"><?=gettext("Description"); ?></td>
|
||||
<td class="listhdrr"><?=gettext("Start"); ?></td>
|
||||
<td class="listhdrr"><?=gettext("End"); ?></td>
|
||||
<td class="listhdrr"><?=gettext("Online"); ?></td>
|
||||
@ -405,6 +407,11 @@ if(count($pools) > 0) {
|
||||
}
|
||||
}
|
||||
echo "<td class=\"listr\">{$fspans}" . htmlentities($data['hostname']) . "{$fspane}</td>\n";
|
||||
if (isset($data['descr'])) {
|
||||
echo "<td class=\"listr\">{$fspans}" . htmlentities($data['descr']) . "{$fspane}</td>\n";
|
||||
} else {
|
||||
echo "<td class=\"listr\">{$fspans} n/a {$fspane}</td>\n";
|
||||
}
|
||||
if ($data['type'] != "static") {
|
||||
echo "<td class=\"listr\">{$fspans}" . adjust_gmt($data['start']) . "{$fspane}</td>\n";
|
||||
echo "<td class=\"listr\">{$fspans}" . adjust_gmt($data['end']) . "{$fspane}</td>\n";
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user