NTP-35196 | Multi bank customer onboarding table integration (#14858)
Co-authored-by: Aditya Narayan Malik <aditya.narayan@navi.com>
This commit is contained in:
@@ -329,12 +329,7 @@ class DeeplinkManager(
|
||||
} else if (ctaData != null) {
|
||||
navigateTo(activity, ctaData, bundle = bundle, finish = finish, clearTask = clearTask)
|
||||
} else if (bundle.getString(IS_UPI_DYNAMIC_DEEP_LINK) == TRUE) {
|
||||
val ctaDataForUpiDeepLink =
|
||||
if (NaviApplication.instance.naviPayManager.get().isUserOnboarded()) {
|
||||
CtaData(url = url)
|
||||
} else {
|
||||
CtaData(url = bundle.getString(NAVI_PAY_HOME_PAGE_URL))
|
||||
}
|
||||
val ctaDataForUpiDeepLink = CtaData(url = url)
|
||||
navigateTo(
|
||||
activity,
|
||||
ctaDataForUpiDeepLink,
|
||||
|
||||
@@ -21,10 +21,6 @@ class UpiSdkHelperImpl(private val naviPayManagerProvider: Lazy<NaviPayManager>)
|
||||
|
||||
private val upiSdkAnalytics = UpiSdkAnalytics()
|
||||
|
||||
override fun isUserOnboarded(): Boolean {
|
||||
return naviPayManagerProvider.get().isUserOnboarded()
|
||||
}
|
||||
|
||||
override suspend fun getDataByType(type: UpiDataType): JSONObject {
|
||||
upiSdkAnalytics.onDataRequest(type)
|
||||
return naviPayManagerProvider.get().getDataByType(type)
|
||||
|
||||
@@ -27,6 +27,9 @@ import com.naviapp.utils.APP_VERSION
|
||||
import com.naviapp.utils.toggleNaviPayIntentActivityState
|
||||
import dagger.hilt.android.qualifiers.ApplicationContext
|
||||
import javax.inject.Inject
|
||||
import kotlinx.coroutines.CoroutineScope
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
class LaunchEventsTracker
|
||||
@Inject
|
||||
@@ -125,16 +128,20 @@ constructor(
|
||||
}
|
||||
|
||||
private fun checkAndEnableNaviPayIntentActivity() {
|
||||
val prevSessionVersion = PreferenceManager.getIntPreferenceApp(APP_VERSION)
|
||||
val currentVersion = BuildConfig.VERSION_CODE
|
||||
if (prevSessionVersion != currentVersion) {
|
||||
val shouldEnableNaviPayIntentActivity =
|
||||
FirebaseRemoteConfigHelper.getBoolean(
|
||||
key = FirebaseRemoteConfigHelper.NAVI_PAY_INTENT_ACTIVITY_CHECK_ENABLED,
|
||||
defaultValue = true,
|
||||
)
|
||||
if (shouldEnableNaviPayIntentActivity && naviPayManager.isUserOnboarded()) {
|
||||
toggleNaviPayIntentActivityState(shouldEnable = true)
|
||||
CoroutineScope(Dispatchers.IO).launch {
|
||||
val prevSessionVersion = PreferenceManager.getIntPreferenceApp(APP_VERSION)
|
||||
val currentVersion = BuildConfig.VERSION_CODE
|
||||
if (prevSessionVersion != currentVersion) {
|
||||
val shouldEnableNaviPayIntentActivity =
|
||||
FirebaseRemoteConfigHelper.getBoolean(
|
||||
key = FirebaseRemoteConfigHelper.NAVI_PAY_INTENT_ACTIVITY_CHECK_ENABLED,
|
||||
defaultValue = true,
|
||||
)
|
||||
if (
|
||||
shouldEnableNaviPayIntentActivity && naviPayManager.isUserOnboardedForAnyPsp()
|
||||
) {
|
||||
toggleNaviPayIntentActivityState(shouldEnable = true)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user