chore: Мелкие правки
This commit is contained in:
parent
0473d410d1
commit
3e0b99c3d2
4 changed files with 9 additions and 21 deletions
|
|
@ -205,14 +205,12 @@ class Component
|
|||
}
|
||||
|
||||
/**
|
||||
* FIXME: Передавать в модель имя класса, а не часть
|
||||
* Создает модель
|
||||
* @param class-string $modelName
|
||||
* @return mixed
|
||||
*/
|
||||
public function getModel($modelName)
|
||||
{
|
||||
// $modelName = "App\\Mapper\\" . $name;
|
||||
$model = new $modelName();
|
||||
$model->config = $this->config;
|
||||
$model->db = $this->db;
|
||||
|
|
@ -300,7 +298,8 @@ class Component
|
|||
*/
|
||||
public function getFields($options = null) {
|
||||
$form = new Form();
|
||||
$form->addFieldList($this->getInfo()['parameter'], $options);
|
||||
$settings = $this->getInfo();
|
||||
$form->addFieldList($settings['parameter'], $options);
|
||||
|
||||
return $form->field;
|
||||
}
|
||||
|
|
@ -485,7 +484,7 @@ class Component
|
|||
* @return mixed
|
||||
*/
|
||||
function actionIndex($request) {
|
||||
return null;
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue