From 7449eee8fa9f8a251e9c4e9162030f1e004bae0f Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 15 十月 2020 09:17:04 +0800 Subject: [PATCH] 2020-10-15 --- src/menu/components/card/cardcellcomponent/index.jsx | 40 +++++++++++++++++++++++++++++++++------- 1 files changed, 33 insertions(+), 7 deletions(-) diff --git a/src/menu/components/card/cardcellcomponent/index.jsx b/src/menu/components/card/cardcellcomponent/index.jsx index 3e9eefb..3c7c241 100644 --- a/src/menu/components/card/cardcellcomponent/index.jsx +++ b/src/menu/components/card/cardcellcomponent/index.jsx @@ -8,21 +8,24 @@ import options from '@/store/options.js' import zhCN from '@/locales/zh-CN/model.js' import enUS from '@/locales/en-US/model.js' +import asyncComponent from '@/utils/asyncComponent' import { getCardCellForm } from './formconfig' import { getActionForm } from '@/menu/actioncomponent/formconfig' import MKEmitter from '@/utils/events.js' import ElementForm from './elementform' import DragElement from './dragaction' -import ActionForm from '@/menu/actioncomponent/actionform' -import CreateFunc from '@/templates/zshare/createfunc' -import VerifyCard from '@/templates/zshare/verifycard' -import VerifyPrint from '@/menu/actioncomponent/verifyprint' -import VerifyExcelIn from '@/menu/actioncomponent/verifyexcelin' -import VerifyExcelOut from '@/menu/actioncomponent/verifyexcelout' import './index.scss' const { confirm } = Modal + +const ActionForm = asyncComponent(() => import('@/menu/actioncomponent/actionform')) +const CreateFunc = asyncComponent(() => import('@/templates/zshare/createfunc')) +const VerifyCard = asyncComponent(() => import('@/templates/zshare/verifycard')) +const VerifyPrint = asyncComponent(() => import('@/menu/actioncomponent/verifyprint')) +const VerifyExcelIn = asyncComponent(() => import('@/menu/actioncomponent/verifyexcelin')) +const VerifyExcelOut = asyncComponent(() => import('@/menu/actioncomponent/verifyexcelout')) +// const ModalConfig = asyncComponent(() => import('@/menu/modalconfig')) class CardCellComponent extends Component { static propTpyes = { @@ -375,7 +378,11 @@ let _elements = elements.map(cell => { if (cell.uuid === ele.uuid) { ele.style = cell.style || {} - ele.btnstyle = cell.btnstyle || {} + if (ele.eleType === 'splitline' && cell.eleType !== 'splitline') { + ele.style.paddingTop = '5px' + ele.style.paddingBottom = '5px' + } + return ele } return cell @@ -401,6 +408,7 @@ if (cell.uuid === ele.uuid) { ele.eleType = 'button' ele.style = cell.style || {} + ele.btnstyle = cell.btnstyle || {} return ele } @@ -475,6 +483,10 @@ }) } + handleSubConfig = (item) => { + console.log(item) + } + render() { const { cards } = this.props const { elements, visible, actvisible, profVisible, card, dict } = this.state @@ -487,8 +499,21 @@ handleMenu={this.handleElement} handleStyle={this.handleStyle} profileAction={this.profileAction} + handleSubConfig={this.handleSubConfig} deleteMenu={this.deleteElement} /> + {/* <ModalConfig + menu={this.state.editMenu} + editTab={this.state.editTab} + tabConfig={this.state.tabConfig} + editSubTab={this.state.editSubTab} + subTabConfig={this.state.subTabConfig} + btnTab={this.state.btnTab} + btnTabConfig={this.state.btnTabConfig} + editAction={this.state.editAction} + subConfig={this.state.subConfig} + handleView={this.handleView} + /> */} {/* 缂栬緫鎸夐挳锛氬鍒躲�佺紪杈� */} <Modal title={'缂栬緫鍏冪礌'} @@ -524,6 +549,7 @@ > <ActionForm dict={dict} + type="card" card={card} formlist={this.state.formlist} inputSubmit={this.handleActionSubmit} -- Gitblit v1.8.0