summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 951f5aa)
raw | patch | inline | side by side (parent: 951f5aa)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 26 Apr 2006 09:39:58 +0000 (09:39 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 26 Apr 2006 09:39:58 +0000 (09:39 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3114 594d385d-05f5-0310-b6e9-bd551577e9d8
index 76bf6e7d4bd577c8bf82dd821a714d337f8bc8e2..66a191fc89f11acfa5cd864ede95bae3de8e3d75 100644 (file)
--- a/include/class_plugin.inc
+++ b/include/class_plugin.inc
return($display);
}
- function postcreate()
+ function postcreate($add_attrs= array())
{
/* Find postcreate entries for this class */
$command= search_config($this->config->data['MENU'], get_class($this), "POSTCREATE");
}
}
$command= preg_replace("/%dn/", $this->dn, $command);
+
+ /* Additional attributes */
+ foreach ($add_attrs as $name => $value){
+ $command= preg_replace("/%$name/", $value, $command);
+ }
+
if (check_command($command)){
@DEBUG (DEBUG_SHELL, __LINE__, __FUNCTION__, __FILE__,
$command, "Execute");
}
}
- function postmodify()
+ function postmodify($add_attrs= array())
{
/* Find postcreate entries for this class */
$command= search_config($this->config->data['MENU'], get_class($this), "POSTMODIFY");
}
}
$command= preg_replace("/%dn/", $this->dn, $command);
+
+ /* Additional attributes */
+ foreach ($add_attrs as $name => $value){
+ $command= preg_replace("/%$name/", $value, $command);
+ }
+
if (check_command($command)){
@DEBUG (DEBUG_SHELL, __LINE__, __FUNCTION__, __FILE__,
$command, "Execute");
}
}
- function postremove()
+ function postremove($add_attrs= array())
{
/* Find postremove entries for this class */
$command= search_config($this->config->data['MENU'], get_class($this), "POSTREMOVE");
}
}
$command= preg_replace("/%dn/", $this->dn, $command);
+
+ /* Additional attributes */
+ foreach ($add_attrs as $name => $value){
+ $command= preg_replace("/%$name/", $value, $command);
+ }
+
if (check_command($command)){
@DEBUG (DEBUG_SHELL, __LINE__, __FUNCTION__, __FILE__,
$command, "Execute");
}
- function handle_post_events($mode)
+ function handle_post_events($mode, $add_attrs= array())
{
switch ($mode){
case "add":
- $this->postcreate();
+ $this->postcreate($add_attrs);
break;
case "modify":
- $this->postmodify();
+ $this->postmodify($add_attrs);
break;
case "remove":
- $this->postremove();
+ $this->postremove($add_attrs);
break;
}
}
index d800479f5250d77703252f142527028a348b68ed..570c3ec2c4476cdad0d2159a3a52e430335bf11a 100644 (file)
@@ -250,20 +250,20 @@ function schema_check($server, $admin, $password, $aff=0,$CalledByIndexPhP=false
/* Fix for PHP Fehler "Undefined index: ldapconf"
* Ablaufverfolgung[1]: Funktion schema_check Datei: /home/hickert/gosa/include/functions_setup.inc (Zeile 230)
*/
- if((isset($_SESSION['ldapconf']['mail_methods']))&&(isset($_SESSION['ldapconf']))){
- if(($_SESSION['ldapconf']['mail_methods'][$_SESSION['ldapconf']['mail']] == "kolab")&&(!$CalledByIndexPhP)){
- if(!isset($objectclasses['kolabInetOrgPerson'])) {
- $messages['kolab']['msg']= _("Support for Kolab disabled, no schema seems to be installed, setting mail-method to cyrus");
- $affich['kolab']['msg']=$messages['kolab']['msg']."<td class=\"check\">kolab2.schema</td>";
- $tmp= array_flip($_SESSION['ldapconf']['mail_methods']);
- $_SESSION['ldapconf']['mail']=$tmp['cyrus'];
- $messages['kolab']['status']= FALSE;
- $affich['kolab']['status']= FALSE;
- }else{
- $affich['kolab']['msg']=_("Support for Kolab enabled")."<td class=\"check\">gofon.schema</td>";
- $affich['kolab']['status']= TRUE;
- }
- }
+ if(isset($_SESSION['ldapconf']['mail_methods'])){
+ if(($_SESSION['ldapconf']['mail_methods'][$_SESSION['ldapconf']['mail']] == "kolab")&&(!$CalledByIndexPhP)){
+ if(!isset($objectclasses['kolabInetOrgPerson'])) {
+ $messages['kolab']['msg']= _("Support for Kolab disabled, no schema seems to be installed, setting mail-method to cyrus");
+ $affich['kolab']['msg']=$messages['kolab']['msg']."<td class=\"check\">kolab2.schema</td>";
+ $tmp= array_flip($_SESSION['ldapconf']['mail_methods']);
+ $_SESSION['ldapconf']['mail']=$tmp['cyrus'];
+ $messages['kolab']['status']= FALSE;
+ $affich['kolab']['status']= FALSE;
+ }else{
+ $affich['kolab']['msg']=_("Support for Kolab enabled")."<td class=\"check\">gofon.schema</td>";
+ $affich['kolab']['status']= TRUE;
+ }
+ }
}
if($aff==0){
return ($messages);
diff --git a/plugins/admin/fai/class_faiTemplateEntry.inc b/plugins/admin/fai/class_faiTemplateEntry.inc
index a82b75ec0996fd298dbb71b01f0a4dd504994c7f..57eee41245f8440b826e34ff19138ea7672279f2 100644 (file)
}else{
$this->status = "new";
- $this->orig_cn = false;
+ $this->orig_cn= false;
}
$this->user = explode( '.', $this->FAIowner );
function execute()
{
- /* Call parent execute */
- plugin::execute();
+ /* Call parent execute */
+ plugin::execute();
/* Fill templating stuff */
$smarty = get_smarty();
diff --git a/plugins/admin/systems/class_workstationGeneric.inc b/plugins/admin/systems/class_workstationGeneric.inc
index 68b41f95672fa073a1c610c09d31f110acaffa39..0748e91381d97067f6bd15153166eba19dc9703e 100644 (file)
show_ldap_error($ldap->get_error());
/* Optionally execute a command after we're done */
- $this->handle_post_events("remove");
+ $this->handle_post_events("remove", array("macAddress", $this->netConfigDNS->macAddress));
/* Delete references to object groups */
$ldap->cd ($this->config->current['BASE']);