/** * @inheritdoc */ public function run() { $class = $this->model; $class = $class::className(); $models = Address::getAddresses($this->model->id, $class); $model = new Address(['scenario' => 'create']); $model->entity = $class; $model->entity_id = $this->model->id; return $this->render('index', ['models' => $models, 'model' => $model]); }
/** * @param Comment $model Comment * * @return string Comments list */ protected function tree($model) { $models = Address::getAddresses($model->entity_id, $model->entity); return $this->renderPartial('@net/frenzel/address/views/widgets/views/_index_item', ['models' => $models]); }