vnorderui / com.venuenext.vnorderui.orders.summary / OrderSummaryViewModel

OrderSummaryViewModel

class OrderSummaryViewModel : ViewModel, OrderChangedListener

Constructors

<init>

OrderSummaryViewModel(orderRepository: OrderRepository, redeemedExperienceRepository: RedeemedExperienceRepository, firesaleRepository: FiresaleRepository)

Properties

countdownTimers

var countdownTimers: MutableMap<String, CountDownTimer>

orderIdFromTransfer

var orderIdFromTransfer: String?

state

val state: LiveData<State>

Functions

cancelExperienceAsync

fun cancelExperienceAsync(transferId: String, success: () -> Unit, failure: (String?) -> Unit): Job

getTransfersLiveData

fun getTransfersLiveData(): LiveData<List<MarketplaceTransfer>>

loadDataAsync

fun loadDataAsync(orderUUID: String?, didRequestExperienceReceipt: Boolean, transfers: List<MarketplaceTransfer> = emptyList()): Job

onOrderChanged

fun onOrderChanged(orderUUID: String?): Unit

purchasedExperienceRedeemBackgroundClicked

fun purchasedExperienceRedeemBackgroundClicked(purchasedExperienceItem: PurchasedExperienceItem): Unit

redeemExperience

fun redeemExperience(purchasedExperienceItem: PurchasedExperienceItem): Unit

setExperienceCarouselPosition

fun setExperienceCarouselPosition(position: Int): Unit

storeRedeemedExperience

fun storeRedeemedExperience(redeemedExperience: RedeemedExperience): Unit