PreApprovalScreenViewModel

class PreApprovalScreenViewModel(defaultRepository: ERROR CLASS: Symbol not found for DefaultRepository, credentialStorage: CredentialStorage, dispatchers: DispatcherProvider, sampleConfig: SampleConfig) : BaseScreenViewModel

ViewModel for the Collection Pre-Approval screen. Showcases createPreApprovalgetPreApprovalStatus, keyed on a locally generated reference ID. Cancellation lives on the Approved Pre-Approvals screen, since it is keyed on the server-assigned preApprovalId.

The last operation's outcome (reference ID, status payload, or error) is exposed via result and rendered in a console panel so the flow is visible to developers exploring the SDK.

Constructors

Link copied to clipboard
constructor(defaultRepository: ERROR CLASS: Symbol not found for DefaultRepository, credentialStorage: CredentialStorage, dispatchers: DispatcherProvider, sampleConfig: SampleConfig)

Properties

Link copied to clipboard
val payerCurrency: ERROR CLASS: Symbol not found for LiveData<kotlin/String>
Link copied to clipboard
val payerMessage: ERROR CLASS: Symbol not found for LiveData<kotlin/String>
Link copied to clipboard
val payerMsisdn: ERROR CLASS: Symbol not found for LiveData<kotlin/String>
Link copied to clipboard
val referenceId: ERROR CLASS: Unresolved name: MutableLiveData

The reference ID of the last created pre-approval; enables status/cancel actions.

Link copied to clipboard
val result: ERROR CLASS: Unresolved name: MutableLiveData

Console output describing the outcome of the last operation.

Link copied to clipboard
val showProgressBar: ERROR CLASS: Unresolved name: MutableLiveData

Controls whether the circular progress indicator is shown instead of the screen content.

Link copied to clipboard
val snackBarStateFlow: ERROR CLASS: Symbol not found for SharedFlow<io/rekast/sdk/sample/utils/SnackBarComponentConfiguration>

Flow of SnackBarComponentConfiguration events to be displayed as snack bars.

Link copied to clipboard
val validityTime: ERROR CLASS: Symbol not found for LiveData<kotlin/String>

Functions

Link copied to clipboard

Fetches the status of the previously created pre-approval and prints the raw payload.

Link copied to clipboard

Creates a pre-approval with a fresh reference ID and stores that ID for status/cancel.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard