| | |
| | | return |
| | | } else if (item.type === 'card' || item.type === 'carousel' || item.type === 'timeline') { |
| | | item.action && item.action.forEach(btn => { |
| | | if (btn.hidden === 'true') return |
| | | if (btn.hidden === 'true' || btn.permission === 'false') return |
| | | |
| | | m.children.push({ |
| | | key: btn.uuid, |
| | |
| | | }) |
| | | item.subcards.forEach(card => { |
| | | card.elements && card.elements.forEach(cell => { |
| | | if (cell.eleType !== 'button' || cell.hidden === 'true') return |
| | | if (cell.eleType !== 'button' || cell.hidden === 'true' || cell.permission === 'false') return |
| | | |
| | | m.children.push({ |
| | | key: cell.uuid, |
| | |
| | | }) |
| | | |
| | | card.backElements && card.backElements.forEach(cell => { |
| | | if (cell.eleType !== 'button' || cell.hidden === 'true') return |
| | | if (cell.eleType !== 'button' || cell.hidden === 'true' || cell.permission === 'false') return |
| | | |
| | | m.children.push({ |
| | | key: cell.uuid, |
| | |
| | | }) |
| | | } else if (item.type === 'balcony') { |
| | | item.elements && item.elements.forEach(cell => { |
| | | if (cell.eleType !== 'button' || cell.hidden === 'true') return |
| | | if (cell.eleType !== 'button' || cell.hidden === 'true' || cell.permission === 'false') return |
| | | |
| | | m.children.push({ |
| | | key: cell.uuid, |
| | |
| | | } |
| | | } else if (item.type === 'table') { |
| | | item.action.forEach(btn => { |
| | | if (btn.hidden === 'true') return |
| | | if (btn.hidden === 'true' || btn.permission === 'false') return |
| | | |
| | | m.children.push({ |
| | | key: btn.uuid, |
| | |
| | | loopCol(col.subcols) |
| | | } else if (col.type === 'custom') { |
| | | col.elements.forEach(cell => { |
| | | if (cell.eleType !== 'button' || cell.hidden === 'true') return |
| | | if (cell.eleType !== 'button' || cell.hidden === 'true' || cell.permission === 'false') return |
| | | m.children.push({ |
| | | key: cell.uuid, |
| | | title: cell.label, |
| | |
| | | let config = fromJS(this.state.config).toJS() |
| | | |
| | | if (!this.checkBase()) { |
| | | return |
| | | } else if (this.checklog()) { |
| | | notification.success({ |
| | | top: 92, |
| | | message: '当前配置未修改,无需保存。', |
| | | duration: 5 |
| | | }) |
| | | MKEmitter.emit('completeSave') |
| | | return |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | updateLogConfig = (config) => { |
| | | config.open_edition = this.state.config.open_edition || '' |
| | | |
| | | this.setState({ |
| | | config: null |
| | | }, () => { |