ILIAS  release_4-3 Revision
 All Data Structures Namespaces Files Functions Variables Groups Pages
class.ilObjCategoryAccess.php
Go to the documentation of this file.
1 <?php
2 
3 /* Copyright (c) 1998-2012 ILIAS open source, Extended GPL, see docs/LICENSE */
4 
5 include_once("./Services/Object/classes/class.ilObjectAccess.php");
6 
17 {
18 
31  function _getCommands()
32  {
33  $commands = array();
34  $commands[] = array("permission" => "read", "cmd" => "render", "lang_var" => "show", "default" => true);
35 
36 
37  // begin-patch fm
38  include_once './Services/WebServices/FileManager/classes/class.ilFMSettings.php';
39  if(ilFMSettings::getInstance()->isEnabled())
40  {
41  $commands[] = array(
42  'permission' => 'read',
43  'cmd' => 'fileManagerLaunch',
44  'lang_var' => 'fm_start',
45  'enable_anonymous' => false
46  );
47  }
48  // end-patch fm
49 
50  // BEGIN WebDAV
51  require_once ('Services/WebDAV/classes/class.ilDAVActivationChecker.php');
53  {
54  include_once './Services/WebDAV/classes/class.ilDAVUtils.php';
55  if(ilDAVUtils::getInstance()->isLocalPasswordInstructionRequired())
56  {
57  $commands[] = array('permission' => 'read', 'cmd' => 'showPasswordInstruction', 'lang_var' => 'mount_webfolder', 'enable_anonymous' => 'false');
58  }
59  else
60  {
61  $commands[] = array("permission" => "read", "cmd" => "mount_webfolder", "lang_var" => "mount_webfolder", "enable_anonymous" => "false");
62  }
63  }
64  // END WebDAV
65  $commands[] = array("permission" => "write", "cmd" => "enableAdministrationPanel", "lang_var" => "edit_content");
66  $commands[] = array("permission" => "write", "cmd" => "edit", "lang_var" => "settings");
67 
68  return $commands;
69  }
70 
74  function _checkGoto($a_target)
75  {
76  global $ilAccess;
77 
78  $t_arr = explode("_", $a_target);
79 
80  if ($t_arr[0] != "cat" || ((int) $t_arr[1]) <= 0)
81  {
82  return false;
83  }
84 
85  if ($ilAccess->checkAccess("read", "", $t_arr[1]))
86  {
87  return true;
88  }
89  return false;
90  }
91 }
92 
93 ?>