mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
33 lines
494 B
Vue
33 lines
494 B
Vue
<template>
|
|
<van-cell
|
|
class="van-order-goods-price"
|
|
title="合计"
|
|
:value="totalPrice"
|
|
/>
|
|
</template>
|
|
|
|
<script>
|
|
import Cell from '../cell';
|
|
import { getTotalPrice } from './utils';
|
|
|
|
export default {
|
|
name: 'van-order-goods-price',
|
|
|
|
components: {
|
|
[Cell.name]: Cell
|
|
},
|
|
|
|
props: {
|
|
price: Number,
|
|
points: Number,
|
|
isPoints: Boolean
|
|
},
|
|
|
|
computed: {
|
|
totalPrice() {
|
|
return getTotalPrice(this.price, this.points, this.isPoints);
|
|
}
|
|
}
|
|
};
|
|
</script>
|