提交 58986cda authored 作者: 张国庆's avatar 张国庆

增加 日志

上级 30e41c7f
...@@ -91,6 +91,7 @@ class RammusPlugin : FlutterPlugin, MethodCallHandler { ...@@ -91,6 +91,7 @@ class RammusPlugin : FlutterPlugin, MethodCallHandler {
.getApplicationInfo(gottenApplication.packageName, PackageManager.GET_META_DATA) .getApplicationInfo(gottenApplication.packageName, PackageManager.GET_META_DATA)
val xiaomiAppId = appInfo.metaData.getString("com.xiaomi.push.client.app_id") val xiaomiAppId = appInfo.metaData.getString("com.xiaomi.push.client.app_id")
val xiaomiAppKey = appInfo.metaData.getString("com.xiaomi.push.client.app_key") val xiaomiAppKey = appInfo.metaData.getString("com.xiaomi.push.client.app_key")
LogUtils.d("小米:appId=$xiaomiAppId,appKey=$xiaomiAppKey")
if ((xiaomiAppId != null && xiaomiAppId.isNotBlank()) if ((xiaomiAppId != null && xiaomiAppId.isNotBlank())
&& (xiaomiAppKey != null && xiaomiAppKey.isNotBlank()) && (xiaomiAppKey != null && xiaomiAppKey.isNotBlank())
) { ) {
...@@ -98,12 +99,14 @@ class RammusPlugin : FlutterPlugin, MethodCallHandler { ...@@ -98,12 +99,14 @@ class RammusPlugin : FlutterPlugin, MethodCallHandler {
MiPushRegister.register(gottenApplication, xiaomiAppId, xiaomiAppKey) MiPushRegister.register(gottenApplication, xiaomiAppId, xiaomiAppKey)
} }
val huaweiAppId = appInfo.metaData.getString("com.huawei.hms.client.appid") val huaweiAppId = appInfo.metaData.getString("com.huawei.hms.client.appid")
LogUtils.d("华为:appId=$huaweiAppId")
if (huaweiAppId != null && huaweiAppId.toString().isNotBlank()) { if (huaweiAppId != null && huaweiAppId.toString().isNotBlank()) {
LogUtils.d("正在注册华为推送服务...") LogUtils.d("正在注册华为推送服务...")
HuaWeiRegister.register(gottenApplication as Application) HuaWeiRegister.register(gottenApplication as Application)
} }
val oppoAppKey = appInfo.metaData.getString("com.oppo.push.client.app_key") val oppoAppKey = appInfo.metaData.getString("com.oppo.push.client.app_key")
val oppoAppSecret = appInfo.metaData.getString("com.oppo.push.client.app_secret") val oppoAppSecret = appInfo.metaData.getString("com.oppo.push.client.app_secret")
LogUtils.d("oppo:oppoAppKey=$oppoAppKey,oppoAppSecret=$oppoAppSecret")
if ((oppoAppKey != null && oppoAppKey.isNotBlank()) if ((oppoAppKey != null && oppoAppKey.isNotBlank())
&& (oppoAppSecret != null && oppoAppSecret.isNotBlank()) && (oppoAppSecret != null && oppoAppSecret.isNotBlank())
) { ) {
...@@ -112,6 +115,7 @@ class RammusPlugin : FlutterPlugin, MethodCallHandler { ...@@ -112,6 +115,7 @@ class RammusPlugin : FlutterPlugin, MethodCallHandler {
} }
val vivoAppId = appInfo.metaData.getString("com.vivo.push.app_id") val vivoAppId = appInfo.metaData.getString("com.vivo.push.app_id")
val vivoApiKey = appInfo.metaData.getString("com.vivo.push.api_key") val vivoApiKey = appInfo.metaData.getString("com.vivo.push.api_key")
LogUtils.d("vivo:vivoAppId=$vivoAppId,vivoApiKey=$vivoApiKey")
if ((vivoAppId != null && vivoAppId.isNotBlank()) if ((vivoAppId != null && vivoAppId.isNotBlank())
&& (vivoApiKey != null && vivoApiKey.isNotBlank()) && (vivoApiKey != null && vivoApiKey.isNotBlank())
) { ) {
...@@ -119,6 +123,7 @@ class RammusPlugin : FlutterPlugin, MethodCallHandler { ...@@ -119,6 +123,7 @@ class RammusPlugin : FlutterPlugin, MethodCallHandler {
VivoRegister.register(gottenApplication) VivoRegister.register(gottenApplication)
} }
val hihonorId = appInfo.metaData.getString("com.hihonor.push.app_id") val hihonorId = appInfo.metaData.getString("com.hihonor.push.app_id")
LogUtils.d("荣耀:hihonorId=$hihonorId")
if (hihonorId != null && hihonorId.toString().isNotBlank()) { if (hihonorId != null && hihonorId.toString().isNotBlank()) {
LogUtils.d("正在注册荣耀推送服务...") LogUtils.d("正在注册荣耀推送服务...")
HonorRegister.register(gottenApplication as Application) HonorRegister.register(gottenApplication as Application)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论