当前位置:网站首页>uniapp下拉弹层选择框效果demo(整理)
uniapp下拉弹层选择框效果demo(整理)
2022-06-27 11:55:00 【000000001111】
效果图:
<template>
<picker @change="onRecipientChangeSelect" :value="recipientIndex" :range="recipient" range-key="name">
<view class="uni-input p-0 txtFont">
<!-- {
{
recipient[recipientIndex].name}}<text class="iconfont icon-xia font-sm pl-1"></text> -->
{
{
shopName}}<text class="iconfont icon-xia font-sm pl-1"></text>
</view>
</picker>
</template>
<script>
export default{
data() {
return {
shopName: '全部',
recipient: [
{
id: 18,
name: "门店01"
},
{
id: 19,
name: "门店字数超长门店字数超长门店字数超长门店字数"
},
],
recipientIndex: 0,
dataObject: {
},
}
},
methods: {
onRecipientChangeSelect(e) {
console.log('携带值为', e.detail.value)
// this.recipientIndex = e.detail.value //选择数组的第几个
this.dataObject.shopId = this.recipient[e.detail.value].id; //选择商店id
this.dataObject.shopName = this.recipient[e.detail.value].name; //选择商店name
},
}
}
</script>
边栏推荐
- How to adjust an integer that is entered in Excel but always displays decimals?
- [tcapulusdb knowledge base] tcapulusdb doc acceptance - create business introduction
- 旭日3SDB,安装原版ros
- C/s architecture
- Research Report on the overall scale, major manufacturers, major regions, products and application segments of hydraulic torque in the global market in 2022
- Daily leetcode force deduction (21~25)
- 星际争霸的虫王IA退役2年搞AI,自叹不如了
- StarCraft's Bug King ia retired for 2 years to engage in AI, and lamented that it was inferior
- Maximum path and problem (cherry picking problem)
- Basic usage and principle of fork/join framework
猜你喜欢
![[tcapulusdb knowledge base] tcapulusdb operation and maintenance doc introduction](/img/04/b1194ca3340b23a4fb2091d1b2a44d.png)
[tcapulusdb knowledge base] tcapulusdb operation and maintenance doc introduction

一个有趣的网络掩码的实验

2022ciscn central China Web
![[tcapulusdb knowledge base] tcapulusdb doc acceptance - Introduction to creating game area](/img/b7/2358e8cf1cdaeaba77e52d04cc74d4.png)
[tcapulusdb knowledge base] tcapulusdb doc acceptance - Introduction to creating game area

【TcaplusDB知识库】TcaplusDB-tcapsvrmgr工具介绍(二)

如何修改 node_modules 裏的文件

MapReduce practical cases (customized sorting, secondary sorting, grouping, zoning)

今晚战码先锋润和赛道第2期直播丨如何参与OpenHarmony代码贡献

Rxjs mergeMap 的使用场合

"24 of the 29 students in the class successfully went to graduate school" rushed to the hot search! Where are the remaining five?
随机推荐
uni-app 使用escook/request-miniprogram插件发请求说明
Dynamic programming [III] (interval DP) stone merging
建木持续集成平台v2.5.0发布
Histrix工作原理
.NET6接入Skywalking链路追踪完整流程
[high frequency interview questions] difficulty 1.5/5, LCS template questions
In depth analysis of error solutions and problems in dynamic loading of unity shadow and outline components
一个有趣的网络掩码的实验
Detailed explanation of interprocess communication
AutoCAD - three pruning methods
Thinkphp6 interface limits user access frequency
最大路径和问题(摘樱桃问题)
Dynamic programming [4] (counting class DP) example: integer partition
This privatized deployed enterprise knowledge base makes telecommuting a zero distance
Rxjs mergeMap 的使用场合
Don't miss it. New media operates 15 treasure official account to share
Wechat applet realizes five-star evaluation
JSP custom tag
Go Web 编程入门:验证器
AUTOCAD——三种修剪方式