Skip to content

Commit

Permalink
fix: payment method name (#143)
Browse files Browse the repository at this point in the history
* fix: payment method name

* chore: changeset

* chore: add more translated properties
  • Loading branch information
patzick authored Apr 14, 2023
1 parent bbd7347 commit ffde908
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 6 deletions.
5 changes: 5 additions & 0 deletions .changeset/happy-owls-deliver.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"vue-demo-store": patch
---

payment method name displayed properly in checkout
2 changes: 1 addition & 1 deletion templates/vue-demo-store/pages/account/payment.vue
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ onMounted(async () => {
:for="paymentMethod.id"
class="ml-3 block text-sm font-medium text-gray-700"
>
{{ paymentMethod.name }}
{{ paymentMethod.translated?.name }}
</label>
</div>
<button
Expand Down
4 changes: 2 additions & 2 deletions templates/vue-demo-store/pages/checkout/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -609,7 +609,7 @@ async function invokeLogout() {
:class="{ 'animate-pulse': isLoading[singleShippingMethod.id] }"
class="ml-2 block text-sm font-medium text-gray-700"
>
{{ singleShippingMethod.name }}
{{ singleShippingMethod.translated?.name }}
</label>
</div>
</fieldset>
Expand Down Expand Up @@ -651,7 +651,7 @@ async function invokeLogout() {
:class="{ 'animate-pulse': isLoading[singlePaymentMethod.id] }"
class="ml-2 block text-sm font-medium text-gray-700"
>
{{ singlePaymentMethod.name }}
{{ singlePaymentMethod.translated?.name }}
</label>
</div>
</fieldset>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,13 +182,13 @@ const formatDate = (date: Date) =>
<div class="w-auto md:w-1/2">
<div class="font-medium">Payment method</div>
<div class="pt-2 text-gray-600">
<div>{{ paymentMethod?.name }}</div>
<div>{{ paymentMethod?.translated?.name }}</div>
</div>
</div>
<div v-if="shippingMethod" class="w-auto md:w-1/2">
<div class="font-medium">Shipping method</div>
<div class="pt-2 text-gray-600">
<div>{{ shippingMethod?.name }}</div>
<div>{{ shippingMethod?.translated?.name }}</div>
<div v-if="shippingMethod?.deliveryTime">
Takes up to {{ shippingMethod.deliveryTime?.name }}
</div>
Expand Down
3 changes: 2 additions & 1 deletion templates/vue-vite-blank/src/components/Frontends.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ const { isLoggedIn } = useUser();
Currency: <strong>{{ currency?.name }} ({{ currency?.symbol }})</strong>
</p>
<p>
Default payment method: <strong>{{ selectedPaymentMethod?.name }}</strong>
Default payment method:
<strong>{{ selectedPaymentMethod?.translated?.name }}</strong>
</p>
<p>
Is customer logged in: <strong>{{ isLoggedIn }}</strong>
Expand Down

2 comments on commit ffde908

@vercel
Copy link

@vercel vercel bot commented on ffde908 Apr 14, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

frontends-demo – ./templates/vue-demo-store

frontends-demo-git-main-shopware-frontends.vercel.app
frontends-demo.vercel.app
frontends-demo-shopware-frontends.vercel.app

@vercel
Copy link

@vercel vercel bot commented on ffde908 Apr 14, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.