WaterfallsFlowItem.vue 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. <template>
  2. <view class="wf-item-page wf-page0">
  3. <view class='pictrue'>
  4. <easy-loadimage
  5. mode="widthFix"
  6. :image-src="item.image"
  7. width="100%"
  8. height="345rpx"
  9. borderRadius="16rpx 16rpx 0 0"></easy-loadimage>
  10. </view>
  11. <view class="info_box">
  12. <view class="w-full line2 fs-28 text--w111-333 lh-40rpx">
  13. <text v-if="item.brand_name" class="brand-tag">{{ item.brand_name }}</text>{{item.store_name}}
  14. </view>
  15. <view class="mt-8">
  16. <view class="flex-y-center flex-wrap mt-8">
  17. <baseMoney :money="item.price" symbolSize="24" integerSize="40" decimalSize="24" weight></baseMoney>
  18. <view class="inline-block h-26 lh-28rpx rd-14rpx bg--w111-F7E9CD fs-22 ml-8"
  19. v-if="Number(item.vip_price) > 0">
  20. <text class="inline-block h-26 lh-28rpx svip_rd fs-18 bg--w111-484643 text--w111-FDDAA4 px-8">SVIP</text>
  21. <text class="px-8 fs-22 SemiBold">¥{{item.vip_price}}</text>
  22. </view>
  23. </view>
  24. <view class="flex-between-center mt-12">
  25. <text class="fs-22 text--w111-999">已售{{item.sales}}{{item.unit_name}}</text>
  26. <view class="w-44 h-44 rd-24 bg-gradient flex-center" v-if="goDetail=='goDetail'">
  27. <text class="iconfont icon-ic_ShoppingCart1 text--w111-fff fs-26"></text>
  28. </view>
  29. <view class="w-44 h-44 rd-24 bg-gradient flex-center" @tap.stop="addCartChange" v-else>
  30. <text class="iconfont icon-ic_ShoppingCart1 text--w111-fff fs-26"></text>
  31. </view>
  32. </view>
  33. </view>
  34. </view>
  35. </view>
  36. </template>
  37. <script>
  38. import easyLoadimage from '@/components/easy-loadimage/easy-loadimage.vue'
  39. import {mapGetters} from "vuex";
  40. import {HTTP_REQUEST_URL} from '@/config/app';
  41. export default {
  42. components: {
  43. easyLoadimage
  44. },
  45. props: {
  46. item: {
  47. type: Object,
  48. require: true
  49. },
  50. type: {
  51. type: Number,
  52. default: 0
  53. },
  54. recommend:{
  55. type: Boolean,
  56. default: false
  57. },
  58. goDetail: {
  59. type: String,
  60. default: ''
  61. }
  62. },
  63. data() {
  64. return {
  65. domain: HTTP_REQUEST_URL
  66. }
  67. },
  68. methods: {
  69. addCartChange(){
  70. this.$eventHub.$emit('onCartAddChange',this.item);
  71. },
  72. }
  73. }
  74. </script>
  75. <style lang="scss" scoped>
  76. .wf-item-page {
  77. background: #fff;
  78. overflow: hidden;
  79. border-radius: 20rpx;
  80. }
  81. .info_box{
  82. padding: 16rpx 20rpx;
  83. border-radius: 0 0 20rpx 20rpx;
  84. background-color: #fff;
  85. }
  86. .text-primary-con{
  87. color: var(--view-theme);
  88. }
  89. .bg-primary-light{
  90. background: var(--view-minorColorT);
  91. }
  92. .bg--w111-484643{
  93. background: linear-gradient(90deg, #484643 0%, #1F1B17 100%);
  94. }
  95. .text--w111-FDDAA4{
  96. color: #FDDAA4;
  97. }
  98. .svip_rd{
  99. border-radius: 14rpx 0 8rpx 14rpx;
  100. }
  101. </style>