Moving to GitHub.
[platal.git] / modules / survey.php
index 8ea5817..22e6566 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /***************************************************************************
- *  Copyright (C) 2003-2011 Polytechnique.org                              *
+ *  Copyright (C) 2003-2014 Polytechnique.org                              *
  *  http://opensource.polytechnique.org/                                   *
  *                                                                         *
  *  This program is free software; you can redistribute it and/or modify   *
@@ -25,15 +25,15 @@ class SurveyModule extends PLModule
     function handlers()
     {
         return array(
-            'survey'              => $this->make_hook('index',         AUTH_PUBLIC),
-            'survey/vote'         => $this->make_hook('vote',          AUTH_PUBLIC),
-            'survey/result'       => $this->make_hook('result',        AUTH_PUBLIC),
-            'survey/edit'         => $this->make_hook('edit',          AUTH_COOKIE),
-            'survey/ajax'         => $this->make_hook('ajax',          AUTH_COOKIE),
-            'survey/admin'        => $this->make_hook('admin',         AUTH_MDP, 'admin'),
-            'survey/admin/edit'   => $this->make_hook('adminEdit',     AUTH_MDP, 'admin'),
-            'survey/admin/valid'  => $this->make_hook('adminValidate', AUTH_MDP, 'admin'),
-            'survey/admin/del'    => $this->make_hook('adminDelete',   AUTH_MDP, 'admin'),
+            'survey'             => $this->make_hook('index',         AUTH_PUBLIC),
+            'survey/vote'        => $this->make_hook('vote',          AUTH_PUBLIC),
+            'survey/result'      => $this->make_hook('result',        AUTH_PUBLIC),
+            'survey/edit'        => $this->make_hook('edit',          AUTH_COOKIE, 'user'),
+            'survey/ajax'        => $this->make_hook('ajax',          AUTH_COOKIE, 'user'),
+            'survey/admin'       => $this->make_hook('admin',         AUTH_PASSWD, 'admin'),
+            'survey/admin/edit'  => $this->make_hook('adminEdit',     AUTH_PASSWD, 'admin'),
+            'survey/admin/valid' => $this->make_hook('adminValidate', AUTH_PASSWD, 'admin'),
+            'survey/admin/del'   => $this->make_hook('adminDelete',   AUTH_PASSWD, 'admin'),
         );
     }
     // }}}
@@ -500,5 +500,5 @@ class SurveyModule extends PLModule
     // }}}
 }
 
-// vim:set et sw=4 sts=4 ts=4 foldmethod=marker enc=utf-8:
+// vim:set et sw=4 sts=4 ts=4 foldmethod=marker fenc=utf-8:
 ?>