/** * @inheritdoc */ public function init() { $stickyAttributes = $this->model->stickyAttributes(); if (in_array($this->attribute, $stickyAttributes)) { $this->sticky(); } $hints = $this->model->hints(); if (isset($hints[$this->attribute])) { $this->hint($hints[$this->attribute]); } $autoCompleteData = $this->model->autoCompleteData(); if (isset($autoCompleteData[$this->attribute])) { if (is_callable($autoCompleteData[$this->attribute])) { $this->autoComplete(call_user_func($autoCompleteData[$this->attribute])); } else { $this->autoComplete($autoCompleteData[$this->attribute]); } } }
/** * @inheritdoc */ public function hints() { return array_merge(parent::hints(), ['modelClass' => 'This is the model class for collecting the form input. You should provide a fully qualified class name, e.g., <code>app\\models\\Post</code>.', 'viewName' => 'This is the view name with respect to the view path. For example, <code>site/index</code> would generate a <code>site/index.php</code> view file under the view path.', 'viewPath' => 'This is the root view path to keep the generated view files. You may provide either a directory or a path alias, e.g., <code>@app/views</code>.', 'scenarioName' => 'This is the scenario to be used by the model when collecting the form input. If empty, the default scenario will be used.']); }
/** * @inheritdoc */ public function stickyAttributes() { return array_merge(parent::stickyAttributes(), ['baseControllerClass', 'moduleID', 'indexWidgetType']); }
/** * @inheritdoc */ public function stickyAttributes() { return array_merge(parent::stickyAttributes(), ['ns', 'db', 'baseClass', 'generateRelations', 'generateLabelsFromComments']); }