king
2022-10-22 03a22ec6f9ad7303d10b4c65bb5bc6fa5cbd448a
src/menu/components/card/cardcellcomponent/index.jsx
@@ -5,7 +5,7 @@
import asyncComponent from '@/utils/asyncComponent'
import { getCardCellForm } from './formconfig'
import { getActionForm } from '@/menu/components/share/actioncomponent/formconfig'
import { getActionForm, getBaseTableActionForm } from '@/menu/components/share/actioncomponent/formconfig'
import MKEmitter from '@/utils/events.js'
import MenuUtils from '@/utils/utils-custom.js'
@@ -260,12 +260,10 @@
    if (card.eleType === 'button') {
      this.handleAction(card)
    } else {
      let anchors = MenuUtils.getAnchors(window.GLOB.customMenu.components, cards.uuid) || []
      this.setState({
        visible: true,
        card: card,
        formlist: getCardCellForm(card, cards.type, cards.subtype, cardCell, anchors)
        formlist: getCardCellForm(card, cards, cardCell)
      })
    }
  }
@@ -303,14 +301,23 @@
      }
    }
    let modules = MenuUtils.getSubModules(window.GLOB.customMenu.components, cards.uuid, supId) || []
    let anchors = MenuUtils.getAnchors(window.GLOB.customMenu.components, cards.uuid) || []
    let modules = MenuUtils.getSubModules(window.GLOB.customMenu.components, cards.uuid, supId)
    this.setState({
      actvisible: true,
      card: card,
      formlist: getActionForm(card, functip, cards, usefulFields, modules, anchors)
    })
    if (cards.subtype === 'basetable') {
      this.setState({
        actvisible: true,
        card: card,
        formlist: getBaseTableActionForm(card, functip, cards, usefulFields, modules)
      })
    } else {
      let anchors = MenuUtils.getAnchors(window.GLOB.customMenu.components, cards.uuid) || []
      this.setState({
        actvisible: true,
        card: card,
        formlist: getActionForm(card, functip, cards, usefulFields, modules, anchors)
      })
    }
  }
  /**
@@ -431,13 +438,14 @@
              res.style = {}
            }
          } else if (res.class !== cell.class || res.show !== cell.show || !res.style) {
            let cl = res.class.replace('border-', '')
            let style = {}
            if (res.show === 'link' || res.show === 'icon') {
              style.color = color[res.class]
              style.color = color[cl]
              style.backgroundColor = 'transparent'
            } else {
              style.color = '#ffffff'
              style.backgroundColor = color[res.class]
              style.backgroundColor = color[cl]
            }
            res.style = {...res.style, ...style}
          }