Code

Added remove confirm dialog
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 19 May 2011 08:19:23 +0000 (08:19 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 19 May 2011 08:19:23 +0000 (08:19 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20875 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/goto-ng/admin/newConfigManagement/class_ConfigManagement.inc
gosa-plugins/goto-ng/admin/newConfigManagement/class_cfgMgmtMangement.inc

index 0b23aaae806bcf680d9243d7d479d82a62376bcc..20cbecf3356905198205dd550a6605b19cf13833 100644 (file)
@@ -530,6 +530,28 @@ class ConfigManagement extends plugin
      */
     function removeEntry($ids)
     {
+        $this->ids = $ids;
+       
+        $names = array();
+        foreach($ids as $id){
+            $item = $this->dataModel->getItemByDn($id);
+            $names["({$item['type']}) {$item['path']})"] = $item['name'];
+        }
+
+        $smarty = get_smarty();
+        $smarty = get_smarty();
+        $smarty->assign("info", msgPool::deleteInfo($names));
+        $smarty->assign("multiple", true);
+
+        return($smarty->fetch(get_template_path('removeEntries.tpl')));
+    }
+
+    function remove_confirmed()
+    {
+        echo 'timmay';
+        return;
+
+        $ids = $this->ids;
         foreach($ids as $id){
             $item = $this->dataModel->getItemByDn($id);
 
index 7d6f06678286636be4513cc2c31e5cae9fe30d1e..3ea534deb44eab8a1c8926d0e776e6d2f9a5bdb6 100644 (file)
@@ -233,6 +233,12 @@ class cfgMgmtMangement extends management
 
     }
 
+    function removeEntryConfirmed($action="",$target=array(),$all=array(),
+            $altTabClass="",$altTabType="",  $altAclCategory="",$altAclPlugin="")
+    {
+        return($this->parent->remove_confirmed());
+    }
+
     function saveItemChanges()
     {
         $this->parent->saveItemChanges();
@@ -240,7 +246,7 @@ class cfgMgmtMangement extends management
 
     function removeEntryRequested($action="",$target=array(),$all=array(), $altTabClass ="", $altTabType = "", $altAclCategory="")
     {
-        $this->parent->removeEntry($target);
+        return($this->parent->removeEntry($target));
     }
 
     function newEntry($action="",$target=array(),$all=array(), $altTabClass ="", $altTabType = "", $altAclCategory="")