1. #1
    Ext JS Premium Member
    Join Date
    Mar 2007
    Location
    Virginia, USA
    Posts
    504
    Vote Rating
    0
    vtswingkid is on a distinguished road

      0  

    Default 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:

    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);
    		}
    at the debugger i find that el.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

  2. #2
    Ext JS Premium Member
    Join Date
    Mar 2007
    Location
    Virginia, USA
    Posts
    504
    Vote Rating
    0
    vtswingkid is on a distinguished road

      0  

    Default


    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

  1. how to stop click event when having dblclick event
    By seldon in forum Ext 1.x: Help & Discussion
    Replies: 5
    Last Post: 8 Nov 2011, 12:31 AM
  2. Am I using Grid.afteredit correctly?
    By gordon in forum Ext 2.x: Help & Discussion
    Replies: 18
    Last Post: 5 Aug 2009, 12:05 PM
  3. Alpha 3 bug? afteredit behaviour
    By kimu in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 12 Mar 2007, 8:18 PM
  4. afteredit event in an editorgrid sent twice!!
    By lucas in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 9 Mar 2007, 12:59 AM
Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi