Exemplo n.º 1
0
 public function actionDeleteRole()
 {
     if ($this->isDeleteAllowed()) {
         if (Yii::$app->request->get()) {
             RoleModule::deleteAll('role = ' . Yii::$app->request->get()['id']);
             Role::deleteAll('id = ' . Yii::$app->request->get()['id']);
             /*return $this->render('role_list');*/
             return $this->redirect(['security/role-management']);
         }
         return $this->render('role_list');
     } else {
         echo "You don't have access here";
         die;
     }
 }