From 3d7b65f57b4ec5d832611aff0064ee4a5b00fe2d Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 19 Jul 2006 03:40:07 +0000 Subject: [PATCH] Replaced 'show_header' with 'show_disable_header' && 'show_enable_header' git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@4210 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/acl/class_aclManagement.inc | 1 - .../applications/class_applicationManagement.inc | 1 - .../applications/class_applicationParameters.inc | 4 ++-- plugins/admin/groups/class_groupApplication.inc | 4 ++-- plugins/admin/groups/class_groupMail.inc | 4 ++-- plugins/admin/groups/class_groupManagement.inc | 1 - .../admin/mimetypes/class_mimetypeManagement.inc | 1 - plugins/admin/ogroups/class_mailogroup.inc | 4 ++-- plugins/admin/ogroups/class_phonequeue.inc | 4 ++-- plugins/admin/systems/class_glpiAccount.inc | 4 ++-- .../admin/systems/class_glpiPrinterAccount.inc | 4 ++-- plugins/admin/systems/class_inventory.inc | 4 ++-- plugins/admin/systems/class_printGeneric.inc | 16 ++++++++-------- plugins/admin/systems/class_servDHCP.inc | 4 ++-- plugins/admin/systems/class_servDNS.inc | 4 ++-- plugins/admin/users/class_userManagement.inc | 1 - plugins/gofax/faxaccount/class_gofaxAccount.inc | 4 ++-- .../gofon/phoneaccount/class_phoneAccount.inc | 6 +++--- plugins/personal/mail/class_mailAccount.inc | 4 ++-- plugins/personal/nagios/class_nagiosAccount.inc | 4 ++-- plugins/personal/netatalk/class_netatalk.inc | 6 +++--- plugins/personal/samba/class_sambaAccount.inc | 6 +++--- 22 files changed, 43 insertions(+), 48 deletions(-) diff --git a/plugins/admin/acl/class_aclManagement.inc b/plugins/admin/acl/class_aclManagement.inc index a0d333196..4b85ff9bf 100644 --- a/plugins/admin/acl/class_aclManagement.inc +++ b/plugins/admin/acl/class_aclManagement.inc @@ -359,7 +359,6 @@ class aclManagement extends plugin function save() { } function adapt_from_template($dn) { } function password_change_needed() { } - function show_header($button_text, $text, $disabled= FALSE) { } } // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: diff --git a/plugins/admin/applications/class_applicationManagement.inc b/plugins/admin/applications/class_applicationManagement.inc index 4cb3ccd04..7f6ee679e 100644 --- a/plugins/admin/applications/class_applicationManagement.inc +++ b/plugins/admin/applications/class_applicationManagement.inc @@ -492,7 +492,6 @@ class applicationManagement extends plugin function check() {} function adapt_from_template($dn) {} function password_change_needed() {} - function show_header($button_text, $text, $disabled= FALSE) {} } // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: ?> diff --git a/plugins/admin/applications/class_applicationParameters.inc b/plugins/admin/applications/class_applicationParameters.inc index c803aff4d..0de056040 100644 --- a/plugins/admin/applications/class_applicationParameters.inc +++ b/plugins/admin/applications/class_applicationParameters.inc @@ -49,10 +49,10 @@ class applicationParameters extends plugin $display= ""; if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove options"), + $display= $this->show_disable_header(_("Remove options"), _("This application has options. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Create options"), + $display= $this->show_enable_header(_("Create options"), _("This application has options disabled. You can enable them by clicking below.")); $this->parent->by_object['application']->generateTemplate(); return ($display); diff --git a/plugins/admin/groups/class_groupApplication.inc b/plugins/admin/groups/class_groupApplication.inc index 9fffda879..722864249 100644 --- a/plugins/admin/groups/class_groupApplication.inc +++ b/plugins/admin/groups/class_groupApplication.inc @@ -398,10 +398,10 @@ class appgroup extends plugin $display= ""; if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove applications"), + $display= $this->show_disable_header(_("Remove applications"), _("This group has application features enabled. You can disable them by clicking below.")); } else { - $display.= $this->show_header(_("Create applications"), + $display.= $this->show_enable_header(_("Create applications"), _("This group has application features disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/admin/groups/class_groupMail.inc b/plugins/admin/groups/class_groupMail.inc index c78710ef2..233f11203 100644 --- a/plugins/admin/groups/class_groupMail.inc +++ b/plugins/admin/groups/class_groupMail.inc @@ -317,10 +317,10 @@ class mailgroup extends plugin $display= ""; if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove mail account"), + $display= $this->show_disable_header(_("Remove mail account"), _("This account has mail features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Create mail account"), + $display= $this->show_enable_header(_("Create mail account"), _("This account has mail features disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/admin/groups/class_groupManagement.inc b/plugins/admin/groups/class_groupManagement.inc index 2d2bc5248..637abae5b 100644 --- a/plugins/admin/groups/class_groupManagement.inc +++ b/plugins/admin/groups/class_groupManagement.inc @@ -567,7 +567,6 @@ class groupManagement extends plugin function check() { } function adapt_from_template($dn) { } function password_change_needed() { } - function show_header($button_text, $text, $disabled= FALSE) { } } // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: ?> diff --git a/plugins/admin/mimetypes/class_mimetypeManagement.inc b/plugins/admin/mimetypes/class_mimetypeManagement.inc index f503455d9..52f91ddc8 100755 --- a/plugins/admin/mimetypes/class_mimetypeManagement.inc +++ b/plugins/admin/mimetypes/class_mimetypeManagement.inc @@ -501,7 +501,6 @@ class mimetypeManagement extends plugin function check() {} function adapt_from_template($dn) {} function password_change_needed() {} - function show_header($button_text, $text, $disabled= FALSE) {} } // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: ?> diff --git a/plugins/admin/ogroups/class_mailogroup.inc b/plugins/admin/ogroups/class_mailogroup.inc index b11190942..0fb270913 100644 --- a/plugins/admin/ogroups/class_mailogroup.inc +++ b/plugins/admin/ogroups/class_mailogroup.inc @@ -37,10 +37,10 @@ class mailogroup extends plugin /* Show tab dialog headers */ if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove mail account"), + $display= $this->show_disable_header(_("Remove mail account"), _("This group has mail features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Create mail account"), _("This group has mail features disabled. You can enable them by clicking below.")); + $display= $this->show_enable_header(_("Create mail account"), _("This group has mail features disabled. You can enable them by clicking below.")); return ($display); } } diff --git a/plugins/admin/ogroups/class_phonequeue.inc b/plugins/admin/ogroups/class_phonequeue.inc index f194328ba..22f235db2 100644 --- a/plugins/admin/ogroups/class_phonequeue.inc +++ b/plugins/admin/ogroups/class_phonequeue.inc @@ -110,10 +110,10 @@ class phonequeue extends plugin /* Show tab dialog headers */ if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove the phone queue from this Account"), + $display= $this->show_disable_header(_("Remove the phone queue from this Account"), _("Phone queue is enabled for this group. You can disable it by clicking below.")); } else { - $display= $this->show_header(_("Create phone queue"), + $display= $this->show_enable_header(_("Create phone queue"), _("For this group the phone queues are disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/admin/systems/class_glpiAccount.inc b/plugins/admin/systems/class_glpiAccount.inc index fc967d3b1..65a9b7609 100644 --- a/plugins/admin/systems/class_glpiAccount.inc +++ b/plugins/admin/systems/class_glpiAccount.inc @@ -562,10 +562,10 @@ class glpiAccount extends plugin /* Show tab dialog headers */ if ($this->is_account){ - $display= $this->show_header(_("Remove inventory"), + $display= $this->show_disable_header(_("Remove inventory"), _("This device has inventory informations enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Add inventory"), + $display= $this->show_enable_header(_("Add inventory"), _("This device has inventory informations disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/admin/systems/class_glpiPrinterAccount.inc b/plugins/admin/systems/class_glpiPrinterAccount.inc index f9b0348ff..5af98b686 100644 --- a/plugins/admin/systems/class_glpiPrinterAccount.inc +++ b/plugins/admin/systems/class_glpiPrinterAccount.inc @@ -196,10 +196,10 @@ class glpiPrinterAccount extends plugin /* Show tab dialog headers */ if ($this->is_account){ - $display= $this->show_header(_("Remove inventory"), + $display= $this->show_disable_header(_("Remove inventory"), _("This server has inventory features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Add inventory"), + $display= $this->show_enable_header(_("Add inventory"), _("This server has inventory features disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/admin/systems/class_inventory.inc b/plugins/admin/systems/class_inventory.inc index be90e46e1..e23eeddd2 100644 --- a/plugins/admin/systems/class_inventory.inc +++ b/plugins/admin/systems/class_inventory.inc @@ -33,10 +33,10 @@ class inventory extends plugin /* Show tab dialog headers */ if ($this->is_account){ - $display= $this->show_header(_("Remove DNS service"), + $display= $this->show_disable_header(_("Remove DNS service"), _("This server has DNS features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Add DNS service"), + $display= $this->show_enable_header(_("Add DNS service"), _("This server has DNS features disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/admin/systems/class_printGeneric.inc b/plugins/admin/systems/class_printGeneric.inc index 770cf15cc..736172021 100644 --- a/plugins/admin/systems/class_printGeneric.inc +++ b/plugins/admin/systems/class_printGeneric.inc @@ -229,7 +229,7 @@ class printgeneric extends plugin * hide this tab. */ if($this->BelongsTo == "unknown"){ - $display= $this->show_header(_("Add printer extension"), + $display= $this->show_enable_header(_("Add printer extension"), _("Could not intialize printer tab, parameter parent was missing while construction."),TRUE,TRUE); return($display); } @@ -237,12 +237,12 @@ class printgeneric extends plugin /* Templates can't have printer extensions */ if($this->BelongsTo == "WorkstationTemplate"){ - $display= $this->show_header(_("Add printer extension"), + $display= $this->show_enable_header(_("Add printer extension"), _("This is a workstation template, printer tab is disabled."),TRUE,TRUE); return($display); } if($this->BelongsTo == "TerminalTemplate"){ - $display= $this->show_header(_("Add printer extension"), + $display= $this->show_enable_header(_("Add printer extension"), _("This is a terminal template, printer tab is disabled."),TRUE,TRUE); return($display); } @@ -281,7 +281,7 @@ class printgeneric extends plugin /* If this is a WS / Terminal depending printer, display account state button */ if($this->BelongsTo != "Printer"){ if((empty($this->cn)) && ($this->dn != "new")){ - $display= $this->show_header(_("Add printer extension"), + $display= $this->show_enable_header(_("Add printer extension"), _("This object has printer extension disabled. You can't enable it while 'cn' is not present in entry. Possibly you are currently creating a new terminal template"),TRUE,TRUE); $this->is_account= false; return $display; @@ -289,18 +289,18 @@ class printgeneric extends plugin if (($this->is_account)){ if($this->BelongsTo=="Workstation"){ - $display= $this->show_header(_("Remove printer extension"), + $display= $this->show_disable_header(_("Remove printer extension"), _("This workstation has printer extension enabled.You can disable it by clicking below.")); }elseif($this->BelongsTo=="Terminal"){ - $display= $this->show_header(_("Remove printer extension"), + $display= $this->show_disable_header(_("Remove printer extension"), _("This terminal has printer extension enabled. You can disable it by clicking below.")); } }else{ if($this->BelongsTo=="Workstation"){ - $display= $this->show_header(_("Add printer extension"), + $display= $this->show_disable_header(_("Add printer extension"), _("This workstation has printer extension disabled. You can enable it by clicking below.")); }elseif($this->BelongsTo=="Terminal"){ - $display= $this->show_header(_("Add printer extension"), + $display= $this->show_enable_header(_("Add printer extension"), _("This terminal has printer extension disabled. You can enable it by clicking below.")); } return ($display); diff --git a/plugins/admin/systems/class_servDHCP.inc b/plugins/admin/systems/class_servDHCP.inc index 8d468f948..8b4e9a878 100644 --- a/plugins/admin/systems/class_servDHCP.inc +++ b/plugins/admin/systems/class_servDHCP.inc @@ -33,10 +33,10 @@ class servdhcp extends plugin /* Show tab dialog headers */ if ($this->is_account){ - $display= $this->show_header(_("Remove DHCP service"), + $display= $this->show_disable_header(_("Remove DHCP service"), _("This server has DHCP features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Add DHCP service"), + $display= $this->show_enable_header(_("Add DHCP service"), _("This server has DHCP features disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/admin/systems/class_servDNS.inc b/plugins/admin/systems/class_servDNS.inc index 6c1307d25..f44efc030 100644 --- a/plugins/admin/systems/class_servDNS.inc +++ b/plugins/admin/systems/class_servDNS.inc @@ -70,10 +70,10 @@ class servdns extends plugin } if ($this->is_account){ - $display= $this->show_header(_("Remove DNS service"), + $display= $this->show_disable_header(_("Remove DNS service"), _("This server has DNS features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Add DNS service"), + $display= $this->show_enable_header(_("Add DNS service"), _("This server has DNS features disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/admin/users/class_userManagement.inc b/plugins/admin/users/class_userManagement.inc index fada1c853..361586706 100644 --- a/plugins/admin/users/class_userManagement.inc +++ b/plugins/admin/users/class_userManagement.inc @@ -833,7 +833,6 @@ class userManagement extends plugin function save() { } function adapt_from_template($dn) { } function password_change_needed() { } - function show_header($button_text, $text, $disabled= FALSE) { } } /* ... class userManagement */ // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: diff --git a/plugins/gofax/faxaccount/class_gofaxAccount.inc b/plugins/gofax/faxaccount/class_gofaxAccount.inc index 5c4c8749a..d106b88cd 100644 --- a/plugins/gofax/faxaccount/class_gofaxAccount.inc +++ b/plugins/gofax/faxaccount/class_gofaxAccount.inc @@ -143,10 +143,10 @@ class gofaxAccount extends plugin $display= ""; if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove fax account"), + $display= $this->show_disable_header(_("Remove fax account"), _("This account has fax features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Create fax account"), + $display= $this->show_enable_header(_("Create fax account"), _("This account has fax features disabled. You can enable them by clicking below.")); return ($display); } diff --git a/plugins/gofon/phoneaccount/class_phoneAccount.inc b/plugins/gofon/phoneaccount/class_phoneAccount.inc index 275a1b44b..5b70424b8 100644 --- a/plugins/gofon/phoneaccount/class_phoneAccount.inc +++ b/plugins/gofon/phoneaccount/class_phoneAccount.inc @@ -748,14 +748,14 @@ class phoneAccount extends plugin /* Show tab dialog headers */ if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove phone account"), + $display= $this->show_disable_header(_("Remove phone account"), _("This account has phone features enabled. You can disable them by clicking below.")); } else { if(empty($this->uid)){ - $display= $this->show_header(_("Create phone account"), + $display= $this->show_enable_header(_("Create phone account"), _("This account has phone features disabled. You can't enable them while no uid is set."),TRUE,TRUE); }else{ - $display= $this->show_header(_("Create phone account"), + $display= $this->show_enable_header(_("Create phone account"), _("This account has phone features disabled. You can enable them by clicking below.")); } return ($display); diff --git a/plugins/personal/mail/class_mailAccount.inc b/plugins/personal/mail/class_mailAccount.inc index 574b16ea4..ecda1e744 100644 --- a/plugins/personal/mail/class_mailAccount.inc +++ b/plugins/personal/mail/class_mailAccount.inc @@ -255,10 +255,10 @@ class mailAccount extends plugin /* Show tab dialog headers */ if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove mail account"), + $display= $this->show_disable_header(_("Remove mail account"), _("This account has mail features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Create mail account"), _("This account has mail features disabled. You can enable them by clicking below.")); + $display= $this->show_enable_header(_("Create mail account"), _("This account has mail features disabled. You can enable them by clicking below.")); return ($display); } } diff --git a/plugins/personal/nagios/class_nagiosAccount.inc b/plugins/personal/nagios/class_nagiosAccount.inc index e2ea3aa0e..3809cb58a 100644 --- a/plugins/personal/nagios/class_nagiosAccount.inc +++ b/plugins/personal/nagios/class_nagiosAccount.inc @@ -98,10 +98,10 @@ class nagiosAccount extends plugin /* Show tab dialog headers */ if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove nagios account"), + $display= $this->show_disable_header(_("Remove nagios account"), _("This account has nagios features enabled. You can disable them by clicking below.")); } else { - $display= $this->show_header(_("Create nagios account"), _("This account has nagios features disabled. You can enable them by clicking below.")); + $display= $this->show_enable_header(_("Create nagios account"), _("This account has nagios features disabled. You can enable them by clicking below.")); return($display); } } diff --git a/plugins/personal/netatalk/class_netatalk.inc b/plugins/personal/netatalk/class_netatalk.inc index 9b3e3db36..177ec4daf 100644 --- a/plugins/personal/netatalk/class_netatalk.inc +++ b/plugins/personal/netatalk/class_netatalk.inc @@ -130,7 +130,7 @@ class netatalk extends plugin { /* Show tab dialog headers */ if ($this->parent != NULL) { if ($this->is_account) { - $display = $this->show_header(_("Remove netatalk account"), _("This account has netatalk features enabled. You can disable them by clicking below.")); + $display = $this->show_disable_header(_("Remove netatalk account"), _("This account has netatalk features enabled. You can disable them by clicking below.")); } else { $errmsg=""; $obj = $this->parent->by_object['posixAccount']; @@ -141,9 +141,9 @@ class netatalk extends plugin { $errmsg.="At least one share with netatalk or NFS mount entry needed."; } if($errmsg==""){ - $display = $this->show_header(_("Create netatalk account"), _("This account has netatalk features disabled. You can enable them by clicking below.")); + $display = $this->show_enable_header(_("Create netatalk account"), _("This account has netatalk features disabled. You can enable them by clicking below.")); } else { - $display = $this->show_header(_("Create netatalk account"), _($errmsg), TRUE); + $display = $this->show_enable_header(_("Create netatalk account"), _($errmsg), TRUE); } return ($display); } diff --git a/plugins/personal/samba/class_sambaAccount.inc b/plugins/personal/samba/class_sambaAccount.inc index 7f548f72a..e06123a0c 100644 --- a/plugins/personal/samba/class_sambaAccount.inc +++ b/plugins/personal/samba/class_sambaAccount.inc @@ -204,7 +204,7 @@ class sambaAccount extends plugin $display= ""; if ($this->parent != NULL){ if ($this->is_account){ - $display= $this->show_header(_("Remove samba account"), + $display= $this->show_disable_header(_("Remove samba account"), _("This account has samba features enabled. You can disable them by clicking below.")); } else { $obj= $this->parent->by_object['posixAccount']; @@ -215,10 +215,10 @@ class sambaAccount extends plugin on. */ if ($obj->is_account){ - $display= $this->show_header(_("Create samba account"), + $display= $this->show_enable_header(_("Create samba account"), _("This account has samba features disabled. You can enable them by clicking below.")); } else { - $display= $this->show_header(_("Create samba account"), + $display= $this->show_enable_header(_("Create samba account"), _("This account has samba features disabled. Posix features are needed for samba accounts, enable them first."), TRUE); } return ($display); -- 2.30.2