| | |
| | | */ |
| | | static openIndexDB (db) { |
| | | try { |
| | | let request = window.indexedDB.open(db, 2) |
| | | let request = window.indexedDB.open(db, 3) |
| | | request.onerror = () => { |
| | | console.warn('IndexedDB 初始化失败!') |
| | | } |
| | |
| | | if (!window.GLOB.IndexDB.objectStoreNames.contains('caches')) { |
| | | window.GLOB.IndexDB.createObjectStore('caches', { keyPath: 'menuid' }) |
| | | } |
| | | if (window.GLOB.systemType === '' && !window.GLOB.IndexDB.objectStoreNames.contains('funcs')) { |
| | | if (!window.GLOB.IndexDB.objectStoreNames.contains('funcs')) { |
| | | window.GLOB.IndexDB.createObjectStore('funcs', { keyPath: 'id' }) |
| | | } |
| | | } |
| | |
| | | if (card.wrap.datatype === 'static') { |
| | | card.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | } else if (cell.datatype === 'dynamic' && cell.field) { |
| | | card.errors.push({ level: 1, detail: `卡片中动态字段“${cell.field}”无效`}) |
| | |
| | | |
| | | card.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | } else if (cell.datatype === 'dynamic' && cell.field && !columns.includes(cell.field)) { |
| | | card.errors.push({ level: 1, detail: `卡片中动态字段“${cell.field}”无效`}) |
| | |
| | | import PropTypes from 'prop-types' |
| | | import { is, fromJS } from 'immutable' |
| | | import { Modal } from 'antd' |
| | | import { MoreOutlined } from '@ant-design/icons' |
| | | import { EditOutlined } from '@ant-design/icons' |
| | | |
| | | |
| | | import MenusForm from './menus' |
| | |
| | | |
| | | return ( |
| | | <> |
| | | <MoreOutlined style={{color: '#1890ff'}} title="节点组" onClick={this.trigger}/> |
| | | <EditOutlined style={{color: '#1890ff'}} title="节点组" onClick={this.trigger}/> |
| | | <Modal |
| | | title="节点组" |
| | | wrapClassName="nodes-field-modal" |
| | |
| | | } |
| | | |
| | | card.action.forEach(cell => { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | }) |
| | | |
| | |
| | | let linkbtn = item.setting.linkbtn || '' |
| | | item.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | if (item.setting.type === 'multi' && appType !== 'mob') { |
| | | item.backElements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | } |
| | | |
| | | card.action.forEach(cell => { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | }) |
| | | |
| | |
| | | let linkbtn = item.setting.linkbtn || '' |
| | | item.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | |
| | | item.backElements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | |
| | | item.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | if (item.setting.type === 'multi' && appType !== 'mob') { |
| | | item.backElements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | let linkbtn = item.setting.linkbtn || '' |
| | | item.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | if (item.setting.type === 'multi' && appType !== 'mob') { |
| | | item.backElements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | let linkbtn = item.setting.linkbtn || '' |
| | | item.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (linkbtn && linkbtn === cell.uuid) { |
| | | linkbtn = '' |
| | |
| | | card.subcards.forEach((item, i) => { |
| | | item.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | } else if (cell.datatype === 'dynamic' && cell.field && !columns.includes(cell.field)) { |
| | | card.errors.push({ level: 1, detail: `卡片中动态字段“${cell.field}”无效`}) |
| | |
| | | card.subcards.forEach(item => { |
| | | item.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | } else if (cell.datatype === 'dynamic' && cell.field) { |
| | | card.errors.push({ level: 1, detail: `卡片中动态字段“${cell.field}”无效`}) |
| | |
| | | card.subcards.forEach((item, i) => { |
| | | item.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | } else if (cell.datatype === 'dynamic' && cell.field && !columns.includes(cell.field)) { |
| | | card.errors.push({ level: 1, detail: `卡片中动态字段“${cell.field}”无效`}) |
| | |
| | | import './index.scss' |
| | | |
| | | const NormalForm = asyncIconComponent(() => import('@/components/normalform')) |
| | | const PasteComponent = asyncIconComponent(() => import('@/menu/components/share/pastecomponent')) |
| | | const PasteForms = asyncIconComponent(() => import('@/menu/components/share/pasteforms')) |
| | | const CopyComponent = asyncIconComponent(() => import('@/menu/components/share/copycomponent')) |
| | | |
| | | const Card = ({ id, card, sort, labelSize, active, moveCard, findCard, closeCard, selectCard, updateGroup, pasteForm }) => { |
| | |
| | | <EditOutlined style={{color: '#1890ff'}} title="编辑"/> |
| | | </NormalForm> |
| | | <CopyComponent type="formgroup" card={card}/> |
| | | <PasteComponent options={['form', 'forms']} updateConfig={(res) => pasteForm(res, id)} /> |
| | | <PasteForms config={card} updateConfig={(res) => pasteForm(res, id)} /> |
| | | <CloseOutlined className="close" type="close" onClick={close} /> |
| | | </div> |
| | | } trigger="hover"> |
| | |
| | | const FormAction = asyncComponent(() => import('../formaction')) |
| | | const NormalHeader = asyncComponent(() => import('@/menu/components/share/normalheader')) |
| | | const CopyComponent = asyncIconComponent(() => import('@/menu/components/share/copycomponent')) |
| | | const PasteComponent = asyncIconComponent(() => import('@/menu/components/share/pastecomponent')) |
| | | const PasteForms = asyncIconComponent(() => import('@/menu/components/share/pasteforms')) |
| | | const UserComponent = asyncIconComponent(() => import('@/menu/components/share/usercomponent')) |
| | | const FieldsComponent = asyncComponent(() => import('@/templates/sharecomponent/fieldscomponent')) |
| | | |
| | |
| | | }) |
| | | } |
| | | |
| | | pasteForm = (res) => { |
| | | pasteForm = (forms, res) => { |
| | | let _config = fromJS(this.state.card).toJS() |
| | | |
| | | _config.subcards[0].fields = forms |
| | | |
| | | if (res.subButton) { |
| | | let that = this |
| | | |
| | | _config.subcards[0].setting.focus = res.focus |
| | | _config.subcards[0].setting.cache = res.cache |
| | | _config.subcards[0].setting.align = res.align |
| | | _config.subcards[0].setting.enable = res.enable |
| | | _config.subcards[0].setting.verticalSpace = res.verticalSpace || '' |
| | | _config.wrap.focus = res.focus |
| | | _config.wrap.cache = res.cache |
| | | _config.wrap.align = res.align |
| | | _config.wrap.enable = res.enable |
| | | _config.wrap.verticalSpace = res.verticalSpace || '' |
| | | |
| | | _config.subcards[0].subButton = res.subButton |
| | | // _config.subcards[0].setting.focus = res.focus |
| | | // _config.subcards[0].setting.cache = res.cache |
| | | // _config.subcards[0].setting.align = res.align |
| | | // _config.subcards[0].setting.enable = res.enable |
| | | // _config.subcards[0].setting.verticalSpace = res.verticalSpace || '' |
| | | // _config.wrap.focus = res.focus |
| | | // _config.wrap.cache = res.cache |
| | | // _config.wrap.align = res.align |
| | | // _config.wrap.enable = res.enable |
| | | // _config.wrap.verticalSpace = res.verticalSpace || '' |
| | | |
| | | _config.subcards[0].fields = res.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | |
| | | confirm({ |
| | | content: '替换表单及按钮配置?', |
| | | content: '是否替换按钮配置?', |
| | | okText: '是', |
| | | cancelText: '否', |
| | | onOk() { |
| | | _config.subcards[0].subButton = res.subButton |
| | | |
| | | that.updateComponent(_config) |
| | | }, |
| | | onCancel() {} |
| | | onCancel() { |
| | | that.updateComponent(_config) |
| | | } |
| | | }) |
| | | return |
| | | } else if (res.fields) { |
| | | if (_config.subcards[0].fields.length > 0) { |
| | | let that = this |
| | | _config.subcards[0].fields = res.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | } else { |
| | | _config.subcards[0].fields = forms |
| | | |
| | | confirm({ |
| | | title: '确定替换表单吗?', |
| | | content: '原表单将删除。', |
| | | onOk() { |
| | | that.updateComponent(_config) |
| | | }, |
| | | onCancel() {} |
| | | }) |
| | | } else { |
| | | _config.subcards[0].fields = res.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | |
| | | this.updateComponent(_config) |
| | | } |
| | | |
| | | return |
| | | this.updateComponent(_config) |
| | | } |
| | | |
| | | let fieldrepet = false // 字段重复 |
| | | |
| | | _config.subcards[0].fields.forEach(item => { |
| | | if (res.field && item.field && item.field.toLowerCase() === res.field.toLowerCase()) { |
| | | fieldrepet = true |
| | | } |
| | | }) |
| | | |
| | | if (fieldrepet) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '字段已存在!', |
| | | duration: 10 |
| | | }) |
| | | return |
| | | } |
| | | _config.subcards[0].fields.push(res) |
| | | |
| | | this.updateComponent(_config) |
| | | |
| | | this.handleForm(res) |
| | | |
| | | notification.success({ |
| | | top: 92, |
| | | message: '粘贴成功!', |
| | | duration: 2 |
| | | }) |
| | | } |
| | | |
| | | getWrapForms = () => { |
| | |
| | | <EditOutlined style={{color: '#1890ff'}} title="编辑"/> |
| | | </NormalForm> |
| | | <CopyComponent type="simpleform" card={card}/> |
| | | <PasteComponent config={card} options={['form', 'forms', 'formgroup']} updateConfig={this.pasteForm} /> |
| | | <PasteForms config={card.subcards[0]} update={this.pasteForm} /> |
| | | <FontColorsOutlined className="style" title="调整样式" onClick={this.changeStyle}/> |
| | | <UserComponent config={card}/> |
| | | <DeleteOutlined className="close" title="删除组件" onClick={() => this.props.deletecomponent(card.uuid)} /> |
| | |
| | | if (res.subtype === 'simpleform') { |
| | | res = res.subcards[0] |
| | | } |
| | | if (res.subButton) { |
| | | let card = fromJS(this.state.card).toJS() |
| | | |
| | | res.uuid = Utils.getuuid() |
| | | res.sort = card.subcards.length + 1 |
| | | let card = fromJS(this.state.card).toJS() |
| | | |
| | | res.fields.forEach(item => { |
| | | item.uuid = Utils.getuuid() |
| | | }) |
| | | res.uuid = Utils.getuuid() |
| | | res.sort = card.subcards.length + 1 |
| | | |
| | | if (!res.prevButton) { |
| | | res.prevButton = {label: '上一步', type: 'prev', enable: 'false', style: {marginRight: '15px', paddingTop: '5px', paddingBottom: '5px'}} |
| | | } |
| | | if (!res.nextButton) { |
| | | res.nextButton = {label: '跳过', type: 'next', enable: 'false', style: {paddingTop: '5px', paddingBottom: '5px'}} |
| | | } |
| | | |
| | | card.subcards.push(res) |
| | | |
| | | this.setState({ |
| | | group: res |
| | | }) |
| | | this.updateComponent(card) |
| | | |
| | | notification.success({ |
| | | top: 92, |
| | | message: '粘贴成功!', |
| | | duration: 2 |
| | | }) |
| | | return |
| | | } |
| | | |
| | | let _config = fromJS(this.state.group).toJS() |
| | | let fieldrepet = false // 字段重复 |
| | | |
| | | _config.fields.forEach(item => { |
| | | if (res.field && item.field && item.field.toLowerCase() === res.field.toLowerCase()) { |
| | | fieldrepet = true |
| | | } |
| | | res.fields.forEach(item => { |
| | | item.uuid = Utils.getuuid() |
| | | }) |
| | | |
| | | if (fieldrepet) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '字段已存在!', |
| | | duration: 10 |
| | | }) |
| | | return |
| | | if (!res.prevButton) { |
| | | res.prevButton = {label: '上一步', type: 'prev', enable: 'false', style: {marginRight: '15px', paddingTop: '5px', paddingBottom: '5px'}} |
| | | } |
| | | _config.fields.push(res) |
| | | if (!res.nextButton) { |
| | | res.nextButton = {label: '跳过', type: 'next', enable: 'false', style: {paddingTop: '5px', paddingBottom: '5px'}} |
| | | } |
| | | |
| | | this.updateGroup(_config) |
| | | |
| | | this.handleForm(res) |
| | | card.subcards.push(res) |
| | | |
| | | this.setState({ |
| | | group: res |
| | | }) |
| | | this.updateComponent(card) |
| | | |
| | | notification.success({ |
| | | top: 92, |
| | |
| | | }) |
| | | } |
| | | |
| | | parseForm = (g, res) => { |
| | | let _group = fromJS(g).toJS() |
| | | let _confirm = false |
| | | |
| | | if (res.copyType === 'form') { |
| | | let fieldrepet = false // 字段重复 |
| | | res.uuid = Utils.getuuid() |
| | | |
| | | _group.fields.forEach(item => { |
| | | if (res.field && item.field && item.field.toLowerCase() === res.field.toLowerCase()) { |
| | | fieldrepet = true |
| | | } |
| | | }) |
| | | |
| | | if (fieldrepet) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '字段已存在!', |
| | | duration: 10 |
| | | }) |
| | | return |
| | | } |
| | | _group.fields.push(res) |
| | | } else { |
| | | if (_group.fields.length > 0) { |
| | | _confirm = true |
| | | } |
| | | |
| | | _group.fields = res.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | } |
| | | |
| | | if (_confirm) { |
| | | let that = this |
| | | confirm({ |
| | | title: '确定替换表单吗?', |
| | | content: '原表单将删除。', |
| | | onOk() { |
| | | that.updateForms(_group) |
| | | }, |
| | | onCancel() {} |
| | | }) |
| | | } else { |
| | | this.updateForms(_group) |
| | | } |
| | | } |
| | | |
| | | updateForms = (_group) => { |
| | | parseForm = (g, forms) => { |
| | | const { group } = this.state |
| | | let card = fromJS(this.state.card).toJS() |
| | | let _group = fromJS(g).toJS() |
| | | |
| | | _group.fields = forms |
| | | |
| | | card.subcards = card.subcards.map(item => { |
| | | if (item.uuid === _group.uuid) { |
| | |
| | | <EditOutlined style={{color: '#1890ff'}} title="编辑"/> |
| | | </NormalForm> |
| | | <CopyComponent type="stepform" card={card}/> |
| | | <PasteComponent config={card} options={['form', 'formgroup', 'simpleform']} updateConfig={this.pasteForm} /> |
| | | <PasteComponent config={card} options={['formgroup', 'simpleform']} updateConfig={this.pasteForm} /> |
| | | <FontColorsOutlined className="style" title="调整样式" onClick={this.changeStyle}/> |
| | | <UserComponent config={card}/> |
| | | <DeleteOutlined className="close" title="删除组件" onClick={() => this.props.deletecomponent(card.uuid)} /> |
| | |
| | | if (res.subtype === 'simpleform') { |
| | | res = res.subcards[0] |
| | | } |
| | | if (res.subButton) { |
| | | let card = fromJS(this.state.card).toJS() |
| | | |
| | | res.uuid = Utils.getuuid() |
| | | res.sort = card.subcards.length + 1 |
| | | let card = fromJS(this.state.card).toJS() |
| | | |
| | | res.fields.forEach(item => { |
| | | item.uuid = Utils.getuuid() |
| | | }) |
| | | res.uuid = Utils.getuuid() |
| | | res.sort = card.subcards.length + 1 |
| | | |
| | | delete res.prevButton |
| | | delete res.nextButton |
| | | |
| | | card.subcards.push(res) |
| | | |
| | | this.setState({ |
| | | group: res |
| | | }) |
| | | this.updateComponent(card) |
| | | |
| | | notification.success({ |
| | | top: 92, |
| | | message: '粘贴成功!', |
| | | duration: 2 |
| | | }) |
| | | return |
| | | } |
| | | |
| | | let _config = fromJS(this.state.group).toJS() |
| | | let fieldrepet = false // 字段重复 |
| | | |
| | | _config.fields.forEach(item => { |
| | | if (res.field && item.field && item.field.toLowerCase() === res.field.toLowerCase()) { |
| | | fieldrepet = true |
| | | } |
| | | res.fields.forEach(item => { |
| | | item.uuid = Utils.getuuid() |
| | | }) |
| | | |
| | | if (fieldrepet) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '字段已存在!', |
| | | duration: 10 |
| | | }) |
| | | return |
| | | } |
| | | _config.fields.push(res) |
| | | delete res.prevButton |
| | | delete res.nextButton |
| | | |
| | | this.updateGroup(_config) |
| | | |
| | | this.handleForm(res) |
| | | card.subcards.push(res) |
| | | |
| | | this.setState({ |
| | | group: res |
| | | }) |
| | | this.updateComponent(card) |
| | | |
| | | notification.success({ |
| | | top: 92, |
| | |
| | | }) |
| | | } |
| | | |
| | | parseForm = (g, res) => { |
| | | let _group = fromJS(g).toJS() |
| | | let _confirm = false |
| | | |
| | | if (res.copyType === 'form') { |
| | | let fieldrepet = false // 字段重复 |
| | | res.uuid = Utils.getuuid() |
| | | |
| | | _group.fields.forEach(item => { |
| | | if (res.field && item.field && item.field.toLowerCase() === res.field.toLowerCase()) { |
| | | fieldrepet = true |
| | | } |
| | | }) |
| | | |
| | | if (fieldrepet) { |
| | | notification.warning({ |
| | | top: 92, |
| | | message: '字段已存在!', |
| | | duration: 10 |
| | | }) |
| | | return |
| | | } |
| | | _group.fields.push(res) |
| | | } else { |
| | | if (_group.fields.length > 0) { |
| | | _confirm = true |
| | | } |
| | | |
| | | _group.fields = res.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | } |
| | | |
| | | if (_confirm) { |
| | | let that = this |
| | | confirm({ |
| | | title: '确定替换表单吗?', |
| | | content: '原表单将删除。', |
| | | onOk() { |
| | | that.updateForms(_group) |
| | | }, |
| | | onCancel() {} |
| | | }) |
| | | } else { |
| | | this.updateForms(_group) |
| | | } |
| | | } |
| | | |
| | | updateForms = (_group) => { |
| | | parseForm = (g, forms) => { |
| | | const { group } = this.state |
| | | let card = fromJS(this.state.card).toJS() |
| | | let _group = fromJS(g).toJS() |
| | | |
| | | _group.fields = forms |
| | | |
| | | card.subcards = card.subcards.map(item => { |
| | | if (item.uuid === _group.uuid) { |
| | |
| | | <EditOutlined style={{color: '#1890ff'}} title="编辑"/> |
| | | </NormalForm> |
| | | <CopyComponent type="tabform" card={card}/> |
| | | <PasteComponent config={card} options={['form', 'formgroup', 'simpleform']} updateConfig={this.pasteForm} /> |
| | | <PasteComponent config={card} options={['formgroup', 'simpleform']} updateConfig={this.pasteForm} /> |
| | | <FontColorsOutlined className="style" title="调整样式" onClick={this.changeStyle}/> |
| | | <UserComponent config={card}/> |
| | | <DeleteOutlined className="close" title="删除组件" onClick={() => this.props.deletecomponent(card.uuid)} /> |
| | |
| | | this.actionFormRef.handleConfirm().then(btn => { |
| | | _actionlist = _actionlist.filter(item => !item.origin || item.uuid === btn.uuid) |
| | | |
| | | if ((btn.OpenType === 'excelIn' || btn.OpenType === 'excelOut') && (!btn.verify || !btn.verify.columns) && config.subtype === 'basetable') { |
| | | let columns = [] |
| | | |
| | | if (btn.OpenType === 'excelOut') { |
| | | config.cols.forEach(item => { |
| | | if (!item.field || item.Hide === 'true') return |
| | | |
| | | let cell = { |
| | | Column: item.field, |
| | | Text: item.label, |
| | | Width: 20, |
| | | abs: 'false', |
| | | output: 'true', |
| | | required: 'false', |
| | | type: 'text', |
| | | uuid: Utils.getuuid() |
| | | } |
| | | |
| | | if (item.type === 'number') { |
| | | cell.type = 'number' |
| | | cell.decimal = item.decimal |
| | | } |
| | | |
| | | columns.push(cell) |
| | | }) |
| | | |
| | | btn.verify = btn.verify || {enable: 'false', dataType: 'default', scripts: []} |
| | | btn.verify.columns = columns |
| | | } else { |
| | | config.cols.forEach(item => { |
| | | if (!item.field || item.Hide === 'true') return |
| | | |
| | | let _type = 'Nvarchar(50)' |
| | | let _limit = '50' |
| | | if (item.type === 'number' && !item.decimal) { |
| | | _type = 'Int' |
| | | _limit = '' |
| | | } else if (item.type === 'number') { |
| | | _type = 'Decimal(18,' + item.decimal + ')' |
| | | _limit = item.decimal |
| | | } |
| | | |
| | | let _cell = { |
| | | uuid: Utils.getuuid(), |
| | | Column: item.field, |
| | | Text: item.label, |
| | | type: _type, |
| | | limit: _limit, |
| | | import: 'true', |
| | | required: 'true' |
| | | } |
| | | |
| | | if (_type !== 'Nvarchar(50)') { |
| | | _cell.min = 0 |
| | | _cell.max = 999999 |
| | | } |
| | | |
| | | columns.push(_cell) |
| | | }) |
| | | |
| | | btn.verify = btn.verify || {sheet: 'Sheet1', default: 'true', range: 1, scripts: [], uniques: []} |
| | | btn.verify.columns = columns |
| | | } |
| | | } |
| | | |
| | | let labelrepet = false |
| | | _actionlist = _actionlist.map(item => { |
| | | if (item.uuid !== btn.uuid && item.label === btn.label) { |
| | |
| | | import Utils from '@/utils/utils.js' |
| | | import MKEmitter from '@/utils/events.js' |
| | | import asyncComponent from '@/utils/asyncComponent' |
| | | import './index.scss' |
| | | // import './index.scss' |
| | | |
| | | const PasteForm = asyncComponent(() => import('@/templates/zshare/pasteform')) |
| | | |
New file |
| | |
| | | import React, {Component} from 'react' |
| | | import PropTypes from 'prop-types' |
| | | import { fromJS } from 'immutable' |
| | | import { Modal, notification, Button } from 'antd' |
| | | import { SnippetsOutlined, QuestionCircleOutlined } from '@ant-design/icons' |
| | | |
| | | import Utils from '@/utils/utils.js' |
| | | import asyncComponent from '@/utils/asyncComponent' |
| | | import './index.scss' |
| | | |
| | | const PasteForm = asyncComponent(() => import('@/templates/zshare/pasteform')) |
| | | |
| | | class PasteController extends Component { |
| | | static propTpyes = { |
| | | config: PropTypes.object, // 组件配置 |
| | | update: PropTypes.func |
| | | } |
| | | |
| | | state = { |
| | | visible: false, |
| | | choVisible: false, |
| | | result: null |
| | | } |
| | | |
| | | pasteSubmit = () => { |
| | | const { config } = this.props |
| | | |
| | | this.pasteFormRef.handleConfirm().then(res => { |
| | | if (!['form', 'forms', 'formgroup', 'simpleform'].includes(res.copyType)) { |
| | | notification.warning({ top: 92, message: '配置信息格式错误!', duration: 5 }) |
| | | return |
| | | } |
| | | |
| | | if (res.copyType === 'form') { |
| | | delete res.copyType |
| | | res = {fields: [res]} |
| | | } |
| | | |
| | | res.fields = res.fields || [] |
| | | res.fields = res.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | |
| | | let fields = res.fields.map(item => item.field ? item.field.toLowerCase() : '') |
| | | |
| | | let repeat = false |
| | | let forms = [] |
| | | if (config.fields) { |
| | | forms = fromJS(config.fields).toJS() |
| | | forms.forEach(item => { |
| | | if (item.field && fields.includes(item.field.toLowerCase())) { |
| | | repeat = true |
| | | } |
| | | }) |
| | | } |
| | | |
| | | if (repeat) { |
| | | this.setState({result: res, choVisible: true, visible: false}) |
| | | return |
| | | } else { |
| | | forms.push(...res.fields) |
| | | } |
| | | |
| | | this.props.update(forms, res) |
| | | |
| | | this.setState({visible: false}) |
| | | |
| | | notification.success({ |
| | | top: 92, |
| | | message: '粘贴成功!', |
| | | duration: 2 |
| | | }) |
| | | }) |
| | | } |
| | | |
| | | replaceForms = () => { |
| | | const { config } = this.props |
| | | const { result } = this.state |
| | | |
| | | let forms = fromJS(config.fields).toJS() |
| | | let fields = fromJS(result.fields).toJS() |
| | | let repeats = [] |
| | | |
| | | forms = forms.map(item => { |
| | | if (!item.field) return item |
| | | |
| | | let cell = fields.filter(m => m.field && m.field.toLowerCase() === item.field.toLowerCase())[0] |
| | | if (cell) { |
| | | repeats.push(cell.field) |
| | | return cell |
| | | } |
| | | |
| | | return item |
| | | }) |
| | | |
| | | fields = fields.filter(m => !m.field || !repeats.includes(m.field)) |
| | | |
| | | forms.push(...fields) |
| | | |
| | | this.props.update(forms, result) |
| | | |
| | | this.setState({choVisible: false}) |
| | | } |
| | | |
| | | jumpForms = () => { |
| | | const { config } = this.props |
| | | const { result } = this.state |
| | | |
| | | let forms = fromJS(config.fields).toJS() |
| | | let fields = fromJS(result.fields).toJS() |
| | | let repeats = [] |
| | | |
| | | forms = forms.map(item => { |
| | | if (!item.field) return item |
| | | |
| | | let cell = fields.filter(m => m.field && m.field.toLowerCase() === item.field.toLowerCase())[0] |
| | | if (cell) { |
| | | repeats.push(cell.field) |
| | | } |
| | | |
| | | return item |
| | | }) |
| | | |
| | | fields = fields.filter(m => !m.field || !repeats.includes(m.field)) |
| | | |
| | | forms.push(...fields) |
| | | |
| | | this.props.update(forms, result) |
| | | |
| | | this.setState({choVisible: false}) |
| | | } |
| | | |
| | | render() { |
| | | const { type } = this.props |
| | | const { visible, choVisible } = this.state |
| | | |
| | | return ( |
| | | <div style={{display: 'inline-block'}}> |
| | | {type === 'toolbar' ? <Button icon="snippets" style={{color: 'purple'}} onClick={() => {this.setState({visible: true})}} >粘贴</Button> : |
| | | <SnippetsOutlined style={{color: 'purple'}} onClick={() => {this.setState({visible: true})}} />} |
| | | <Modal |
| | | title="粘贴" |
| | | visible={visible} |
| | | width={600} |
| | | maskClosable={false} |
| | | onOk={this.pasteSubmit} |
| | | onCancel={() => {this.setState({visible: false})}} |
| | | destroyOnClose |
| | | > |
| | | <PasteForm wrappedComponentRef={(inst) => this.pasteFormRef = inst} inputSubmit={this.pasteSubmit}/> |
| | | </Modal> |
| | | <Modal |
| | | title="" |
| | | visible={choVisible} |
| | | width={450} |
| | | closable={false} |
| | | maskClosable={false} |
| | | onCancel={() => {this.setState({choVisible: false, result: null})}} |
| | | footer={[ |
| | | <Button key="cancel" onClick={() => this.setState({choVisible: false, result: null})}>取消</Button>, |
| | | <Button key="replace" className="mk-border-purple" style={{color: 'purple'}} onClick={this.replaceForms}>替换</Button>, |
| | | <Button key="confirm" type="primary" onClick={this.jumpForms}>跳过</Button> |
| | | ]} |
| | | destroyOnClose |
| | | > |
| | | <QuestionCircleOutlined style={{color: 'orange', fontSize: '24px', margin: '15px 10px', position: 'relative', top: '2px'}}/>存在重复表单,请选择处理方式。 |
| | | </Modal> |
| | | </div> |
| | | ) |
| | | } |
| | | } |
| | | |
| | | export default PasteController |
| | |
| | | } |
| | | |
| | | card.action.forEach(cell => { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | |
| | | if (doubleClick === cell.uuid) { |
| | | doubleClick = '' |
| | | } |
| | |
| | | card.cols.forEach(col => { |
| | | if (col.type === 'action') { |
| | | col.elements.forEach(cell => { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | |
| | | if (doubleClick === cell.uuid) { |
| | | doubleClick = '' |
| | | } |
| | |
| | | } |
| | | |
| | | card.action.forEach(cell => { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | }) |
| | | |
| | | card.cols.forEach(col => { |
| | | if (col.type === 'action') { |
| | | col.elements.forEach(cell => { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | }) |
| | | } else if (col.type === 'custom') { |
| | |
| | | } |
| | | |
| | | card.action.forEach(cell => { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (doubleClick === cell.uuid) { |
| | | doubleClick = '' |
| | |
| | | card.cols.forEach(col => { |
| | | if (col.type === 'action') { |
| | | col.elements.forEach(cell => { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | if (doubleClick === cell.uuid) { |
| | | doubleClick = '' |
| | |
| | | card.subcards.forEach(col => { |
| | | col.elements.forEach(cell => { |
| | | if (cell.eleType === 'button') { |
| | | if (cell.hidden === 'true') return |
| | | if (cell.OpenType === 'pop' || (cell.OpenType === 'funcbutton' && cell.execMode === 'pop')) { |
| | | if (!cell.modal || cell.modal.fields.length === 0) { |
| | | card.errors.push({ level: 1, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中表单尚未添加`}) |
| | | } |
| | | } else if (cell.OpenType === 'excelIn' && (!cell.verify || !cell.verify.sheet || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导入列未设置!`}) |
| | | } else if (cell.OpenType === 'excelOut' && (!cell.verify || !cell.verify.columns || cell.verify.columns.length === 0)) { |
| | | card.errors.push({ level: 0, detail: `按钮“${cell.label}”中导出列未设置!`}) |
| | | } |
| | | } else if (cell.datatype === 'dynamic' && cell.field && !columns.includes(cell.field)) { |
| | | card.errors.push({ level: 1, detail: `卡片中动态字段“${cell.field}”无效`}) |
| | |
| | | const { Panel } = Collapse |
| | | const { confirm } = Modal |
| | | const ModalForm = asyncComponent(() => import('@/templates/zshare/modalform')) |
| | | const EditComponent = asyncComponent(() => import('@/templates/zshare/editcomponent')) |
| | | const PasteForms = asyncComponent(() => import('@/menu/components/share/pasteforms')) |
| | | const DragElement = asyncComponent(() => import('@/templates/modalconfig/dragelement')) |
| | | const FieldsComponent = asyncComponent(() => import('@/templates/sharecomponent/fieldscomponent')) |
| | | |
| | |
| | | }) |
| | | } |
| | | |
| | | plusFields = (items, type) => { |
| | | plusFields = (items) => { |
| | | let _config = fromJS(this.state.config).toJS() |
| | | |
| | | if (type === 'forms') { |
| | | if (_config.fields.length > 0) { |
| | | let that = this |
| | | _config.fields = items.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | |
| | | confirm({ |
| | | title: '确定替换表单吗?', |
| | | content: '原表单将删除。', |
| | | onOk() { |
| | | that.setState({ |
| | | config: _config |
| | | }) |
| | | }, |
| | | onCancel() {} |
| | | }) |
| | | } else { |
| | | _config.fields = items.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | |
| | | this.setState({ |
| | | config: _config |
| | | }) |
| | | notification.success({ |
| | | top: 92, |
| | | message: '粘贴成功!', |
| | | duration: 2 |
| | | }) |
| | | } |
| | | return |
| | | } |
| | | |
| | | _config.fields.push(...items) |
| | | |
| | |
| | | if (items.length === 1 && items[0].focus) { |
| | | this.handleForm(items[0]) |
| | | } |
| | | }) |
| | | } |
| | | |
| | | pasteFields = (items) => { |
| | | let _config = fromJS(this.state.config).toJS() |
| | | _config.fields = items |
| | | |
| | | this.setState({ |
| | | config: _config |
| | | }) |
| | | } |
| | | |
| | |
| | | <Card title="表单配置" bordered={false} extra={ |
| | | <div> |
| | | <Button type="danger" onClick={this.clearConfig}>清空</Button> |
| | | <EditComponent options={['form', 'forms']} type="formboard" config={this.state.config} plusFields={this.plusFields}/> |
| | | <PasteForms type="toolbar" config={config} update={this.pasteFields}/> |
| | | <Button type="primary" id="save-modal-config" loading={saving} onClick={this.submitConfig}>保存</Button> |
| | | <Button onClick={this.cancelConfig}>返回</Button> |
| | | </div> |
| | |
| | | formItem = (<div className={'am-list-item input ' + (card.place || '')}><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className={'am-input-control ' + card.cursor}>{card.initval ? card.initval : <span style={{color: '#bcbcbc'}}>{card.placeholder || <span style={{color: 'transparent'}}>input</span>}</span> }</div>{card.scan && card.scan !== 'false' ? <div className="am-list-extra"><ScanOutlined /></div> : null}</div></div>) |
| | | } else if (card.type === 'number') { |
| | | formItem = (<div className={'am-list-item input ' + (card.place || '')}><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className={'am-input-control ' + card.cursor}>{card.initval || 0}</div>{card.placeholder ? <div className="am-list-extra" style={{color: '#999999', width: 'auto', lineHeight: 1.5, height: '22px'}}>{card.placeholder}</div> : null}</div></div>) |
| | | } else if (card.type === 'number') { |
| | | formItem = (<div className="am-list-item input"><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className={'am-input-control ' + card.cursor}>{card.initval || <span style={{color: 'transparent'}}>input</span>}</div></div></div>) |
| | | } else if (card.type === 'select' || card.type === 'link' || card.type === 'cascader') { |
| | | formItem = (<div className="am-list-item"><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className="am-input-control">{selectval || '请选择'}</div><div className="am-list-extra"><RightOutlined /></div></div></div>) |
| | | formItem = (<div className={'am-list-item picker ' + (card.place || '')}><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className="am-input-control">{selectval || '请选择'}</div><div className="am-list-extra"><RightOutlined /></div></div></div>) |
| | | } else if (card.type === 'date') { |
| | | let format = 'YYYY-MM-DD' |
| | | if (card.precision === 'hour') { |
| | |
| | | } else if (card.precision === 'second') { |
| | | format = 'YYYY-MM-DD HH:mm:ss' |
| | | } |
| | | formItem = (<div className="am-list-item"><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className="am-input-control">{card.initval ? moment().subtract(card.initval, 'days').format(format) : '请选择'}</div><div className="am-list-extra"><RightOutlined /></div></div></div>) |
| | | formItem = (<div className={'am-list-item picker ' + (card.place || '')}><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className="am-input-control">{card.initval ? moment().subtract(card.initval, 'days').format(format) : '请选择'}</div><div className="am-list-extra"><RightOutlined /></div></div></div>) |
| | | } else if (card.type === 'datemonth') { |
| | | formItem = (<div className="am-list-item"><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className="am-input-control">{card.initval ? moment().subtract(card.initval, 'month').format('YYYY-MM') : '请选择'}</div><div className="am-list-extra"><RightOutlined /></div></div></div>) |
| | | formItem = (<div className={'am-list-item picker ' + (card.place || '')}><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className="am-input-control">{card.initval ? moment().subtract(card.initval, 'month').format('YYYY-MM') : '请选择'}</div><div className="am-list-extra"><RightOutlined /></div></div></div>) |
| | | } else if (card.type === 'datetime') { |
| | | formItem = (<div className="am-list-item"><div className="am-list-line"><div className="am-input-label">{card.label}</div><div className="am-input-control">{card.initval ? moment().subtract(card.initval, 'days').format('YYYY-MM-DD HH:mm') : '请选择'}</div><div className="am-list-extra"><RightOutlined /></div></div></div>) |
| | | } else if (card.type === 'textarea') { |
| | | let height = (card.maxRows || 2) * 25 |
| | | formItem = (<div className="am-list-item check-card"> |
| | | formItem = (<div className={'am-list-item check-card ' + (card.place || '')}> |
| | | <div className="am-list-line"> |
| | | <div className="am-input-label">{card.label}</div> |
| | | <div className="am-input-control"> |
| | |
| | | } |
| | | |
| | | formItem = ( |
| | | <div className={'am-list-item checkbox mk-radio ' + (card.arrange || '')}> |
| | | <div className={'am-list-item checkbox mk-radio ' + (card.arrange || '') + ' ' + (card.place || '')}> |
| | | <div className="am-list-line"> |
| | | <div className="am-input-label">{card.label}</div> |
| | | <div className="am-input-control"> |
| | |
| | | } |
| | | |
| | | formItem = ( |
| | | <div className={'am-list-item checkbox ' + (card.arrange || '')}> |
| | | <div className={'am-list-item checkbox ' + (card.arrange || '') + ' ' + (card.place || '')}> |
| | | <div className="am-list-line"> |
| | | <div className="am-input-label">{card.label}</div> |
| | | <div className="am-input-control"> |
| | |
| | | } else if (card.type === 'split') { |
| | | formItem = <div className="split-line">{card.label}</div> |
| | | } else if (card.type === 'checkcard') { |
| | | formItem = (<div className="am-list-item check-card"> |
| | | formItem = (<div className={'am-list-item check-card ' + (card.place || '')}> |
| | | <div className="am-list-line"> |
| | | {card.hidelabel !== 'true' ? <div className="am-input-label">{card.label}</div> : null} |
| | | <div className="am-input-control"> |
| | |
| | | } |
| | | } |
| | | } |
| | | .am-list-item:not(.up_down) { |
| | | .am-list-line { |
| | | .am-input-label { |
| | | width: 28%; |
| | | max-width: 120px; |
| | | } |
| | | } |
| | | } |
| | | .am-list-item.up_down { |
| | | height: auto; |
| | | .am-list-line { |
| | |
| | | } |
| | | } |
| | | } |
| | | .am-list-item.picker:not(.up_down) { |
| | | .am-list-line { |
| | | .am-input-control { |
| | | padding-right: 0px; |
| | | } |
| | | } |
| | | } |
| | | .am-list-item.up_down.picker { |
| | | .am-list-line { |
| | | .am-input-control { |
| | | line-height: 40px; |
| | | padding-right: 20px; |
| | | } |
| | | .am-list-extra { |
| | | top: auto; |
| | | right: 10px; |
| | | bottom: 13px; |
| | | } |
| | | } |
| | | } |
| | | .ant-form-item.actived { |
| | | .am-input-label { |
| | | color: #1890ff; |
| | |
| | | } |
| | | .am-input-label { |
| | | width: auto; |
| | | } |
| | | } |
| | | } |
| | | .am-list-item.check-card.left_right { |
| | | .am-list-line { |
| | | display: flex; |
| | | .am-input-label { |
| | | width: 28%; |
| | | max-width: 120px; |
| | | line-height: 1; |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | } |
| | | } |
| | | .am-list-item.checkbox.left_right { |
| | | .am-list-line { |
| | | display: flex; |
| | | .ant-checkbox-group { |
| | | float: right; |
| | | } |
| | | .am-input-control { |
| | | padding-right: 0px; |
| | | } |
| | | } |
| | | } |
| | | .am-list-item.checkbox.mk-radio { |
| | | .ant-checkbox-inner { |
| | | border-radius: 50%; |
| | |
| | | |
| | | const { Panel } = Collapse |
| | | const { confirm } = Modal |
| | | const PasteComponent = asyncComponent(() => import('./pastecomponent')) |
| | | const ModalForm = asyncComponent(() => import('@/templates/zshare/modalform')) |
| | | const PasteForms = asyncComponent(() => import('@/menu/components/share/pasteforms')) |
| | | const DragElement = asyncComponent(() => import('@/mob/components/formdragelement')) |
| | | const FieldsComponent = asyncComponent(() => import('@/templates/sharecomponent/fieldscomponent')) |
| | | |
| | |
| | | }) |
| | | } |
| | | |
| | | insert = (config, type) => { |
| | | if (type === 'forms') { |
| | | let _config = fromJS(this.state.config).toJS() |
| | | |
| | | if (_config.fields.length > 0) { |
| | | let that = this |
| | | _config.fields = config.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | |
| | | confirm({ |
| | | title: '确定替换表单吗?', |
| | | content: '原表单将删除。', |
| | | onOk() { |
| | | that.setState({ |
| | | config: _config |
| | | }) |
| | | }, |
| | | onCancel() {} |
| | | }) |
| | | } else { |
| | | _config.fields = config.fields.map(item => { |
| | | item.uuid = Utils.getuuid() |
| | | return item |
| | | }) |
| | | |
| | | this.setState({ |
| | | config: _config |
| | | }) |
| | | notification.success({ |
| | | top: 92, |
| | | message: '粘贴成功!', |
| | | duration: 2 |
| | | }) |
| | | } |
| | | return |
| | | } |
| | | pasteFields = (items) => { |
| | | let _config = fromJS(this.state.config).toJS() |
| | | _config.fields = items |
| | | |
| | | this.setState({ |
| | | config |
| | | }, () => { |
| | | this.handleForm(config.fields[config.fields.length - 1]) |
| | | config: _config |
| | | }) |
| | | } |
| | | |
| | |
| | | <Button type="primary" id="save-modal-config" loading={saving} onClick={this.submitConfig}>保存</Button> |
| | | <Button onClick={this.cancelConfig}>返回</Button> |
| | | <Button type="primary" style={{background: '#26C281', border: 'none'}} onClick={this.triggerCopy}>复制</Button> |
| | | <PasteComponent config={config} updateConfig={this.insert} /> |
| | | <PasteForms type="toolbar" config={config} update={this.pasteFields}/> |
| | | <Button type="danger" onClick={this.clearConfig}>清空</Button> |
| | | <Switch checkedChildren="开" unCheckedChildren="关" defaultChecked={this.state.showField} onChange={(val) => this.setState({showField: val})} /> |
| | | </div> |
| | |
| | | .page-card { |
| | | margin-bottom: 5px; |
| | | } |
| | | } |
| | | } |
| | | // .modal-fields-row.copy { |
| | | // z-index: 3; |
| | | // } |
| | | // .modal-fields-row.copy::before { |
| | | // content: ' '; |
| | | // display: block; |
| | | // position: fixed; |
| | | // left: 0; |
| | | // right: 0; |
| | | // top: 0; |
| | | // bottom: 0; |
| | | // background: rgba(0,0,0,0.2); |
| | | // z-index: 2; |
| | | // } |
| | |
| | | card.precision = 'second' |
| | | } |
| | | |
| | | if (!card.place && appType === 'mob') { |
| | | card.place = ['checkbox', 'radio', 'checkcard', 'textarea'].includes(card.type) ? 'up_down' : 'left_right' |
| | | } |
| | | |
| | | let options = card.options || [] |
| | | if (['select', 'radio', 'link'].includes(card.type) && card.setAll === 'true') { // 兼容 |
| | | options.unshift({ |
| | |
| | | key: 'place', |
| | | label: '排列', |
| | | initVal: card.place || 'left_right', |
| | | tooltip: '提示文字与输入框的位置关系。注:选择器、日期表单在表单样式为阴影时有效', |
| | | tooltip: '提示文字与输入框的位置关系。', |
| | | forbid: appType !== 'mob', |
| | | options: [{ |
| | | value: 'left_right', |
| | |
| | | text: ['initval', 'readonly', 'required', 'hidden', 'readin', 'fieldlength', 'regular', 'interception', 'span', 'labelwidth', 'encryption', 'tooltip', 'extra', 'enter', 'cursor', 'scan', 'splitline', 'placeholder', 'place', 'marginTop', 'marginBottom', 'lenControl', 'inputType'], |
| | | number: ['initval', 'readonly', 'hidden', 'decimal', 'min', 'max', 'readin', 'span', 'labelwidth', 'tooltip', 'extra', 'enter', 'cursor', 'splitline', 'place', 'marginTop', 'marginBottom'], |
| | | select: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'declare', 'setAll', 'linkSubField', 'span', 'labelwidth', 'tooltip', 'extra', 'place', 'emptyText', 'enter', 'splitline', 'dropdown', 'marginTop', 'marginBottom'], |
| | | checkbox: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'fieldlength', 'span', 'labelwidth', 'tooltip', 'extra', 'splitline', 'arrange', 'marginTop', 'marginBottom'], |
| | | radio: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'declare', 'linkSubField', 'span', 'labelwidth', 'tooltip', 'extra', 'setAll', 'emptyText', 'splitline', 'arrange', 'marginTop', 'marginBottom'], |
| | | checkcard: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'span', 'labelwidth', 'display', 'tooltip', 'extra', 'width', 'multiple', 'splitline', 'marginTop', 'marginBottom'], |
| | | checkbox: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'fieldlength', 'span', 'labelwidth', 'tooltip', 'extra', 'place', 'splitline', 'arrange', 'marginTop', 'marginBottom'], |
| | | radio: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'declare', 'linkSubField', 'span', 'labelwidth', 'tooltip', 'extra', 'place', 'setAll', 'emptyText', 'splitline', 'arrange', 'marginTop', 'marginBottom'], |
| | | checkcard: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'span', 'labelwidth', 'display', 'tooltip', 'extra', 'place', 'width', 'multiple', 'splitline', 'marginTop', 'marginBottom'], |
| | | multiselect: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'fieldlength', 'span', 'labelwidth', 'tooltip', 'extra', 'marginTop', 'marginBottom', 'dropdown'], |
| | | link: ['initval', 'readonly', 'required', 'hidden', 'readin', 'resourceType', 'declare', 'setAll', 'linkField', 'linkSubField', 'span', 'place', 'labelwidth', 'tooltip', 'extra', 'emptyText', 'enter', 'splitline', 'dropdown', 'marginTop', 'marginBottom'], |
| | | fileupload: ['readonly', 'required', 'readin', 'fieldlength', 'maxfile', 'fileType', 'span', 'labelwidth', 'tooltip', 'extra', 'compress', 'miniSet', 'splitline', 'marginTop', 'marginBottom', 'maxSize'], |
| | |
| | | date: ['initval', 'readonly', 'required', 'hidden', 'readin', 'span', 'labelwidth', 'tooltip', 'extra', 'declareType', 'mode', 'splitline', 'place', 'marginTop', 'marginBottom', 'minDate', 'maxDate', 'precision'], |
| | | datemonth: ['initval', 'readonly', 'required', 'hidden', 'readin', 'span', 'labelwidth', 'tooltip', 'extra', 'declareType', 'splitline', 'place', 'marginTop', 'marginBottom'], |
| | | datetime: ['initval', 'readonly', 'required', 'hidden', 'readin', 'span', 'labelwidth', 'tooltip', 'extra', 'declareType', 'mode', 'splitline', 'marginTop', 'marginBottom', 'minDate', 'maxDate'], |
| | | textarea: ['initval', 'readonly', 'required', 'hidden', 'readin', 'fieldlength', 'span', 'labelwidth', 'maxRows', 'encryption', 'interception', 'tooltip', 'extra', 'count', 'placeholder', 'marginTop', 'marginBottom'], |
| | | textarea: ['initval', 'readonly', 'required', 'hidden', 'readin', 'fieldlength', 'span', 'labelwidth', 'maxRows', 'encryption', 'interception', 'tooltip', 'extra', 'place', 'count', 'placeholder', 'marginTop', 'marginBottom'], |
| | | cascader: ['readonly', 'required', 'hidden', 'readin', 'resourceType', 'fieldlength', 'span', 'labelwidth', 'tooltip', 'extra', 'place', 'splitline', 'marginTop', 'marginBottom', 'separator'], |
| | | color: ['initval', 'readonly', 'required', 'hidden', 'readin', 'span', 'labelwidth', 'tooltip', 'colorType', 'extra', 'marginTop', 'marginBottom'], |
| | | rate: ['initval', 'readonly', 'required', 'hidden', 'readin', 'span', 'labelwidth', 'splitline', 'tooltip', 'extra', 'marginTop', 'marginBottom', 'allowHalf', 'color', 'rateCount', 'character', 'place'], |