Happy-Coding-Clans / vue-easytable

A powerful data table based on vuejs. You can use it as data grid、Microsoft Excel or Google sheets. It supports virtual scroll、cell edit etc.
https://happy-coding-clans.github.io/vue-easytable/
MIT License
3.69k stars 738 forks source link

[Bug Report] 1、beforeCellValueChange 单元格编辑前 方法 只有在第二次进入编辑模式后才会触发回调 第一次不会回调 #555

Closed tiantianchuangduixiang closed 1 year ago

tiantianchuangduixiang commented 1 year ago

选择要提交 issue 的库

vue-easytable

Issue 类型

Bug

Issue 标题

1、beforeCellValueChange 单元格编辑前 方法 只有在第二次进入编辑模式后才会触发回调 第一次不会回调

仓库版本

v2.24.0

Vue 版本

2.7.1

浏览器

Chrome

系统类型

Windows

重现链接

https://codesandbox.io/p/sandbox/cocky-mcclintock-byz8x8?file=%2Fmain.js&selection=%5B%7B%22endColumn%22%3A1%2C%22endLineNumber%22%3A14%2C%22startColumn%22%3A1%2C%22startLineNumber%22%3A14%7D%5D

重现步骤

进入单元格编辑前 第一次不会触发 beforeCellValueChange 方法

期望的结果是什么?

可以在第一次的时候就触发 beforeCellValueChange返回false 将单元格返回到编辑模式前的状态

实际的结果是什么?

第一次编辑不会触发 beforeCellValueChange 方法 beforeCellValueChange返回false 也不会将单元格返回到编辑模式前的状态

补充说明(可选)

beforeCellValueChange返回false 也不会将单元格返回到编辑模式前的状态 并且在第二次进入编辑模式后 column 取的也是不对的

huangshuwei commented 1 year ago

进入单元格编辑前 第一次不会触发 beforeCellValueChange 方法

beforeCellValueChange是单元格数据变化前的回调,数据编辑之前不会调用该方法。不清楚你的使用场景是什么

tiantianchuangduixiang commented 1 year ago

进入单元格编辑前 第一次不会触发 beforeCellValueChange 方法

beforeCellValueChange是单元格数据变化前的回调,数据编辑之前不会调用该方法。不清楚你的使用场景是什么

哦 好把 那我在提交一个功能需求把