本文整理汇总了PHP中Render::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Render::__construct方法的具体用法?PHP Render::__construct怎么用?PHP Render::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Render
的用法示例。
在下文中一共展示了Render::__construct方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
public function __construct()
{
try {
//rendereiza o construtor da classe pai
$empresasRelacionadas = array();
parent::__construct();
$this->empresas_id = Session::read('Empresa.empresas_id');
/* PEGAR O ID DA EMPRESA NA SEÇÃO */
$this->pessoas_id = Session::read('Usuario.pessoas_id');
/* PEGAR O ID DA EMPRESA NA SEÇÃO */
$this->css = array('css/bootstrap', 'bs3/css/bootstrap.min', 'css/bootstrap_papper', 'css/bootstrap-reset', 'font-awesome/css/font-awesome', 'css/style', 'css/style-responsive', 'css/custom', 'js/advanced-datatable/css/demo_page', 'js/advanced-datatable/css/demo_table', 'css/Icomoon/style', 'css/preloader', 'js/data-tables/DT_bootstrap', 'js/bootsAlert/css/bootsAlert', 'js/chosen/chosen');
$this->js = array('js/jquery-1.11.1.min', 'bs3/js/bootstrap.min', 'js/jquery-ui-1.9.2.custom.min', 'js/ajaxForm', 'js/ckeditor/ckeditor', 'js/jquery.scrollTo.min', 'js/jQuery-slimScroll-1.3.0/jquery.slimscroll', 'js/jquery.nicescroll', 'js/dashboard', 'js/sparkline/jquery.sparkline', 'js/advanced-datatable/js/jquery.dataTables.min', 'js/advanced-datatable/js/dataTables.bootstrap.min', 'js/advanced-datatable/js/dataTables.responsive.min', 'js/dynamic_table_init', 'js/jquery.mask.min', 'js/funcoes', 'js/permission_js', 'js/scripts', 'js/bootsAlert/js/bootsAlert', 'js/chosen/chosen.jquery.min');
$this->ACL = new ACL();
$this->Util = new Utils();
$this->Empresa = new Empresa();
/**
* definindo a data hora local
*/
date_default_timezone_set('America/Sao_Paulo');
if (!in_array($this->view, $this->ClasseAllow)) {
if (Session::check('Auth') && Session::check('Usuario')) {
if ($this->ACL->authenticacaoUser($this->controller, $this->view, Session::read('Usuario.roles_id'))) {
Session::isLogged();
} else {
//verifica se é um metodo ou pagina
if ($this->autoRender == true) {
throw new PageException("Pagina {$this->view}.php não encontrada", 405);
}
}
} else {
//logica para o usuario publico
if ($this->ACL->authenticacaoUser($this->controller, $this->view, 1)) {
//header('Location: ' . Router::url() . 'Erros/areaRestrita' );
} else {
//verifica se é um metodo ou pagina
if ($this->autoRender) {
//redireciona para a pagina de area restrita
throw new PageException("Pagina {$this->view}.php não encontrada", 405);
}
}
}
}
/**
* variaveis pora todas as areas do sistema
*/
if (in_array(Session::read('Usuario.roles_id'), array(3, 4))) {
$empresasRelacionadas = $this->Empresa->empresasRelacionadas(md5($this->pessoas_id), Session::read('Usuario.roles_id'));
}
$this->set('empresasRelacionadas', $empresasRelacionadas);
$this->set('css', $this->css);
} catch (PageException $ex) {
echo $ex->pageNotFound();
exit;
} catch (Exception $ex) {
echo $ex->getTraceAsString();
}
}
示例2:
function __construct($view, $data = [], $layout = null)
{
parent::__construct($view, $data);
if ($layout == null) {
$this->layout = SiteBuilder::$app->layout;
} else {
$this->layout = $layout;
}
}
示例3: __construct
public function __construct($if, $viewFile, $data = NULL)
{
parent::__construct($viewFile, $data);
$this->_if = $if;
}
示例4: __construct
public function __construct($fileView, $dataArrAssoc = NULL)
{
parent::__construct($fileView, $dataArrAssoc);
}
示例5: __construct
public function __construct()
{
parent::__construct();
$this->Controll($this->controller);
}
示例6: __construct
/**
* Constructor, load parent constructor
*/
protected function __construct()
{
parent::__construct();
}