36 public const EDIT =
'edit';
37 public const VIEW =
'view';
50 $DIC[
'static_url.uri_builder']
62 if ($reference_id ===
null) {
63 return $response_factory->
cannot();
68 if ($additional_params ===
'_wsp') {
73 $capability_context = new \ILIAS\File\Capabilities\Context(
74 $reference_id->toObjectId()->toInt(),
75 $reference_id->toInt(),
83 $referrer = $context->
http()->request()->getServerParams()[
'HTTP_REFERER'] ??
'';
84 if (str_contains(strtolower($referrer), strtolower(ilObjectCopyGUI::class))) {
89 $capability = match ($additional_params) {
97 if (!$capability->isUnlocked() || $capability->getUri() ===
null) {
101 $uri = $capability->getUri();
103 return $response_factory->
can($uri->getPath() .
'?' . $uri->getQuery());
getAdditionalParameters()
loginFirst()
Convenience: the Handler cannot serve the target with the current permissions.
can(string $uri_path, bool $shift=false)
The Handler successfully resolved the target.
cannot()
The Handler cannot process the given Request at all, e.g.
readonly CapabilityBuilder $capabilities
handle(Request $request, Context $context, Factory $response_factory)
static _gotoSharedWorkspaceNode(int $wsp_id)
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
Interface Observer \BackgroundTasks Contains several chained tasks and infos about them.