How to reset value of Bootstrap-select after button click

前端 未结 3 1710
陌清茗
陌清茗 2020-12-15 03:13

I am using Bootstrap-select plugin (https://silviomoreto.github.io/bootstrap-select/) for my dropdown select box. After I click a button, I want the box to refresh and the \

3条回答
  •  攒了一身酷
    2020-12-15 04:02

    You can write it in one single line reduces extra piece of code.

    $("#dataPicker").val('default').selectpicker("refresh");
    

提交回复
热议问题