Updated on 2026-08-14

This commit is contained in:
Tangem 2025-06-03 13:12:04 +04:00
parent 3bcb5280fb
commit 7703832cf1
17 changed files with 393 additions and 23 deletions

View file

@ -17,6 +17,7 @@ import com.google.firebase.messaging.FirebaseMessagingService
import com.google.firebase.messaging.RemoteMessage
import com.tangem.core.deeplink.DEEPLINK_KEY
import com.tangem.core.deeplink.WEBLINK_KEY
import com.tangem.core.deeplink.converter.PayloadToDeeplinkConverter
import com.tangem.domain.common.LogConfig
import com.tangem.tap.MainActivity
import com.tangem.tap.common.images.createCoilImageLoader
@ -37,9 +38,10 @@ internal class TangemPushNotificationService : FirebaseMessagingService() {
val notification = message.notification ?: return
val channelId = notification.channelId ?: TANGEM_CHANNEL_ID
val deeplink = PayloadToDeeplinkConverter.convert(message.data)
val intent = Intent(applicationContext, MainActivity::class.java).apply {
putExtra(DEEPLINK_KEY, message.data[DEEPLINK_KEY])
putExtra(DEEPLINK_KEY, deeplink)
putExtra(WEBLINK_KEY, message.data[WEBLINK_KEY])
putExtra(OnPushClickedIntentHandler.OPENED_FROM_GCM_PUSH, true)
addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP)