用于数据表的 yadcf:在 select 下拉框中仅显示 filtered/available 值

yadcf for DataTables: Show only filtered/available values in select dropdown-box

对于 select2 下拉框中的值,yadcf 中的数据表是否有办法适应 table.

的当前过滤

这意味着:我只想看到下拉框中的值,这些值现在在 table 中可见。

示例: 到这里: http://yadcf-showcase.appspot.com/DOM_source_chosen.html

并查看我的截图:

过滤第 1 列后,我希望标记列仅显示“标记 1”、“标记 2”、“标记 3”,因为只剩下这些...

有办法吗?

非常感谢!

您应该使用 yadcf

cumulative_filtering 选项

查看现场演示页面 https://yadcf-showcase.appspot.com/cumulative_filtering.html

  • cumulative_filtering Required: false Type: boolean Default value: false Description: Change the default behavior of the filters so its options will be populated from the filtered rows (remaining table data after filtering) only, unlike the normal behavior in which the options of the filters are from all the table data