Results 1 to 3 of 3

Thread: Manually Set Date Filtersfeature?

  1. #1
    Sencha User
    Join Date
    Jul 2015
    Posts
    15
    Answers
    3

    Default Answered: Manually Set Date Filtersfeature?

    I have been able to manually add filters to the filtersfeature on my grid but am struggling to activate the before/after/on datepicker with a button press. Thank you.

    https://fiddle.sencha.com/#fiddle/163n

    This fiddle sets the date manually but I cant locate the filtersfeature datepickers.

    https://fiddle.sencha.com/#fiddle/5l7

  2. Apply the filter and check the correct boxes in the column menu to indicate to the user that the filter exists. Thank you.

    Update: got it, I was recreating the filter which is not at all needed, just needed appropriate setValue the format of which varies(numeric uses eq, gt, lt)(date before, on, after).

    Code:
    grid.filters.getFilter('data_index_name').setValue({on: new Date('03/07/2016 00:00:01 PM GMT-0600')});
    grid.filters.getFilter('data_index_name').setActive(true);

  3. #2
    Sencha User
    Join Date
    Feb 2013
    Location
    California
    Posts
    11,985
    Answers
    506

    Default

    So when someone clicks the 'Filter' button, are you wanting to apply the filter or activate the date picker?

  4. #3
    Sencha User
    Join Date
    Jul 2015
    Posts
    15
    Answers
    3

    Default

    Apply the filter and check the correct boxes in the column menu to indicate to the user that the filter exists. Thank you.

    Update: got it, I was recreating the filter which is not at all needed, just needed appropriate setValue the format of which varies(numeric uses eq, gt, lt)(date before, on, after).

    Code:
    grid.filters.getFilter('data_index_name').setValue({on: new Date('03/07/2016 00:00:01 PM GMT-0600')});
    grid.filters.getFilter('data_index_name').setActive(true);

Similar Threads

  1. [CLOSED] Sencha CMD + FilterFeature = no css classes loaded
    By AmsTaFFix in forum Sencha Cmd
    Replies: 2
    Last Post: 10 Apr 2014, 11:25 PM
  2. Replies: 1
    Last Post: 8 Aug 2012, 5:52 PM
  3. Replies: 0
    Last Post: 19 Jul 2012, 6:51 AM
  4. Simple ExtJS 4 grid filterfeature
    By harman in forum Ext: Q&A
    Replies: 1
    Last Post: 18 Jun 2012, 8:20 AM
  5. Replies: 0
    Last Post: 28 Apr 2011, 8:17 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
  •