AutoGrid reloads structure after columnHelpers loads
authorBill Erickson <berick@esilibrary.com>
Thu, 29 Mar 2012 14:03:42 +0000 (10:03 -0400)
committerBill Erickson <berick@esilibrary.com>
Thu, 29 Mar 2012 14:03:42 +0000 (10:03 -0400)
Otherwise, the newly added columns are not recognized by the grid
(unless you happen to have the column picker enabled).

Signed-off-by: Bill Erickson <berick@esilibrary.com>
Open-ILS/web/js/dojo/openils/widget/AutoGrid.js

index f101585..b2aae23 100644 (file)
@@ -45,8 +45,9 @@ if(!dojo._hasResource['openils.widget.AutoGrid']) {
                 this.inherited(arguments);
                 this.initAutoEnv();
 
-                this.attr('structure', this._compileStructure());
+                this.setStructure(this._compileStructure());
                 this._startupGridHelperColumns();
+                this.setStructure(this.structure); // required after _startupGridHelper()
 
                 this.setStore(this.buildAutoStore());
                 this.cachedQueryOpts = {};