| | |
| | | /** |
| | | * @description tablecard setting表单配置信息 |
| | | */ |
| | | export function getTableSetting (setting, columns, buttons = []) { |
| | | export function getTableSetting (setting, columns, buttons = [], action = []) { |
| | | let _columns = columns.map(item => ({value: item.field, label: item.label})) |
| | | _columns.push({value: '$Index', label: '序号(前端)'}) |
| | | let appType = sessionStorage.getItem('appType') |
| | |
| | | initval: setting.linkbtn || '', |
| | | required: true, |
| | | options: buttons |
| | | }, |
| | | { |
| | | type: 'radio', |
| | | field: 'swipe', |
| | | label: '滑动按钮', |
| | | initval: setting.swipe || 'true', |
| | | required: false, |
| | | options: [ |
| | | {value: 'true', label: '显示'}, |
| | | {value: 'false', label: '不显示'}, |
| | | ], |
| | | forbid: action.length === 0 || appType !== 'mob' |
| | | } |
| | | ] |
| | | |