VouchersView

TerraCore v0

Introduction#

Use this built-in view to display a horizontal list of public vouchers which is available for user. By default, the max number of item can be display is 10.

Usage#

After init your TerraApp, call this

TerraUserCornerUI.getInstance(terraApp)

to initialize SDK.

Then You can add VouchersView into your layout like any Android widget.

The VouchersView must be set with a TerraApp name and a LifeCycleOwner before being able to load data.

let vouchersView = VouchersView()
vouchersView.setTerraApp(terraAppName, lifecycleOwner)

VouchersView will auto reload its data after an voucher is ended.

You can load its data when you need by calling loadData method

vouchersView.loadData()

When user tapping on Xem thêm button, the SDK will navigate to User corner list screen.