detail.vue 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219
  1. <template>
  2. <div class="point-detail">
  3. <div class="good">
  4. <img :src="img" alt="" srcset="" />
  5. </div>
  6. <div class="title">
  7. <div class="text">教育读本</div>
  8. <div class="price">
  9. <span class="icon"></span>
  10. <span class="amount">99.00</span>
  11. </div>
  12. <div class="sold">已兑换223</div>
  13. </div>
  14. <!-- <div class="selected">
  15. <div class="text">已选</div>
  16. <div class="content">儿童情商课+智慧课堂,1</div>
  17. <div class="icon"></div>
  18. </div> -->
  19. <!-- <div class="pictures">
  20. <div class="text">- 图文详情 -</div>
  21. </div> -->
  22. <div class="buy">
  23. <nuxt-link to="/point/pay" tag="button">立刻兑换</nuxt-link>
  24. </div>
  25. </div>
  26. </template>
  27. <script>
  28. import ProductList from "../../components/ProductList";
  29. export default {
  30. head() {
  31. return {
  32. title: "积分商品详情页",
  33. };
  34. },
  35. data() {
  36. return {
  37. images: [],
  38. list: [],
  39. loading: false, // 加载状态
  40. finished: false, // 是否完成加载
  41. refreshing: false, // 是否正在上拉刷新
  42. img: "/test/pro.png",
  43. };
  44. },
  45. components: {
  46. ProductList,
  47. },
  48. beforeCreate() {},
  49. created() {},
  50. beforeMount() {},
  51. mounted() {
  52. console.log(this);
  53. },
  54. beforeUpdate() {},
  55. updated() {},
  56. beforeDestroy() {},
  57. destroyed() {},
  58. methods: {},
  59. };
  60. </script>
  61. <style>
  62. .point-detail {
  63. display: flex;
  64. width: 100vw;
  65. flex-direction: column;
  66. box-sizing: border-box;
  67. background: #f8f8f8;
  68. }
  69. .point-detail .good {
  70. box-sizing: border-box;
  71. width: 100vw;
  72. height: 100vw;
  73. padding: 15vw;
  74. background: #ffffff;
  75. }
  76. .point-detail .good img {
  77. width: 100%;
  78. height: 100%;
  79. }
  80. .point-detail .title {
  81. width: 100%;
  82. height: 26.66vw;
  83. padding: 4vw;
  84. background: #ffffff;
  85. position: relative;
  86. box-sizing: border-box;
  87. }
  88. .point-detail .title .text {
  89. width: 3.6rem;
  90. height: 0.5rem;
  91. font-size: 0.36rem;
  92. font-family: PingFangSC-Medium, PingFang SC;
  93. font-weight: 800;
  94. color: #111111;
  95. line-height: 0.5rem;
  96. position: absolute;
  97. left: 0.3rem;
  98. top: 0.3rem;
  99. }
  100. .point-detail .title .price {
  101. height: 0.7rem;
  102. font-size: 0.28rem;
  103. font-family: PingFangSC-Semibold, PingFang SC;
  104. font-weight: 600;
  105. color: #fe9700;
  106. line-height: 0.7rem;
  107. position: absolute;
  108. left: 0.57rem;
  109. bottom: 0.27rem;
  110. }
  111. .point-detail .title .price .icon {
  112. display: inline-block;
  113. width: 0.3rem;
  114. height: 0.3rem;
  115. background: url("../../static/common/a01_jifen@2x.png") no-repeat;
  116. background-size: cover;
  117. margin-right: 0.1rem;
  118. }
  119. .point-detail .title .price .amount {
  120. display: inline-block;
  121. font-size: 0.5rem;
  122. }
  123. .point-detail .title .sold {
  124. height: 0.4rem;
  125. font-size: 0.28rem;
  126. font-family: PingFangSC-Regular, PingFang SC;
  127. font-weight: 400;
  128. color: #666666;
  129. line-height: 0.4rem;
  130. position: absolute;
  131. right: 0.45rem;
  132. bottom: 0.3rem;
  133. }
  134. .point-detail .selected {
  135. width: 100%;
  136. height: 1.1rem;
  137. background: #ffffff;
  138. margin-top: 0.2rem;
  139. position: relative;
  140. }
  141. .point-detail .selected .text {
  142. width: 0.56rem;
  143. height: 1.1rem;
  144. font-size: 0.28rem;
  145. font-family: PingFangSC-Regular, PingFang SC;
  146. font-weight: 400;
  147. color: #aaaaaa;
  148. line-height: 1.1rem;
  149. position: absolute;
  150. left: 0.31rem;
  151. top: 0rem;
  152. }
  153. .point-detail .selected .content {
  154. width: 3.09rem;
  155. height: 1.1rem;
  156. font-size: 0.28rem;
  157. font-family: PingFangSC-Regular, PingFang SC;
  158. font-weight: 500;
  159. color: #111111;
  160. line-height: 1.1rem;
  161. position: absolute;
  162. left: 1.17rem;
  163. }
  164. .point-detail .selected .icon {
  165. width: 0.42rem;
  166. height: 0.1rem;
  167. background: url("../../static/point/6_d02_more.png") no-repeat 0px 0px;
  168. background-size: cover;
  169. position: absolute;
  170. left: 6.3rem;
  171. top: 0.49rem;
  172. }
  173. .point-detail .pictures {
  174. width: 100%;
  175. height: 3.2rem;
  176. background: #ffffff;
  177. margin-top: 0.21rem;
  178. position: relative;
  179. }
  180. .point-detail .pictures .text {
  181. width: 1.74rem;
  182. height: 1.1rem;
  183. font-size: 0.28rem;
  184. font-family: PingFangSC-Regular, PingFang SC;
  185. font-weight: 400;
  186. color: #aaaaaa;
  187. line-height: 1.1rem;
  188. position: absolute;
  189. top: 0rem;
  190. left: 2.88rem;
  191. }
  192. .point-detail .buy {
  193. position: fixed;
  194. bottom: 0.83rem;
  195. left: 0;
  196. right: 0;
  197. height: 1.03rem;
  198. }
  199. .point-detail .buy button {
  200. border: none;
  201. background-color: transparent;
  202. outline: none;
  203. display: block;
  204. width: 6.9rem;
  205. height: 0.8rem;
  206. background: #fe9700;
  207. border-radius: 0.45rem;
  208. font-size: 0.28rem;
  209. font-family: PingFangSC-Regular, PingFang SC;
  210. font-weight: 400;
  211. color: #ffffff;
  212. line-height: 0.4rem;
  213. margin: 0 auto;
  214. }
  215. </style>