ILIAS  release_7 Revision v7.30-3-g800a261c036
All Data Structures Namespaces Files Functions Variables Modules Pages
class.ilPortfolioPageConfig.php
Go to the documentation of this file.
1 <?php
2 
3 /* Copyright (c) 1998-2019 ILIAS open source, Extended GPL, see docs/LICENSE */
4 
11 {
15  protected $settings;
16 
20  protected $rbacsystem;
21 
25  public function init()
26  {
27  global $DIC;
28 
29  $this->settings = $DIC->settings();
30  $this->rbacsystem = $DIC->rbac()->system();
31 
34 
35  $prfa_set = new ilSetting("prfa");
36  $this->setPreventHTMLUnmasking(!(bool) $prfa_set->get("mask", false));
37 
38  $this->setEnableInternalLinks(true);
39  $this->setIntLinkFilterWhiteList(true);
40  $this->addIntLinkFilter("User");
41  $this->addIntLinkFilter("PortfolioPage");
42  $this->removeIntLinkFilter("File");
43  $this->setIntLinkHelpDefaultId($_GET["prt_id"], false);
44  $this->setIntLinkHelpDefaultType("PortfolioPage");
45  $this->setEnablePCType("Profile", true);
46  $this->setEditLockSupport(false);
47 
48  $validator = new ilCertificateActiveValidator();
49  if (true === $validator->validate()) {
50  $this->setEnablePCType("Verification", true);
51  }
52  $skmg_set = new ilSetting("skmg");
53  if ($skmg_set->get("enable_skmg")) {
54  $this->setEnablePCType("Skills", true);
55  }
56 
58  if ($settings->isEnabled() &&
59  $rbacsystem->checkAccess('add_consultation_hours', $settings->getCalendarSettingsId()) &&
60  $settings->areConsultationHoursEnabled()) {
61  $this->setEnablePCType("ConsultationHours", true);
62  }
63 
64  $prfa_set = new ilSetting("prfa");
65  if ($prfa_set->get("mycrs", true)) {
66  $this->setEnablePCType("MyCourses", true);
67  }
68 
69  $mset = new ilSetting("mobs");
70  if ($mset->get("mep_activate_pages")) {
71  $this->setEnablePCType("ContentInclude", true);
72  }
73 
74  $this->setEnablePCType("LearningHistory", true);
75  }
76 }
static _getInstance()
get singleton instance
setEnablePCType($a_pc_type, $a_val)
Set enable pc type.
settings()
Definition: settings.php:2
setIntLinkHelpDefaultType($a_val)
Set internal link default type.
$_GET["client_id"]
removeIntLinkFilter($a_val)
Remove int link filter.
Config class for page editing.
global $DIC
Definition: goto.php:24
setEnableInternalLinks($a_enabledinternallinks)
Set Enable internal links.
Portfolio page configuration.
global $ilSetting
Definition: privfeed.php:17
setPreventHTMLUnmasking($a_preventhtmlunmasking)
Set Prevent HTML Unmasking (true/false).
addIntLinkFilter($a_val)
Add internal links filter.
setEditLockSupport($a_val)
setIntLinkFilterWhiteList($a_white_list)
Set internal links filter type list to white list.
setIntLinkHelpDefaultId($a_val, $a_is_ref=true)
Set internal link default id.