1. #1
    Sencha User
    Join Date
    Aug 2011
    Location
    india
    Posts
    51
    Vote Rating
    0
    amitkumarchauhan is on a distinguished road

      0  

    Default Unanswered: extjs persist filter criteria & sort oders

    Unanswered: extjs persist filter criteria & sort oders


    I am building grids using extjs, which allows sorting & filtering; same grid is used for tickets as well as for requirements (2 different entities).My requirement is that when user navigates to tickets for 2nd time ;he should get data & filters as per criteria set by him during his earlier visit (Say High priority tickets sorted descending on date identified).
    I am storing this criteria in session; hence i an getting such data as per filter criteria & sort order from server & i can provide Priority=High & Sort order Descending on Date Identified column from server json too but not sure what should be the exact format for grid to show this criteria in date column header filter as well as priority header filter.Help required.

  2. #2
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,652
    Answers
    618
    Vote Rating
    402
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    You can add a filter with something like:

    Code:
    { // button
        text: 'FILTER',
        handler: function() {
     
            var myfilters= [{
                type: 'numeric',
                dataIndex: 'price',
                value: {gt: 50}
            }];
     
            grid.filters.addFilters(myfilters);
        }
    }
    Regards,
    Scott.

  3. #3
    Sencha User
    Join Date
    Aug 2011
    Location
    india
    Posts
    51
    Vote Rating
    0
    amitkumarchauhan is on a distinguished road

      0  

    Default


    This will add new filter i guess, i want when i visit that page 2nd time & click on filter on header of columns it should display selected date identified & rest all filter criteria which were used previously.
    Also sorting icon & order on previously sorted column

  4. #4
    Sencha User
    Join Date
    Aug 2011
    Location
    india
    Posts
    51
    Vote Rating
    0
    amitkumarchauhan is on a distinguished road

      0  

    Default


    Can somebody help?

  5. #5
    Sencha User
    Join Date
    Aug 2011
    Location
    india
    Posts
    51
    Vote Rating
    0
    amitkumarchauhan is on a distinguished road

      0  

    Default


    still looking for help

  6. #6
    Sencha User
    Join Date
    Aug 2011
    Location
    india
    Posts
    51
    Vote Rating
    0
    amitkumarchauhan is on a distinguished road

      0  

    Default


    Still waiting for update

  7. #7
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,652
    Answers
    618
    Vote Rating
    402
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    You will need to save/restore that state of you sort/filter. The grid will not perform this unless you tell it to.
    See if this will help:
    http://www.sencha.com/forum/showthread.php?137142

    Regards,
    Scott.

  8. #8
    Sencha User
    Join Date
    Aug 2011
    Location
    india
    Posts
    51
    Vote Rating
    0
    amitkumarchauhan is on a distinguished road

      0  

    Default


    Thanks, what about sorting column & order?

  9. #9
    Sencha - Support Team scottmartin's Avatar
    Join Date
    Jul 2010
    Location
    Houston, Tx
    Posts
    8,652
    Answers
    618
    Vote Rating
    402
    scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future scottmartin has a brilliant future

      0  

    Default


    When you run the following example and change the column sorting, then reload the grid, does it save the state of the sort?
    http://dev.sencha.com/deploy/ext-4.1...rray-grid.html

    Regards,
    Scott.

  10. #10
    Sencha User
    Join Date
    Aug 2011
    Location
    india
    Posts
    51
    Vote Rating
    0
    amitkumarchauhan is on a distinguished road

      0  

    Default


    Thanks, yes it stores sort order too but it is stored in browser cookies so if cookies are cleared info will get lost.I am storing such information in DB, is it possible to provide both filtering values & sort order during rendering of grid itself ie while configuring grid columns/filters etc?

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar