-
3 Mar 2007 3:07 PM #1
afteredit event ... new value?
afteredit event ... new value?
the new value is not set before the afteredit event is called.
so i attempt to get the new value using:
at the debugger i find that el.value=""Code:afteredit:function(grid, record, field, row, column){ alert(record.data[field]+"-->");//+ed.getValue()); var cm = grid.getColumnModel(); alert("cm: "+cm); var ed = cm.getCellEditor(row, column); alert("ed: "+ed); debugger; var value = ed.getValue(); alert("value: "+value); //alert("-->"+value); }
plz help...I know there is new code planned to replace this but i need something in the mean time.
or the new code
-
4 Mar 2007 8:13 AM #2
I added value to the fireEvent. This seems to be a good temporary fix until Jack makes his next release.
Code:Ext.grid.EditorGrid.prototype.onEditComplete = function(ed, value, startValue){ this.editing = false; ed.un("specialkey", this.onEditorKey, this); if(value != startValue){ var r = this.dataSource.getAt(ed.row); var field = this.colModel.getDataIndex(ed.col); if(this.fireEvent("afteredit", this, r, field, ed.row, ed.col, value) !== false){ r.set(field, value); } } this.view.focusCell(ed.row, ed.col); };
Similar Threads
-
how to stop click event when having dblclick event
By seldon in forum Ext 1.x: Help & DiscussionReplies: 5Last Post: 8 Nov 2011, 12:31 AM -
Am I using Grid.afteredit correctly?
By gordon in forum Ext 2.x: Help & DiscussionReplies: 18Last Post: 5 Aug 2009, 12:05 PM -
Alpha 3 bug? afteredit behaviour
By kimu in forum Ext 2.x: Help & DiscussionReplies: 1Last Post: 12 Mar 2007, 8:18 PM -
afteredit event in an editorgrid sent twice!!
By lucas in forum Ext 2.x: Help & DiscussionReplies: 0Last Post: 9 Mar 2007, 12:59 AM


Reply With Quote