如何使用引导表更改clearSearch图标?

问题描述 投票:0回答:1

我有一个启用了清除搜索按钮的表格,但我想将iconfa-trash更改为fa-undo。我在下面尝试过,但这不起作用。

<table id="table"
   data-icons="{ clearSearch: 'fa-undo' }"
   data-search="true"
   data-show-search-clear-button="true">

是否有一种方法只能更改通过clearSearch属性使用的data-icons图标?还是有另一种方法?

bootstrap-table
1个回答
0
投票

我已使用以下命令全局覆盖了clearSearch

  $.extend($.fn.bootstrapTable.defaults.icons, {
    clearSearch: 'fa-undo'
  });
© www.soinside.com 2019 - 2024. All rights reserved.