uniapp选择框下拉列表<template>
<!-- 下拉列表 -->
<view>
<view class="index">
<view class="flex-row flex">
<view class="mybill-text">提现⽅式:</view>
<view class="mybill-text">
<select v-model="editSelectTypeLists" class="selectType" @change="selectTypeChange" ref="addRequestState">
<option v-for="(item,index) in selectTypeLists" :key="index" :value="item.value">{{item.name}} </option>
</select>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
selectTypeLists: [{
value: "0",
name: '银⾏卡提现(默认⽅式)'
},
{
value: "1",
name: '提现'
}
],
withdrawType: '',
wxDepositShow: false,
}
},
created() {
this.editSelectTypeLists = this.selectTypeLists[1].value; /* 默认选中 */
},
methods: {
selectTypeChange() {
let index = this.$refs.addRequestState.value
console.log("index:" + index)
},
}
flutter uniapp 哪个好}
</script>