Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Say Thanks
Say Thanks
View message
Customer app link -> Voucher logic
SMS link -> Voucher logic
Voucher logic
Has this voucher been claimed before?
Yes -> View used voucher
No -> Is this a single product voucher?
View used voucher
Is this a single product voucher?
Yes -> Redeem
No -> Multiple product voucher
Multiple product voucher
View category
Transport & Travel -> View product
TV & Media -> View product
help -> Reward help
View product
Go back -> View category
R200 voucher -> View selected product
3 month subscription - R400 -> View selected product
help -> Product help
Help
Reward help
Go back -> View category
Product help
Go back -> View product
Redeem
View selected product
Go back multiple product -> View product
Redeem -> Confirm product
Confirm product
Go back -> View selected product
Confirm -> Voucher code
Voucher
Voucher code
Email me this voucher -> Enter email
Enter email
Go back -> Voucher code
Send -> View confirmation
View confirmation
function render(model){
if (model.active_states[0].image_url) {
return $("img",
{src: model.active_states[0].image_url, style: {height: "100%"}});
} else {
let current_state_name = model.active_states[0].name;
return $("h1",
{style: {color: "darkBlue"}},
`The current state is: ${current_state_name}`);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.