|
@@ -1,4 +1,4 @@
|
|
-import { computed, ref, defineComponent, onMounted, reactive,watch } from 'vue'
|
|
|
|
|
|
+import { computed, ref, defineComponent, onMounted, reactive, watch } from 'vue'
|
|
import { Card, Cell, CellGroup, Popup, SubmitBar, Toast } from 'vant'
|
|
import { Card, Cell, CellGroup, Popup, SubmitBar, Toast } from 'vant'
|
|
import { addressType, cartConfirm, formateAttr } from '../cart'
|
|
import { addressType, cartConfirm, formateAttr } from '../cart'
|
|
import styles from '../index.module.less'
|
|
import styles from '../index.module.less'
|
|
@@ -12,6 +12,7 @@ import ColPopup from '@/components/col-popup'
|
|
import UserAuth from '@/views/order-detail/userAuth'
|
|
import UserAuth from '@/views/order-detail/userAuth'
|
|
import ColResult from '@/components/col-result'
|
|
import ColResult from '@/components/col-result'
|
|
import { moneyFormat } from '@/helpers/utils'
|
|
import { moneyFormat } from '@/helpers/utils'
|
|
|
|
+import UseCoupons, { couponEnum } from '@/views/order-detail/use-coupons'
|
|
export default defineComponent({
|
|
export default defineComponent({
|
|
name: 'cartConfirmAgin',
|
|
name: 'cartConfirmAgin',
|
|
setup() {
|
|
setup() {
|
|
@@ -20,7 +21,8 @@ export default defineComponent({
|
|
const calcAmount = {
|
|
const calcAmount = {
|
|
totalAmount: cartConfirm.orderInfo?.totalAmount || 0,
|
|
totalAmount: cartConfirm.orderInfo?.totalAmount || 0,
|
|
payAmount: cartConfirm.orderInfo?.payAmount || 0,
|
|
payAmount: cartConfirm.orderInfo?.payAmount || 0,
|
|
- freightAmount: cartConfirm.orderInfo?.freightAmount || 0
|
|
|
|
|
|
+ freightAmount: cartConfirm.orderInfo?.freightAmount || 0,
|
|
|
|
+ couponAmount: cartConfirm.orderInfo?.couponAmount
|
|
}
|
|
}
|
|
const payType = ref(0) // 0->未支付;1->支付宝;2->微信
|
|
const payType = ref(0) // 0->未支付;1->支付宝;2->微信
|
|
const address: addressType = {
|
|
const address: addressType = {
|
|
@@ -105,6 +107,23 @@ export default defineComponent({
|
|
<CellGroup border={false}>
|
|
<CellGroup border={false}>
|
|
<Cell
|
|
<Cell
|
|
border={false}
|
|
border={false}
|
|
|
|
+ title="优惠劵"
|
|
|
|
+ v-slots={{
|
|
|
|
+ value: () => (
|
|
|
|
+ <span
|
|
|
|
+ style={{
|
|
|
|
+ fontSize: '0.42667rem',
|
|
|
|
+ color: '#ff3535',
|
|
|
|
+ fontWeight: 'bold'
|
|
|
|
+ }}
|
|
|
|
+ >
|
|
|
|
+ {'-¥ ' + calcAmount.couponAmount}
|
|
|
|
+ </span>
|
|
|
|
+ )
|
|
|
|
+ }}
|
|
|
|
+ ></Cell>
|
|
|
|
+ <Cell
|
|
|
|
+ border={false}
|
|
title="总额"
|
|
title="总额"
|
|
value={'¥ ' + calcAmount.totalAmount}
|
|
value={'¥ ' + calcAmount.totalAmount}
|
|
></Cell>
|
|
></Cell>
|
|
@@ -113,7 +132,7 @@ export default defineComponent({
|
|
title="运费"
|
|
title="运费"
|
|
value={calcAmount.freightAmount}
|
|
value={calcAmount.freightAmount}
|
|
></Cell>
|
|
></Cell>
|
|
- <Cell border={false} title="优惠" value={'-¥ ' + cartConfirm.orderInfo?.promotionAmount}></Cell> */}
|
|
|
|
|
|
+ */}
|
|
{/* <Cell border={false} title="优惠卷" value="暂无可用优惠卷"></Cell>
|
|
{/* <Cell border={false} title="优惠卷" value="暂无可用优惠卷"></Cell>
|
|
<Cell border={false} title="乐乐币抵扣" value={"-¥" + calcAmount.promotionAmount}></Cell> */}
|
|
<Cell border={false} title="乐乐币抵扣" value={"-¥" + calcAmount.promotionAmount}></Cell> */}
|
|
</CellGroup>
|
|
</CellGroup>
|