/** * @return \yii\db\ActiveQuery */ public function getCategory() { return $this->hasOne(SeoCategoryModel::className(), ['id' => 'categoryId']); }
/** * Declares external actions for the controller. * This method is meant to be overwritten to declare external actions for the controller. * @return array */ public function actions() { return ['edit-category-name' => ['class' => EditableAction::className(), 'modelClass' => SeoCategoryModel::className(), 'forceCreate' => false], 'toggle' => ['class' => ToggleAction::className(), 'modelClass' => SeoCategoryModel::className()]]; }