summaryrefslogtreecommitdiff
path: root/protected/controllers/VeranstaltungController.php
diff options
context:
space:
mode:
authorPatrick Seeger <pseeger@ccwn.org>2012-05-15 21:30:11 +0200
committerPatrick Seeger <pseeger@ccwn.org>2012-05-15 21:30:11 +0200
commit5759435f4da8ec800ba9af0fbbf7d6691e9ed56c (patch)
treea3e6f6c676743e89b11804a03bd4f1e837983be9 /protected/controllers/VeranstaltungController.php
parent94bdb31c204cdae3ca820828d4731f11f6ffeeae (diff)
diverse Layoutings
Diffstat (limited to 'protected/controllers/VeranstaltungController.php')
-rw-r--r--protected/controllers/VeranstaltungController.php17
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.