Results 1 to 3 of 3

Thread: [FIXED] sorters config option for Ext.data.Store issue.

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Ext User
    Join Date
    Jul 2010
    Location
    Kanagawa, Japan
    Posts
    12
    Vote Rating
    0
      0  

    Default [FIXED] sorters config option for Ext.data.Store issue.

    Code:
    Ext.setup({
        onReady : function() {
            Ext.regModel('Contact', {
                fields: ['firstName', 'lastName']
            });
            
            var groupingBase = {
                fullscreen: true,
                tpl: '<tpl for="."><div class="contact"><strong>{firstName}</strong> {lastName}</div></tpl>',
                itemSelector: 'div.contact',
                singleSelect: true,
    
                store: new Ext.data.Store({
                    model: 'Contact',
                    sorters: 'firstName',
    
                    data: [
                        {firstName: 'Tommy', lastName: 'Maintz'}, 
                        {firstName: 'Ed', lastName: 'Spencer'}
                    ]
                }),
                listeners: {
                    itemtap: function(dataView, index, item, e) {
                        alert(dataView.getSelectedRecords()[0].get('firstName'));
                    }
                }
            };
            new Ext.List(groupingBase);
        }
    });
    The code displays a List that contains two items 'Tommy', 'Ed'.

    When you tap 'Tommy'. Then you can see the message 'Ed'.
    And when you tap 'Ed'. Then you can see the message 'Tommy'.
    Probably Store and View is not Synchronized.

    sorters config option for Ext.data.Store is undocumented.
    but examples\list\src\index.js uses this config option.

  2. #2
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    18,590
    Vote Rating
    873
      0  

    Default

    What build are you running? I tried your test case with the latest from Git and it worked as I would expect.
    Evan Trimboli
    Twitter - @evantrimboli

  3. #3
    Ext User
    Join Date
    Jul 2010
    Location
    Kanagawa, Japan
    Posts
    12
    Vote Rating
    0
      0  

    Default

    I used Sencha Touch 0.93.

Similar Threads

  1. [FIXED-130] Remove issue of Ext.data.Store
    By leeby in forum Sencha Touch 1.x: Bugs
    Replies: 1
    Last Post: 28 Jul 2010, 11:30 AM
  2. Replies: 4
    Last Post: 19 Jan 2010, 5:59 AM

Posting Permissions

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