index.vue 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206
  1. <template>
  2. <view class="">
  3. <view class="swiper">
  4. <u-swiper :list="swiper" keyName="url" height="100%" ></u-swiper>
  5. <view class="banner">
  6. <view class="logo">
  7. <image src="../../static/LOGO@2x.png" mode="widthFix"></image>
  8. </view>
  9. <view class="bannertitle">
  10. 遇见森林瑜伽
  11. </view>
  12. <view class="subtitle">
  13. 明心静待花开
  14. </view>
  15. </view>
  16. </view>
  17. <view class="contentTops">
  18. <view class="contentTop">
  19. <view class="iconl">
  20. </view>
  21. <view class="contentTop-title">
  22. 日月峡森林康养
  23. </view>
  24. <view class="iconr">
  25. <image src="../../static/senlinicon@2x.png" mode="widthFix"></image>
  26. </view>
  27. </view>
  28. </view>
  29. <view class="list">
  30. <view class="video">
  31. <!-- 这是视频 -->
  32. <video poster=""></video>
  33. </view>
  34. <view class="contentfooter">
  35. <view class="contentfooter-title">
  36. 森林瑜伽
  37. </view>
  38. <view class="contentfooter-subtitle">
  39. 夏日的森林,雨水充沛了山林,鲜花盛放,溪水潺潺。漫步于自然之中,感受清新的空气,放空心灵,沉醉于山雾之中,感受不同于城市的静谧与轻松
  40. </view>
  41. </view>
  42. </view>
  43. <view class="list">
  44. <view class="video">
  45. <!-- 这是视频 -->
  46. <video poster=""></video>
  47. </view>
  48. <view class="contentfooter">
  49. <view class="contentfooter-title">
  50. 森林瑜伽
  51. </view>
  52. <view class="contentfooter-subtitle">
  53. 夏日的森林,雨水充沛了山林,鲜花盛放,溪水潺潺。漫步于自然之中,感受清新的空气,放空心灵,沉醉于山雾之中,感受不同于城市的静谧与轻松
  54. </view>
  55. </view>
  56. </view>
  57. </view>
  58. </template>
  59. <script>
  60. export default {
  61. data() {
  62. return {
  63. swiper: [],
  64. }
  65. },
  66. onLoad() {
  67. this.init()
  68. },
  69. methods: {
  70. init(){
  71. let phone=uni.getStorageSync("phone")
  72. let code=uni.getStorageSync("code")
  73. uni.$u.http.post('/api/config/list',{phone,code},{
  74. custom: {
  75. auth: true
  76. }
  77. }).then((res) => {
  78. console.log(res)
  79. this.swiper=res[9].value
  80. uni.setStorageSync("data",res)
  81. }).catch((err) => {
  82. console.log( err)
  83. })
  84. }
  85. }
  86. }
  87. </script>
  88. <style lang="less">
  89. page{
  90. font-family: PingFang-SC-Heavy, PingFang-SC;
  91. background: #ffffff;
  92. }
  93. .swiper{
  94. height: 100vh;
  95. // width: 100%;
  96. position: relative;
  97. }
  98. .banner{
  99. width: 100%;
  100. position: absolute;
  101. left: 0;top: 0;
  102. // background-color: rgba(0,0,0,.5);
  103. height: 100vh;
  104. text-align: center;
  105. .logo{
  106. // text-align: center;
  107. padding-top:160rpx;
  108. image{
  109. width: 114rpx;
  110. }
  111. }
  112. .bannertitle{
  113. font-size: 64rpx;
  114. // text-align: center;
  115. margin: 138rpx 0 37rpx;
  116. color: #FFFFFF;
  117. }
  118. .subtitle{
  119. font-size: 44rpx;
  120. color: #FFFFFF;
  121. }
  122. }
  123. .contentTops{
  124. position: relative;
  125. }
  126. .contentTop{
  127. position: absolute;
  128. top: -48rpx;
  129. right: 0;
  130. width: 93%;
  131. display: flex;
  132. align-items: center;
  133. background-color: #FCFCFC;
  134. z-index: 9999 !important;
  135. padding: 56rpx 30rpx 38rpx;
  136. border-radius: 0px 56rpx 0px 0px;
  137. box-shadow: 0px 8rpx 14rpx 0px rgba(0, 21, 3, 0.05);
  138. .iconl{
  139. border-radius: 50%;
  140. width: 48rpx;
  141. height: 48rpx;
  142. background: linear-gradient(140deg, #2F8F49 0%, rgba(119, 204, 168, 0) 100%);
  143. opacity: 0.3;
  144. margin-top: -24rpx;
  145. margin-right: -10rpx;
  146. }
  147. .contentTop-title{
  148. font-size: 32rpx;
  149. font-weight: 800;
  150. color: #333333;
  151. margin: 0 20rpx 0 -26rpx;
  152. }
  153. .iconr{
  154. image{
  155. width: 32rpx;
  156. }
  157. }
  158. }
  159. .list{
  160. background-color: #FCFCFC;
  161. margin-top: 92rpx;
  162. width: 100%;
  163. // margin-bottom: 40rpx;
  164. // background-color: #fff;
  165. border-radius:0px 0px 16rpx 100rpx;;
  166. box-shadow: 0px 8rpx 14rpx 0px rgba(0, 21, 3, 0.08);
  167. .video{
  168. margin: 0 30rpx;
  169. height: 410rpx;
  170. // background-color: skyblue;
  171. video{
  172. width: 100%;
  173. height: 100%;
  174. }
  175. }
  176. .contentfooter{
  177. .contentfooter-title{
  178. font-size: 30rpx;
  179. font-family: PingFang-SC-Bold, PingFang-SC;
  180. font-weight: bold;
  181. color: #333333;
  182. text-shadow: 0px 8rpx 14rpx rgba(0, 21, 3, 0.05);
  183. margin: 40rpx 0rpx 24rpx 56rpx;
  184. }
  185. .contentfooter-subtitle{
  186. font-size: 26rpx;
  187. font-weight: 500;
  188. color: #333333;
  189. overflow: hidden;
  190. white-space: nowrap;
  191. text-overflow: ellipsis;
  192. padding: 0rpx 71rpx 40rpx 56rpx;
  193. }
  194. }
  195. }
  196. </style>