Skip to content

Commit

Permalink
Remove capture mode selector, only capture is implemented
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt75 committed Dec 15, 2022
1 parent 087a6f0 commit ac41f2b
Showing 1 changed file with 6 additions and 39 deletions.
45 changes: 6 additions & 39 deletions _dev/js/back/src/components/panel/payment-mode.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,27 +23,13 @@
{{ $t('panel.payment-mode.title') }}
</template>
<b-card-body>
<b-alert class="d-inline-block w-100" variant="warning" show>
<p>
After switch environment, please logout from PayPal Account and login
again on the new environment.
</p>
</b-alert>
<b-form>
<b-form-group
label-cols="4"
label-align="right"
:label="$t('panel.payment-mode.paymentAction')"
label-for="intent-mode"
>
<b-form-radio-group
id="intent-mode"
v-model="captureMode"
:options="intentOptions"
buttons
button-variant="outline-primary"
name="radio-btn-outline"
/>
</b-form-group>

<b-alert class="d-inline-block w-100" variant="info" show>
<p>{{ $t('panel.payment-mode.infoAlertText') }}.</p>
</b-alert>

<b-form-group
v-if="paymentMode === 'LIVE'"
label-cols="4"
Expand Down Expand Up @@ -96,14 +82,6 @@

<script>
export default {
data() {
return {
intentOptions: [
{ text: this.$t('panel.payment-mode.capture'), value: 'CAPTURE' },
{ text: this.$t('panel.payment-mode.authorize'), value: 'AUTHORIZE' }
]
};
},
methods: {
updatePaymentMode() {
let mode = 'LIVE';
Expand All @@ -117,17 +95,6 @@
}
},
computed: {
captureMode: {
get() {
return this.$store.state.configuration.captureMode;
},
set(value) {
if (this.captureMode === value) {
return;
}
this.$store.dispatch('updateCaptureMode', value);
}
},
paymentMode() {
return this.$store.state.configuration.paymentMode;
}
Expand Down

0 comments on commit ac41f2b

Please sign in to comment.