WaterfallsFlowItem.vue 3.0 KB

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