king
2019-12-30 84e806945ef8982508a79e0b62a7bcb0881b108c
src/templates/comtableconfig/tabdragelement/index.jsx
@@ -12,11 +12,14 @@
  SubTable: subtable
}
const Container = ({list, type, setting, placeholder, handleList, handleMenu, deleteMenu }) => {
const Container = ({list, type, groupId, placeholder, handleList, handleMenu, deleteMenu }) => {
  let target = null
  const [cards, setCards] = useState(list)
  const moveCard = (id, atIndex) => {
    const { card, index } = findCard(id)
    if (!card) return
    const _cards = update(cards, { $splice: [[index, 1], [atIndex, 0, card]] })
    setCards(_cards)
    handleList(type, _cards)
@@ -48,7 +51,9 @@
      newcard.icon = ''
      newcard.type = item.subType
      newcard.linkTab = Utils.getuuid()
      newcard.subtabs = []
      newcard.supMenu = ''
      newcard.groupId = groupId
      
      let targetId = cards.length > 0 ? cards[cards.length - 1].uuid : 0
      if (target) {