NTP-33778| Sidharth Bamba | post payment issue resolved (#14802)

This commit is contained in:
Sidharth Bamba
2025-01-31 23:33:45 +05:30
committed by GitHub
parent 8eb48642f8
commit ecddf894ed

View File

@@ -595,6 +595,7 @@ fun SharedTransitionScope.RenderPostPaymentScreenV2(
PaymentStatusDescription(
billEntity = billEntity,
naviBbpsDefaultConfig = naviBbpsDefaultConfig,
isArcProtected = isArcProtected,
)
if (isArcProtected) {
@@ -1458,6 +1459,45 @@ private fun CrossSellFallbackSection(
private fun PaymentStatusDescription(
billEntity: MyBillEntity,
naviBbpsDefaultConfig: NaviBbpsDefaultConfig,
isArcProtected: Boolean,
) {
if (isArcProtected) {
ArcProtectedPaymentStatus(
billEntity = billEntity,
naviBbpsDefaultConfig = naviBbpsDefaultConfig,
)
} else {
NonArcProtectedPaymentStatus(billEntity = billEntity)
}
}
@Composable
private fun NonArcProtectedPaymentStatus(billEntity: MyBillEntity) {
Row(
modifier = Modifier.fillMaxWidth().background(NaviBbpsColor.bgAlt2).padding(16.dp),
verticalAlignment = Alignment.CenterVertically,
) {
Image(
painter = painterResource(id = CommonR.drawable.ic_purple_exclamation),
contentDescription = EMPTY,
modifier = Modifier.size(16.dp),
)
Spacer(modifier = Modifier.width(12.dp))
NaviText(
text = getNonArcProtectedMessage(billEntity.categoryId),
color = NaviBbpsColor.textPrimary,
fontSize = 14.sp,
fontFamily = naviFontFamily,
fontWeight = getFontWeight(FontWeightEnum.NAVI_BODY_REGULAR),
)
}
}
@Composable
private fun ArcProtectedPaymentStatus(
billEntity: MyBillEntity,
naviBbpsDefaultConfig: NaviBbpsDefaultConfig,
) {
Row(
modifier =
@@ -1481,6 +1521,15 @@ private fun PaymentStatusDescription(
}
}
@Composable
private fun getNonArcProtectedMessage(categoryId: String): String {
return if (NaviBbpsCommonUtils.isRechargeCategory(categoryId)) {
stringResource(id = R.string.bbps_recharge_pending_message)
} else {
stringResource(id = R.string.bbps_bill_payment_pending_message)
}
}
@Composable
private fun CoinDiscountBanner(availableCoinsDiscount: String?) {
Column(modifier = Modifier.fillMaxWidth().padding(horizontal = 16.dp)) {