ILIAS  trunk Revision v11.0_alpha-2662-g519ff7d528f
ILIAS\Container\Skills\ContSkillMemberTableBuilder Class Reference
+ Inheritance diagram for ILIAS\Container\Skills\ContSkillMemberTableBuilder:
+ Collaboration diagram for ILIAS\Container\Skills\ContSkillMemberTableBuilder:

Public Member Functions

 __construct (protected SkillInternalManagerService $manager_service, protected ContainerSkillManager $cont_skill_manager, protected \ilContainer $container, object $parent_gui, string $parent_cmd)
 
- Public Member Functions inherited from ILIAS\Repository\Table\CommonTableBuilder
 __construct (protected object $parent_gui, protected string $parent_cmd, bool $numeric_ids=true)
 
 getTable ()
 

Protected Member Functions

 getId ()
 
 getTitle ()
 
 getRetrieval ()
 
 activeAction (string $action, array $data_row)
 
 build (TableAdapterGUI $table)
 
- Protected Member Functions inherited from ILIAS\Repository\Table\CommonTableBuilder
 getId ()
 
 getTitle ()
 
 getRetrieval ()
 
 getNamespace ()
 
 getOrderingCommand ()
 
 activeAction (string $action, array $data_row)
 
 transformRow (array $data_row)
 transform raw data array to table row data array More...
 
 build (TableAdapterGUI $table)
 

Additional Inherited Members

- Protected Attributes inherited from ILIAS\Repository\Table\CommonTableBuilder
TableAdapterGUI $table
 

Detailed Description

Definition at line 27 of file ContSkillMemberTableBuilder.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Container\Skills\ContSkillMemberTableBuilder::__construct ( protected SkillInternalManagerService  $manager_service,
protected ContainerSkillManager  $cont_skill_manager,
protected \ilContainer  $container,
object  $parent_gui,
string  $parent_cmd 
)

Definition at line 29 of file ContSkillMemberTableBuilder.php.

References ILIAS\GlobalScreen\Provider\__construct().

35  {
36  parent::__construct($parent_gui, $parent_cmd, true);
37  }
__construct(Container $dic, ilPlugin $plugin)
+ Here is the call graph for this function:

Member Function Documentation

◆ activeAction()

ILIAS\Container\Skills\ContSkillMemberTableBuilder::activeAction ( string  $action,
array  $data_row 
)
protected

Definition at line 92 of file ContSkillMemberTableBuilder.php.

References ilContainer\_lookupContainerSetting().

92  : bool
93  {
94  $container_publish_setting = \ilContainer::_lookupContainerSetting(
95  $this->container->getId(),
96  "cont_skill_publish",
97  '0'
98  );
99 
100  switch ($action) {
101  case "assignCompetences":
102  // Available when not published OR publish setting disabled
103  return !$data_row["published"] || $container_publish_setting === '0';
104  case "publishAssignments":
105  // Available when not published
106  return !$data_row["published"];
107  case "deassignCompetencesConfirm":
108  // Always available
109  return true;
110  }
111  return true;
112  }
static _lookupContainerSetting(int $a_id, string $a_keyword, ?string $a_default_value=null)
+ Here is the call graph for this function:

◆ build()

ILIAS\Container\Skills\ContSkillMemberTableBuilder::build ( TableAdapterGUI  $table)
protected

Definition at line 114 of file ContSkillMemberTableBuilder.php.

References $DIC, $lng, ILIAS\Repository\Table\CommonTableBuilder\$table, ilContainer\_lookupContainerSetting(), ILIAS\Repository\Table\TableAdapterGUI\singleAction(), ILIAS\Repository\Table\TableAdapterGUI\standardAction(), and ILIAS\Repository\Table\TableAdapterGUI\textColumn().

114  : TableAdapterGUI
115  {
116  global $DIC;
117  $lng = $DIC->language();
118 
119  $table = $table
120  ->textColumn("name", $lng->txt("name"))
121  ->textColumn("login", $lng->txt("login"))
122  ->textColumn("cont_mem_skills", $lng->txt("cont_mem_skills"))
123  ->textColumn("cont_published", $lng->txt("cont_published"));
124 
125  // Add single actions
126  $table = $table
127  ->singleAction("assignCompetences", $lng->txt("cont_assign_competence"))
128  ->standardAction("deassignCompetencesConfirm", $lng->txt("cont_deassign_competence"));
129 
130  // Add multi commands based on container settings
131  $container_publish_setting = \ilContainer::_lookupContainerSetting(
132  $this->container->getId(),
133  "cont_skill_publish",
134  '0'
135  );
136 
137  if ($container_publish_setting === '1') {
138  $table = $table->standardAction("publishAssignments", $lng->txt("cont_publish_assignment"));
139  }
140 
141  return $table;
142  }
textColumn(string $key, string $title, bool $sortable=false)
global $DIC
Definition: shib_login.php:26
standardAction(string $action, string $title)
global $lng
Definition: privfeed.php:31
singleAction(string $action, string $title, bool $async=false)
static _lookupContainerSetting(int $a_id, string $a_keyword, ?string $a_default_value=null)
+ Here is the call graph for this function:

◆ getId()

ILIAS\Container\Skills\ContSkillMemberTableBuilder::getId ( )
protected

Definition at line 39 of file ContSkillMemberTableBuilder.php.

39  : string
40  {
41  return "cont_skll_mem_" . $this->container->getId();
42  }

◆ getRetrieval()

ILIAS\Container\Skills\ContSkillMemberTableBuilder::getRetrieval ( )
protected

Definition at line 50 of file ContSkillMemberTableBuilder.php.

References $DIC, $lng, $path, ilSkillTreeNode\_lookupTitle(), ilBasicSkill\lookupLevelTitle(), and ILIAS\Repository\Table\CommonTableBuilder\transformRow().

51  {
52  return $this->manager_service->contSkillMemberRetrieval(
53  $this->cont_skill_manager,
54  $this->container
55  );
56  }
+ Here is the call graph for this function:

◆ getTitle()

ILIAS\Container\Skills\ContSkillMemberTableBuilder::getTitle ( )
protected

Definition at line 44 of file ContSkillMemberTableBuilder.php.

References $DIC.

44  : string
45  {
46  global $DIC;
47  return $DIC->language()->txt("cont_cont_skills");
48  }
global $DIC
Definition: shib_login.php:26

The documentation for this class was generated from the following file: