king
2022-10-17 e8edfdadb561cd83bf6e1c3e00d55b8cc2aee6d5
src/templates/sharecomponent/cardcomponent/index.jsx
@@ -5,8 +5,6 @@
import { EditOutlined, CloseOutlined, PlusOutlined } from '@ant-design/icons'
import Utils from '@/utils/utils.js'
import zhCN from '@/locales/zh-CN/model.js'
import enUS from '@/locales/en-US/model.js'
import { getCardDetailForm } from '@/templates/zshare/formconfig'
import MkIcon from '@/components/mk-icon'
import DragDetail from './dragdetail'
@@ -24,7 +22,6 @@
  }
  state = {
    dict: sessionStorage.getItem('lang') !== 'en-US' ? zhCN : enUS,
    modaltype: '',
    formlist: null,
    cardwidth: 0,
@@ -273,11 +270,10 @@
  deletedetail = (cell) => {
    const { card } = this.props
    const { dict } = this.state
    let _this = this
    confirm({
      content: dict['model.confirm'] + dict['model.delete'] + ` - ${cell.content} ?`,
      content: `确定删除 - ${cell.content} ?`,
      onOk() {
        let _details = fromJS(card.details).toJS()
@@ -290,11 +286,10 @@
  }
  deleteElem = (type) => {
    const { dict } = this.state
    let _this = this
    confirm({
      content: dict['model.confirm'] + dict['model.delete'] + '?',
      content: '确定删除?',
      onOk() {
        let _subelement = fromJS(_this.props.card.subelement).toJS()
        _subelement = _subelement.filter(_type => _type !== type)
@@ -331,7 +326,7 @@
  render() {
    const { card } = this.props
    const { dict, modaltype, cardcell, cardwidth, cardheight } = this.state
    const { modaltype, cardcell, cardwidth, cardheight } = this.state
    let _width = '100%'
    if (card.bottom && card.bottom.actions.length > 0) {
      _width = Math.floor((100 / card.bottom.actions.length) * 10000) / 10000 + '%'
@@ -463,7 +458,6 @@
          destroyOnClose
        >
          <CardDetailForm
            dict={dict}
            card={cardcell}
            inputSubmit={this.handleSubmit}
            formlist={this.state.formlist}