| | |
| | | import Card from './card' |
| | | import './index.scss' |
| | | |
| | | const Container = ({list, handleList, handleMenu, deleteMenu, profileMenu, doubleClickCard }) => { |
| | | const Container = ({type, list, handleList, handleMenu, deleteMenu, profileMenu, doubleClickCard }) => { |
| | | const [cards, setCards] = useState(list) |
| | | const moveCard = (id, atIndex) => { |
| | | const { card, index } = findCard(id) |
| | |
| | | handleList(_cards, copycard) |
| | | } |
| | | |
| | | let cardIds = cards.map(card => card.uuid) |
| | | |
| | | const [, drop] = useDrop({ |
| | | accept: 'action', |
| | | drop(item) { |
| | | if (item.hasOwnProperty('originalIndex')) { |
| | | return |
| | | } |
| | | } |
| | | drop() {} |
| | | }) |
| | | |
| | | const addaction = () => { |
| | |
| | | newcard.label = 'button' |
| | | newcard.sqlType = '' |
| | | newcard.Ot = 'requiredSgl' |
| | | newcard.OpenType = 'excelIn' |
| | | newcard.tabType = 'SubTable' |
| | | newcard.OpenType = 'prompt' |
| | | newcard.icon = '' |
| | | newcard.class = 'default' |
| | | newcard.intertype = 'inner' |
| | |
| | | <Card |
| | | id={card.uuid} |
| | | key={card.uuid} |
| | | cardIds={cardIds} |
| | | type={type} |
| | | card={card} |
| | | moveCard={moveCard} |
| | | copyCard={copyCard} |