wangguoyu il y a 1 semaine
Parent
commit
372312ff82
1 fichiers modifiés avec 16 ajouts et 1 suppressions
  1. 16 1
      pages/login/index.vue

+ 16 - 1
pages/login/index.vue

@@ -124,7 +124,8 @@
 		console.log('物理分辨率宽:', info.windowWidth * info.pixelRatio) */
 		console.log('物理分辨率宽:', info.windowWidth * info.pixelRatio) */
 		showAppleLogin.value = isIOS13OrAbove();
 		showAppleLogin.value = isIOS13OrAbove();
 		getLoginInit()
 		getLoginInit()
-		getUUid()
+		getUUid()
+		getUUid2()
 		if (plus.runtime.isApplicationExist({
 		if (plus.runtime.isApplicationExist({
 				pname: 'com.tencent.mm',
 				pname: 'com.tencent.mm',
 				action: 'weixin://'
 				action: 'weixin://'
@@ -260,6 +261,20 @@
         console.error('获取设备信息失败:', err);
         console.error('获取设备信息失败:', err);
       }
       }
     });
     });
+	};
+	
+	const getUUid2 = (data) => {
+    plus.device.getOAID({
+      success: (res) => {
+        // res.uuid 是设备的 UUID(iOS 下为 identifierForVendor)
+        console.log('res', res);
+        uuid.value = res.uuid;
+        console.log('iOS 设备 UUID:', uuid.value);
+      },
+      fail: (err) => {
+        console.error('获取设备信息失败:', err);
+      }
+    });
 	};
 	};
 
 
 	const handleAgreementChange = (event) => {
 	const handleAgreementChange = (event) => {