From 1897c4ad5fa73b3f0a36e1aa0e1e9000302a6ace Mon Sep 17 00:00:00 2001
From: riku <risaku@163.com>
Date: 星期五, 31 十月 2025 17:35:09 +0800
Subject: [PATCH] 2025.10.31 1. 新增巡查场景历史详情相关数据逻辑(待完成);
---
app/src/main/java/cn/flightfeather/thirdappmodule/util/push/PushService.kt | 106 ++++++++++++++++++++++++++--------------------------
1 files changed, 53 insertions(+), 53 deletions(-)
diff --git a/app/src/main/java/cn/flightfeather/thirdappmodule/util/push/PushService.kt b/app/src/main/java/cn/flightfeather/thirdappmodule/util/push/PushService.kt
index 7055c2f..1287c90 100644
--- a/app/src/main/java/cn/flightfeather/thirdappmodule/util/push/PushService.kt
+++ b/app/src/main/java/cn/flightfeather/thirdappmodule/util/push/PushService.kt
@@ -2,9 +2,9 @@
import android.content.Context
import android.util.Log
-import com.alibaba.sdk.android.push.CloudPushService
-import com.alibaba.sdk.android.push.CommonCallback
-import com.alibaba.sdk.android.push.noonesdk.PushServiceFactory
+//import com.alibaba.sdk.android.push.CloudPushService
+//import com.alibaba.sdk.android.push.CommonCallback
+//import com.alibaba.sdk.android.push.noonesdk.PushServiceFactory
/**
* 绉诲姩鎺ㄩ�佹湇鍔¢厤缃被
@@ -12,54 +12,54 @@
* Date: 2019/12/26
*/
class PushService {
- companion object {
- const val TAG = "PushService"
-
- private var mPushService: CloudPushService? = null
-
- /**
- * 鍒濆鍖栦簯鎺ㄩ�侀�氶亾
- * @param applicationContext
- */
- fun init(applicationContext: Context) {
- PushServiceFactory.init(applicationContext)
- mPushService = PushServiceFactory.getCloudPushService()
- mPushService?.register(applicationContext, object : CommonCallback {
- override fun onSuccess(response: String) {
- Log.d(TAG, "init cloudChannel success")
- Log.d(TAG, response)
- }
-
- override fun onFailed(errorCode: String, errorMessage: String) {
- Log.d(TAG, "init cloudChannel failed -- errorCode:$errorCode -- errorMessage:$errorMessage")
- }
- })
- }
-
- fun bindAccount(account: String, s: () -> Unit) {
- mPushService?.bindAccount(account, object : CommonCallback {
- override fun onSuccess(p0: String?) {
- Log.d(TAG, "bind account $account success")
- s()
- }
-
- override fun onFailed(p0: String?, p1: String?) {
-
- }
- })
- }
-
- fun unBindAccount(s: () -> Unit) {
- mPushService?.unbindAccount(object : CommonCallback {
- override fun onSuccess(p0: String?) {
- Log.d(TAG, "unbind account success")
- s()
- }
-
- override fun onFailed(p0: String?, p1: String?) {
-
- }
- })
- }
- }
+// companion object {
+// const val TAG = "PushService"
+//
+// private var mPushService: CloudPushService? = null
+//
+// /**
+// * 鍒濆鍖栦簯鎺ㄩ�侀�氶亾
+// * @param applicationContext
+// */
+// fun init(applicationContext: Context) {
+// PushServiceFactory.init(applicationContext)
+// mPushService = PushServiceFactory.getCloudPushService()
+// mPushService?.register(applicationContext, object : CommonCallback {
+// override fun onSuccess(response: String) {
+// Log.d(TAG, "init cloudChannel success")
+// Log.d(TAG, response)
+// }
+//
+// override fun onFailed(errorCode: String, errorMessage: String) {
+// Log.d(TAG, "init cloudChannel failed -- errorCode:$errorCode -- errorMessage:$errorMessage")
+// }
+// })
+// }
+//
+// fun bindAccount(account: String, s: () -> Unit) {
+// mPushService?.bindAccount(account, object : CommonCallback {
+// override fun onSuccess(p0: String?) {
+// Log.d(TAG, "bind account $account success")
+// s()
+// }
+//
+// override fun onFailed(p0: String?, p1: String?) {
+//
+// }
+// })
+// }
+//
+// fun unBindAccount(s: () -> Unit) {
+// mPushService?.unbindAccount(object : CommonCallback {
+// override fun onSuccess(p0: String?) {
+// Log.d(TAG, "unbind account success")
+// s()
+// }
+//
+// override fun onFailed(p0: String?, p1: String?) {
+//
+// }
+// })
+// }
+// }
}
\ No newline at end of file
--
Gitblit v1.9.3