ILIAS  trunk Revision v11.0_alpha-1689-g66c127b4ae8
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
MemberViewLayoutProvider.php
Go to the documentation of this file.
1 <?php
2 
20 
21 use ILIAS\Data\URI;
30 use ilLink;
32 use ilObject;
33 
40 {
45  {
46  return $this->context_collection->repository();
47  }
48 
49  public static function getMemberViewModeInfo(\ILIAS\DI\Container $dic): ?ModeInfo
50  {
52  if (!$mv->isActive()) {
53  return null;
54  }
55  $ref_id = $mv->getCurrentRefId();
56  $url = new URI(ilLink::_getLink(
57  $ref_id,
59  ));
60  $url = $url->withParameter('mv', 0);
61 
62  $modeinfo = $dic->ui()->factory()->mainControls()->modeInfo(
63  $dic->language()->txt('mem_view_long'),
64  $url
65  );
66 
67  return $modeinfo;
68  }
69 
73  public function getPageBuilderDecorator(CalledContexts $screen_context_stack): ?PageBuilderModification
74  {
75  $mv_mode_info = self::getMemberViewModeInfo($this->dic);
76  if (is_null($mv_mode_info)) {
77  return null;
78  }
79 
80  return $this->factory->page()
81  ->withLowPriority()
82  ->withModification(
83  static function (PagePartProvider $parts) use ($mv_mode_info): Page {
84  $p = new StandardPageBuilder();
85  $page = $p->build($parts);
86  return $page->withModeInfo($mv_mode_info);
87  }
88  );
89  }
90 }
getPageBuilderDecorator(CalledContexts $screen_context_stack)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
if($clientAssertionType !='urn:ietf:params:oauth:client-assertion-type:jwt-bearer'|| $grantType !='client_credentials') $parts
Definition: ltitoken.php:61
Interface Observer Contains several chained tasks and infos about them.
factory()
$url
Definition: shib_logout.php:66
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:35
static _lookupObjId(int $ref_id)
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
$ref_id
Definition: ltiauth.php:65
Class HTTPServicesTest.
This describes the Page.
Definition: Page.php:30
$dic
Definition: result.php:31
static _lookupType(int $id, bool $reference=false)