incubator-esme-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From esjew...@apache.org
Subject svn commit: r937631 - in /incubator/esme/trunk/server/src/main/webapp: scripts/display_messages.js scripts/display_single_message.js templates-hidden/message.html
Date Sat, 24 Apr 2010 14:55:01 GMT
Author: esjewett
Date: Sat Apr 24 14:55:00 2010
New Revision: 937631

URL: http://svn.apache.org/viewvc?rev=937631&view=rev
Log:
[ESME-203] Make reply-to link set the pool for the reply and clear the pool when reply is
removed

Modified:
    incubator/esme/trunk/server/src/main/webapp/scripts/display_messages.js
    incubator/esme/trunk/server/src/main/webapp/scripts/display_single_message.js
    incubator/esme/trunk/server/src/main/webapp/templates-hidden/message.html

Modified: incubator/esme/trunk/server/src/main/webapp/scripts/display_messages.js
URL: http://svn.apache.org/viewvc/incubator/esme/trunk/server/src/main/webapp/scripts/display_messages.js?rev=937631&r1=937630&r2=937631&view=diff
==============================================================================
--- incubator/esme/trunk/server/src/main/webapp/scripts/display_messages.js (original)
+++ incubator/esme/trunk/server/src/main/webapp/scripts/display_messages.js Sat Apr 24 14:55:00
2010
@@ -68,7 +68,9 @@ function displayMessages(msgArray, eleme
       var msgDateStr = prettyDate(msgDateObj);
       
       var msgPool = '';
-      if (cometMsg.pool) msgPool = 'in pool ' + cometMsg.pool.name;
+      if (cometMsg.pool) msgPool = 'in pool ' + cometMsg.pool.name; 
+      var msgPoolId = 0;
+      if (cometMsg.pool) msgPoolId = cometMsg.pool.id; 
       var msgSource = cometMsg.source;
       var msgConversation = cometMsg.conversation;
       var msgReason = ""
@@ -110,6 +112,7 @@ function displayMessages(msgArray, eleme
       //newMsg.find('#reason').text(msgReason);
       //newMsg.find('#when').text(msgDateStr);
       var id = cometMsg.id;
+
       var resendButton = newMsg.find('#resend');
       if (cometResent) {
         resendButton.css("display", "none");
@@ -119,7 +122,7 @@ function displayMessages(msgArray, eleme
                                      'clearResend("resend_' + id + '")');
       }
       newMsg.find('#reply').attr('href',
-        "javascript:setReplyTo(" + id + ", '"+ msgBody + "')");
+        "javascript:setReplyTo(" + id + ", '"+ msgBody + "'," + msgPoolId + ")");
       var conversation = newMsg.find('#conversation');
       if (msgConversation != 0) {
         conversation.attr('href',

Modified: incubator/esme/trunk/server/src/main/webapp/scripts/display_single_message.js
URL: http://svn.apache.org/viewvc/incubator/esme/trunk/server/src/main/webapp/scripts/display_single_message.js?rev=937631&r1=937630&r2=937631&view=diff
==============================================================================
--- incubator/esme/trunk/server/src/main/webapp/scripts/display_single_message.js (original)
+++ incubator/esme/trunk/server/src/main/webapp/scripts/display_single_message.js Sat Apr
24 14:55:00 2010
@@ -79,7 +79,9 @@ function displayMessages(msgArray, eleme
       var msgDateStr = prettyDate(msgDateObj);
       
       var msgPool = '';
-      if (cometMsg.pool) msgPool = 'in pool ' + cometMsg.pool.name;
+      if (cometMsg.pool) msgPool = 'in pool ' + cometMsg.pool.name;     
+      var msgPoolId = 0;
+      if (cometMsg.pool) msgPoolId = cometMsg.pool.id;
       var msgSource = cometMsg.source;
       var msgConversation = cometMsg.conversation;
       var msgReason = ""
@@ -125,7 +127,7 @@ function displayMessages(msgArray, eleme
                                      'clearResend("resend_' + id + '")');
       }
       newMsg.find('#reply').attr('href',
-        "javascript:setReplyTo(" + id + ", '"+ msgBody + "')");
+        "javascript:setReplyTo(" + id + ", '"+ msgBody + "', " + msgPoolId + ")");
       var conversation = newMsg.find('#conversation');
       if (msgConversation != 0) {
         conversation.attr('href',

Modified: incubator/esme/trunk/server/src/main/webapp/templates-hidden/message.html
URL: http://svn.apache.org/viewvc/incubator/esme/trunk/server/src/main/webapp/templates-hidden/message.html?rev=937631&r1=937630&r2=937631&view=diff
==============================================================================
--- incubator/esme/trunk/server/src/main/webapp/templates-hidden/message.html (original)
+++ incubator/esme/trunk/server/src/main/webapp/templates-hidden/message.html Sat Apr 24 14:55:00
2010
@@ -69,15 +69,17 @@
                                         // <![CDATA[
                                         var currentConvNumber = 0;
                                         
-                                        function setReplyTo(id, text){
+                                        function setReplyTo(id, text, msgPool){
                                             currentConvNumber = id;
                                             document.getElementById('reply-to-div').style.display
= "block";
                                             jQuery('#reply-to-span').html(text);
+											jQuery('#vPool').val(msgPool);
                                         }
                                         
                                         function clearReplyTo(){
                                             currentConvNumber = 0;
                                             document.getElementById('reply-to-div').style.display
= "none";
+											jQuery('#vPool').val(0);
                                         }
                                         
                                         function clearResend(id){



Mime
View raw message