<template>
<view>
<view class="uni-list">
hahah1
<view class="uni-list-cell">
<view class="uni-list-cell-db">
<picker class="picker" @change="bindPickerChange" :value="index" :range="clientType">
<view class="uni-input">{{clientType[index]}}</view>
</picker>
</view>
</view>
</view>
<view class="section">
<view class="section__title">普通选择器</view>
<picker @change="bindPickerChange" :value="index" :range="clientType">
<view class="pickerhaha">
当前选择:{{clientType[index]}}
</view>
</picker>
</view>
</view>
</template>
<script>
import empty from "../../components/empty.vue";
export default {
components: {
empty,
},
data() {
return {
index: 0,
clientType: ['全新客户', '回收客户', '全部'],
}
},
methods: {
bindPickerChange(e) {
let {
value
} = e.detail
this.index = value
console.log(e, 'e')
}
}
}
</script>
<style lang="scss" scoped>
.picker {
position: fixed;
bottom: 0rpx;
}
.uni-mask {
z-index: 900 !important;
}
.uni-picker-container .uni-picker {
z-index: 1000 !important;
}
</style>
1***@qq.com (作者)
谢谢,是因为HbuilderX版本太低了导致的,更新了一下HbuilderX,然后重新编译上传就好了
2021-02-26 18:29