feat: fix user boughts

This commit is contained in:
Rogee
2025-04-30 21:44:18 +08:00
parent 9c88b14202
commit 53b3556ee9
6 changed files with 11 additions and 8 deletions

View File

@@ -17,7 +17,7 @@ const formattedDate = computed(() => {
})
const discountPrice = computed(() => {
return (props.article.price * props.article.discount / 100).toFixed(2)
return (props.article.price * props.article.discount / (100 * 100)).toFixed(2)
})
const showArticle = (article) => {
@@ -68,7 +68,7 @@ const showArticle = (article) => {
</span>
<template v-else>
<span v-if="article.discount < 100" class="text-xs line-through text-gray-500">
¥{{ article.price }}
¥{{ (article.price / 100).toFixed(2) }}
</span>
<span class="text-xl text-orange-600">&yen;{{ discountPrice }}</span>
</template>