jifenShop.vue 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. <template>
  2. <view class="container">
  3. <view class="goodsList-box">
  4. <view class="goodsList-item flex" >
  5. <image src="" mode=" scaleToFill"></image>
  6. <view class="goodsList-content">
  7. <view class="title">
  8. <text class="clamp2"></text>
  9. </view>
  10. <view class="goods-money flex">
  11. <view class="money-box">
  12. <text class="otMoney">¥</text>
  13. <image src="../../static/icon/in2.png"></image>
  14. <!-- <image src="../../static/error/errorImage.jpg"></image> -->
  15. <text class="decline">直降元</text>
  16. <!-- <view class="otMoney-box"> -->
  17. <view class="money">¥</view>
  18. <!-- <text class="sales">已售{{ ls.sales }}件</text> -->
  19. <!-- </view> -->
  20. </view>
  21. <view class="button" @click="navTo(ls)">立即购买</view>
  22. </view>
  23. </view>
  24. </view>
  25. </view>
  26. </view>
  27. </template>
  28. <script>
  29. import { loadIndexs,groom } from '@/api/index.js';
  30. export default {
  31. data() {
  32. return {
  33. list: [],
  34. bannerImg: [],
  35. title: '',
  36. goods: [],
  37. page: 1,
  38. limit: 10
  39. };
  40. },
  41. onLoad(option) {
  42. },
  43. methods: {
  44. }
  45. }
  46. </script>
  47. <style lang="scss">
  48. page {
  49. background: $page-color-base;
  50. }
  51. .carousel-section {
  52. padding: 0;
  53. .titleNview-placing {
  54. padding-top: 0;
  55. height: 0;
  56. }
  57. .swiper-dots {
  58. left: 45rpx;
  59. bottom: 40rpx;
  60. }
  61. .carousel {
  62. width: 100%;
  63. height: 360rpx;
  64. .carousel-item {
  65. width: 100%;
  66. height: 100%;
  67. overflow: hidden;
  68. }
  69. image {
  70. width: 100%;
  71. height: 100%;
  72. }
  73. }
  74. }
  75. // 中间标题样式
  76. .type-title-box {
  77. padding: 40rpx;
  78. .title-content {
  79. height: 100%;
  80. width: 200rpx;
  81. text-align: center;
  82. font-size: $font-lg;
  83. font-weight: 500;
  84. color: $font-color-dark;
  85. }
  86. .title-border {
  87. width: 250rpx;
  88. height: 2rpx;
  89. background-color: #e9e9e9;
  90. }
  91. }
  92. // 商品列表
  93. .goodsList-box {
  94. padding: 30rpx;
  95. .goodsList-item {
  96. box-shadow:0 0 20rpx 6rpx #f1f1f1;
  97. border-radius: 10rpx;
  98. margin-bottom: 30rpx;
  99. background-color: #ffffff;
  100. padding: 30rpx;
  101. image {
  102. flex-shrink: 0;
  103. border-radius: $border-radius-sm;
  104. height: 180rpx;
  105. width: 180rpx;
  106. }
  107. .goodsList-content {
  108. margin-left: 20rpx;
  109. flex-grow: 1;
  110. height: 180rpx;
  111. position: relative;
  112. .title {
  113. font-size: $font-base;
  114. color: $font-color-dark;
  115. font-weight: bold;
  116. }
  117. .goods-money {
  118. position: absolute;
  119. left: 0;
  120. bottom: 0;
  121. width:100%;
  122. .money-box {
  123. .otMoney {
  124. color: #999999;
  125. text-decoration: line-through;
  126. margin-right: 15rpx;
  127. font-size: 20rpx;
  128. }
  129. .money {
  130. color: #FF6F0F;
  131. font-weight: bold;
  132. font-size: 35rpx;
  133. }
  134. image {
  135. width: 20rpx;
  136. height: 20rpx;
  137. margin-right: 5rpx;
  138. }
  139. .decline {
  140. color: #B59467;
  141. font-size: 20rpx;
  142. }
  143. .sales {
  144. color: $font-color-light;
  145. }
  146. }
  147. .button {
  148. background: #52C696;
  149. height: 50rpx;
  150. border-radius: 20rpx;
  151. padding: 10rpx 15rpx;
  152. color: #fff;
  153. font-size: 25rpx;
  154. position: relative;
  155. top: 20rpx;
  156. }
  157. .cart {
  158. border: 1px solid $color-red;
  159. color: $color-red;
  160. font-size: $font-base;
  161. font-weight: bold;
  162. border-radius: 99px;
  163. width: 55rpx;
  164. height: 55rpx;
  165. display: flex;
  166. justify-content: center;
  167. align-items: center;
  168. }
  169. }
  170. }
  171. }
  172. }
  173. </style>