2

I'm using the yadcf plugin (v0.9.3) to perform cumulative filtering on my datatables. The filtering is working fine, however I'm trying to fix the following behaviour :

  • before I select anything in the primary select control, the number of options is 10
  • when I select one of the 10 options, the filtering happens with no issue, but the 9 other options go away, and I need to "deselect the option" to find the complete list again.

here is my yacdf code :

yadcf.init(table, 
   [
      {
          column_number : 2,
                    filter_container_id: 'headergroupFltr',
                    filter_type: 'select',
                    filter_default_label: "Select Head Group",
                    filter_reset_button_text: false,
                    select_type: 'select2',
                    style_class:"js-example-basic-single js-states form-control"
      },
      {
         column_number : 3,
                    filter_container_id: 'subgroupFltr',
                    filter_type: 'select',
                    filter_default_label: "Select Sub Group",
                    filter_reset_button_text: false,
                    select_type: 'select2',
                    style_class:"js-example-basic-single js-states form-control"
      }
   ],
      {
         cumulative_filtering: true ,
         filter_match_mode: "exact" 
      }
);

I would like to keep all options available in the primary filter, even when I select one. How can I acheive that ?

Adam Dulson
  • 283
  • 5
  • 16
  • Hi, currently it's not really possible to use `cumulative_filtering` with `ajax data source` there is an open issue about it :| – Daniel Jul 08 '20 at 12:56
  • Oh OK. Actually the filtering works well. Just that odd behaviour with the dropdowns. – Adam Dulson Jul 08 '20 at 16:42
  • Actually this is my mistake. This datatable does not use ajax. I build it on the fly using php. so no Ajax involved. I've edited my main question. – Adam Dulson Jul 08 '20 at 16:55
  • this is how cumulative works with server/ajax, see this issue https://github.com/vedmack/yadcf/issues/523 – Daniel Jul 08 '20 at 19:52

0 Answers0