Commit 1dabd53d authored by Ad Schellevis's avatar Ad Schellevis

(plugins, interfaces) add ifgroup type, filter in interfaces_groups_edit.php....

(plugins, interfaces) add ifgroup type, filter in interfaces_groups_edit.php. for https://github.com/opnsense/core/issues/1455
parent f6d83a94
......@@ -40,6 +40,7 @@ function if_group_interfaces()
$oc['if'] = $ifgen['ifname'];
$oc['descr'] = $ifgen['ifname'];
$oc['virtual'] = true;
$oc['type'] = 'ifgroup';
$interfaces[$ifgen['ifname']] = $oc;
}
}
......
......@@ -79,7 +79,7 @@ function if_openvpn_interfaces()
$oic = array('enable' => true);
$oic['if'] = 'openvpn';
$oic['descr'] = 'OpenVPN';
$oic['type'] = 'none';
$oic['type'] = 'ifgroup';
$oic['virtual'] = true;
$oic['networks'] = array();
$interfaces['openvpn'] = $oic;
......
......@@ -183,7 +183,11 @@ legacy_html_escape_form_data($pconfig);
<td>
<select name="members[]" multiple="multiple" class="selectpicker" data-size="5" data-live-search="true">
<?php
foreach (legacy_config_get_interfaces(array("enable" => true)) as $ifn => $ifdetail):?>
foreach (legacy_config_get_interfaces(array("enable" => true)) as $ifn => $ifdetail):
if (!empty($ifdetail['type']) && $ifdetail['type'] == 'ifgroup') {
continue;
}
?>
<option value="<?=$ifn;?>" <?=in_array($ifn, $pconfig['members']) ? "selected=\"selected\"" : "";?>>
<?=strtoupper($ifdetail['descr']);?>
</option>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment