z***@163.com
z***@163.com
  • 发布:2024-05-17 10:19
  • 更新:2024-05-19 09:14
  • 阅读:50

#插件讨论# 【 支付键盘 金额键盘 - 2***@qq.com 】双向绑定失效

分类:uni-app

引用后绑定的值失效```javascript
<template>
<view>
<!-- <view class="dis_aic dis_jcsb P_a10" style="background-color: #eee;">
<view class="dis_fdc">
<text class="m_b10">付款{{num}}</text>
<text style="font-size: 26rpx;color: #666;">用户123213123</text>
</view>
<view class="">
<image src="@/static/none.png" style="width: 200rpx;height: 200rpx;" mode=""></image>
</view>
</view>
<view class="pay" style="">
<text>付款金额</text>
<view class="dis pay_input">
</view>
</view> -->
<!-- <text>¥</text> <input type="text" v-model="num" /> -->
2{{num}}1
<uv-button @click="opens" text="shuru"></uv-button>
<jia-PayKeyboard ref="keyWord" v-model="num"></jia-PayKeyboard>
</view>
</template>

<script setup>
import {
onLoad,
onShow
} from '@dcloudio/uni-app';
import {
ref,
watch
} from 'vue';
let num = ref('0')
let keyWord = ref()
onShow(() => {
setTimeout(() => {

    }, 300)  

})  
watch(num, (e, n) => {  
    console.log(e, n)  
})  
const opens = () => {  
    keyWord.value.open()  
}  
const inputs = (e) => {  
    console.log(e)  
}  

</script>

<style lang="scss">
page {
background-color: #EEEEEE;
}

.pay {  
    height: 100%;  
    border-radius: 10% 10% 0 0;  
    padding-top: 60rpx;  
    padding: 100rpx 30rpx 0 30rpx;  
    background-color: #fff;  
}  

.pay_input {  
    margin-top: 20rpx;  
    align-content: flex-end;  

    >text {  
        font-weight: 600;  
        font-size: 40rpx;  
    }  

    input {  
        font-size: 24rpx;  
        line-height: 56rpx;  
        border-bottom: 1rpx solid #eee;  
    }  
}  

</style>

2024-05-17 10:19 负责人:无 分享
已邀请:
2***@qq.com

2***@qq.com

暂时不支持vue3 晚点做兼容处理

2***@qq.com

2***@qq.com

已支持vue3 请更新到最新版本

要回复问题请先登录注册