Results 1 to 3 of 3

Thread: Documentation bug in Ext.data.Store::add

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User Dumas's Avatar
    Join Date
    Dec 2008
    Location
    Vienna, Austria
    Posts
    589
    Vote Rating
    10
      0  

    Default Documentation bug in Ext.data.Store::add

    REQUIRED INFORMATION




    Sencha Touch version tested:
    • Sencha Touch 2.x documentaiton


    Description:
    • The documentation claims that it takes an array of model instances, but in the example it also takes an model configurations.
    • Also there is often used a singular (model), which is confusing. I had to check the source to be sure how to use it.
      http://docs.sencha.com/touch/2-0/#!/...ore-method-add


    The result that was expected:
    • Please make possible usages clearer.
      myStore.add({some: 'data2'}, {some: 'other data2'});
      myStore.add([{some: 'data2'}, {some: 'other data2'}]);
      myStore.add(new MyApp.data.MyModel({some: 'data2'}));
      ...

    Best regards,
    Roland

  2. #2
    Sencha - Sr Software Engineer mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    39,985
    Vote Rating
    1335
      0  

    Default

    In 2.1 the accepted has been changed to

    Ext.data.Model[]/Ext.data.Model... model
    So it says it can accept an array and a single model. In the example it also shows that it can accept single config objects.
    Mitchell Simoens @LikelyMitch
    Modus Create, Senior Frontend Engineer
    ________________
    Learn BBCode and use it! Checkout the CODE tag!

    Check out my GitHub:
    https://github.com/mitchellsimoens

  3. #3
    Sencha User Dumas's Avatar
    Join Date
    Dec 2008
    Location
    Vienna, Austria
    Posts
    589
    Vote Rating
    10
      0  

    Default

    Ok, the first sentence is not really english "Adds Model instance to the Store. ", but the rest seems ok.

    Bug can be closed.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •