1.用户提交信息过滤表格内容:

  a.设置表格查询参数,并在用户提交按钮时候更新表格

<form id="current_table" class="form-inline" role="form"  onSubmit="return table_filter(this);">
   ...
</form>  
<table id='table1' data-url="...">
    ...
</table>
 <script>

        $("#table1").bootstrapTable({
            'onPageChange':function(number, size){
            },
            'queryParams':function (params){
                s_data=$('form').serializeArray();
                for (key in s_data){
                    item=s_data[key];
                    var1=item["name"];
                    var2=item["value"];
                    params[var1]=var2;
                }
                return  params
            }
        });
        function table_filter(current){
            $("#comsumptionlist").bootstrapTable('refresh', {
                'onPageChange':function(number, size){
                }
            });
            return false;
        }
</script>

 

相关文章:

  • 2022-12-23
  • 2021-11-23
  • 2021-05-16
  • 2022-12-23
  • 2021-10-05
  • 2021-10-24
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-01-04
  • 2021-12-31
  • 2021-12-26
  • 2021-09-15
  • 2021-08-08
相关资源
相似解决方案