From e0165aa22895f076ae70e4aca643418e54821306 Mon Sep 17 00:00:00 2001 From: erickson Date: Wed, 13 May 2009 20:29:54 +0000 Subject: [PATCH] call onPostCreate before we insert the new item into the store git-svn-id: svn://svn.open-ils.org/ILS/trunk@13156 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/web/js/dojo/openils/widget/AutoGrid.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js b/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js index a344437a49..f98421645d 100644 --- a/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js +++ b/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js @@ -285,10 +285,10 @@ if(!dojo._hasResource['openils.widget.AutoGrid']) { disableWidgetTest : this.disableWidgetTest, onPostSubmit : function(r) { var fmObject = openils.Util.readResponse(r); - if(fmObject) - grid.store.newItem(fmObject.toStoreItem()); if(grid.onPostCreate) grid.onPostCreate(fmObject); + if(fmObject) + grid.store.newItem(fmObject.toStoreItem()); setTimeout(function(){ try { grid.selection.select(grid.rowCount-1); -- 2.11.0