Results 1 to 2 of 2

Thread: Does a use an idProperty? If not, bug in docs

    Success! Looks like we've fixed this one. According to our records the fix was applied for a bug in our system in a recent build.
  1. #1
    Sencha Premium User
    Join Date
    Aug 2009
    Amsterdam, NY

    Default Does a use an idProperty? If not, bug in docs

    If you check out the JsonStore docs:
    There is this example below which suggests a json reader can use an 'idProperty' config option. I know Model's use that, but I can't find anything about a reader using it. Does anything other than a Model use the idProperty?

    Also I noticed the 'root' config option for the reader is used but the docs for the reader say to use 'rootProperty', which I assume is the recommended config property to use?

    var store = new{
        // store configs
        storeId: 'myStore',
        proxy: {
            type: 'ajax',
            url: 'get-images.php',
            reader: {
                type: 'json',
                root: 'images',
                idProperty: 'name'       <--------- 
        //alternatively, a name can be given (see for an example)
        fields: ['name', 'url', {name:'size', type: 'float'}, {name:'lastmod', type:'date'}]

  2. #2
    Sencha Premium User evant's Avatar
    Join Date
    Apr 2007
    Sydney, Australia


    Correct, there's no idProperty for the reader, it's a doc bug.
    Twitter - @evantrimboli
    Former Sencha framework engineer, available for consulting.
    As of 2017-09-22 I am not employed by Sencha, all subsequent posts are my own and do not represent Sencha in any way.

Posting Permissions

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