diff options
Diffstat (limited to 'h-source')
-rw-r--r-- | h-source/Application/Controllers/HistoryController.php | 5 | ||||
-rw-r--r-- | h-source/Application/Controllers/WikiController.php | 2 | ||||
-rw-r--r-- | h-source/Application/Include/languages.php | 2 | ||||
-rw-r--r-- | h-source/Application/Views/Wiki/page.php | 25 |
4 files changed, 32 insertions, 2 deletions
diff --git a/h-source/Application/Controllers/HistoryController.php b/h-source/Application/Controllers/HistoryController.php index 13d3b3a..ac1ab1a 100644 --- a/h-source/Application/Controllers/HistoryController.php +++ b/h-source/Application/Controllers/HistoryController.php @@ -201,7 +201,7 @@ class HistoryController extends BaseController 'clean_type' => 'page_del', 'model_name' => 'WikiModel', 'id_name' => 'id_wiki', - 'field_name' => 'deleted', + 'field_name' => '-deleted', 'actions' => array('pagehide','pageshow'), 'group' => 'admin', @@ -312,6 +312,9 @@ class HistoryController extends BaseController { if (eg_strlen($message) < 500) { + //drop the - char if present + $clean['field_name'] = str_replace('-',null,$clean['field_name']); + //hide the message $model->values = array($clean['field_name'] => $this->strings[$action]['to_status']); $model->pUpdate($clean['id']); diff --git a/h-source/Application/Controllers/WikiController.php b/h-source/Application/Controllers/WikiController.php index cc0c922..b282d24 100644 --- a/h-source/Application/Controllers/WikiController.php +++ b/h-source/Application/Controllers/WikiController.php @@ -205,7 +205,7 @@ class WikiController extends BaseController $this->redirect('wiki/page/'.$this->lang.'/Main-Page'); } - $data['md_javascript'] = "moderator_dialog(\"pageblock\",\"page\");moderator_dialog(\"pageunblock\",\"page\");"; + $data['md_javascript'] = "moderator_dialog(\"pageblock\",\"page\");moderator_dialog(\"pageunblock\",\"page\");moderator_dialog(\"pagehide\",\"page_del\");moderator_dialog(\"pageshow\",\"page_del\");"; $this->append($data); diff --git a/h-source/Application/Include/languages.php b/h-source/Application/Include/languages.php index 6a9d9ec..9922e87 100644 --- a/h-source/Application/Include/languages.php +++ b/h-source/Application/Include/languages.php @@ -205,6 +205,8 @@ class Lang "This wiki page has been blocked" => "Questa pagina della wiki รจ stata bloccata", "unblock the wiki page" => "sblocca la pagina", "block the wiki page" => "blocca la pagina", + "show the wiki page" => "mostra la pagina della wiki", + "hide the wiki page" => "nascondi la pagina della wiki", ), 'es' => array ( diff --git a/h-source/Application/Views/Wiki/page.php b/h-source/Application/Views/Wiki/page.php index 1580d67..e59d85c 100644 --- a/h-source/Application/Views/Wiki/page.php +++ b/h-source/Application/Views/Wiki/page.php @@ -30,6 +30,7 @@ <a href="<?php echo $this->baseUrl."/home/index/$lang";?>">Home</a> » <a href="<?php echo $this->baseUrl."/wiki/page/$lang/Main-Page";?>">Wiki</a> » <?php echo $tree_name;?> </div> + <!--block a page--> <?php if ($isadmin) { ?> <div class="moderator_box"> <?php if ($isBlocked) { ?> @@ -52,6 +53,30 @@ </div> <?php } ?> + + <!--delete a page--> + <?php if ($isadmin) { ?> + <div class="moderator_box"> + <?php if ($isDeleted) { ?> + <?php echo gtext('This wiki page has been deleted'); ?> + + <a id="<?php echo $id_wiki;?>" class="pageshow_page_del block_general" href="<?php echo $this->baseUrl."/home/index/$lang";?>"><img src="<?php echo $this->baseUrl;?>/Public/Img/Crystal/button_ok.png"><?php echo gtext('show the wiki page'); ?></a> + + <?php } else { ?> + + <a id="<?php echo $id_wiki;?>" class="pagehide_page_del block_general" href="<?php echo $this->baseUrl."/home/index/$lang";?>"><img src="<?php echo $this->baseUrl;?>/Public/Img/Crystal/button_cancel.png"><?php echo gtext('hide the wiki page'); ?></a> + + <?php } ?> + + <!--view details--> + <div class="show_hidden_box_ext"> + <div class="md_type">page_del</div> + <a id="<?php echo $id_wiki;?>" class="hidden_message_view_details" href="<?php echo $this->baseUrl."/home/index/$lang";?>">view details</a> + <div class="moderation_details_box"></div> + </div> + + </div> + <?php } ?> <div class="notebook_insert_link"> <div class="view_page_back_button"> |