接收提现结果 - 显示dialog
This commit is contained in:
parent
82d7f7d9d8
commit
2859edcc89
|
|
@ -230,15 +230,14 @@ class WithDrawActivity : AppViewsEmptyViewModelActivity<ViewBinding>() {
|
||||||
|
|
||||||
private fun showTransactionResultDialog(record: RecordCash) {
|
private fun showTransactionResultDialog(record: RecordCash) {
|
||||||
if (!record.hasShowResultDialog && record.withdrawState != TRANSACTION_STATE_ONGOING) {
|
if (!record.hasShowResultDialog && record.withdrawState != TRANSACTION_STATE_ONGOING) {
|
||||||
|
WithdrawManager.instance().updateRecordHasNotifyState(record.payOutReplyNo)
|
||||||
when (record.withdrawState) {
|
when (record.withdrawState) {
|
||||||
TRANSACTION_STATE_SUCCESS -> {
|
TRANSACTION_STATE_SUCCESS -> {
|
||||||
showSuccessDialog(record.amountNum)
|
showSuccessDialog(record.amountNum)
|
||||||
WithdrawManager.instance().updateRecordHasNotifyState(record.payOutReplyNo)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
TRANSACTION_STATE_FAIL -> {
|
TRANSACTION_STATE_FAIL -> {
|
||||||
showFailDialog(WithdrawManager.instance().getFailHintStrRes(record.withdrawFailType))
|
showFailDialog(WithdrawManager.instance().getFailHintStrRes(record.withdrawFailType))
|
||||||
WithdrawManager.instance().updateRecordHasNotifyState(record.payOutReplyNo)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -173,15 +173,14 @@ class WithDrawSubActivity : AppViewsEmptyViewModelActivity<ViewBinding>() {
|
||||||
|
|
||||||
private fun showTransactionResultDialog(record: RecordCash) {
|
private fun showTransactionResultDialog(record: RecordCash) {
|
||||||
if (!record.hasShowResultDialog && record.withdrawState != TRANSACTION_STATE_ONGOING) {
|
if (!record.hasShowResultDialog && record.withdrawState != TRANSACTION_STATE_ONGOING) {
|
||||||
|
WithdrawManager.instance().updateRecordHasNotifyState(record.payOutReplyNo)
|
||||||
when (record.withdrawState) {
|
when (record.withdrawState) {
|
||||||
TRANSACTION_STATE_SUCCESS -> {
|
TRANSACTION_STATE_SUCCESS -> {
|
||||||
showSuccessDialog(record.amountNum)
|
showSuccessDialog(record.amountNum)
|
||||||
WithdrawManager.instance().updateRecordHasNotifyState(record.payOutReplyNo)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
TRANSACTION_STATE_FAIL -> {
|
TRANSACTION_STATE_FAIL -> {
|
||||||
showFailDialog(WithdrawManager.instance().getFailHintStrRes(record.withdrawFailType))
|
showFailDialog(WithdrawManager.instance().getFailHintStrRes(record.withdrawFailType))
|
||||||
WithdrawManager.instance().updateRecordHasNotifyState(record.payOutReplyNo)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -179,7 +179,7 @@ class WithdrawManager private constructor() {
|
||||||
NotifyMan.instance().sendEvent(VididinEvents.EVENT_WITHDRAW_ITEM_LIST_CHANGED, null)
|
NotifyMan.instance().sendEvent(VididinEvents.EVENT_WITHDRAW_ITEM_LIST_CHANGED, null)
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun notifyWithdrawResult2(withdrawRecord: RecordCash) {
|
private fun notifyWithdrawResult(withdrawRecord: RecordCash) {
|
||||||
NotifyMan.instance().sendEvent(VididinEvents.EVENT_WITHDRAW_RESULT_UPDATED, NotifyMan.NotifyData(withdrawRecord))
|
NotifyMan.instance().sendEvent(VididinEvents.EVENT_WITHDRAW_RESULT_UPDATED, NotifyMan.NotifyData(withdrawRecord))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -617,7 +617,7 @@ class WithdrawManager private constructor() {
|
||||||
RecordsManager.instance().updateCashRecord(withdrawRecord)
|
RecordsManager.instance().updateCashRecord(withdrawRecord)
|
||||||
|
|
||||||
// 2. 事件通知以便更新UI
|
// 2. 事件通知以便更新UI
|
||||||
notifyWithdrawResult2(withdrawRecord)
|
notifyWithdrawResult(withdrawRecord)
|
||||||
|
|
||||||
// 3. Statistics
|
// 3. Statistics
|
||||||
StatisticUtil.reportEvents(StatisticUtil.KEY_Withdrawal_Reason, mapOf(
|
StatisticUtil.reportEvents(StatisticUtil.KEY_Withdrawal_Reason, mapOf(
|
||||||
|
|
@ -642,7 +642,7 @@ class WithdrawManager private constructor() {
|
||||||
}
|
}
|
||||||
|
|
||||||
// 3. event 通知
|
// 3. event 通知
|
||||||
notifyWithdrawResult2(withdrawRecord)
|
notifyWithdrawResult(withdrawRecord)
|
||||||
|
|
||||||
// 4. Statistic
|
// 4. Statistic
|
||||||
StatisticUtil.reportEvents(StatisticUtil.KEY_Withdrawal_Reason,
|
StatisticUtil.reportEvents(StatisticUtil.KEY_Withdrawal_Reason,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue