Vuejs2 Vue Multiselect插件:如何安全删除;添加一个新的“;标签功能?
我正在使用一个名为的插件,它在我的应用程序上运行得非常好但是,插件中有一个我不想要的功能。如何安全地将其卸下? 让我解释一下。 注意:要查看此流程的运行情况,请选择ACME小部件旁边的EDIT,然后在multiselect输入框中搜索现有用户 在multiselect输入框中搜索用户时,如果找到匹配项,则会弹出匹配项供用户选择。那很好。但是,当找不到用户时,会出现一个占位符文本,上面显示以下内容:Vuejs2 Vue Multiselect插件:如何安全删除;添加一个新的“;标签功能?,vuejs2,vue-multiselect,Vuejs2,Vue Multiselect,我正在使用一个名为的插件,它在我的应用程序上运行得非常好但是,插件中有一个我不想要的功能。如何安全地将其卸下? 让我解释一下。 注意:要查看此流程的运行情况,请选择ACME小部件旁边的EDIT,然后在multiselect输入框中搜索现有用户 在multiselect输入框中搜索用户时,如果找到匹配项,则会弹出匹配项供用户选择。那很好。但是,当找不到用户时,会出现一个占位符文本,上面显示以下内容:按enter键创建标记。如果选项不存在,我不想让我的用户能够创建新的标记/选项。如何从该组件中删除该
按enter键创建标记
。如果选项不存在,我不想让我的用户能够创建新的标记/选项。如何从该组件中删除该功能
这是我的多选组件代码:
<multiselect
id="customer_last_name_input"
v-model="values"
:options="options"
label="lastname"
placeholder="Select or search for an existing customer"
track-by="uid"
:loading="isLoading"
:custom-label="customerSelectName"
aria-describedby="searchHelpBlock"
selectLabel
:multiple="true"
:taggable="true"
>
<template
slot="singleLabel"
slot-scope="props"
>{{ props.option.lastname }}, {{props.option.firstname}}</template>
<template slot="option" slot-scope="props">
<strong>{{ props.option.lastname }}</strong>
, {{ props.option.firstname }} —
<small>{{ props.option.email }}</small>
</template>
<!-- <template slot="noResult">Looks like this customer doesn't exist yet.<button class="btn btn-primary" type="button" @click="addCustomer">Add Customer</button></template> -->
</multiselect>
{{props.option.lastname},{{props.option.firstname}
{{props.option.lastname}}
,{{props.option.firstname}}&mdash;
{{props.option.email}
我找到了答案。我只需从multiselect组件中删除taggle=true
prop