Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] 1.14.1版本后getCheckboxState(fielId)就获取不了数据了,getCheckboxState()却能获取到数据,与文档描述不符 #3239

Open
robertyclin opened this issue Dec 31, 2024 · 0 comments · May be fixed by #3252
Assignees
Labels
bug Something isn't working

Comments

@robertyclin
Copy link

Version

1.14.1

Link to Minimal Reproduction

https://visactor.io/vtable/demo/cell-type/checkbox?version=1.14.3

Steps to Reproduce

const records = [
{ productName: 'aaaa', price: 20, check: { text: 'unchecked', checked: false, disable: false } },
{ productName: 'bbbb', price: 18, check: { text: 'checked', checked: true, disable: false } },
{ productName: 'cccc', price: 16, check: { text: 'disable', checked: true, disable: true } },
{ productName: 'cccc', price: 14, check: { text: 'disable', checked: false, disable: true } },
{ productName: 'eeee', price: 12, check: { text: 'checked', checked: false, disable: false } },
{ productName: 'ffff', price: 10, check: { text: 'checked', checked: false, disable: false } },
{ productName: 'gggg', price: 10, check: { text: 'checked', checked: false, disable: false } }
];

const columns = [
{
field: 'isCheck',
title: '',
width: 60,
headerType: 'checkbox',
cellType: 'checkbox',
},
{
field: 'productName',
title: 'productName',
width: 120
},
];
const option = {
records,
columns
};
const tableInstance = new VTable.ListTable(document.getElementById(CONTAINER_ID), option);
window['tableInstance'] = tableInstance;

setTimeout(() => {
const info = tableInstance.getCheckboxState('isCheck');
const infos = tableInstance.getCheckboxState();
console.log(info, infos,'1111111')
}, 4000)

Current Behavior

getCheckboxState(fielId)就获取不了数据了,getCheckboxState()却能获取到数据

Expected Behavior

getCheckboxState(fielId)就获取得了数据了

Environment

- OS:
- Browser:
- Framework:

Any additional comments?

No response

@robertyclin robertyclin added the bug Something isn't working label Dec 31, 2024
@Rui-Sun Rui-Sun linked a pull request Jan 2, 2025 that will close this issue
21 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants