【问题标题】:Is there any way to pass v-chip-group v-model id not index of item?有没有办法传递 v-chip-group v-model id 而不是项目索引?
【发布时间】:2020-08-24 06:27:07
【问题描述】:

https://codepen.io/xnkka/pen/GRZrQmV?editors=1010 - 在这个例子中,我有三个带有标签的类别,其中之一:“All” - 包含来自另一个类别的所有标签,所以我想在类别之间同步选择标签。

new Vue({
  el: '#app',
  vuetify: new Vuetify(),
  data: () => ({
    selectedTagsOrder:[],
    panel: 0,})
});

【问题讨论】:

    标签: vue.js vuetify.js


    【解决方案1】:

    使用

    :value="tag.id"
    

    在您的芯片上指示 v-chip-group 的 v-model 以使用标签的 id 作为参考

    【讨论】:

      猜你喜欢
      • 2018-01-02
      • 1970-01-01
      • 2020-08-26
      • 2021-03-04
      • 2023-03-23
      • 1970-01-01
      • 1970-01-01
      • 2021-01-02
      • 2021-08-07
      相关资源
      最近更新 更多