ARTEMIS-1480 web console 'purge queue' is broken

This commit is contained in:
Shailendra Kumar Singh 2017-10-25 01:17:15 +05:30 committed by Justin Bertram
parent 0e0693d112
commit c9975817cb
2 changed files with 4 additions and 4 deletions

View File

@ -119,14 +119,14 @@ var ARTEMIS = (function(ARTEMIS) {
$scope.purgeDestination = function () {
var selection = workspace.selection;
var entries = selection.entries;
var mbean = getBrokerMBean(jolokia);
var mbean = selection.objectName;
if (mbean) {
if (selection && jolokia && entries) {
var name = entries["Destination"] || entries["destinationName"] || selection.title;
name = name.unescapeHTML();
var operation = "purge()";
$scope.message = "Purged queue " + name;
ARTEMISService.artemisConsole.purgeQueue(mbean, jolokia, name, onSuccess(deleteSuccess));
ARTEMISService.artemisConsole.purgeQueue(mbean, jolokia, onSuccess(deleteSuccess));
}
}
};

View File

@ -38,8 +38,8 @@ function ArtemisConsole() {
jolokia.execute(mbean, "destroyQueue(java.lang.String)", name, method);
};
this.purgeQueue = function (mbean, jolokia, name, method) {
//todo
this.purgeQueue = function (mbean, jolokia, method) {
jolokia.execute(mbean, "removeAllMessages()", method);
};
this.browse = function (mbean, jolokia, method) {