From bc464398c7c398c52df3dd7457746bcda3b8e55e Mon Sep 17 00:00:00 2001 From: Kubbo <390378816@qq.com> Date: Mon, 5 Aug 2024 00:56:50 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4table=E6=BB=9A=E5=8A=A8?= =?UTF-8?q?=E5=85=BC=E9=A1=BE=E4=BD=BF=E7=94=A8=E6=BB=9A=E5=8A=A8=E6=9D=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/inject.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/utils/inject.js b/src/utils/inject.js index 709f2d8..1548b68 100644 --- a/src/utils/inject.js +++ b/src/utils/inject.js @@ -152,7 +152,12 @@ Vue.component("scrollTable", { props: { headerCellClassName: 'tableHeader', cellClassName: 'tableCell', stripe: !0, ...config, data: tableData, height: '100%' - }, class: 'scrollTable' + }, class: 'scrollTable', + on: { + 'cell-click': (row, column, cell, event) => { + this.$emit("click", row, column, cell, event) + } + } }, columns.map(col => h("tableColumn", {props: {column: col}})) )