aboutsummaryrefslogtreecommitdiffstats
path: root/config/haproxy-devel/www
diff options
context:
space:
mode:
authorPiBa-NL <pba_2k3@yahoo.com>2015-12-23 23:23:12 +0100
committerPiBa-NL <pba_2k3@yahoo.com>2015-12-23 23:23:12 +0100
commit5317a20269bd39459ca22737a35e494ca972bf88 (patch)
tree2afbdf9c22ae598779dd3211fb551a4a63513896 /config/haproxy-devel/www
parent3bd905893f4eeb15485783e49a8ea2af14b31f4e (diff)
downloadpfsense-packages-5317a20269bd39459ca22737a35e494ca972bf88.tar.gz
pfsense-packages-5317a20269bd39459ca22737a35e494ca972bf88.tar.bz2
pfsense-packages-5317a20269bd39459ca22737a35e494ca972bf88.zip
haproxy-devel, small fixes for showing/hiding acl fields not applicable, fix custom action, pkg v0.36
Diffstat (limited to 'config/haproxy-devel/www')
-rw-r--r--config/haproxy-devel/www/haproxy_listeners_edit.php25
1 files changed, 22 insertions, 3 deletions
diff --git a/config/haproxy-devel/www/haproxy_listeners_edit.php b/config/haproxy-devel/www/haproxy_listeners_edit.php
index f26341b2..8c37332e 100644
--- a/config/haproxy-devel/www/haproxy_listeners_edit.php
+++ b/config/haproxy-devel/www/haproxy_listeners_edit.php
@@ -251,14 +251,33 @@ function customdrawcell_actions($object, $item, $itemvalue, $editable, $itemname
$htmllist_extaddr = new HaproxyHtmlList("table_extaddr", $fields_externalAddress);
$htmllist_extaddr->editmode = true;
+function fields_details_showfieldfunction($items, $action, $itemname) {
+ if (is_array($items[$action]) && is_array($items[$action]['fields'])) {
+ foreach($items[$action]['fields'] as $item) {
+ if ($action . "" . $item['name'] == $itemname) {
+ return true;
+ }
+ }
+ }
+ return false;
+}
+function fields_acls_details_showfieldfunction($htmltable, $itemname, $values) {
+ $items = $htmltable->fields[1]['items'];
+ $action = $values['expression'];
+ return fields_details_showfieldfunction($items, $action, $itemname);
+}
$htmllist_acls = new HaproxyHtmlList("table_acls", $fields_aclSelectionList);
$htmllist_acls->fields_details = $fields_acl_details;
-//$htmllist_acls->editmode = true;
+$htmllist_acls->fields_details_showfieldfunction = fields_acls_details_showfieldfunction;
+function fields_actions_details_showfieldfunction($htmltable, $itemname, $values) {
+ $items = $htmltable->fields[0]['items'];
+ $action = $values['action'];
+ return fields_details_showfieldfunction($items, $action, $itemname);
+}
$htmllist_actions = new HaproxyHtmlList("table_actions", $fields_actions);
$htmllist_actions->fields_details = $fields_actions_details;
-//$htmllist_actions->keyfield = "name";
-//$htmllist_actions->editmode = true;
+$htmllist_actions->fields_details_showfieldfunction = fields_actions_details_showfieldfunction;
$htmllist_sslCertificates = new HaproxyHtmlList("tbl_sslCerts", $fields_sslCertificates);
$htmllist_caCertificates = new HaproxyHtmlList("tbl_caCerts", $fields_caCertificates );