Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

vc-table里面的EXPAND_COLUMN用indexOf和includes判断导致出问题 #8243

Closed
Labels
@lllianreg

Description

- [ ] I have searched the issues of this repository and believe that this is not a duplicate.

Version

undefined

Environment

all env

Reproduction link

http://www.baidu.com

Steps to reproduce

const columns = ref([{title: '序号', dataIndex: 'key', key: 'key', align: 'center'}, {}])

What is expected?

箭头在第二列

What is actually happening?

源码es\vc-table\hooks\useColumns.js
107行 if (!cloneColumns.includes(EXPAND_COLUMN)) {
117行 const expandColumnIndex = cloneColumns.indexOf(EXPAND_COLUMN);
实际上EXPAND_COLUMN指向一个空对象 并不能用includes or indexOf判断 只能使用expandIconColumnIndex 但是这里会导致使用expandIconColumnIndex一直预警

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /