From 99a6ba9947839d62a3f09f48a0ba962c23794491 Mon Sep 17 00:00:00 2001 From: Antonio Gallo Date: Thu, 6 Oct 2011 19:43:29 +0000 Subject: moderators can now hide issues - part 2 --- .../Application/Controllers/IssuesController.php | 6 +-- h-source/Application/Include/languages.php | 8 ++++ h-source/Application/Views/Issues/view.php | 14 +++---- h-source/Application/Views/Issues/viewall.php | 10 +++-- h-source/Public/Css/main.css | 45 +++++++++++++++++----- 5 files changed, 61 insertions(+), 22 deletions(-) (limited to 'h-source') diff --git a/h-source/Application/Controllers/IssuesController.php b/h-source/Application/Controllers/IssuesController.php index 274bc56..e69c598 100644 --- a/h-source/Application/Controllers/IssuesController.php +++ b/h-source/Application/Controllers/IssuesController.php @@ -98,16 +98,16 @@ class IssuesController extends BaseController //load the Pages helper $this->helper('Pages',$this->controller.'/viewall/'.$this->lang,'page'); //get the number of records - $this->m['IssuesModel']->from('issues left join messages')->using('id_issue')->aWhere(array('deleted'=>'no'))->groupBy('issues.id_issue')->orderBy('issues.update_date desc'); + $this->m['IssuesModel']->from('issues')->left('messages')->using('id_issue')->groupBy('issues.id_issue')->orderBy('issues.update_date desc'); $recordNumber = $this->m['IssuesModel']->rowNumber(); $page = $this->viewArgs['page']; //set the limit clause $this->m['IssuesModel']->limit = $this->h['Pages']->getLimit($page,$recordNumber,20); - $data['table'] = $this->m['IssuesModel']->getFields('issues.*,messages.message,count(*) as numb_mess'); + $data['table'] = $this->m['IssuesModel']->select('issues.*,messages.message,count(*) as numb_mess')->send(); $data['pageList'] = $this->h['Pages']->render($page-3,7); - + $this->append($data); $this->load('viewall'); $this->right(); diff --git a/h-source/Application/Include/languages.php b/h-source/Application/Include/languages.php index de36683..4839e43 100644 --- a/h-source/Application/Include/languages.php +++ b/h-source/Application/Include/languages.php @@ -303,6 +303,14 @@ class Lang /*0255*/"Would you like to add it to the database?" => "Vorresti inserirlo nel database?", /*0256*/"can free operating systems be installed?" => "possono essere installati sistemi operativi liberi?", /*0257*/"This issue has been deleted" => "Questa questione è stata cancellata", + /*0258*/"hidden for those who are not moderators" => "Nascosto per coloro che non sono moderatori", + /*0259*/"This issue is hidden for all the users that are not moderators" => "Questa questione è nascosta per tutti gli utenti non moderatori", + /*0260*/"hide the issue" => "nascondi la questione", + /*0261*/"show the issue" => "mostra la questione", + /*0262*/"open the issue again" => "apri nuovamente la questione", + /*0263*/"close the issue" => "chiudi la questione", + /*0264*/"This issue is closed" => "Questa questione è stata chiusa", + /*0265*/"This issue is opened" => "Questa questione è aperta", ), 'es' => array ( diff --git a/h-source/Application/Views/Issues/view.php b/h-source/Application/Views/Issues/view.php index cbedcde..769717a 100644 --- a/h-source/Application/Views/Issues/view.php +++ b/h-source/Application/Views/Issues/view.php @@ -43,25 +43,25 @@
- This issue is opened + - ">close the issue + "> - This issue is closed + - ">open the issue again + "> - ">hide the issue + "> -
This issue is hidden for all the users that are not moderators
+
- ">show the issue + "> diff --git a/h-source/Application/Views/Issues/viewall.php b/h-source/Application/Views/Issues/viewall.php index 1705670..d5d652f 100644 --- a/h-source/Application/Views/Issues/viewall.php +++ b/h-source/Application/Views/Issues/viewall.php @@ -55,8 +55,10 @@ - - viewStatus;?>"> + + + + viewStatus;?>"> () getUser($row['issues']['created_by']));?> @@ -76,6 +78,8 @@ + +
@@ -86,7 +90,7 @@
-
+
diff --git a/h-source/Public/Css/main.css b/h-source/Public/Css/main.css index 31b120a..dacb52b 100644 --- a/h-source/Public/Css/main.css +++ b/h-source/Public/Css/main.css @@ -1069,19 +1069,49 @@ ins } .issues_viewall_table { - font:normal 14px/1 sans-serif,arial; + font:normal 13px/1 sans-serif,arial; } + .issues_viewall_table td { -/* background:#E6E6FA; */ +/* background:#F0FFFF; */ padding:5px; /* border-bottom:1px solid #E6E6FA; */ } +.issues_viewall_table td a +{ + color:#3E3E3E; +} +.issue_deleted_yes td +{ + background-color:#E6E6FA; +} + +.issue_deleted_yes span +{ + color:red; + padding-left:5px; + font-size:10px; +} + +.issue_deleted_no span +{ + display:none; +} + +.issue_deleted_yes, +.issue_deleted_yes td a +{ + color:#808080; +} + .issues_viewall_table th { background:#ADD8E6; - border-top:1px solid #4169E1; - border-bottom:1px solid #4169E1; +/* font-weight:normal; */ +/* border-top:1px solid #4169E1; */ +/* border-left:4px solid #4169E1; */ +/* border-bottom:1px solid #4169E1; */ padding:5px; } @@ -1958,11 +1988,8 @@ div#description_tabs_content { width:500px; float:left; - padding:5px; - margin:10px 0; -/* font-style:italic; */ -/* border: 1px solid #F65637; */ - background-color:#F65637; + margin-bottom:10px; + color:red; } .show_hidden_box_ext { -- cgit v1.2.3