disable the button as soon as it is clicked
This commit is contained in:
parent
e8a50b0930
commit
70b928707f
|
@ -52,15 +52,17 @@ export default Ember.Component.extend({
|
|||
submitStripeCard() {
|
||||
let self = this;
|
||||
|
||||
self.set('transactionInProgress', true);
|
||||
|
||||
this.get('stripe').createToken(this.get('card')).then(data => {
|
||||
|
||||
self.set('result', []);
|
||||
|
||||
if (data.error) {
|
||||
self.set('result', data.error.message);
|
||||
self.endTranscation();
|
||||
}
|
||||
else {
|
||||
self.set('transactionInProgress', true);
|
||||
|
||||
let params = {
|
||||
stripeToken: data.token.id,
|
||||
|
|
Loading…
Reference in New Issue