1. #1

    Join Date
    Aug 2012
    Posts
    3
    Vote Rating
    0
    abondili is on a distinguished road

      0  

    Default Unanswered: How to create Grid Local filtering?

    Unanswered: How to create Grid Local filtering?


    I have an application with a Grid in it with lots of records. I just wanted to create a search box to filter the grid based on the search criteria. I have seen that there are some UX classes available for it. But I don't know how to integrate those classes in the app and make use of them. It would be more helpful if I have filtering like in the example given in the Sencha Examples.

    Thanks in Advance.



  2. #2
    Sencha Premium Member
    Join Date
    Feb 2012
    Location
    Mülheim an der Ruhr, Germany
    Posts
    79
    Vote Rating
    0
    Answers
    5
    blade226 is on a distinguished road

      0  

    Default


    I tried it so:

    Code:
        // configure whether filter query is encoded or not (initially)
        var encode = false;
        // configure whether filtering is performed locally or remotely (initially)
        var local = true;
        var filters = {
            ftype: 'filters',
            // encode and local configuration options defined previously for easier reuse
            encode: encode, // json encode the filter query
            local: local,   // defaults to false (remote filtering)
            // Filters are most naturally placed in the column definition, but can also be
            // added here.
            filters: [
                {
                    type: 'boolean',
                    dataIndex: 'visible'
                }
            ]
        };
    and in the grid for example:
    Code:
    {header:"CM-Sachgebiet",dataIndex:"sachgebiet", hidden:true,
    filter: {
                    type: 'string'
             }},
              {text:"Casemanager",dataIndex:"cm", hidden:true,            
                        filter: {
                    type: 'string'
                    
                }},

Thread Participants: 1

Tags for this Thread