ILIAS  release_8 Revision v8.24
class.ilSkillProfileUserTableGUI.php
Go to the documentation of this file.
1<?php
2
24
31{
37 protected int $requested_ref_id = 0;
38
39 public function __construct(
40 $a_parent_obj,
41 string $a_parent_cmd,
42 SkillProfile $a_profile
43 ) {
44 global $DIC;
45
46 $this->ctrl = $DIC->ctrl();
47 $this->lng = $DIC->language();
48 $this->access = $DIC->access();
49 $ilCtrl = $DIC->ctrl();
50 $lng = $DIC->language();
51 $ilAccess = $DIC->access();
52 $lng = $DIC->language();
53
54 $this->admin_gui_request = $DIC->skills()->internal()->gui()->admin_request();
55 $this->requested_ref_id = $this->admin_gui_request->getRefId();
56
57 $this->tree_access_manager = $DIC->skills()->internal()->manager()->getTreeAccessManager($this->requested_ref_id);
58 $this->profile_manager = $DIC->skills()->internal()->manager()->getProfileManager();
59
60 $this->profile = $a_profile;
61 parent::__construct($a_parent_obj, $a_parent_cmd);
62 $this->setData($this->profile_manager->getAssignments($this->profile->getId()));
63 $this->setTitle($lng->txt("skmg_assigned_users"));
64
65 if ($this->tree_access_manager->hasManageProfilesPermission() && !$this->profile->getRefId() > 0) {
66 $this->addColumn("", "", "1px", true);
67 $this->setSelectAllCheckbox("id[]");
68 }
69 $this->addColumn($this->lng->txt("type"), "type");
70 $this->addColumn($this->lng->txt("name"), "name");
71 $this->addColumn($this->lng->txt("object"), "object");
72 // $this->addColumn($this->lng->txt("actions"));
73
74 $this->setFormAction($ilCtrl->getFormAction($a_parent_obj));
75 $this->setRowTemplate("tpl.profile_user_row.html", "Services/Skill");
76
77 if ($this->tree_access_manager->hasManageProfilesPermission() && !$this->profile->getRefId() > 0) {
78 $this->addMultiCommand("confirmUserRemoval", $lng->txt("remove"));
79 }
80 //$this->addCommandButton("", $lng->txt(""));
81 }
82
83 protected function fillRow(array $a_set): void
84 {
86
87 $this->tpl->setVariable("TYPE", $a_set["type"]);
88 $this->tpl->setVariable("NAME", $a_set["name"]);
89 $this->tpl->setVariable("OBJECT", $a_set["object_title"]);
90 if ($this->tree_access_manager->hasManageProfilesPermission() && !$this->profile->getRefId() > 0) {
91 $this->tpl->setCurrentBlock("checkbox");
92 $this->tpl->setVariable("ID", $a_set["id"]);
93 $this->tpl->parseCurrentBlock();
94 }
95 }
96}
Request wrapper for guis in skill administration.
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
TableGUI class for skill profile user assignment.
__construct( $a_parent_obj, string $a_parent_cmd, SkillProfile $a_profile)
fillRow(array $a_set)
Standard Version of Fill Row.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setTitle(string $a_title, string $a_icon="", string $a_icon_alt="")
addMultiCommand(string $a_cmd, string $a_text)
setFormAction(string $a_form_action, bool $a_multipart=false)
addColumn(string $a_text, string $a_sort_field="", string $a_width="", bool $a_is_checkbox_action_column=false, string $a_class="", string $a_tooltip="", bool $a_tooltip_with_html=false)
setSelectAllCheckbox(string $a_select_all_checkbox, bool $a_select_all_on_top=false)
setRowTemplate(string $a_template, string $a_template_dir="")
Set row template.
setData(array $a_data)
Set table data.
ilLanguage $lng
global $DIC
Definition: feed.php:28
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc