From cc45c1df15653fee61e8d08e6211fdf78a7f1138 Mon Sep 17 00:00:00 2001 From: zeph Date: Sun, 23 Mar 2008 20:18:11 +0000 Subject: [PATCH] first container for sudo-ldap git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5-plugins@9960 594d385d-05f5-0310-b6e9-bd551577e9d8 --- sudo-ldap/src/class_sudoLdap.inc | 24 ++++++++++++++++++++++-- sudo-ldap/src/sudoldap.tpl | 14 ++++++++++++++ 2 files changed, 36 insertions(+), 2 deletions(-) create mode 100644 sudo-ldap/src/sudoldap.tpl diff --git a/sudo-ldap/src/class_sudoLdap.inc b/sudo-ldap/src/class_sudoLdap.inc index d6652aad6..bdbd9a1c9 100644 --- a/sudo-ldap/src/class_sudoLdap.inc +++ b/sudo-ldap/src/class_sudoLdap.inc @@ -46,9 +46,29 @@ class sudoLdap extends plugin /* Call parent execute */ plugin::execute(); $display= ""; + $smarty= get_smarty(); - $display = "execute()"; - + $RoleList = new divSelectBox("sudoRoles"); + $RoleList -> SetHeight(300); + $editImg = " + "; + /* + foreach($this->Zones as $zone => $values ){ + $link = "%s"; + $ZoneList->AddEntry(array( + array("string" => sprintf($link,base64_encode($zone),getNameFromMix($zone))), + array("string" => sprintf($link,base64_encode($zone),_("Reverse zone")." : ".getNameFromMix($values['ReverseZone']))), + array("string" => _("TTL")." : ".$values['sOAttl']), + array("string" => _("Class")." : ".$values['dNSClass']), + array("string" => str_replace("%s",base64_encode($zone),$editImg)) + )); + } + */ + + $smarty->assign("sudoldapACL",chkacl($this->acl,"sudoldap")); + + $smarty->assign("RoleList",$RoleList->DrawList()); + $display.= $smarty->fetch(get_template_path('sudoldap.tpl', TRUE)); return($display); } diff --git a/sudo-ldap/src/sudoldap.tpl b/sudo-ldap/src/sudoldap.tpl new file mode 100644 index 000000000..409f218c3 --- /dev/null +++ b/sudo-ldap/src/sudoldap.tpl @@ -0,0 +1,14 @@ + + + + +
+

{t}Sudo Roles{/t}

+ {$RoleList} + +
+ -- 2.30.2