[open-ils-commits] r12057 - trunk/Open-ILS/web/js/dojo/openils/widget
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Feb 3 23:47:40 EST 2009
Author: erickson
Date: 2009-02-03 23:47:38 -0500 (Tue, 03 Feb 2009)
New Revision: 12057
Modified:
trunk/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js
Log:
better handle case where grid structure may exist but just have no columns yet defined
Modified: trunk/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js
===================================================================
--- trunk/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js 2009-02-04 04:46:55 UTC (rev 12056)
+++ trunk/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js 2009-02-04 04:47:38 UTC (rev 12057)
@@ -12,7 +12,8 @@
startup : function() {
this.inherited(arguments);
this.initAutoEnv();
- var existing = (this.structure) ? this.structure[0].cells[0] : [];
+ var existing = (this.structure && this.structure[0].cells[0]) ?
+ this.structure[0].cells[0] : [];
var fields = [];
for(var f in this.sortedFieldList) {
var field = this.sortedFieldList[f];
@@ -27,7 +28,6 @@
this.setStructure([{cells: [fields]}]);
this.setStore(this.buildAutoStore());
},
-
}
);
openils.widget.AutoGrid.markupFactory = dojox.grid.DataGrid.markupFactory;
More information about the open-ils-commits
mailing list