>[danger] 友情提示:构建器目前只支持HisiPHP Pro版本([我要升级](https://www.hisiphp.com/authorize.html))
## 表头工具栏(toolbar)
表头工具栏,主要用来实现某些快捷操作需求,你可以根据自己的需要添加不同的链接按钮或表格操作按钮,支持下拉展示等。
| 参数 | 类型 | 必须 | 默认 | 说明
| --- | --- | --- | --- | --- |
| title | String | Y | | 按钮文本信息 |
| url | String | N | | 链接地址或ajax请求地址 |
| class | String | N | | class属性 |
| options | Array | N | | 扩展选项(js用) |
| childs | Array | N | | 下拉菜单 |
>[info] 如需触发弹窗,class设置为hisi-iframe
> 如需ajax请求,class设置为hisi-ajax
> 如需ajax请求并批量操作表格数据,class设置为hisi-table-ajax
示例代码:
```
$assign['buildTable']['toolbar'] = [
[
'title' => '添加',
'url' => url('add'),
'class' => 'hisi-iframe',
'options' => [
'title' => '添加内容',
],
],
[
'title' => '删除',
'url' => url('del'),
'class' => 'hisi-table-ajax layui-btn-normal hisi-ajax',
],
[
'title' => '更多操作',
'childs' => [
[
'title' => '我是下拉菜单1',
'url' => url('del'),
'class' => 'hisi-ajax',// ajax请求
],
[
'title' => '我是下拉菜单2',
'class' => 'hisi-iframe',// 弹窗
],
[
'title' => '我是下拉菜单3',
],
[
'title' => '我是下拉菜单4',
],
],
],
];
```
![](https://box.kancloud.cn/571d6154b79af5a5eca6888fbe260723_2114x650.jpg)