Ejemplo n.º 1
0
 protected function doBuild(\PageContext $ctxt, \PageBuilderContext $builderCtxt, \RequestArrayAdapter $requestParams, \ArrayAdapter $buildParams)
 {
     //1. ЗАГОЛОВОК
     $builderCtxt->setTitle($this->authed ? 'Админка | ' . $this->adminPage->title() : 'xxx');
     //2. JAVASCRIPT
     $builderCtxt->setJsParams($this->authed ? $this->adminPage->getJsParams() : null);
     //3. SMARTY RESOURCES
     if ($this->authed) {
         $builderCtxt->setSmartyParams4Resources($this->adminPage->getSmartyParams4Resources());
         $builderCtxt->setSmartyParam4Resources('IDENT', $this->adminPage->getPageIdent());
         $builderCtxt->setSmartyParam4Resources('TIMELINE_ENABE', true);
     }
     $smartyParams['authed'] = $this->authed;
     $smartyParams['isBasic'] = PsSecurity::isBasic();
     if (!$this->authed) {
         return $smartyParams;
     }
     //Запустим неограниченный по времени режим - мало ли, что мы там будем делать:)
     PsUtil::startUnlimitedMode();
     //Отменим нормализацию страницы
     PsDefines::setNormalizePage(false);
     //Получаем содержимое админской страницы
     $content = ContentHelper::getContent($this->adminPage);
     //Добавляем к ней ресурсы
     $content = APagesResources::inst()->getResourcesLinks($this->adminPage->getPageIdent(), $content);
     $smartyParams['page'] = $this->adminPage;
     $smartyParams['content'] = $content;
     $smartyParams['pagesLayout'] = AdminPagesManager::getInstance()->getLayout();
     return $smartyParams;
 }
Ejemplo n.º 2
0
class X
{
    protected function __construct()
    {
        echo 'X';
    }
}
class Y extends X
{
    function __construct()
    {
        //parent::__construct();
    }
}
$y = new Y();
echo PsSecurity::isBasic();
die;
ExceptionHandler::registerPretty();
print_r(PopupPagesManager::inst()->getPagesList());
die('');
echo PluginsManager::inst()->getAutogenDi('advgraph', array('x', 'y', 'z'), null, 'temp', 'php')->touch();
die;
echo TestUtils::testProductivity(function () {
    FoldedStorage::getEntities('lib-s');
}, 200);
br();
echo FoldedStorage::extractInfoFromClassName('PL_slib', $classPrefix, $entity);
br();
echo $classPrefix;
br();
echo $entity;