19 declare(strict_types=1);
49 $this->
lng->loadLanguageModule(
'grp');
53 $this->
addColumn($this->
lng->txt(
'name'),
'name',
'20%');
54 $this->
addColumn($this->
lng->txt(
'login'),
'login',
'25%');
56 if ($this->privacy->enabledGroupAccessTimes()) {
57 $this->
addColumn($this->
lng->txt(
'last_access'),
'access_time');
59 $this->
addColumn($this->
lng->txt(
'grp_mem_contacts'),
'contact');
60 $this->
addColumn($this->
lng->txt(
'grp_notification'),
'notification');
66 $this->
setRowTemplate(
"tpl.edit_participants_row.html",
"components/ILIAS/Group");
74 protected function fillRow(array $a_set): void
76 $this->tpl->setVariable(
'VAL_ID', $a_set[
'usr_id']);
77 $this->tpl->setVariable(
'VAL_NAME', $a_set[
'lastname'] .
', ' . $a_set[
'firstname']);
79 $this->tpl->setVariable(
'VAL_LOGIN', $a_set[
'login']);
81 if ($this->privacy->enabledGroupAccessTimes()) {
82 $this->tpl->setVariable(
'VAL_ACCESS', $a_set[
'access_time']);
84 $this->tpl->setVariable(
'VAL_CONTACT_CHECKED', $a_set[
'contact'] ?
'checked="checked"' :
'');
85 $this->tpl->setVariable(
'VAL_NOTIFICATION_ID', $a_set[
'usr_id']);
86 $this->tpl->setVariable(
'VAL_NOTIFICATION_CHECKED', $a_set[
'notification'] ?
'checked="checked"' :
'');
88 $this->tpl->setVariable(
'NUM_ROLES', count($this->participants->getRoles()));
90 $assigned = $this->participants->getAssignedRoles((
int) $a_set[
'usr_id']);
91 foreach ($this->rep_object->getLocalGroupRoles(
true) as $name => $role_id) {
92 $this->tpl->setCurrentBlock(
'roles');
93 $this->tpl->setVariable(
'ROLE_ID', $role_id);
94 $this->tpl->setVariable(
'ROLE_NAME', $name);
96 if (in_array($role_id, $assigned)) {
97 $this->tpl->setVariable(
'ROLE_CHECKED',
'selected="selected"');
99 $this->tpl->parseCurrentBlock();
enable(string $a_module_name)
setFormAction(string $a_form_action, bool $a_multipart=false)
addCommandButton(string $a_cmd, string $a_text, string $a_onclick='', string $a_id="", string $a_class="")
setFormName(string $a_name="")
Singleton class that stores all privacy settings.
ilParticipants $participants
setRowTemplate(string $a_template, string $a_template_dir="")
Set row template.
__construct(object $a_parent_obj, ilObject $rep_object)
Constructor.
Base class for course and group participants.
static _getInstanceByObjId(int $a_obj_id)
Get singleton instance.
__construct(Container $dic, ilPlugin $plugin)
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)
disable(string $a_module_name)
ilPrivacySettings $privacy