public function actionDelete(string $id)
    {
        $model = $this->findModel($id);
        Yii::$app->authManager->remove($model->item);
        Yii::$app->session->setFlash('success', Yii::t('yii2mod.rbac', 'Rule has been deleted.'));

        return $this->redirect(['index']);
    }
public function actionDelete(string $id)
    {
        $model = $this->findModel($id);
        Yii::$app->authManager->remove($model->item);
        Yii::$app->session->setFlash('success', Yii::t('yii2mod.rbac', 'Rule has been deleted.'));

        return $this->redirect(['index']);
    }
public function actionDelete ( string $ id ) { $ model = $ this -> findModel ( $ id ) ; Yii :: $ app -> authManager -> remove ( $ model -> item ) ; Yii :: $ app -> session -> setFlash ( 'success' , Yii :: t ( 'yii2mod.rbac' , 'Rule has been deleted.' ) ) ; return $ this -> redirect ( [ 'index' ] ) ; }
Deletes an existing Rule item.

If deletion is successful, the browser will be redirected to the 'index' page.

@param string $id

@return mixed
Deletes an existing Rule item .