Iview's select component search function searches both label and value

html:

<i-select v-model="companyId" clearable filterable>
    <i-option v-for="item in managements"
              :value="item.companyId"
              :key="item.companyId">
        {{ item.shortName }}
    </i-option>
</i-select>

js:

[
    {companyId: 6, shortName: ""},
    {companyId: 7, shortName: ""},
    {companyId: 8, shortName: ""},
    {companyId: 9, shortName: ""},
    {companyId: 10, shortName: ""},
    {companyId: 15, shortName: ""}
]

screenshot above:

clipboard.png
searching for "1" will also find out the items with 1 in companyId. Please take a look at

Apr.02,2021

Demo

  

after version 4.2, you can solve

by adding the filter-by-label attribute.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b31619-2b508.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b31619-2b508.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?