From: hickert Date: Wed, 12 Mar 2008 14:41:18 +0000 (+0000) Subject: Added delete Info X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=c39c7f46e966de42f59ba07fd721d778434a0857;p=gosa.git Added delete Info git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9718 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/class_MultiSelectWindow.inc b/gosa-core/include/class_MultiSelectWindow.inc index fee26be03..f258f944b 100644 --- a/gosa-core/include/class_MultiSelectWindow.inc +++ b/gosa-core/include/class_MultiSelectWindow.inc @@ -449,7 +449,7 @@ class MultiSelectWindow{ /* Check for exeeded sizelimit */ $smarty->assign("hint" , print_sizelimit_warning()); - $smarty->assign("DivList" , $divlist->DrawList().$this->footer); + $smarty->assign("DivList" , $divlist->DrawList()."\n\n\n\n\n".$this->footer."\n\n\n\n\n"); if($this->is_headpage){ $smarty->assign("tree_image", get_template_path('images/tree.png')); diff --git a/gosa-core/include/utils/class_msgPool.inc b/gosa-core/include/utils/class_msgPool.inc index c8831f325..3c14c4eb2 100644 --- a/gosa-core/include/utils/class_msgPool.inc +++ b/gosa-core/include/utils/class_msgPool.inc @@ -8,6 +8,37 @@ define ("LDAP_AUTH", 6); class msgPool { + public static function deleteInfo($name= "",$type = "") + { + if ($name == "") { + if($type == ""){ + return (_("You are going to delete this object!")); + }else{ + return (sprintf(_("You are going to delete this '%s' object!"),$type)); + } + } + if (!is_array($name)){ + if($type == ""){ + return (_("You are going to delete this object:")."

$name"); + }else{ + return (sprintf(_("You are going to delete the '%s' object:"),$type)."

$name"); + } + } + if (count($name) == 1){ + if($type == ""){ + return (_("You are going to delete this object:")."
".msgPool::buildList($name)); + }else{ + return (sprintf(_("You are going to delete the '%s' object:"),$type)."
".msgPool::buildList($name)); + } + } + if($type == ""){ + return (_("You are going to delete these objects:")."
".msgPool::buildList($name)); + }else{ + return (sprintf(_("You are going to delete these '%s' objects:"),$type)."
".msgPool::buildList($name)); + } + } + + public static function permDelete($name= "") { if ($name == "") { @@ -284,7 +315,7 @@ class msgPool public static function buildList($data) { $objects= ""; - foreach ($name as $key => $value){ + foreach ($data as $key => $value){ if (is_numeric($key)){ $objects.= "
\n$value"; } else {