From 1c584ef8ba861ce361135dc44aeabd76423c0c94 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Fri, 9 Nov 2012 11:46:17 +0100 Subject: [feature/soft-delete] Use JS to display softdeleted/ignored posts PHPBB3-9567 --- phpBB/styles/prosilver/template/ajax.js | 14 +++++++++++ .../styles/prosilver/template/viewtopic_body.html | 29 +++++++++++++++------- 2 files changed, 34 insertions(+), 9 deletions(-) (limited to 'phpBB/styles') diff --git a/phpBB/styles/prosilver/template/ajax.js b/phpBB/styles/prosilver/template/ajax.js index b473e608dc..c29a38d080 100644 --- a/phpBB/styles/prosilver/template/ajax.js +++ b/phpBB/styles/prosilver/template/ajax.js @@ -77,6 +77,20 @@ $('#qr_full_editor').click(function() { }); +/** + * Make the display post links to use JS + */ +$('.display_post').click(function(e) { + // Do not follow the link + e.preventDefault(); + + var post_id = $(this).attr('data-post-id'); + $('#post_content' + post_id).show(); + $('#profile' + post_id).show(); + $('#post_hidden' + post_id).hide(); +}); + + /** * This AJAXifies the quick-mod tools. The reason it cannot be a standard diff --git a/phpBB/styles/prosilver/template/viewtopic_body.html b/phpBB/styles/prosilver/template/viewtopic_body.html index 9e49e91be5..14c03dbb08 100644 --- a/phpBB/styles/prosilver/template/viewtopic_body.html +++ b/phpBB/styles/prosilver/template/viewtopic_body.html @@ -114,13 +114,24 @@ -
+
- -
{postrow.L_IGNORE_POST}
- + + +
+ {postrow.L_POST_DELETED_MESSAGE}
+ {postrow.L_POST_DISPLAY} +
+ +
+ {postrow.L_IGNORE_POST}
+ {postrow.L_POST_DISPLAY} +
+ + +
style="display: none;"> @@ -156,7 +167,9 @@ {S_FORM_TOKEN}
- {REPORTED_IMG} {L_POST_REPORTED} + + {REPORTED_IMG} {L_POST_REPORTED} +

@@ -197,12 +210,11 @@


{postrow.BUMPED_MESSAGE}
{postrow.SIGNATURE}
- +
- -
+
style="display: none;">
{postrow.POSTER_AVATAR}{postrow.POSTER_AVATAR}
@@ -245,7 +257,6 @@
- -- cgit v1.2.1