From 40172f56b5cdb748a795a9678169758819364df2 Mon Sep 17 00:00:00 2001 From: SJ Date: Wed, 27 Feb 2013 21:03:46 +0100 Subject: [PATCH] fixed a bug in the preview pane --- webui/view/javascript/piler-in.js | 13 ++++++++++--- .../view/theme/default/templates/search/helper.tpl | 4 ++-- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/webui/view/javascript/piler-in.js b/webui/view/javascript/piler-in.js index 26a8bd29..a1bbbded 100644 --- a/webui/view/javascript/piler-in.js +++ b/webui/view/javascript/piler-in.js @@ -212,10 +212,10 @@ var Piler = /* - * load the selected message to preview area + * load the selected message by position to preview area */ - view_message:function(pos) + view_message_by_pos:function(pos) { Piler.log("[view_message]", pos, Piler.Messages[pos]); @@ -230,6 +230,13 @@ var Piler = $('#e_' + id).attr('class', 'resultrow selected'); Piler.prev_message_id = id; + Piler.view_message(id); + }, + + + view_message:function(id) + { + Piler.log("[view_message]"); jQuery.ajax('/message.php/' + id, { cache: true }) .done( function(a) { @@ -381,7 +388,7 @@ var Piler = if ( x.nodeName == "DIV" && x.id.charAt( 0 ) == 'e' && x.id.charAt( 1 ) == '_' ) { - Piler.log("[fill_current_messages_array], i/id", i, x.id.substring(2, 1000)); + Piler.log("[fill_current_messages_array], pos/id", i, x.id.substring(2, 1000)); u[i] = x.id.substring(2, 1000); } diff --git a/webui/view/theme/default/templates/search/helper.tpl b/webui/view/theme/default/templates/search/helper.tpl index 0507492c..e78dd312 100644 --- a/webui/view/theme/default/templates/search/helper.tpl +++ b/webui/view/theme/default/templates/search/helper.tpl @@ -9,11 +9,11 @@
checked="checked" class="restorebox" />
- +
*
- +
0) { ?>