detail.vue 4.2 KB

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