index.vue 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. <template>
  2. <view>
  3. <!-- 购物车优惠明细 -->
  4. <base-drawer mode="bottom" :visible="discountInfo.discount" background-color="transparent" mask maskClosable @close="closeDiscount">
  5. <view class="w-full bg--w111-fff rd-t-40rpx py-32">
  6. <view class="text-center fs-32 text--w111-333 fw-500">金额明细</view>
  7. <view class="mt-32 p-32 scroll-content" :style="[moneyPD.pb]">
  8. <view class="flex-between-center">
  9. <view class="fs-26">商品总价:</view>
  10. <view class="fs-28 SemiBold">¥{{discountInfo.deduction.sum_price}}</view>
  11. </view>
  12. <!-- <view class="flex-between-center mt-38">
  13. <view class="fs-26">优惠抵扣:</view>
  14. <view class="fs-28 SemiBold">-¥{{$util.$h.Sub(discountInfo.deduction.sum_price,discountInfo.deduction.pay_price)}}</view>
  15. </view> -->
  16. <view class="flex-between-center mt-38" v-if="discountInfo.deduction.coupon_price">
  17. <view class="fs-26">{{discountInfo.coupon.coupon_title}}</view>
  18. <view class="fs-28 SemiBold">-¥{{discountInfo.deduction.coupon_price}}</view>
  19. </view>
  20. <view class="flex-between-center mt-38" v-if="discountInfo.deduction.first_order_price">
  21. <view class="fs-26">新人首单优惠</view>
  22. <view class="fs-28 SemiBold">-¥{{discountInfo.deduction.first_order_price}}</view>
  23. </view>
  24. <view class="flex-between-center mt-38" v-if="discountInfo.deduction.promotions_price">
  25. <view class="fs-26">优惠活动</view>
  26. <view class="fs-28 SemiBold">-¥{{discountInfo.deduction.promotions_price}}</view>
  27. </view>
  28. <view class="flex-between-center mt-38" v-if="discountInfo.deduction.vip_price">
  29. <view class="fs-26">会员优惠</view>
  30. <view class="fs-28 SemiBold">-¥{{discountInfo.deduction.vip_price}}</view>
  31. </view>
  32. <view class="flex-between-center mt-44" v-if="discountInfo.deduction.vip_price">
  33. <view class="fs-28 fw-500">优惠合计</view>
  34. <view class="fs-32 SemiBold font-num">-¥{{$util.$h.Sub(discountInfo.deduction.sum_price,discountInfo.deduction.pay_price)}}</view>
  35. </view>
  36. </view>
  37. </view>
  38. </base-drawer>
  39. </view>
  40. </template>
  41. <script>
  42. import baseDrawer from '@/components/tui-drawer/tui-drawer.vue';
  43. export default {
  44. props: {
  45. discountInfo: {
  46. type: Object,
  47. default: () => {}
  48. },
  49. moneyPD: {
  50. type: Object,
  51. default: () => {}
  52. }
  53. },
  54. components:{
  55. baseDrawer
  56. },
  57. data() {
  58. return {};
  59. },
  60. mounted() {},
  61. methods: {
  62. closeDiscount(){
  63. this.$emit('myevent');
  64. }
  65. }
  66. }
  67. </script>
  68. <style scoped lang="scss">
  69. .scroll-content {
  70. max-height: 600rpx;
  71. overflow-y: auto;
  72. }
  73. </style>