Results 1 to 2 of 2

Thread: this is grid plugin?a combobox select grid page rows

  1. #1
    Sencha User
    Join Date
    Aug 2012
    Posts
    8
    Vote Rating
    0
      0  

    Default this is grid plugin?a combobox select grid page rows

    0.pnghas a plugin for ExtJs4 Grid?

  2. #2
    Touch Premium Member
    Join Date
    Jun 2011
    Posts
    1,101
    Answers
    113
    Vote Rating
    100
      0  

    Default

    I dont know if such a plugin already exists but you can extend the paging toolbar component and add the combobox there:

    Code:
    Ext.create('Ext.PagingToolbar', {
                store: gridStore,
                displayInfo: true,
                displayMsg: ' {0} - {1} of {2}',
                items:
                [
                    {xtype: 'tbseparator'},
                    {
                        xtype:'combo',
                        id: 'pagingSize_store',
                        name: 'pagingSize_store',
                        width: 70,
                        store: store_pageSize,
                        allowBlank: true,
                        displayField: 'value',
                        valueField: 'value',
                        value: '25',
                        queryMode: 'local',
                        editable: false,
                        forceSelection: true,
                        pickerOffset: [0, OFFSET_Y_COMBO],
                        listeners:
                        {
                            select: function(combo, records, eOpts)
                            {
                                var value = records[0].data.value;
                                gridStore.pageSize = value;
                                gridStore.loadPage(1);  // load first page after page size has been changed
                            }
                        }
                    }
                ]
            });

Tags for this Thread

Posting Permissions

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