[dss-commits] digitalSTROM web-sources branch, master, updated. 2370d8cceb6aad46e2668a95f7f1409f6c85017a

git version control dss-commits at forum.digitalstrom.org
Thu Dec 17 15:39:04 CET 2009


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "digitalSTROM web-sources".

The branch, master has been updated
       via  2370d8cceb6aad46e2668a95f7f1409f6c85017a (commit)
       via  4f7ced81957b66e19cde0813351a8e50b94bed1e (commit)
       via  5ddab4a6f004ea4f9e5d1cffc7527de2b8e8846a (commit)
       via  62edf7b0566ba80a8874128320b59c1a7ff4d562 (commit)
      from  fa31ec75f6a3df65902637e37949f64e4039f6ec (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 2370d8cceb6aad46e2668a95f7f1409f6c85017a
Author: Matias E. Fernandez <“mfernandez at futurelab.ch”>
Date:   Thu Dec 17 15:38:29 2009 +0100

    Very basic ping function added

commit 4f7ced81957b66e19cde0813351a8e50b94bed1e
Author: Matias E. Fernandez <“mfernandez at futurelab.ch”>
Date:   Thu Dec 17 15:37:39 2009 +0100

    Minor changes to dSM Overview

commit 5ddab4a6f004ea4f9e5d1cffc7527de2b8e8846a
Author: Matias E. Fernandez <“mfernandez at futurelab.ch”>
Date:   Thu Dec 17 15:03:23 2009 +0100

    Added links to setup page
    
    * made header and logo on setup page link to digitalSTROM.org

commit 62edf7b0566ba80a8874128320b59c1a7ff4d562
Author: Matias E. Fernandez <“mfernandez at futurelab.ch”>
Date:   Wed Dec 16 16:36:45 2009 +0100

    Fixed positioning bug
    
    * ... that caused an ExtJS error complaining that there is no center region

-----------------------------------------------------------------------

Changes:
diff --git a/customizing/extjs/resources/css/ds_gui.css b/customizing/extjs/resources/css/ds_gui.css
index 19a1199..fb1d15a 100644
--- a/customizing/extjs/resources/css/ds_gui.css
+++ b/customizing/extjs/resources/css/ds_gui.css
@@ -36,6 +36,10 @@ float:right;
 padding:6px;
 }
 
+h1 a{
+	text-decoration:none;
+	color:#005138;
+}
 
 .ext-el-mask-msg {
     z-index: 20001;
diff --git a/dss-setup-interface/dSS/grid/DevicePanel.js b/dss-setup-interface/dSS/grid/DevicePanel.js
index e7bcd4e..f8c213f 100644
--- a/dss-setup-interface/dSS/grid/DevicePanel.js
+++ b/dss-setup-interface/dSS/grid/DevicePanel.js
@@ -46,9 +46,9 @@ dSS.grid.DevicePanel = Ext.extend(Ext.grid.GridPanel, {
 				}
 			}
 		});
-		
+
 		dSS.grid.DevicePanel.superclass.initComponent.apply(this, arguments);
-		
+
 		// Here you can add functionality that requires the object to
 		// exist, like event handling.
 		this.on(
@@ -61,19 +61,27 @@ dSS.grid.DevicePanel = Ext.extend(Ext.grid.GridPanel, {
 				} else {
 					this.contextMenu.removeAll();
 				}
-				
+
 				var menuItem = new Ext.menu.Item({
 					text: 'Edit Device',
 					icon: '/images/page_white_edit.png',
 					handler: this.editDevice.createDelegate(this, rowIndex, true)
 				});
 				this.contextMenu.add(menuItem)
+
+				var menuItem = new Ext.menu.Item({
+					text: 'Send Diagnostic Ping',
+					icon: '/images/application_osx_terminal.png',
+					handler: this.pingDevice.createDelegate(this, rowIndex, true)
+				});
+				this.contextMenu.add(menuItem)
+
 				var xy = event.getXY();
 				this.contextMenu.showAt(xy);
 			},
 			this
 		);
-		
+
 		this.on(
 			'cellclick',
 			function (grid, rowIndex, columnIndex, event) {
@@ -101,6 +109,7 @@ dSS.grid.DevicePanel = Ext.extend(Ext.grid.GridPanel, {
 			this
 		);
 	},
+
 	editDevice: function(item, event, rowIndex) {
 		var record = this.getStore().getAt(rowIndex);
 		Ext.Msg.prompt('Edit device', 'Name:', function(btn, text){
@@ -131,7 +140,41 @@ dSS.grid.DevicePanel = Ext.extend(Ext.grid.GridPanel, {
 				});
 			}
 		}, this, false, record.get('name'));
+	},
+
+	pingDevice: function(item, event, rowIndex) {
+		var record = this.getStore().getAt(rowIndex);
+		Ext.Ajax.request({
+			url: '/json/debug/pingDevice',
+			disableCaching: true,
+			method: "GET",
+			params: { dsid: record.get('id') },
+			success: function(result, request) {
+				try {
+					var jsonData = Ext.util.JSON.decode(result.responseText);
+					if(jsonData.ok) {
+						var title = 'Ping ' + record.get('id');
+						var message = "HK: " + jsonData.result.qualityHK + "<br/>RK: " + jsonData.result.qualityHK;
+						Ext.MessageBox.show({
+							title: title,
+							msg: message,
+							buttons: Ext.Msg.OK,
+							minWidth: 300
+							});
+					} else {
+						Ext.MessageBox.alert('Ping Error', jsonData.message);
+					}
+				}
+				catch (err) {
+					Ext.MessageBox.alert('Error', 'Could send ping command to dSS: ' + err);
+				}
+			},
+			failure: function(result, request) {
+				Ext.MessageBox.alert('Error', 'Could send ping command to dSS');
+			}
+		});
 	}
+
 });
 
 Ext.reg('dssdevicepanel', dSS.grid.DevicePanel);
diff --git a/dss-setup-interface/dSS/system/dSMOverview.js b/dss-setup-interface/dSS/system/dSMOverview.js
index cf31b48..4614bec 100644
--- a/dss-setup-interface/dSS/system/dSMOverview.js
+++ b/dss-setup-interface/dSS/system/dSMOverview.js
@@ -28,22 +28,23 @@ dSS.system.dSMOverview = Ext.extend(Ext.grid.GridPanel, {
 		this.groupingStore = new Ext.data.GroupingStore({
 					autoDestroy: true,
 					reader: deviceReader,
-					sortInfo: {field: 'modulator', direction: 'ASC'},
+					sortInfo: {field: 'id', direction: 'ASC'},
 					groupOnSort: false,
-					remoteGroup: true,
+					remoteGroup: false,
 					groupField: 'modulator'
 		});
 
 		this.colModel = new Ext.grid.ColumnModel({
 					columns:[
 							{header: 'Modulator', dataIndex: 'modulator'},
-							{header: 'dSID', width: 150, dataIndex: 'id', groupable: false},
-							{header: 'Zone', dataIndex: 'zone', groupable: false}
+							{header: 'dSID', width: 150, dataIndex: 'id'},
+							{header: 'Zone', dataIndex: 'zone'}
 					],
 					defaults: {
-							sortable: false,
+							sortable: true,
 							menuDisabled: true,
-							width: 20
+							width: 100,
+							groupable: false
 					}
 		});
 
@@ -53,11 +54,10 @@ dSS.system.dSMOverview = Ext.extend(Ext.grid.GridPanel, {
 					hideGroupedColumn: true,
 					enableNoGroups: false,
 					enableGroupingMenu: false,
-					groupTextTpl: '{text} ({[values.rs.length]} {[values.rs.length > 1 ? "Items" : "Item"]})'
+					groupTextTpl: '{text} ({[values.rs.length]} {[values.rs.length > 1 ? "Devices" : "Device"]})'
 		});
 
 		Ext.apply(this, {
-			layout: 'border',
 			store: this.groupingStore,
 			colModel: this.colModel,
 			view: groupingView
diff --git a/dss-setup-interface/dss-setup-interface.js b/dss-setup-interface/dss-setup-interface.js
index 46c1b37..258c801 100644
--- a/dss-setup-interface/dss-setup-interface.js
+++ b/dss-setup-interface/dss-setup-interface.js
@@ -12,7 +12,9 @@ Ext.onReady(function(){
 				height: 80, // give north and south regions a height
 				autoEl: {
 					tag: 'div',
-					html:'<img id="logo" src="js/lib/extjs/resources/images/content_img/ds_logo01.gif" alt="dS-Logo"> <h1>digitalSTROM Setup</h1><p>Release 0.6 - November 2009</p> '
+					html:'<a href="http://digitalstrom.org/" alt="visit digitalSTROM.org"><img id="logo" src="js/lib/extjs/resources/images/content_img/ds_logo01.gif" alt="dS-Logo"></a>' +
+								'<h1><a href="http://digitalstrom.org/" alt="visit digitalSTROM.org">digitalSTROM Setup</a></h1>' + 
+								'<p>Release 0.6 - November 2009</p>'
 				}
 			}, {
 				region: 'center',


hooks/post-receive
-- 
digitalSTROM web-sources


More information about the dss-commits mailing list