summaryrefslogtreecommitdiff
path: root/qpid/java/broker-plugins
diff options
context:
space:
mode:
authorAlex Rudyy <orudyy@apache.org>2014-05-16 13:13:21 +0000
committerAlex Rudyy <orudyy@apache.org>2014-05-16 13:13:21 +0000
commitd45f6769e15965d19aaa85cf1c37851c1bdf757d (patch)
tree1144abe2ebeafea5a8275a0e8124686543cfdccd /qpid/java/broker-plugins
parent8b9d54dcb70bb397dae8742cf1a005945102dede (diff)
downloadqpid-python-d45f6769e15965d19aaa85cf1c37851c1bdf757d.tar.gz
QPID-5413: Improve virtual host node and virtual host UI
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1595188 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/java/broker-plugins')
-rw-r--r--qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNode.html1
-rw-r--r--qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/Broker.js18
-rw-r--r--qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNode.js9
3 files changed, 18 insertions, 10 deletions
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNode.html b/qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNode.html
index d5e86130a3..d5e8d44e98 100644
--- a/qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNode.html
+++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/addVirtualHostNode.html
@@ -30,6 +30,7 @@
name: 'type',
required: true,
disabled: true,
+ placeHolder: 'select node type',
title: 'Select virtual host node type',
searchAttr: 'name'">
</select>
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/Broker.js b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/Broker.js
index 618b49b02f..03f7383f51 100644
--- a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/Broker.js
+++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/Broker.js
@@ -344,18 +344,24 @@ define(["dojo/_base/xhr",
that.vhostsGrid =
new UpdatableStore(that.brokerData.virtualhostnodes, query(".broker-virtualhosts")[0],
[
- { name: "Node Name", field: "name", width: "20%"},
- { name: "Node State", field: "state", width: "15%"},
- { name: "Virtual Host Path", field: "_item", width: "20%",
+ { name: "Node Name", field: "name", width: "15%"},
+ { name: "Node State", field: "state", width: "10%"},
+ { name: "Node Type", field: "type", width: "10%"},
+ { name: "Host Name", field: "_item", width: "15%",
formatter: function(item){
- return item && item.virtualhosts? item.virtualhosts[0].name: (item?item.name: "N/A");
+ return item && item.virtualhosts? item.virtualhosts[0].name: "N/A";
}
},
- { name: "Virtual Host State", field: "_item", width: "15%",
+ { name: "Host State", field: "_item", width: "10%",
formatter: function(item){
- return item && item.virtualhosts? item.virtualhosts[0].state: (item?item.state: "N/A");
+ return item && item.virtualhosts? item.virtualhosts[0].state: "N/A";
}
},
+ { name: "Host Type", field: "_item", width: "10%",
+ formatter: function(item){
+ return item && item.virtualhosts? item.virtualhosts[0].type: "N/A";
+ }
+ },
{ name: "Connections", field: "_item", width: "10%",
formatter: function(item){
return item && item.virtualhosts? item.virtualhosts[0].statistics.connectionCount: 0;
diff --git a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNode.js b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNode.js
index fd18414aa9..d1889b8f17 100644
--- a/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNode.js
+++ b/qpid/java/broker-plugins/management-http/src/main/java/resources/js/qpid/management/addVirtualHostNode.js
@@ -80,6 +80,7 @@ define(["dojo/_base/xhr",
show: function()
{
this.form.reset();
+ this.type.set("value", null);
this.dialog.show();
},
destroy: function()
@@ -98,12 +99,12 @@ define(["dojo/_base/xhr",
},
_typeChanged: function(type)
{
+ var widgets = registry.findWidgets(this.typeFieldsContainer);
+ array.forEach(widgets, function(item) { item.destroyRecursive();});
+ domConstruct.empty(this.typeFieldsContainer);
+
if (type)
{
- var widgets = registry.findWidgets(this.typeFieldsContainer);
- array.forEach(widgets, function(item) { item.destroyRecursive();});
- domConstruct.empty(this.typeFieldsContainer);
-
var that = this;
require(["qpid/management/virtualhostnode/" + type.toLowerCase() + "/add"],
function(TypeUI)