Переглянути джерело

Merge branch 'staging-fixes' into staging

pull/2/head
Nabin Hait 6 роки тому
джерело
коміт
ec83fc6765
3 змінених файлів з 18 додано та 1 видалено
  1. +8
    -0
      payments/templates/includes/braintree_checkout.js
  2. +1
    -1
      payments/templates/pages/braintree_checkout.html
  3. +9
    -0
      payments/templates/pages/payment-success.html

+ 8
- 0
payments/templates/includes/braintree_checkout.js Переглянути файл

@@ -42,6 +42,14 @@ $(document).ready(function() {
})
});
});

instance.on('paymentMethodRequestable', function (event) {
button.removeAttribute('disabled');
});

instance.on('noPaymentMethodRequestable', function () {
button.setAttribute('disabled', true);
});
});

})

+ 1
- 1
payments/templates/pages/braintree_checkout.html Переглянути файл

@@ -26,7 +26,7 @@
</div>
</section>

<button class="btn btn-primary" type="submit" id="submit-button"><span>{{ _("Pay") }} {{ amount }} {{ currency }}</span></button>
<button class="btn btn-primary" type="submit" id="submit-button" disabled><span>{{ _("Pay") }} {{ amount }} {{ currency }}</span></button>
</form>

</div>


+ 9
- 0
payments/templates/pages/payment-success.html Переглянути файл

@@ -15,4 +15,13 @@
<style>
{% include "templates/styles/card_style.css" %}
</style>
<script>
frappe.ready(function() {
if('{{ frappe.form_dict.redirect_to or "" }}'){
setTimeout(function(){
window.location.href = '{{ frappe.form_dict.redirect_to }}';
}, 6000);
}
})
</script>
{% endblock %}

Завантаження…
Відмінити
Зберегти