diff --git a/src/components/DndList/index.vue b/src/components/DndList/index.vue index da4afb82..7587daa7 100644 --- a/src/components/DndList/index.vue +++ b/src/components/DndList/index.vue @@ -80,6 +80,13 @@ export default { } }, pushEle(ele) { + for (const item of this.list2) { + if (item.id === ele.id) { + const index = this.list2.indexOf(item) + this.list2.splice(index, 1) + break + } + } if (this.isNotInList1(ele)) { this.list1.push(ele) }