19 declare(strict_types=1);
65 ILIAS_HTTP_PATH .
'/' . $this->
ctrl->getLinkTargetByClass(
66 \ilResourceCollectionGUI::class,
71 $parameters = $uri_builder->acquireParameter(
72 [self::ACTION_NAMESPACE],
76 $this->url_builder = $parameters[0];
77 $this->url_token = $parameters[1];
101 $actions[self::ACTION_DOWNLOAD] =
102 $this->ui_factory->table()->action()->single(
103 $this->
language->txt(self::ACTION_DOWNLOAD),
108 if ($this->request->canUserAdministrate()) {
109 $actions[self::ACTION_REMOVE] =
110 $this->ui_factory->table()->action()->standard(
111 $this->
language->txt(self::ACTION_REMOVE),
116 $actions[self::ACTION_UNZIP] =
117 $this->ui_factory->table()->action()->single(
118 $this->
language->txt(self::ACTION_UNZIP),
123 $actions[self::ACTION_EDIT] =
124 $this->ui_factory->table()->action()->single(
125 $this->
language->txt(self::ACTION_EDIT),
139 $revision = $this->irss->manage()->getCurrentRevision($rid);
140 $mime_type = $revision->getInformation()->getMimeType();
141 if ($index === self::ACTION_UNZIP
142 && !in_array($mime_type, [
'application/zip',
'application/x-zip-compressed'])
147 $target =
$a->getTarget();
148 $target = $this->url_builder->withURI($target)
154 if (!
$a->isAsync()) {
155 $items[] = $this->ui_factory->link()->standard(
160 $this->modals[] = $modal = $this->ui_factory->modal()->interruptive(
164 )->withAsyncRenderUrl($target->__toString());
166 $items[] = $this->ui_factory->button()->shy(
168 $modal->getShowSignal()
172 return $this->ui_factory->dropdown()->standard(
181 ILIAS_HTTP_PATH .
'/' . $this->
ctrl->getLinkTargetByClass(
182 \ilResourceCollectionGUI::class,
buildURI(string $command)
Interface Observer Contains several chained tasks and infos about them.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
const CMD_RENDER_CONFIRM_REMOVE
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class ResourceIdentification.
buildDropDownForResource(ResourceIdentification $rid)
The scope of this class is split ilias-conform URI's into components.
ILIAS UI URLBuilderToken $url_token
__construct(private Request $request, private \ilCtrlInterface $ctrl, private Factory $ui_factory, private \ilLanguage $language, private Services $irss)
$a
thx to https://mlocati.github.io/php-cs-fixer-configurator for the examples
language()
description: > Example for rendring a language glyph.