Author: justi9
Date: 2007-10-26 22:04:05 -0400 (Fri, 26 Oct 2007)
New Revision: 1171
Modified:
mgmt/cumin/python/cumin/broker.strings
mgmt/cumin/python/cumin/brokercluster.py
mgmt/cumin/python/cumin/brokercluster.strings
mgmt/cumin/python/cumin/brokergroup.strings
mgmt/cumin/python/cumin/brokerprofile.strings
mgmt/cumin/python/cumin/client.py
mgmt/cumin/python/cumin/client.strings
mgmt/cumin/python/cumin/page.strings
mgmt/cumin/python/cumin/queue.py
mgmt/cumin/python/cumin/queue.strings
mgmt/cumin/python/cumin/virtualhost.py
mgmt/cumin/python/cumin/virtualhost.strings
Log:
Big revamp of navigation and nav styling.
Modified: mgmt/cumin/python/cumin/broker.strings
===================================================================
--- mgmt/cumin/python/cumin/broker.strings 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/broker.strings 2007-10-27 02:04:05 UTC (rev 1171)
@@ -22,24 +22,22 @@
<form id="{id}" method="post" action="?">
<!-- <select
onchange="document.getElementById('{id}.submit').submit()"> -->
- <div>
- <div class="sactions">
- <h2>Act on Selected Brokers:</h2>
- <select>
- <option>Choose Action...</option>
- <optgroup label="Actions">
- <option>Shutdown</option>
- <option>Load Balance</option>
- </optgroup>
- <optgroup label="Add to Group">
- <option>East Coast</option>
- <option>West Coast</option>
- <option>Marketing</option>
- <option>Sales</option>
- </optgroup>
- </select>
- {submit}
- </div>
+ <div class="sactions">
+ <h2>Act on Selected Brokers:</h2>
+ <select>
+ <option>Choose Action...</option>
+ <optgroup label="Actions">
+ <option>Shutdown</option>
+ <option>Load Balance</option>
+ </optgroup>
+ <optgroup label="Add to Group">
+ <option>East Coast</option>
+ <option>West Coast</option>
+ <option>Marketing</option>
+ <option>Sales</option>
+ </optgroup>
+ </select>
+ {submit}
</div>
<table class="mobjects">
@@ -143,29 +141,29 @@
</script>
[BrokerView.html]
-<div class="oblock">
- <div class="mstatus green" id="{id}">
- <h2>Broker Status</h2>
+<div class="mstatus green" id="{id}">
+ <h2>Broker Status</h2>
- <div>0 errors, 0 warnings</div>
- </div>
+ <div>0 errors, 0 warnings</div>
+</div>
- <h1>{title}</h1>
+<h1>{title}</h1>
- <dl class="properties">
- <dt>Name</dt><dd>{name}</dd>
- <dt>Cluster</dt><dd>{cluster_link}</dd>
- <dt>Profile</dt><dd>{profile_link}</dd>
- <dt>Version</dt><dd>{version}</dd>
- </dl>
+<table class="props">
+ <tr><th>Name</th><td>{name}</td></tr>
+ <tr><th>Cluster</th><td>{cluster_link}</td></tr>
+ <tr><th>Profile</th><td>{profile_link}</td></tr>
+ <tr><th>Version</th><td>{version}</td></tr>
+ <tr>
+ <th class="actions" colspan="2">
+ <h2>Act on This Broker:</h2>
+ <a href="{href}">Shutdown</a>
+ </th>
+ </tr>
+</table>
- <ul class="actions">
- <li><a href="">Shutdown This Broker</a></li>
- </ul>
+{tabs}
- {tabs}
-</div>
-
[BrokerBrowser.html]
<table class="browser">
<tr>
@@ -176,15 +174,18 @@
<h2>Filter by Group</h2>
<ul class="slist">{group_filters}</ul>
+
<h2>Filter by Profile</h2>
<ul class="slist">{profile_filters}</ul>
+
<h2>Filter by Cluster</h2>
<ul class="slist">{cluster_filters}</ul>
</td>
<td class="view">
<ul class="actions">
- <li><a href="">Register New Brokers</a></li>
+ <li><a class="nav" href="{href}">Register New
Brokers</a></li>
</ul>
+
{brokers}
</td>
</tr>
Modified: mgmt/cumin/python/cumin/brokercluster.py
===================================================================
--- mgmt/cumin/python/cumin/brokercluster.py 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/brokercluster.py 2007-10-27 02:04:05 UTC (rev 1171)
@@ -88,7 +88,7 @@
def render_name(self, session, cluster):
return cluster.name
- class ClusterBrokerTab(BrokerSet):
+ class ClusterBrokerTab(BrokerSetForm):
def render_title(self, session, cluster):
return "Brokers (%i)" % len(cluster.broker_items())
Modified: mgmt/cumin/python/cumin/brokercluster.strings
===================================================================
--- mgmt/cumin/python/cumin/brokercluster.strings 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/brokercluster.strings 2007-10-27 02:04:05 UTC (rev 1171)
@@ -13,7 +13,11 @@
}
[BrokerClusterSet.html]
-<table class="BrokerClusterSet mobjects">
+<ul class="actions">
+ <li><a class="nav" href="{href}">Add Broker
Cluster</a></li>
+</ul>
+
+<table class="mobjects">
<tr>
<th>Broker Cluster</th>
<th>Configuration</th>
@@ -42,39 +46,17 @@
<h1>{title}</h1>
-<dl class="properties">
- <dt>Name</dt><dd>{name}</dd>
-</dl>
-
-<ul class="actions">
- <li><a href="">Shutdown This Cluster</a></li>
-</ul>
-
-{tabs}
-
-[ClusterBrokerTab.html]
-<ul class="actions">
- <li><a href="{add_broker_href}">Add Broker</a></li>
-</ul>
-
-<table class="mobjects">
+<table class="props">
+ <tr><th>Name</th><td>{name}</td></tr>
<tr>
- <th>Broker</th>
- <th>Profile</th>
- <th>Status</th>
- <th>Load</th>
+ <th class="actions" colspan="2">
+ <h2>Act on This Cluster:</h2>
+ <a href="{href}">Shutdown</a>
+ </th>
</tr>
-
- {items}
</table>
-[ClusterBrokerTab.item_html]
-<tr>
- <td>{item_link}</td>
- <td>{item_profile_link}</td>
- <td>{item_status}</td>
- <td>{item_load}</td>
-</tr>
+{tabs}
[ClusterVirtualHostTab.html]
<ul class="actions">
Modified: mgmt/cumin/python/cumin/brokergroup.strings
===================================================================
--- mgmt/cumin/python/cumin/brokergroup.strings 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/brokergroup.strings 2007-10-27 02:04:05 UTC (rev 1171)
@@ -1,6 +1,6 @@
[BrokerGroupSet.html]
<ul class="actions">
- <li><a href="{group_add_href}">Add Broker
Group</a></li>
+ <li><a class="nav" href="{group_add_href}">Add Broker
Group</a></li>
</ul>
<div class="sactions">
@@ -37,16 +37,18 @@
<h1>{title}</h1>
-<dl class="properties">
- <dt>Name</dt><dd>{name}</dd>
- <dt>Category</dt><dd>{category}</dd>
-</dl>
+<table class="props">
+ <tr><th>Name</th><td>{name}</td></tr>
+ <tr><th>Category</th><td>{category}</td></tr>
+ <tr>
+ <th class="actions" colspan="2">
+ <h2>Act on This Group:</h2>
+ <a href="{edit_href}">Edit</a>
+ <a href="{href}">Remove</a>
+ </th>
+ </tr>
+</table>
-<ul class="actions">
- <li><a href="{edit_href}">Edit This Broker
Group</a></li>
- <li><a href="">Remove This Broker Group</a></li>
-</ul>
-
{tabs}
[BrokerGroupForm.html]
Modified: mgmt/cumin/python/cumin/brokerprofile.strings
===================================================================
--- mgmt/cumin/python/cumin/brokerprofile.strings 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/brokerprofile.strings 2007-10-27 02:04:05 UTC (rev 1171)
@@ -1,4 +1,8 @@
[BrokerProfileSet.html]
+<ul class="actions">
+ <li><a class="nav" href="{href}">Add Broker
Profile</a></li>
+</ul>
+
<table class="BrokerProfileSet mobjects">
<tr>
<th>Broker Profile</th>
@@ -13,20 +17,20 @@
</tr>
[BrokerProfileView.html]
-<div class="oblock">
- <h1>{title}</h1>
+<h1>{title}</h1>
- <dl class="properties">
- <dt>Name</dt><dd>{name}</dd>
- </dl>
+<table class="props">
+ <tr><th>Name</th><td>{name}</td></tr>
+ <tr>
+ <th class="actions" colspan="2">
+ <h2>Act on This Profile:</h2>
+ <a href="{href}">Edit</a>
+ </th>
+ </tr>
+</table>
- <ul class="actions">
- <li><a href="">Edit This Profile</a></li>
- </ul>
+{tabs}
- {tabs}
-</div>
-
[ProfileConfigTab.html]
<ul class="actions">
<li><a href="">Add Property</a></li>
Modified: mgmt/cumin/python/cumin/client.py
===================================================================
--- mgmt/cumin/python/cumin/client.py 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/client.py 2007-10-27 02:04:05 UTC (rev 1171)
@@ -19,8 +19,8 @@
self.page().show_client(branch, client).show_view(branch)
return mlink(branch.marshal(), "Client", client.address)
- def render_item_sessions(self, session, client):
- return "10 sessions"
+ def render_item_status(self, session, client):
+ return "Attached"
def render_item_messages_produced(self, session, client):
return client.get_measurement("msgsProduced").get_value()
Modified: mgmt/cumin/python/cumin/client.strings
===================================================================
--- mgmt/cumin/python/cumin/client.strings 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/client.strings 2007-10-27 02:04:05 UTC (rev 1171)
@@ -1,10 +1,11 @@
[ClientSet.html]
<form>
- <button>Close Clients</button>
- <button>Detach Clients</button>
+ <div class="sactions">
+ <h2>Act on Selected Clients:</h2>
+ <button>Close</button>
+ <button>Detach</button>
+ </div>
- <br/><br/>
-
<table class="mobjects">
<tr>
<th><input type="checkbox"/></th>
@@ -24,7 +25,7 @@
<tr>
<td><input type="checkbox"/></td>
<td>{item_link}</td>
- <td>{item_sessions}</td>
+ <td>{item_status}</td>
<td style="text-align: right;">{item_messages_produced}</td>
<td style="text-align: right;">{item_messages_consumed}</td>
<td style="text-align: right;">{item_bytes_produced}</td>
Modified: mgmt/cumin/python/cumin/page.strings
===================================================================
--- mgmt/cumin/python/cumin/page.strings 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/page.strings 2007-10-27 02:04:05 UTC (rev 1171)
@@ -143,6 +143,16 @@
list-style: none;
}
+ul.actions li {
+ display: inline;
+}
+
+a.nav:before {
+ content: "\00BB \0020";
+ font-weight: bold;
+ color: #dc9f2e;
+}
+
div.sactions {
margin: 0;
padding: 0.5em 0.75em;
@@ -156,8 +166,57 @@
margin: 0 0.5em 0 0;
}
+div.mobject div.mactions h2 {
+ display: inline;
+ font-size: 0.9em;
+ font-weight: normal;
+ margin: 0 0.5em 0 0;
+}
+
+table.props {
+ margin: 0 0 1em 0;
+ width: 25em;
+ border-collapse: collapse;
+}
+
+table.props tr {
+ border-top: 1px dotted #ccc;
+ vertical-align: top;
+}
+
+table.props th, table.props td {
+ text-align: left;
+ padding: 0.25em 0.5em;
+}
+
+table.props th {
+ background-color: #f7f7f7;
+ font-weight: normal;
+}
+
+table.props th.actions {
+ padding: 0.5em;
+ background-color: #e7e7f7;
+}
+
+table.props th.actions h2 {
+ display: inline;
+ font-weight: normal;
+ font-size: 0.9em;
+ margin: 0 0.5em 0 0;
+}
+
+button, table.props th.actions a, ul.actions a {
+ margin: 0;
+ border: 1px solid #ddd;
+ padding: 0.25em 0.5em 0.15em 0.5em;
+ background-color: #f7f7f7;
+ color: #000;
+ font-size: 0.9em;
+}
+
dl.properties {
- margin: 1em 0;
+ margin: 0 0 1.5em 0;
width: 25em;
}
@@ -194,12 +253,6 @@
float: right;
}
-a.action:before, ul.actions li:before {
- content: "\00BB \0020";
- font-weight: bold;
- color: #dc9f2e;
-}
-
ul.mobjects .flags {
font-size: small;
font-style: italic;
@@ -294,8 +347,6 @@
}
form.mform button {
- border-style: groove;
- padding: 0.25em 0.5em;
margin: 0.5em;
}
@@ -466,7 +517,7 @@
<div id="head">
<ul id="whonav">
<li>Hi, <strong>nsantos</strong></li>
- <li><a class="action" href="">Log
Out</a></li>
+ <li><a class="nav" href="">Log
Out</a></li>
</ul>
<a id="logo" href="{href}"><img
src="resource?name=logo.png"/></a>
@@ -488,31 +539,3 @@
<ul class="TabSet tabs">{tabs}</ul>
<div class="TabSet mode">{mode}</div>
</div>
-
-[BrokerProfileTab.html]
-<ul class="actions">
- <li><a href="">Add Broker Profile</a></li>
-</ul>
-
-<table class="mobjects">
- <tr>
- <th>Broker Profile</th>
- </tr>
-
- {items}
-</table>
-
-[BrokerClusterTab.html]
-<ul class="actions">
- <li><a href="">Add Broker Cluster</a></li>
-</ul>
-
-<table class="BrokerClusterSet mobjects">
- <tr>
- <th>Broker Cluster</th>
- <th>Configuration</th>
- <th>Status</th>
- </tr>
-
- {items}
-</table>
Modified: mgmt/cumin/python/cumin/queue.py
===================================================================
--- mgmt/cumin/python/cumin/queue.py 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/queue.py 2007-10-27 02:04:05 UTC (rev 1171)
@@ -118,7 +118,7 @@
def render_title(self, session, queue):
return "Queue '%s'" % queue.name
- def render_queue_name(self, session, queue):
+ def render_name(self, session, queue):
return queue.name
def render_latency_tuning(self, session, queue):
Modified: mgmt/cumin/python/cumin/queue.strings
===================================================================
--- mgmt/cumin/python/cumin/queue.strings 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/queue.strings 2007-10-27 02:04:05 UTC (rev 1171)
@@ -7,10 +7,11 @@
[QueueSet.html]
<form action="{href}" method="get">
- <button type="submit">Purge Messages</button>
+ <div class="sactions">
+ <h2>Act on Selected Queues:</h2>
+ <button>Purge Messages</button>
+ </div>
- <br/><br/>
-
<table class="QueueSet mobjects">
<tr>
<th><input type="checkbox"/></th>
@@ -118,23 +119,23 @@
</div>
[QueueView.html]
-<div class="QueueView oblock">
- {status}
+{status}
- <h1><img src="resource?name=queue-36.png"> {title}</h1>
+<h1><img src="resource?name=queue-36.png"> {title}</h1>
- <dl class="properties">
- <dt>Name</dt><dd>{queue_name}</dd>
- <dt>Latency Tuning</dt><dd>{latency_tuning}</dd>
- </dl>
+<table class="props">
+ <tr><th>Name</th><td>{name}</td></tr>
+ <tr><th>Latency
Tuning</th><td>{latency_tuning}</td></tr>
+ <tr>
+ <th class="actions" colspan="2">
+ <h2>Act on This Queue:</h2>
+ <a href="{href}">Purge Messages</a>
+ </th>
+ </tr>
+</table>
- <ul class="actions">
- <li><a href="">Purge Messages</a></li>
- </ul>
+{tabs}
- {tabs}
-</div>
-
[QueueBindingSet.html]
<table class="QueueBindingSet mobjects">
<tr>
@@ -230,16 +231,14 @@
</div>
[ConsumerSet.html]
-<select>
- <option>Act on Selection...</option>
- <option>Throttle Consumers</option>
- <option>Start Consumers</option>
- <option>Stop Consumers</option>
- <option>Close Consumers</option>
-</select>
+<div class="sactions">
+ <h2>Act on Selected Consumers:</h2>
+ <button>Start</button>
+ <button>Stop</button>
+ <button>Close</button>
+ <button>Throttle</button>
+</div>
-<br/><br/>
-
<table class="mobjects">
<tr>
<th><input type="checkbox"/></th>
Modified: mgmt/cumin/python/cumin/virtualhost.py
===================================================================
--- mgmt/cumin/python/cumin/virtualhost.py 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/virtualhost.py 2007-10-27 02:04:05 UTC (rev 1171)
@@ -75,7 +75,7 @@
def render_name(self, session, vhost):
return vhost.name
- def render_broker(self, session, vhost):
+ def render_broker_link(self, session, vhost):
broker = vhost.get_broker()
if broker:
@@ -85,7 +85,7 @@
else:
return none()
- def render_broker_cluster(self, session, vhost):
+ def render_cluster_link(self, session, vhost):
cluster = vhost.get_broker_cluster()
if cluster:
Modified: mgmt/cumin/python/cumin/virtualhost.strings
===================================================================
--- mgmt/cumin/python/cumin/virtualhost.strings 2007-10-26 18:39:05 UTC (rev 1170)
+++ mgmt/cumin/python/cumin/virtualhost.strings 2007-10-27 02:04:05 UTC (rev 1171)
@@ -17,20 +17,18 @@
</tr>
[VirtualHostView.html]
-<div class="oblock">
- <div class="mstatus green" id="{id}">
- <h2>Functional Host Status</h2>
+<div class="mstatus green" id="{id}">
+ <h2>Functional Host Status</h2>
- <div>0 errors, 0 warnings</div>
- </div>
+ <div>0 errors, 0 warnings</div>
+</div>
- <h1>{title}</h1>
+<h1>{title}</h1>
- <dl class="properties">
- <dt>Name</dt><dd>{name}</dd>
- <dt>Broker</dt><dd>{broker}</dd>
- <dt>Broker Cluster</dt><dd>{broker_cluster}</dd>
- </dl>
+<table class="props">
+ <tr><th>Name</th><td>{name}</td></tr>
+ <tr><th>Broker</th><td>{broker_link}</td></tr>
+ <tr><th>Cluster</th><td>{cluster_link}</td></tr>
+</table>
- {tabs}
-</div>
+{tabs}