可以在页面尾部添加:
<?php
$this->registerJs(<<<JS
$('.filters input, .filters select').change(function() {
return false;
})
JS
);
或者
如果你没有修改搜索框的class的话,搜索框的class应该是 form-control。可以在页面尾部添加:
<?php
$this->registerJs(<<<JS
$('.filters .form-control').change(function() {
return false;
})
JS
);
2 回答1.5k 阅读✓ 已解决
1 回答1.2k 阅读✓ 已解决
2 回答871 阅读✓ 已解决
1 回答1.1k 阅读✓ 已解决
1 回答991 阅读✓ 已解决
2 回答927 阅读
3 回答1.7k 阅读
我也遇到了相同的问题。继承GridView类重写 renderFilters 方法