| | |
| | | /** |
| | | * @description Wrap表单配置信息 |
| | | */ |
| | | export default function (wrap, action = [], columns = []) { |
| | | export default function (wrap, action = [], columns = [], toolBtns = []) { |
| | | const wrapForm = [ |
| | | { |
| | | type: 'radio', |
| | |
| | | tooltip: '双击表格中行,触发的按钮。', |
| | | required: false, |
| | | allowClear: true, |
| | | options: action.map(item => ({value: item.uuid, label: item.label})), |
| | | options: [...toolBtns, ...action].map(item => ({value: item.uuid, label: item.label})), |
| | | }, |
| | | { |
| | | type: 'select', |
| | | field: 'autoExec', |
| | | label: '自动执行', |
| | | initval: wrap.autoExec || '', |
| | | tooltip: '初始化自动执行按钮。', |
| | | required: false, |
| | | options: toolBtns.map(item => ({value: item.uuid, label: item.label})) |
| | | }, |
| | | { |
| | | type: 'select', |
| | |
| | | required: false |
| | | }, |
| | | { |
| | | type: 'number', |
| | | field: 'maxPageSize', |
| | | label: '每页最大数', |
| | | initval: wrap.maxPageSize || '', |
| | | min: 10, |
| | | max: 500, |
| | | precision: 0, |
| | | required: false |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | field: 'cacheSearch', |
| | | label: '搜索缓存', |