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]: 表格 slot 中获取到的 rowIndex 变量始终为 -1 #1114

Closed
hashiqi12138 opened this issue Feb 13, 2025 · 7 comments
Closed
Labels
enhancement New feature or request

Comments

@hashiqi12138
Copy link
Contributor

Environment

windows;chrome latest

Version

22.12.0

Version

3.2.0

Link to minimal reproduction

Step to reproduce

开启 table 列 default 插槽

拖入文本

绑定文本变量为 rowIndex

What is expected

文本展示该行的 index

What is actually happening

所有行展示 -1

What is your project name

Any additional comments (optional)

No response

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


Title: 🐛 [Bug]: The rowIndex variable obtained in the table slot is always -1

@chilingling chilingling added the enhancement New feature or request label Feb 24, 2025
@chilingling
Copy link
Member

chilingling commented Feb 24, 2025

@hashiqi12138 应该是TinyVue 组件库api变动了,需要改为: $rowIndex

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


It should be that the internal change of the TinyVue component library is needed to be changed to: $rowIndex

@chilingling
Copy link
Member

@hashiqi12138 跟 TinyVue 组件库维护者 @gimmyhehe 进行了确认:

  • $columnIndex :代表当前渲染数据的列序号
  • columnIndex:代表所有数据的列序号
  • $rowIndex: 代表当前渲染数据的列序号
  • rowIndex:代表所有数据的列序号(当传递的表格数据 data 为非响应式数据时,会一直为 -1
  • seq:代表列序号。

后续TinyVue 官网也会进行更新,欢迎关注。

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


@hashiqi12138 confirmed with TinyVue component library maintainer @gimmyhehe:

  • $columnIndex: The column number representing the current rendered data
  • columnIndex: column number representing all data
  • $rowIndex: The column number representing the current rendered data
  • rowIndex: The column number representing all data (When the passed table data is non-responsive data, it will always be -1)
  • seq: represents the column number.

The TinyVue official website will also be updated in the future, welcome to follow.

@hashiqi12138
Copy link
Contributor Author

测试了下,$rowIndex可以取到正确的序号,可能文档需要更新说明一下,感谢

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


After testing, $rowIndex can get the correct serial number. The document may need to be updated and explained. Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants