public function getOkrug() { if ($this->id_okrug) { return FOkrug::findOne($this->id_okrug); } else { return false; } }
public function actionIndexRegion($id) { $FRegion = FRegion::find()->where(["id_okrug" => $id])->orderBy('sort, name')->all(); $FOkrug = FOkrug::findOne($id); return $this->render('indexRegion', ['regions' => $FRegion, 'okrug' => $FOkrug]); }