Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User
    Join Date
    Oct 2009
    Location
    Bucharest, Romania
    Posts
    70
    Vote Rating
    0
    icflorescu is on a distinguished road

      0  

    Default [CLOSED]Model.load success callback params

    [CLOSED]Model.load success callback params


    According to Ext4 preview documentation, we should get the user object as parameter to success callback of Model.load method:

    Code:
    //get a reference to the User model class
    var User = Ext.ModelMgr.getModel('User');
    
    //Uses the configured RestProxy to make a GET request to /users/123
    User.load(123, {
        success: function(user) {
            console.log(user.getId()); //logs 123
        }
    });
    However, if you run the above example you get an undefined user variable.

  2. #2
    Sencha User
    Join Date
    Dec 2010
    Posts
    7
    Vote Rating
    0
    Pandaxia is on a distinguished road

      0  

    Default


    Check out my post on this thread

  3. #3
    Sencha User
    Join Date
    Oct 2009
    Location
    Bucharest, Romania
    Posts
    70
    Vote Rating
    0
    icflorescu is on a distinguished road

      0  

    Default Got it now...

    Got it now...


    Thank you Pandaxia,

    I've read your post and that entire thread (which I found quite entertaining).
    I know that load can take a second operation parameter, I just didn't need it in the test above.

    Anyway, I've rebuilt my test case and the example works perfectly if the server responds with:
    Code:
    [
    	{
    		"id":		123,
    		"name":		"Name of user 123",
    		"email":	"anemailaddress@gmail.com"
    	}
    ]
    In other words even if you're just trying to load a single entity, it still must be placed inside an array. Thought I should mention this because others may run into the same issue.

    Still, I was wondering, is this the intended behavior or will it be changed before the release?

Similar Threads

  1. success param in callback from store.load is false
    By guys2008 in forum Ext 3.x: Help & Discussion
    Replies: 3
    Last Post: 27 Dec 2011, 1:29 PM
  2. [CLOSED]Error in Ext.data.Model.load ?
    By htammen in forum Ext:Bugs
    Replies: 1
    Last Post: 7 Mar 2011, 8:48 PM
  3. add success property or callback to my own function
    By pasblin in forum Ext 3.x: Help & Discussion
    Replies: 1
    Last Post: 8 Sep 2009, 10:18 PM
  4. Replies: 1
    Last Post: 12 Nov 2008, 7:00 AM

Thread Participants: 1

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..."