版本更新,折扣打印优化
This commit is contained in:
@@ -6,10 +6,10 @@
|
||||
<span class="num">{{ money }}</span>
|
||||
</div>
|
||||
<div class="t2">
|
||||
<span>共计:¥{{ props.amount }}</span>
|
||||
<span>原价:¥{{ formatDecimal(props.amount) }}</span>
|
||||
<span style="margin-left: 20px;">优惠:¥{{ formatDecimal(props.amount - money) }}</span>
|
||||
<span v-if="props.discount" @click="cancelDiscount">({{ formatDecimal(props.discount * 10, 1, true) }}折)
|
||||
<el-icon>
|
||||
<span style="margin-left: 20px;" v-if="props.discount" @click="cancelDiscount">折扣:{{ formatDecimal(props.discount * 10, 1, true) }}折
|
||||
<el-icon style="margin-left: 6px;">
|
||||
<CircleClose />
|
||||
</el-icon>
|
||||
</span>
|
||||
@@ -124,7 +124,7 @@ const money = ref('0')
|
||||
const scanModalRef = ref(null)
|
||||
|
||||
watch(props, (value) => {
|
||||
money.value = `${props.amount}`
|
||||
money.value = `${formatDecimal(props.amount)}`
|
||||
if (props.discount > 0) {
|
||||
money.value = `${formatDecimal(props.amount * props.discount)}`
|
||||
}
|
||||
@@ -334,7 +334,7 @@ function cancelDiscount() {
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
money.value = `${props.amount}`
|
||||
money.value = `${formatDecimal(props.amount)}`
|
||||
queryPayTypeAjax()
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user