aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntonio Gallo <tonicucoz@gmail.com>2011-10-14 11:37:34 +0000
committerAntonio Gallo <tonicucoz@gmail.com>2011-10-14 11:37:34 +0000
commit2ab9d78444374d55a45b63a1693f5194a7baae60 (patch)
tree78e13a96e6d56367c931cff8f17fd89d2a4266a8
parent120b3fbf51b0844b1bc4a4de876ddb6ac567279d (diff)
moderators can now see all the actions carried out by users - part 1
-rw-r--r--h-source/Application/Controllers/HistoryController.php10
-rw-r--r--h-source/Application/Controllers/SpecialController.php22
-rw-r--r--h-source/Application/Views/Special/modactions.php4
-rw-r--r--h-source/Config/Route.php1
4 files changed, 34 insertions, 3 deletions
diff --git a/h-source/Application/Controllers/HistoryController.php b/h-source/Application/Controllers/HistoryController.php
index ad2c7dd..fac65c0 100644
--- a/h-source/Application/Controllers/HistoryController.php
+++ b/h-source/Application/Controllers/HistoryController.php
@@ -34,7 +34,13 @@ class HistoryController extends BaseController
'device' => 'device page',
'device_app' => 'device page',
'device_cl' => 'device page',
- 'issue_del' => 'issue',
+ 'issue_del' => 'issue', //registered
+ 'issue_ins' => 'issue', //registered
+ 'message_ins' => 'message', //registered
+ 'talk_ins' => 'talk', //registered
+ 'wiki_talk_ins' => 'wiki talk',//registered
+ 'hardware' => 'hardware', //registered
+ 'wiki' => 'wiki', //registered
);
public static $actionTable = array(
@@ -54,6 +60,8 @@ class HistoryController extends BaseController
'deviceclear' => 'perm deleted',
'issuehide' => 'hide',
'issueshow' => 'show',
+ 'insert' => 'insert', //registered
+ 'update' => 'update', //registered
);
protected $strings = array(
diff --git a/h-source/Application/Controllers/SpecialController.php b/h-source/Application/Controllers/SpecialController.php
index 480c0fa..eb80582 100644
--- a/h-source/Application/Controllers/SpecialController.php
+++ b/h-source/Application/Controllers/SpecialController.php
@@ -75,6 +75,19 @@ class SpecialController extends BaseController
$viewFile = 'modactions';
break;
+
+ case 'usersactions':
+ $data['title'] = 'last registered users actions - '.Website::$generalName;
+ $data['viewTitle'] = 'List of actions carried out by registered users';
+ $data['user_status'] = 'USER';
+
+ $whereClauseArray = array(
+ 'gr' => 'registered',
+ );
+
+ $viewFile = 'modactions';
+
+ break;
}
$this->helper('Pages','special/'.$this->action.'/'.$this->lang,'page');
@@ -144,6 +157,15 @@ class SpecialController extends BaseController
$this->last($lang = 'en','adminactions');
}
+ public function usersactions($lang = 'en')
+ {
+ $this->shift(1);
+
+ $this->s['registered']->check('moderator');
+
+ $this->last($lang = 'en','usersactions');
+ }
+
protected function pagelist($lang = 'en', $type)
{
switch ($type)
diff --git a/h-source/Application/Views/Special/modactions.php b/h-source/Application/Views/Special/modactions.php
index d3d535f..36aee20 100644
--- a/h-source/Application/Views/Special/modactions.php
+++ b/h-source/Application/Views/Special/modactions.php
@@ -23,7 +23,7 @@
<div id="left">
<div class="position_tree_box">
- <a href="<?php echo $this->baseUrl."/home/index/$lang";?>">Home</a> &raquo; <a href="<?php echo $this->baseUrl."/my/home/$lang/$token";?>"><?php echo gtext('panel');?></a> &raquo; moderators' actions
+ <a href="<?php echo $this->baseUrl."/home/index/$lang";?>">Home</a> &raquo; <a href="<?php echo $this->baseUrl."/my/home/$lang/$token";?>"><?php echo gtext('panel');?></a> &raquo; list of actions
</div>
<div class="contrib_explain_box">
@@ -38,7 +38,7 @@
<td class="simpleText">TYPE</td>
<td class="simpleText">OBJECT ID</td>
<td class="simpleText text_item_date">DATE</td>
- <td class="simpleText">MOTIVATION</td>
+ <td class="simpleText">NOTE</td>
</tr>
<?php foreach ($table as $row) { ?>
<tr class="listRow">
diff --git a/h-source/Config/Route.php b/h-source/Config/Route.php
index 1d824b8..cd052b6 100644
--- a/h-source/Config/Route.php
+++ b/h-source/Config/Route.php
@@ -172,6 +172,7 @@ class Route
'special,modifications',
'special,modactions',
'special,adminactions',
+ 'special,usersactions',
'special,deleted',
'special,notapproved',
'wiki,insert',