ThinkChat2.0新版上线,更智能更精彩,支持会话、画图、阅读、搜索等,送10W Token,即刻开启你的AI之旅 广告
## 属性 `$toolbarFilter array 工具栏筛选` ## 方法 设置表格工具栏筛选: ```php $tableBuilder->setToolbarFilter([ 'keyword' => $this->toolbarFilter->text()->label('关键词')->placeholder('请输入账号/姓名')->defaultValue()->attribute(['test' => 1])->uiClass('w-330 mr-3'), //'username' => $this->toolbarFilter->datetime()->style(['width' => '800px'])->label('注册时间')->placeholder('请选择注册时间'), //'username' => $this->toolbarFilter->datetime()->label('注册时间')->placeholder('请选择注册时间'), /*'status' => $this->toolbarFilter->select()->label('用户状态')->uiClass(['layui-col-sm12'])->placeholder('请选择用户状态')->options([ '分组1' => [ 'normal' => '正常', 'deny' => '禁用', ], '分组2' => [ 'A' => '不可以', 'B' => '可以', ], ])->disabled(['deny'])->uiClass('w-330 mr-3'),*/ 'link1' => $this->toolbarFilter->selectLink()->label('联动1')->placeholder('请选择')->route('admin/link')->initOptions([ '测试1' => [ 'a' => 'A', 'b' => 'B' ], '测试2' => [ 'c' => 'C', 'd' => 'D' ], ])->disabled(['d'])->targetLink('link2')->start()->uiClass('w-330'), 'link2' => $this->toolbarFilter->selectLink()->label('')->placeholder('请选择')->route('admin/link')->targetLink('link3')->through()->uiClass('w-330'), 'link3' => $this->toolbarFilter->selectLink()->label('')->placeholder('请选择')->end()->uiClass('w-330'), ]); // $this ``` 获取工具筛选项: ```php $tableBuilder->getToolbarFilter(); // array ```