1. #1
    Sencha User Bogdan0x400's Avatar
    Join Date
    Dec 2010
    Location
    Ukraine, Kiev
    Posts
    55
    Vote Rating
    0
    Bogdan0x400 is on a distinguished road

      0  

    Question autoload items to combobox from jsonstore

    autoload items to combobox from jsonstore


    I have a combobox with defined jsonstore. The jsonstore loads fine - I've checked it in "load" event of jsonstore. The problem is that combobox doesn't update the items itself, and I also can't find any methods to do that manually. The displayField and valueField values are correct. Am I missing something? Or what can be the reason of items not being loaded?
    Code:
    {            xtype: 'combo',
                store: {
                    autoDestroy: true,
                    autoLoad: true,
                    xtype: 'jsonstore',
                    url: "http://someurl"
                    totalProperty: 'count',
                    root: 'result',
                    fields: ["ID", "Name"],
                    remoteSort: true,
                    sortInfo: {
                        field: 'Name',
                        direction: 'ASC'
                    }
                },
                displayField: "Name",
                valueField: "ID",
                forceSelection: true
            }

  2. #2
    Sencha User Bogdan0x400's Avatar
    Join Date
    Dec 2010
    Location
    Ukraine, Kiev
    Posts
    55
    Vote Rating
    0
    Bogdan0x400 is on a distinguished road

      0  

    Default


    Code:
    triggerAction: 'all'
    This is the solution.