ILIAS  Release_5_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
class.ilObjRecoveryFolderGUI.php
Go to the documentation of this file.
1 <?php
2 /*
3  +-----------------------------------------------------------------------------+
4  | ILIAS open source |
5  +-----------------------------------------------------------------------------+
6  | Copyright (c) 1998-2001 ILIAS open source, University of Cologne |
7  | |
8  | This program is free software; you can redistribute it and/or |
9  | modify it under the terms of the GNU General Public License |
10  | as published by the Free Software Foundation; either version 2 |
11  | of the License, or (at your option) any later version. |
12  | |
13  | This program is distributed in the hope that it will be useful, |
14  | but WITHOUT ANY WARRANTY; without even the implied warranty of |
15  | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16  | GNU General Public License for more details. |
17  | |
18  | You should have received a copy of the GNU General Public License |
19  | along with this program; if not, write to the Free Software |
20  | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
21  +-----------------------------------------------------------------------------+
22 */
23 
24 require_once "./Services/Container/classes/class.ilContainerGUI.php";
25 
37 {
42  function ilObjRecoveryFolderGUI($a_data,$a_id,$a_call_by_reference)
43  {
44  $this->type = "recf";
45  $this->ilObjectGUI($a_data,$a_id,$a_call_by_reference,false);
46  }
47 
52  function saveObject()
53  {
54  global $rbacadmin;
55 
56  // create and insert forum in objecttree
57  $newObj = parent::saveObject();
58 
59  // put here object specific stuff
60 
61  // always send a message
62  ilUtil::sendSuccess($this->lng->txt("object_added"),true);
63  exit();
64  }
65 
67  {
68  global $rbacsystem;
69 
70  include_once("./Services/Repository/classes/class.ilRepUtilGUI.php");
71  $ru = new ilRepUtilGUI($this);
72  $ru->removeObjectsFromSystem($_POST["id"], true);
73  $this->ctrl->redirect($this, "view");
74  }
75 
76  function &executeCommand()
77  {
78  $next_class = $this->ctrl->getNextClass($this);
79  $cmd = $this->ctrl->getCmd();
80  $this->prepareOutput();
81 
82  switch($next_class)
83  {
84  case 'ilpermissiongui':
85  include_once("Services/AccessControl/classes/class.ilPermissionGUI.php");
86  $perm_gui =& new ilPermissionGUI($this);
87  $ret =& $this->ctrl->forwardCommand($perm_gui);
88  break;
89 
90  default:
91  if(!$cmd)
92  {
93  $cmd = "view";
94  }
95  $cmd .= "Object";
96  $this->$cmd();
97 
98  break;
99  }
100  return true;
101  }
102 
103 
105  {
106  $this->sub_objects = "";
107  }
108 
112  function getActions()
113  {
114  // standard actions for container
115  return array(
116  "cut" => array("name" => "cut", "lng" => "cut"),
117  "clear" => array("name" => "clear", "lng" => "clear"),
118  "removeFromSystem" => array("name" => "removeFromSystem", "lng" => "btn_remove_system")
119  );
120  }
121 
122 } // END class.ilObjRecoveryFolderGUI
123 ?>