瀏覽代碼

adjust labels

pull/1/head
Jonathan Cobb 4 年之前
父節點
當前提交
2487cc685c
共有 1 個檔案被更改,包括 1 行新增4 行删除
  1. +1
    -4
      src/account/payment/StripePayment.vue

+ 1
- 4
src/account/payment/StripePayment.vue 查看文件

@@ -1,7 +1,7 @@
<template>
<div>
<div ref="card"></div>
<button v-on:click="authorizeCard">{{messages.button_label_submit_card_authorization}}</button>
<button v-on:click="authorizeCard">{{messages.button_label_submit_card}}</button>
</div>
</template>

@@ -21,7 +21,6 @@
...mapState('system', ['messages']),
},
created () {
console.log('StripePayment.vue: created, stripe key='+this.paymentMethod.driverConfig.publicApiKey);
window.stripe = Stripe(this.paymentMethod.driverConfig.publicApiKey);
this.elements = window.stripe.elements();
this.card = undefined;
@@ -33,8 +32,6 @@
methods: {
...mapActions('paymentMethods', ['setPaymentInfo']),
authorizeCard(e) {
console.log('authorizeCard: starting with key='+this.paymentMethod.driverConfig.publicApiKey);
// window.stripe.setPublishableKey(this.paymentMethod.driverConfig.publicApiKey);
window.stripe.createToken(this.card).then(function(result) {
console.log('authorizedCard: created token='+JSON.stringify(result.token));
if (result.error) {


Loading…
取消
儲存