getRuntimePerspective() public static method

Gets the active perspective for the current user
public static getRuntimePerspective ( ) : array
return array
Example #1
0
 /**
  * @return array
  */
 public function getDisabledPortlets()
 {
     $perspectiveCfg = Config::getRuntimePerspective();
     $dasboardCfg = $perspectiveCfg["dashboards"] ? $perspectiveCfg["dashboards"] : [];
     return isset($dasboardCfg["disabledPortlets"]) ? $dasboardCfg["disabledPortlets"] : [];
 }
Example #2
0
        <div class="bounce2"></div>
        <div class="bounce3"></div>
    </div>
</div>

<div id="pimcore_avatar" style="display:none;">
    <img src="/admin/user/get-image" data-menu-tooltip="<?php 
echo \Pimcore\Tool\Admin::getCurrentUser()->getName();
?>
" />
</div>

<a id="pimcore_logout" href="/admin/login/logout/" style="display: none"></a>

<?php 
$runtimePerspective = \Pimcore\Config::getRuntimePerspective();
?>

<div id="pimcore_navigation" style="display:none;">
    <ul>
        <?php 
if (\Pimcore\Config::inPerspective($runtimePerspective, "file")) {
    ?>
            <li id="pimcore_menu_file" data-menu-tooltip="<?php 
    echo $this->translate("file");
    ?>
" class="pimcore_menu_item"></li>
        <?php 
}
?>
        <?php