DashboardHelper::__construct PHP Method

__construct() public method

public __construct ( array $items = null, OEWebUser $user = null )
$items array expected to be of the form: [ [ 'module' => 'ModuleName', 'restricted' => (optional) ] ]
$user OEWebUser
    public function __construct(array $items = null, OEWebUser $user = null)
    {
        $this->items = $items;
        $this->user = $user;
        if (is_null($this->items)) {
            $this->items = Yii::app()->params['dashboard_items'] ?: array();
        }
        if (is_null($this->user)) {
            $this->user = Yii::app()->user;
        }
        // uses a config variable for ease of turning on the demo.
        $this->sortable = Yii::app()->params['dashboard_sortable'] ?: false;
    }