Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

快手小程序 getphonenumber not found #4113

Closed
alice-ti opened this issue Jan 13, 2023 · 1 comment
Closed

快手小程序 getphonenumber not found #4113

alice-ti opened this issue Jan 13, 2023 · 1 comment
Assignees

Comments

@alice-ti
Copy link

alice-ti commented Jan 13, 2023

问题描述
问题描述:快手小程序使用vue3版本 getphonenumber获取手机号获取不到

复现步骤
<button open-type="getPhoneNumber"组件内嵌套viewimage组件会出现手机号获取不到情况;
嵌套text 组件有较小概念出现此情况

HbuildX 创建vue3默认模板项目
index.vue代码如下

<template>
	<view class="content">
		<image class="logo" src="/static/logo.png"></image>
		<view class="text-area">
			<view class="title">{{ title }}</view>
			<view>
		                <button open-type="getPhoneNumber" @getphonenumber="getPhoneNumberHandler">
			                <view>text 获取手机号{{ title}}</view>
		                </button>
	                </view>
		</view>
	</view>
</template>

<script setup>
import { ref } from 'vue'
import { onLoad, onShow, onHide } from '@dcloudio/uni-app'

const title = ref('uniapp')

onLoad(() => {
	uni.login()
})
const getPhoneNumberHandler = (e) => {
	console.log('获取手机号', e)
}
</script>

<style>
.content {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}

.logo {
	height: 200rpx;
	width: 200rpx;
	margin-top: 200rpx;
	margin-left: auto;
	margin-right: auto;
	margin-bottom: 50rpx;
}

.text-area {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}

.title {
	font-size: 36rpx;
	color: #8f8f94;
}
</style>

预期结果
正常调用

实际结果
image

系统信息:

  • 发行平台: 快手小程序
  • 操作系统: Android 12 、快手开发工具版本v1.22.1
  • HBuilderX版本: 3.6.17
  • 设备信息: iPhone14
@zhenyuWang
Copy link
Contributor

HBuilderX 3.7.1.20230210-alpha 已修复。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants