|
@ -36,6 +36,8 @@ import java.util.TimeZone;
|
36
|
36
|
public class MobileInfo extends Plugin {
|
37
|
37
|
public String platform = "Android";
|
38
|
38
|
|
|
39
|
public static final int ANDROID_Q = 29;
|
|
40
|
|
39
|
41
|
public static final String MAC_FAIL = "02:00:00:00:00:00";
|
40
|
42
|
|
41
|
43
|
public MobileInfo(IIpuMobile ipumobile) {
|
|
@ -140,8 +142,12 @@ public class MobileInfo extends Plugin {
|
140
|
142
|
}
|
141
|
143
|
|
142
|
144
|
public String getImei() {
|
143
|
|
TelephonyManager manager = (TelephonyManager) this.context.getSystemService(Context.TELEPHONY_SERVICE);
|
144
|
|
return manager.getDeviceId();
|
|
145
|
if (Build.VERSION.SDK_INT < ANDROID_Q) {
|
|
146
|
TelephonyManager manager = (TelephonyManager) this.context.getSystemService(Context.TELEPHONY_SERVICE);
|
|
147
|
return manager.getDeviceId();
|
|
148
|
} else { //Android 10之后获取不到IMEI
|
|
149
|
return getUuid();
|
|
150
|
}
|
145
|
151
|
}
|
146
|
152
|
|
147
|
153
|
public String getSimNumber() {
|