App\Controllers\Admin\BaseController::init PHP Method

init() protected method

protected init ( )
    protected function init()
    {
        if (!isset($this->controllerName) || !$this->controllerName) {
            return;
        }
        $arDataContr = array('title', 'description', 'keywords', 'h1');
        foreach ($arDataContr as $name) {
            $this->data[$name] = $this->controllerName;
        }
        $this->data['all_e_link'] = 'list.' . $this->controllerName;
        if ($this->resourse) {
            $this->data['create_link'] = 'add.' . $this->controllerName;
            $this->data['edit_link'] = 'edit.' . $this->controllerName;
            $this->data['store_link'] = 'store.' . $this->controllerName;
            $this->data['save_link'] = 'save.' . $this->controllerName;
            $this->data['delete_link'] = 'delete.' . $this->controllerName;
        }
        $this->data['system_options'] = $this->containerSlim->systemOptions;
        $this->data['menu_left'] = $this->containerSlim->get('adminMenuLeft');
        $this->data['menu_top'] = $this->containerSlim->get('adminMenuTop');
    }