fix: error for default

pull/1/head
Saeid 4 years ago
parent 39f7261828
commit 200ffde1c5

1
.gitignore vendored

@ -32,6 +32,7 @@ Homestead.json
### PhpStorm ### ### PhpStorm ###
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider # Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 # Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
.idea/
.idea/vcs.xml .idea/vcs.xml
# User-specific stuff # User-specific stuff
.idea/**/workspace.xml .idea/**/workspace.xml

@ -1,7 +1,7 @@
<template> <template>
<div :class="`we-price ${theme}`"> <div :class="`we-price ${theme}`">
<div v-if="original_price && original_price != 0" class="discount"> <div v-if="original_price && original_price != 0" class="discount">
<div class="number-original En Bold" > {{ Intl.NumberFormat().format(original_price) }} </div> <div class="number-original En Bold" > {{ Intl.NumberFormat().format(Number(original_price)) }} </div>
<div class="percent En Bold"> 12 <v-icon color="white"> WMi-percentage</v-icon> </div> <div class="percent En Bold"> 12 <v-icon color="white"> WMi-percentage</v-icon> </div>
</div> </div>
<div v-if="(price != 0 || !zeroLabel)" class="number En Bold"> {{ Intl.NumberFormat().format(price) }} </div> <div v-if="(price != 0 || !zeroLabel)" class="number En Bold"> {{ Intl.NumberFormat().format(price) }} </div>
@ -14,7 +14,7 @@
export default { export default {
props: { props: {
theme: { default: '' }, theme: { default: '' },
original_price: String, original_price: { default: 0 },
price: { default: 1000 }, price: { default: 1000 },
label: { default: 'تومان' }, label: { default: 'تومان' },
zeroLabel: String, zeroLabel: String,

Loading…
Cancel
Save