NTP-33778| Sidharth Bamba | arc issues resolved (#14791)
This commit is contained in:
@@ -77,6 +77,7 @@ import com.navi.bbps.common.ui.SetStatusBarColor
|
||||
import com.navi.bbps.common.utils.NaviBbpsCommonUtils
|
||||
import com.navi.bbps.common.utils.NaviBbpsCommonUtils.isCreditCardCategory
|
||||
import com.navi.bbps.common.utils.NaviBbpsCommonUtils.isUrlPathValidForSavedBills
|
||||
import com.navi.bbps.common.utils.clearBackStackUpToAndNavigate
|
||||
import com.navi.bbps.common.utils.getDisplayableAmount
|
||||
import com.navi.bbps.customHide
|
||||
import com.navi.bbps.entry.NaviBbpsActivity
|
||||
@@ -85,6 +86,7 @@ import com.navi.bbps.feature.category.model.view.BillCategoryEntity
|
||||
import com.navi.bbps.feature.contactlist.model.view.PhoneContactEntity
|
||||
import com.navi.bbps.feature.customerinput.model.view.BillerAdditionalParamsEntity
|
||||
import com.navi.bbps.feature.customerinput.model.view.BillerDetailsEntity
|
||||
import com.navi.bbps.feature.destinations.BillCategoriesScreenV2Destination
|
||||
import com.navi.bbps.feature.destinations.MyBillHistoryDetailsScreenDestination
|
||||
import com.navi.bbps.feature.mybills.model.view.MyBillEntity
|
||||
import com.navi.bbps.feature.paybill.PayBillViewModel
|
||||
@@ -198,6 +200,26 @@ fun PayBillScreen(
|
||||
}
|
||||
}
|
||||
|
||||
LaunchedEffect(Unit) {
|
||||
payBillViewModel.goToNextScreen.collectLatest { nextScreen ->
|
||||
val direction = nextScreen.first
|
||||
val clearBackStack = nextScreen.second
|
||||
if (direction != null) {
|
||||
if (clearBackStack) {
|
||||
navigator.clearBackStackUpToAndNavigate(
|
||||
destination = direction,
|
||||
popUpTo = BillCategoriesScreenV2Destination,
|
||||
inclusive = false,
|
||||
)
|
||||
} else {
|
||||
navigator.navigate(direction = direction)
|
||||
}
|
||||
} else {
|
||||
navigator.navigateUp()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
LaunchedEffect(Unit) {
|
||||
payBillViewModel.navigateToOrderDetailsScreen.collectLatest { navigateToOrderDetailsScreen
|
||||
->
|
||||
|
||||
@@ -104,6 +104,7 @@ import com.navi.bbps.common.utils.NaviBbpsCommonUtils.isCategoryOfTypeAmountChip
|
||||
import com.navi.bbps.common.utils.NaviBbpsCommonUtils.isCreditCardCategory
|
||||
import com.navi.bbps.common.utils.NaviBbpsCommonUtils.isRechargeCategory
|
||||
import com.navi.bbps.common.utils.NaviBbpsCommonUtils.isUrlPathValidForSavedBills
|
||||
import com.navi.bbps.common.utils.clearBackStackUpToAndNavigate
|
||||
import com.navi.bbps.common.utils.getDisplayableAmount
|
||||
import com.navi.bbps.customHide
|
||||
import com.navi.bbps.entry.NaviBbpsActivity
|
||||
@@ -113,6 +114,7 @@ import com.navi.bbps.feature.contactlist.model.view.PhoneContactEntity
|
||||
import com.navi.bbps.feature.customerinput.model.view.BillDetailsEntity
|
||||
import com.navi.bbps.feature.customerinput.model.view.BillerAdditionalParamsEntity
|
||||
import com.navi.bbps.feature.customerinput.model.view.BillerDetailsEntity
|
||||
import com.navi.bbps.feature.destinations.BillCategoriesScreenV2Destination
|
||||
import com.navi.bbps.feature.destinations.MyBillHistoryDetailsScreenDestination
|
||||
import com.navi.bbps.feature.mybills.model.view.MyBillEntity
|
||||
import com.navi.bbps.feature.mybills.model.view.UnpaidBillDetails
|
||||
@@ -402,6 +404,26 @@ fun PayBillScreenV2(
|
||||
}
|
||||
}
|
||||
|
||||
LaunchedEffect(Unit) {
|
||||
payBillViewModelV2.goToNextScreen.collectLatest { nextScreen ->
|
||||
val direction = nextScreen.first
|
||||
val clearBackStack = nextScreen.second
|
||||
if (direction != null) {
|
||||
if (clearBackStack) {
|
||||
navigator.clearBackStackUpToAndNavigate(
|
||||
destination = direction,
|
||||
popUpTo = BillCategoriesScreenV2Destination,
|
||||
inclusive = false,
|
||||
)
|
||||
} else {
|
||||
navigator.navigate(direction = direction)
|
||||
}
|
||||
} else {
|
||||
navigator.navigateUp()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
SetStatusBarColor(activity = naviBbpsActivity, colorResId = R.color.bbps_text_white)
|
||||
|
||||
val onBackClicked = {
|
||||
|
||||
Reference in New Issue
Block a user