DevCloudFE / ng-devui

Angular UI Component Library based on DevUI Design
https://devui.design
MIT License
1.75k stars 210 forks source link

🐛 [Bug]: Select 下拉选择框 文字回显错误 #311

Closed opxdo closed 1 year ago

opxdo commented 1 year ago

Version

ng-devui@15.1.0

Angular Version

15.2.8

Link to minimal reproduction

官网demo https://devui.design/components/zh-cn/select/demo#object-filter

使用对象数组,通过filterKey配置对象显示字段。

Step to reproduce

当 option 的value为 0, false, ""空字符串 时,文字回显不正确。应该显示为 "Option 1", 文本框显示成了 value 值

options = [
    {
      name: 'Option 1',
//      value: 4,
      value: 0, 
    },
    {
      name: 'Option 2',
      value: 8,
    },
    {
      name: 'Option 3',
      value: 16,
    },
    {
      name: 'Option 4',
      value: 32,
    },
  ];

select

What is expected

No response

What is actually happening

No response

Any additional comments (optional)

No response

Simplelegant commented 1 year ago

问题已收到,我们近期修复