1. #1
    Ext JS Premium Member
    Join Date
    Apr 2007
    Posts
    228
    Vote Rating
    4
    XASD is on a distinguished road

      0  

    Default [2.??] Record.commit()

    [2.??] Record.commit()


    Record.commit() does not take into account if Record has already been commited,so you can get "double" commit,that not desirable in some circumstences.That looks really odd if you remember how careful "change" event handled for TextField and alike(value checked if it's really modified before firing "change").

    Thanks.

  2. #2
    Sencha - Community Support Team mystix's Avatar
    Join Date
    Mar 2007
    Location
    Singapore
    Posts
    6,236
    Vote Rating
    5
    mystix will become famous soon enough

      0  

    Default


    a commit is a commit. what do you mean by "double commits"?
    (i'm thinking along the lines of database commits here.)

    could you post some demo code to better explain your situation?

  3. #3
    Ext JS Premium Member
    Join Date
    Apr 2007
    Posts
    228
    Vote Rating
    4
    XASD is on a distinguished road

      0  

    Default


    a commit is a commit
    exactly-I could not make commit second time.
    Code of commit method for Record:
    Code:
            this.dirty = false;
            delete this.modified;
            this.editing = false;
            if(this.store && silent !== true){
                this.store.afterCommit(this);
            }
    all this code execute EVERYTIME I call commit(),particularly
    Code:
     this.store.afterCommit(this);
    that makes false assertion,if commit was done earlier.

    Thanks.

  4. #4
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    16,795
    Vote Rating
    602
    evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute

      0  

    Default


    This isn't a bug, if you're explicitly calling commit on the record then that's what it will do.

    If your issue is the afterCommit being called, you can always have it commit silently.
    Evan Trimboli
    Sencha Developer
    Twitter - @evantrimboli
    Don't be afraid of the source code!

Thread Participants: 2

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