Last active
June 28, 2020 05:34
-
-
Save shanwixcode/fb3bd571fe15cb8e288793489ca7cfe4 to your computer and use it in GitHub Desktop.
Stripe Tutorial - Dude Lemon
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export function selectPlan_click(event) { | |
let $item = $w.at(event.context); | |
$w('#selectPlan').hide(); //hide button | |
$item("#openingLb").show(); //show a loader animation on this item | |
let planData = $item("#plans").getCurrentItem(); //get the click item's data from its dataset | |
let deployData = { | |
name: planData.displayName, | |
price: planData.displayPrice, | |
planId: planData.planId, | |
currency: planData.currency | |
}; | |
wixWindow.openLightbox('subscribe', deployData) //lightbox name | |
.then( () => { | |
$item("#openingLb").hide(); | |
$w("#selectPlan").show(); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment