vue 不使用select,实现下拉框功能

html部分:
<-- v-for循环出的div部分 -->

{{item.name}}

{{item1.AttrValueName}}


js部分:

data() {
    return {
      isShow: false,
      i: -1
    };
  },
//实现点击循环出的任意一个下拉框显示
     clickSize (item, index) {
        this.i = index;
        this.isShow = !this.isShow;
    },
//实现选取相应下拉框下拉的值
    getSize (item, item1) {
        this.item.name = item1.AttrValueName;
        this.isShow = !this.isShow;
    },


你可能感兴趣的:(vue,实现下拉功能)