diff options
Diffstat (limited to 'protected/controllers/VeranstaltungController.php')
| -rw-r--r-- | protected/controllers/VeranstaltungController.php | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/protected/controllers/VeranstaltungController.php b/protected/controllers/VeranstaltungController.php index 49ec10a..0e88513 100644 --- a/protected/controllers/VeranstaltungController.php +++ b/protected/controllers/VeranstaltungController.php @@ -27,8 +27,8 @@ class VeranstaltungController extends Controller { return array( array('allow', // allow admin user to perform 'admin' and 'delete' actions - 'actions'=>array('create','update','index','view','delete'), - 'users'=>array('admin'), + 'actions'=>array('index','view','now'), + 'users'=>array('*'), ), array('deny', // deny all users 'users'=>array('*'), @@ -141,6 +141,19 @@ class VeranstaltungController extends Controller )); } + public function actionNow() + { + $model=new Veranstaltung('now'); + $model->unsetAttributes(); // clear any default values + if(isset($_GET['Veranstaltung'])) + $model->attributes=$_GET['Veranstaltung']; + + $this->render('now',array( + 'model'=>$model, + )); + + } + /** * Returns the data model based on the primary key given in the GET variable. * If the data model is not found, an HTTP exception will be raised. |
