From ba08e7b5497928f7e8c8ada1a923118a67799466 Mon Sep 17 00:00:00 2001 From: jmal Date: Mon, 16 Mar 2020 18:05:54 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0grid=E5=B8=83=E5=B1=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/home/index.vue | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/views/home/index.vue b/src/views/home/index.vue index b239915..0dd33f2 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -644,9 +644,11 @@ export default { target.ondragenter = function(e){ clearTimeout(loop) + console.log('ondragenter',e,e.relatedTarget,e.relatedTarget.rowIndex) // 由于被拖动的元素 经过tbody中的每一元素都会触发该事件, 但是我们只需要它正在那一行上就行了 let throughRow = judgThroughDom(e) if(throughRow){ + console.log('拖动进入目标元素'+throughRow.rowIndex); // console.log('throughRow',throughRow) if(dragIndex !== throughRow.rowIndex){ if(dragIndex > -1){ @@ -684,6 +686,7 @@ export default { clearTimeout(loop) let throughRow = judgThroughDom(e) if(throughRow){ + console.log('拖动离开目标元素'+throughRow.rowIndex); if(dragIndex !== throughRow.rowIndex){ console.log('拖动离开目标元素'+throughRow.rowIndex); // selectRow.style.height = 'unset'