rbrindley: branch rbrindley/welcome_revamp r4184 - in /team/rbrindley/welcome...

SVN commits to the Asterisk-GUI project asterisk-gui-commits at lists.digium.com
Fri Nov 21 01:41:32 CST 2008


Author: rbrindley
Date: Fri Nov 21 01:41:31 2008
New Revision: 4184

URL: http://svn.digium.com/view/asterisk-gui?view=rev&rev=4184
Log:

- added event delegation for toggling visibility of sections
- tweaked more css styling to improve look and feel
- moved legend around to improve look and feel


Modified:
    team/rbrindley/welcome_revamp/config/js/welcome2.js
    team/rbrindley/welcome_revamp/config/welcome2.html

Modified: team/rbrindley/welcome_revamp/config/js/welcome2.js
URL: http://svn.digium.com/view/asterisk-gui/team/rbrindley/welcome_revamp/config/js/welcome2.js?view=diff&rev=4184&r1=4183&r2=4184
==============================================================================
--- team/rbrindley/welcome_revamp/config/js/welcome2.js (original)
+++ team/rbrindley/welcome_revamp/config/js/welcome2.js Fri Nov 21 01:41:31 2008
@@ -24,7 +24,7 @@
 
  	$('#sysstat_right_container').sortable({
 		axis: 'y',
-		containment: 'div.content_container',
+		containment: '#sysstat_right_container',
 		cursor: 'move',
 		handle: 'div.handle',
 		items: '> div:not(#legend)',
@@ -34,7 +34,7 @@
 
  	$('#sysstat_left_container').sortable({
 		axis: 'y',
-		containment: 'div.content_container',
+		containment: '#sysstat_left_container',
 		cursor: 'move',
 		handle: 'div.handle',
 		items: '> div:not(#legend)',
@@ -42,5 +42,23 @@
 		placeholder: 'placeholder'
 	});
 
+	$('body').click( $.delegate({
+		'.minimaxi': function (e) {
+			$(e.target).parents("div.content").children(".body").toggle();
+		}
+	}));
+
 	return;
  });
+
+ jQuery.delegate = function(rules) {
+ return function(e) {
+ 	var target = $(e.target);
+	
+	for (var selector in rules) {
+	        if (target.is(selector)) {
+		 	return rules[selector].apply(this, $.makeArray(arguments));
+		}
+	}
+}
+};

Modified: team/rbrindley/welcome_revamp/config/welcome2.html
URL: http://svn.digium.com/view/asterisk-gui/team/rbrindley/welcome_revamp/config/welcome2.html?view=diff&rev=4184&r1=4183&r2=4184
==============================================================================
--- team/rbrindley/welcome_revamp/config/welcome2.html (original)
+++ team/rbrindley/welcome_revamp/config/welcome2.html Fri Nov 21 01:41:31 2008
@@ -43,6 +43,7 @@
 
 div.content_container {
 	background-color: #FFFFFF;
+	border: 1px solid #6b79a5;
 	-moz-border-radius: 8px;
 	-webkit-border-radius: 8px;
 	margin: 8px;
@@ -71,9 +72,15 @@
 	-webkit-border-radius-topright: 4px;
 }
 
-#sysstat_hdr_container #legend {
+div.content_container div div.handle span.minimaxi {
+	cursor: pointer;
 	display: block;
 	float: right;
+	color: #000000;
+	margin-right: 20px;
+}
+
+#legend {
 	text-align: left;
 }
 
@@ -85,11 +92,23 @@
 }
 
 div.content_container div.content div.body {
-	padding: 4px;
-	border: 1px solid #6b79a5;
-	-moz-border-radius: 4px;
-	-webkit-border-radius: 4px;
-	-webkit-border-radius: 4px;
+	-moz-border-radius: 4px;
+	-webkit-border-radius: 4px;
+}
+
+div.content_container div.content div.body table.list {
+	-moz-border-radius: 4px;
+	-webkit-border-radius: 4px;
+	border-spacing: 0px;
+	border-collapse: collapse;
+	width: 100%;
+	background-color: #ffffff;
+}
+
+div.content_container div.content div.body table.list tr.list_titles {
+	background-color: #6b79a5;
+	color: #ffffff;
+	font-weight: bold;
 }
 
 div.content_container .title {
@@ -129,30 +148,61 @@
 		<span class='refresh_icon' onclick="window.location.reload();" >&nbsp;<img src="images/refresh.png" title=" Refresh " border=0 >&nbsp;</span>
 	</div>
 
+	<div id="sysstat_hdr_container">
+		<div id="ast_uptime"></div>
+		<div id="sys_uptime"></div>
+	</div>
+
 	<div class="left column">
-		<div id="sysstat_hdr_container">
-			<div id="legend">
-				<img src="images/status_green.png" border="0"> Free <br />
-				<img src="images/status_red.png" border="0"> Busy <br />
-				<img src="images/status_gray.png" border="0"> UnAvailable <br />
-				<img src="images/status_orange.png" border="0"> Ringing <br />
-			</div>
-			<div class="clear"></div>
-			<div id="header_title">System Status</div>
-			<div id="ast_uptime"></div>
-			<div id="sys_uptime"></div>
+		<div id="legend">
+			<img src="images/status_green.png" border="0"> Free 
+			<img src="images/status_orange.png" border="0"> Ringing 
+			<img src="images/status_red.png" border="0"> Busy 
+			<img src="images/status_gray.png" border="0"> UnAvailable 
 		</div>
+		<div class="clear"></div>
 		<div id="sysstat_left_container" class="content_container">
 			<div id="sys_status_users" class="content">
-				<div class="handle title">Trunks</div>
-				<div class="body">Trunk placeholder</div>
+				<div class="handle title"> 
+					<span class="minimaxi">[ - ]</span>
+					Trunks
+				</div>
+				<div class="body">
+					<table id="trunks_list" class="list">
+					<tr class="list_titles">
+						<td>Status</td>
+						<td>Trunk</td>
+						<td>Type</td>
+						<td>Username</td>
+						<td>Port/Hostname/IP</td>
+					</tr>
+					</table>
+					Trunk placeholder
+				</div>
 			</div>
 			<div id="sys_status_trunks" class="content">
-				<div class="handle title">Users</div>
-				<div class="body">User placeholder!</div>
+				<div class="handle title"> 
+					<span class="minimaxi">[ - ]</span>
+					Users
+				</div>
+				<div class="body">
+					<table id="users_list" class="list">
+					<tr class="list_titles">
+						<td></td>
+						<td>Extension</td>
+						<td>Name/Label</td>
+						<td>Status</td>
+						<td>Type</td>
+					</tr>
+					</table>
+					User placeholder!
+				</div>
 			</div>
 			<div id="sys_status_queues" class="content">
-				<div class="handle title">Queues</div>
+				<div class="handle title"> 
+					<span class="minimaxi">[ - ]</span>
+					Queues
+				</div>
 				<div class="body">Queue placeholder!</div>
 			</div>
 		</div>
@@ -161,15 +211,24 @@
 	<div class="right column">
 		<div id="sysstat_right_container" class="content_container">
 			<div id="sys_status_agents" class="content">
-				<div class="handle title">Agents</div>
+				<div class="handle title"> 
+					<span class="minimaxi">[ - ]</span>
+					Agents
+				</div>
 				<div class="body">Agent placeholder!</div>
 			</div>
 			<div id="sys_status_meetme" class="content">
-				<div class="handle title">Conference Rooms</div>
+				<div class="handle title"> 
+					<span class="minimaxi">[ - ]</span>
+					Conference Rooms
+				</div>
 				<div class="body">Conference placeholder!</div>
 			</div>
 			<div id="sys_status_plot" class="content">
-				<div class="handle title">Parking Lot</div>
+				<div class="handle title"> 
+					<span class="minimaxi">[ - ]</span>
+					Parking Lot
+				</div>
 				<div class="body">Parking Lot placeholder!</div>
 			</div>
 		</div>




More information about the asterisk-gui-commits mailing list