ILIAS  eassessment Revision 61809
 All Data Structures Namespaces Files Functions Variables Groups Pages
class.ilPCListItemGUI.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/COPage/classes/class.ilPCListItem.php");
25 require_once("./Services/COPage/classes/class.ilPageContentGUI.php");
26 
38 {
39 
44  function ilPCListItemGUI(&$a_pg_obj, &$a_content_obj, $a_hier_id, $a_pc_id = "")
45  {
46  parent::ilPageContentGUI($a_pg_obj, $a_content_obj, $a_hier_id, $a_pc_id);
47  }
48 
52  function &executeCommand()
53  {
54  // get next class that processes or forwards current command
55  $next_class = $this->ctrl->getNextClass($this);
56 
57  // get current command
58  $cmd = $this->ctrl->getCmd();
59 
60  switch($next_class)
61  {
62  default:
63  $ret =& $this->$cmd();
64  break;
65  }
66 
67  return $ret;
68  }
69 
70 
74  function newItemAfter()
75  {
76  $this->content_obj->newItemAfter();
77  $_SESSION["il_pg_error"] = $this->pg_obj->update();
78  $this->ctrl->returnToParent($this, "jump".$this->hier_id);
79  }
80 
84  function newItemBefore()
85  {
86  $this->content_obj->newItemBefore();
87  $_SESSION["il_pg_error"] = $this->pg_obj->update();
88  $this->ctrl->returnToParent($this, "jump".$this->hier_id);
89  }
90 
94  function deleteItem()
95  {
96  $this->content_obj->deleteItem();
97  $_SESSION["il_pg_error"] = $this->pg_obj->update();
98  $this->ctrl->returnToParent($this, "jump".$this->hier_id);
99  }
100 
104  function moveItemDown()
105  {
106  $this->content_obj->moveItemDown();
107  $_SESSION["il_pg_error"] = $this->pg_obj->update();
108  $this->ctrl->returnToParent($this, "jump".$this->hier_id);
109  }
110 
114  function moveItemUp()
115  {
116  $this->content_obj->moveItemUp();
117  $_SESSION["il_pg_error"] = $this->pg_obj->update();
118  $this->ctrl->returnToParent($this, "jump".$this->hier_id);
119  }
120 
121 }
122 ?>