Commit eec63d622224830e33523c3cf81a4095287b8cc7
1 parent
c72badde
delete author
Showing
1 changed file
with
6 additions
and
1 deletions
Show diff stats
backend/controllers/AuthorController.php
@@ -9,7 +9,6 @@ | @@ -9,7 +9,6 @@ | ||
9 | namespace backend\controllers; | 9 | namespace backend\controllers; |
10 | 10 | ||
11 | use artbox\core\admin\actions\Index; | 11 | use artbox\core\admin\actions\Index; |
12 | - use artbox\core\admin\interfaces\ControllerInterface; | ||
13 | use common\models\Author; | 12 | use common\models\Author; |
14 | use yii\filters\AccessControl; | 13 | use yii\filters\AccessControl; |
15 | use yii\filters\VerbFilter; | 14 | use yii\filters\VerbFilter; |
@@ -101,4 +100,10 @@ | @@ -101,4 +100,10 @@ | ||
101 | throw new NotFoundHttpException('The requested page does not exist.'); | 100 | throw new NotFoundHttpException('The requested page does not exist.'); |
102 | } | 101 | } |
103 | } | 102 | } |
103 | + | ||
104 | + | ||
105 | + public function actionDelete($id){ | ||
106 | + $this->findModel($id)->delete(); | ||
107 | + return $this->redirect(['author/index']); | ||
108 | + } | ||
104 | } | 109 | } |
105 | \ No newline at end of file | 110 | \ No newline at end of file |