activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hadr...@apache.org
Subject [1/4] git commit: [AMQ-4174] Redirect back to queue overview after delete/moving message Patch from Robert Balent applied
Date Thu, 06 Feb 2014 02:58:16 GMT
Updated Branches:
  refs/heads/trunk 2e5a64652 -> dacc03747


[AMQ-4174] Redirect back to queue overview after delete/moving message
Patch from Robert Balent applied


Project: http://git-wip-us.apache.org/repos/asf/activemq/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq/commit/3321f996
Tree: http://git-wip-us.apache.org/repos/asf/activemq/tree/3321f996
Diff: http://git-wip-us.apache.org/repos/asf/activemq/diff/3321f996

Branch: refs/heads/trunk
Commit: 3321f99643edc5ebc4bd8f4b9eaea90744fc6d60
Parents: 146fb12
Author: Daniel Kulp <dkulp@apache.org>
Authored: Wed Feb 5 15:19:44 2014 -0500
Committer: Daniel Kulp <dkulp@apache.org>
Committed: Wed Feb 5 15:19:44 2014 -0500

----------------------------------------------------------------------
 .../java/org/apache/activemq/web/controller/CopyMessage.java   | 2 +-
 .../java/org/apache/activemq/web/controller/DeleteMessage.java | 2 +-
 .../java/org/apache/activemq/web/controller/MoveMessage.java   | 2 +-
 activemq-web-console/src/main/webapp/message.jsp               | 6 +++---
 .../main/java/org/apache/activemq/web/DestinationFacade.java   | 4 ++++
 5 files changed, 10 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/3321f996/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CopyMessage.java
----------------------------------------------------------------------
diff --git a/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CopyMessage.java
b/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CopyMessage.java
index 3a82898..178eadd 100644
--- a/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CopyMessage.java
+++ b/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CopyMessage.java
@@ -49,7 +49,7 @@ public class CopyMessage extends DestinationFacade implements Controller
{
             	log.warn("No queue named: " + getPhysicalDestinationName());
             }
         }
-        return redirectToBrowseView();
+        return redirectToDestinationView();
     }
 
     public String getMessageId() {

http://git-wip-us.apache.org/repos/asf/activemq/blob/3321f996/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteMessage.java
----------------------------------------------------------------------
diff --git a/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteMessage.java
b/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteMessage.java
index 1f060fe..d9bf009 100644
--- a/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteMessage.java
+++ b/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteMessage.java
@@ -48,7 +48,7 @@ public class DeleteMessage extends DestinationFacade implements Controller
{
             	log.warn("No queue named: " + getPhysicalDestinationName());
             }
         }
-        return redirectToBrowseView();
+        return redirectToDestinationView();
     }
 
     public String getMessageId() {

http://git-wip-us.apache.org/repos/asf/activemq/blob/3321f996/activemq-web-console/src/main/java/org/apache/activemq/web/controller/MoveMessage.java
----------------------------------------------------------------------
diff --git a/activemq-web-console/src/main/java/org/apache/activemq/web/controller/MoveMessage.java
b/activemq-web-console/src/main/java/org/apache/activemq/web/controller/MoveMessage.java
index 2155382..5a49165 100644
--- a/activemq-web-console/src/main/java/org/apache/activemq/web/controller/MoveMessage.java
+++ b/activemq-web-console/src/main/java/org/apache/activemq/web/controller/MoveMessage.java
@@ -49,7 +49,7 @@ public class MoveMessage extends DestinationFacade implements Controller
{
             	log.warn("No queue named: " + getPhysicalDestinationName());
             }
         }
-        return redirectToBrowseView();
+        return redirectToDestinationView();
     }
 
     public String getMessageId() {

http://git-wip-us.apache.org/repos/asf/activemq/blob/3321f996/activemq-web-console/src/main/webapp/message.jsp
----------------------------------------------------------------------
diff --git a/activemq-web-console/src/main/webapp/message.jsp b/activemq-web-console/src/main/webapp/message.jsp
index be4e14f..cc5ff0c 100644
--- a/activemq-web-console/src/main/webapp/message.jsp
+++ b/activemq-web-console/src/main/webapp/message.jsp
@@ -133,10 +133,10 @@ No message could be found for ID <c:out value="${requestContext.messageQuery.id}
                 </thead>
                 <tbody>
                     <tr>
-                        <td colspan="2"><a href="deleteMessage.action?JMSDestination=<c:out
value="${row.JMSDestination}" />&messageId=${row.JMSMessageID}&secret=<c:out
value='${sessionScope["secret"]}'/>">Delete</a></td>
+                        <td colspan="2"><a href="deleteMessage.action?JMSDestination=<c:out
value="${requestContext.messageQuery.JMSDestination}" />&messageId=${row.JMSMessageID}&secret=<c:out
value='${sessionScope["secret"]}'/>">Delete</a></td>
                     </tr>
                     <tr class="odd">
-                    <td><a href="javascript:confirmAction('queue', 'copyMessage.action?destination=%target%&JMSDestination=<c:out
value="${row.JMSDestination}" />&messageId=${row.JMSMessageID}&JMSDestinationType=queue&secret=<c:out
value='${sessionScope["secret"]}'/>')">Copy</a></td>
+                    <td><a href="javascript:confirmAction('queue', 'copyMessage.action?destination=%target%&JMSDestination=<c:out
value="${requestContext.messageQuery.JMSDestination}" />&messageId=${row.JMSMessageID}&JMSDestinationType=queue&secret=<c:out
value='${sessionScope["secret"]}'/>')">Copy</a></td>
                         <td rowspan="2">
                             <select id="queue">
                                 <option value=""> -- Please select --</option>
@@ -150,7 +150,7 @@ No message could be found for ID <c:out value="${requestContext.messageQuery.id}
 
                     </tr>
                     <tr class="odd">
-                        <td><a href="javascript:confirmAction('queue', 'moveMessage.action?destination=%target%&JMSDestination=<c:out
value="${row.JMSDestination}" />&messageId=${row.JMSMessageID}&JMSDestinationType=queue&secret=<c:out
value='${sessionScope["secret"]}'/>')">Move</a></td>
+                        <td><a href="javascript:confirmAction('queue', 'moveMessage.action?destination=%target%&JMSDestination=<c:out
value="${requestContext.messageQuery.JMSDestination}" />&messageId=${row.JMSMessageID}&JMSDestinationType=queue&secret=<c:out
value='${sessionScope["secret"]}'/>')">Move</a></td>
                     </tr>
                 </tbody>
             </table>

http://git-wip-us.apache.org/repos/asf/activemq/blob/3321f996/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java
----------------------------------------------------------------------
diff --git a/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java b/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java
index 7e4e548..367f110 100644
--- a/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java
+++ b/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java
@@ -128,6 +128,10 @@ public class DestinationFacade {
         return new ModelAndView("redirect:" + (isQueue() ? "queues.jsp" : "topics.jsp"));
     }
 
+    protected ModelAndView redirectToDestinationView() {        
+        return new ModelAndView("redirect:browse.jsp?JMSDestination=" + jmsDestination);
+    }
+
     protected String getPhysicalDestinationName() {
         return createDestination().getPhysicalName();
     }


Mime
View raw message