NTP-74530 | update NAE logic in bill actions api (#16649)
This commit is contained in:
@@ -101,6 +101,7 @@ interface AddBillScreenEventTracker :
|
||||
|
||||
@EventName("mm_add_bill_footer_button_clicked")
|
||||
fun onAddBillFooterButtonClicked(
|
||||
billId: String,
|
||||
billName: String,
|
||||
billAmount: String,
|
||||
billSelectedDate: String,
|
||||
|
||||
@@ -111,10 +111,14 @@ fun AddNewBillScreen(
|
||||
AddBillScreenTopBar(
|
||||
navBarData = navBarData,
|
||||
onHelpClick = {
|
||||
eventTracker.onAddBillScreenHelpClicked()
|
||||
focusManager.clearFocus()
|
||||
viewModel.setEffect { AddNewBillUiEffect.Navigation.Help }
|
||||
},
|
||||
onBackClick = { viewModel.setEffect { AddNewBillUiEffect.Navigation.Back } },
|
||||
onBackClick = {
|
||||
eventTracker.onAddBillScreenBackClicked()
|
||||
viewModel.setEffect { AddNewBillUiEffect.Navigation.Back }
|
||||
},
|
||||
)
|
||||
}
|
||||
},
|
||||
@@ -127,6 +131,13 @@ fun AddNewBillScreen(
|
||||
billId?.let {
|
||||
viewModel.submitBill(actionType = BillActionType.EDIT, billId = it)
|
||||
} ?: run { viewModel.submitBill(actionType = BillActionType.ADD) }
|
||||
eventTracker.onAddBillFooterButtonClicked(
|
||||
billId = billId.orEmpty(),
|
||||
billName = data.data?.content?.billName?.text.orEmpty(),
|
||||
billAmount = data.data?.content?.billAmount?.text.orEmpty(),
|
||||
billSelectedDate = data.data?.content?.billSelectedDate.orEmpty(),
|
||||
billFrequency = data.data?.content?.billFrequency.orEmpty(),
|
||||
)
|
||||
},
|
||||
)
|
||||
}
|
||||
@@ -148,6 +159,7 @@ fun AddNewBillScreen(
|
||||
viewModel.onBillAmountChanged(billAmount)
|
||||
},
|
||||
onSelectBillFrequencyIconClick = {
|
||||
eventTracker.onAddBillFrequencySectionClicked()
|
||||
focusManager.clearFocus()
|
||||
viewModel.sendEvent(
|
||||
AddBillUiEvent.ShowBottomSheet(
|
||||
@@ -156,10 +168,12 @@ fun AddNewBillScreen(
|
||||
)
|
||||
},
|
||||
onDatePickerIconClick = {
|
||||
eventTracker.onAddBillSelectDateSectionClicked()
|
||||
focusManager.clearFocus()
|
||||
viewModel.sendEvent(AddBillUiEvent.ShowDatePickerDialog)
|
||||
},
|
||||
onEditIconClick = {
|
||||
eventTracker.onAddBillIconClicked()
|
||||
focusManager.clearFocus()
|
||||
viewModel.getSelectBillIconBottomSheetData()
|
||||
},
|
||||
|
||||
@@ -242,7 +242,7 @@ class RemoteDataProviderImpl @Inject constructor(private val retrofitService: Re
|
||||
metricInfo =
|
||||
MetricInfo.AppMetric(
|
||||
screen = MMScreen.BILL_CALENDAR_SCREEN.screen,
|
||||
isNae = { true },
|
||||
isNae = { !it.isSuccessWithData() },
|
||||
),
|
||||
)
|
||||
}
|
||||
@@ -253,7 +253,7 @@ class RemoteDataProviderImpl @Inject constructor(private val retrofitService: Re
|
||||
metricInfo =
|
||||
MetricInfo.AppMetric(
|
||||
screen = MMScreen.BILL_CALENDAR_SCREEN.screen,
|
||||
isNae = { true },
|
||||
isNae = { !it.isSuccessWithData() },
|
||||
),
|
||||
)
|
||||
}
|
||||
@@ -266,7 +266,7 @@ class RemoteDataProviderImpl @Inject constructor(private val retrofitService: Re
|
||||
metricInfo =
|
||||
MetricInfo.AppMetric(
|
||||
screen = MMScreen.BILL_CALENDAR_SCREEN.screen,
|
||||
isNae = { true },
|
||||
isNae = { !it.isSuccessWithData() },
|
||||
),
|
||||
)
|
||||
}
|
||||
@@ -280,7 +280,7 @@ class RemoteDataProviderImpl @Inject constructor(private val retrofitService: Re
|
||||
metricInfo =
|
||||
MetricInfo.AppMetric(
|
||||
screen = MMScreen.BILL_CALENDAR_SCREEN.screen,
|
||||
isNae = { true },
|
||||
isNae = { !it.isSuccessWithData() },
|
||||
),
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user