ILIAS  release_8 Revision v8.24
class.ilObjRemoteGroupListGUI.php
Go to the documentation of this file.
1<?php
2
18declare(strict_types=1);
19
29{
36 public function __construct()
37 {
39 }
40
46 public function init(): void
47 {
48 $this->copy_enabled = false;
49 $this->static_link_enabled = true;
50 $this->delete_enabled = true;
51 $this->cut_enabled = true;
52 $this->subscribe_enabled = true;
53 $this->link_enabled = true;
54 $this->info_screen_enabled = true;
55 $this->type = 'rgrp';
56 $this->gui_class_name = 'ilobjremotegroupgui';
57
58 $this->substitutions = ilAdvancedMDSubstitution::_getInstanceByObjectType($this->type);
59 if ($this->substitutions->isActive()) {
60 $this->substitutions_enabled = true;
61 }
62
63 // general commands array
64 $this->commands = ilObjRemoteGroupAccess::_getCommands();
65 }
66
67
75 public function getProperties(): array
76 {
77 if ($org = $this->_lookupOrganization(ilObjRemoteGroup::DB_TABLE_NAME, $this->obj_id)) {
78 $this->addCustomProperty($this->lng->txt('organization'), $org, false, true);
79 }
80 if (!ilObjRemoteGroup::_lookupOnline($this->obj_id)) {
81 $this->addCustomProperty($this->lng->txt("status"), $this->lng->txt("offline"), true, true);
82 }
83
84 return array();
85 }
86
94 public function getCommandFrame(string $cmd): string
95 {
96 switch ($cmd) {
97 case 'show':
98 if (ilECSExportManager::getInstance()->_isRemote(
99 ilECSImportManager::getInstance()->lookupServerId($this->obj_id),
100 (int) ilECSImportManager::getInstance()->_lookupEContentId($this->obj_id)
101 )) {
102 return '_blank';
103 }
104
105 // no break
106 default:
107 return parent::getCommandFrame($cmd);
108 }
109 }
110} // END class.ilObjRemoteGroupListGUI
static _getInstanceByObjectType(string $a_type)
static getInstance()
Get the singelton instance of this ilECSExportManager.
static getInstance()
Get the singleton instance of this ilECSImportManager.
getProperties()
get properties (offline)
getCommandFrame(string $cmd)
get command frame
static _lookupOnline($a_obj_id)
Lookup online.
addCustomProperty(string $property="", string $value="", bool $alert=false, bool $newline=false)
_lookupOrganization(string $table, int $a_obj_id)
lookup organization
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc