新增三码适配
This commit is contained in:
+5
-10
@@ -181,7 +181,6 @@
|
||||
|
||||
// 生命周期 onLoad 钩子
|
||||
onLoad(async (options) => {
|
||||
console.log('options', options)
|
||||
|
||||
// 普通链接二维码进入时,参数通常在 options.q(且为编码后的完整 URL)
|
||||
if (!options.deviceNo && options.q) {
|
||||
@@ -232,11 +231,6 @@
|
||||
isAlipayMiniProgram.value = false
|
||||
isH5.value = true
|
||||
// #endif
|
||||
console.log('当前运行环境:', {
|
||||
isWechatMiniProgram: isWechatMiniProgram.value,
|
||||
isAlipayMiniProgram: isAlipayMiniProgram.value,
|
||||
isH5: isH5.value
|
||||
})
|
||||
await checkUserPhone()
|
||||
await fetchDeviceInfo()
|
||||
})
|
||||
@@ -366,7 +360,7 @@
|
||||
const fetchDeviceInfo = async () => {
|
||||
try {
|
||||
loading.value = true
|
||||
console.log(deviceId.value);
|
||||
// console.log(deviceId.value);
|
||||
const res = await getDeviceInfo(deviceId.value)
|
||||
if (res.code == 200) {
|
||||
deviceInfo.value = res.data.device || {}
|
||||
@@ -404,9 +398,10 @@
|
||||
}
|
||||
}
|
||||
}else{
|
||||
uni.reLaunch({
|
||||
url:'/pages/index/index'
|
||||
})
|
||||
|
||||
// uni.reLaunch({
|
||||
// url:'/pages/index/index'
|
||||
// })
|
||||
}
|
||||
}catch(error){
|
||||
console.error('获取设备信息失败:', error)
|
||||
|
||||
Reference in New Issue
Block a user