Set inline filters in Frappe Datatable

Is there any built-in api to set the inline filters in Frappe Datatable? Else any ideas to set a value in inline filter for a column…

I managed to use functions from Datatable, add added a custom menu item to set inline filter value, and then trigger the filtering.

This could be extended for the functionality needed here

  onload: function (report) {
    report.page.add_menu_item(__("Filter Blanks"), () => {
      const dt = report.datatable,
        header = $(dt.header),
        col_manager = dt.columnmanager;
      const inline_filters = $(header).find('input[data-name="Balance (INR)"]');
      inline_filters.val("=0.00");
      col_manager.applyFilter(col_manager.getAppliedFilters());
    });
  },
6 Likes

inline_filter_by_value