index.vue 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180
  1. <template>
  2. <view :style="{ minHeight: sys.windowHeight + 'px' }" :class="[$tm.vx.state().tmVuetify.black ? 'black' : ' ']">
  3. <tm-menubars title="" :shadow="0" :showback="false"></tm-menubars>
  4. <view class="C1b1b1b">
  5. <tm-search v-model="soso" color="white">
  6. <template #right>
  7. <view class="xiangji">
  8. <image src="/static/img/xiangji.png" mode="widthFix"></image>
  9. </view>
  10. </template>
  11. </tm-search>
  12. <view class="dingwei">
  13. <image style="vertical-align: middle;" src="/static/img/dingwei.png" mode="widthFix"></image>
  14. <text style="vertical-align: middle;" class="text-size-g">北京Beijing</text>
  15. </view>
  16. </view>
  17. <view class="zhuti mt-20">
  18. <tm-grid :grid="5" :list="list3" :icon-size="140" font-color="white"></tm-grid>
  19. <tm-sheet class="lunbo">
  20. <view class="py-10 text-size-g dianz">
  21. <image src="/static/img/6.png" mode="widthFix"></image>
  22. <text class="text-white">今日穿搭推荐</text>
  23. </view>
  24. <view class="mt-20 text-size-g dianz">
  25. <view class="text-white">西装夹克高级感穿搭 | 彰显</view>
  26. <view class="text-white">秋冬复古型男典范</view>
  27. </view>
  28. <view class="touxiang mt-20">
  29. <image src="/static/img/7.png" mode="widthFix"></image>
  30. <text class="text-white text-size-m">可樂crys</text>
  31. </view>
  32. <view class="shoucang mt-20">
  33. <image src="/static/img/8.png" mode="widthFix" style="margin-right: 15px;"></image>
  34. <image src="/static/img/9.png" mode="widthFix"></image>
  35. </view>
  36. </tm-sheet>
  37. </view>
  38. <!-- <tm-swiper :previmage="false" :noSwiping="true" width="400" :current="current" :margin="32" :autoplay="false" :list="list"></tm-swiper>
  39. <tm-button theme="white" size="m" @click="shang()">下一张</tm-button>
  40. <tm-button theme="white" size="m" @click="xia()">上一张</tm-button>
  41. <view class="bbb">
  42. <tm-swiper :notouch="true" :disable-touch="true" class="aaa" :current="current1" :autoplay="false" dot-model="rect" :indicator-dots="true" :list="list"></tm-swiper>
  43. </view>
  44. <tm-button theme="white" size="m" @click="shang()">下一张</tm-button>
  45. <tm-button theme="white" size="m" @click="xia()">上一张</tm-button> -->
  46. </view>
  47. </template>
  48. <script>
  49. import{myRequest} from '@/api/request.js'
  50. export default {
  51. data() {
  52. return {
  53. soso:'',
  54. list3:[
  55. {icon:'/static/img/1.png',text:'预约家政'},
  56. {icon:'/static/img/2.png',text:'预约服务'},
  57. {icon:'/static/img/3.png',text:'自助录入'},
  58. {icon:'/static/img/4.png',text:'鞋服洗护'},
  59. {icon:'/static/img/5.png',text:'闲置交换'},
  60. ],
  61. keyword: '',
  62. top: 60,
  63. sys: null,
  64. list:[
  65. 'https://picsum.photos/800?jv=34',
  66. 'https://picsum.photos/800?jv=74',
  67. 'https://picsum.photos/800?jv=3',
  68. 'https://picsum.photos/800?jv=5',
  69. 'https://picsum.photos/800?jv=74',
  70. 'https://picsum.photos/800?jv=3',
  71. 'https://picsum.photos/800?jv=5'
  72. ],
  73. current:0,
  74. current1:0
  75. };
  76. },
  77. onLoad() {
  78. // #ifdef MP
  79. this.top = uni.upx2px(150);
  80. // #endif
  81. },
  82. created() {
  83. setTimeout(function(){
  84. if(uni.getStorageSync("token")==""){
  85. uni.redirectTo({
  86. url:"/pages/login/index"
  87. })
  88. }
  89. },2000)
  90. this.sys = uni.getSystemInfoSync();
  91. },
  92. methods: {
  93. shang(){
  94. this.current=this.current+1;
  95. this.current1=this.current1+1
  96. },
  97. xia(){
  98. this.current=this.current-1;
  99. this.current1=this.current1-1
  100. }
  101. },
  102. }
  103. </script>
  104. <style lang="scss">
  105. /deep/ .tm-menubars .body{
  106. background-color: #1b1b1b !important;
  107. }
  108. /deep/ .aaa uni-image{
  109. width: 100px !important;
  110. height: 100px !important;
  111. }
  112. /deep/ .aaa uni-swiper-item{
  113. width: 100px !important;
  114. height: 100px !important;
  115. padding: 0 10px !important;
  116. }
  117. //
  118. .xiangji image{
  119. width: 30px;
  120. height: 22px;
  121. }
  122. .suosou image{
  123. width: 40px;
  124. }
  125. /deep/ .icon-search{
  126. font-size: 23px !important;
  127. color: #8E8E93 !important;
  128. }
  129. /deep/ .tm-search{
  130. width: 94%;
  131. margin: 0 auto;
  132. background-color: #414141 !important;
  133. border-radius: 10px;
  134. }
  135. /deep/ .tm-search .grey-darken-5{
  136. background-color: #414141 !important;
  137. }
  138. .dingwei{
  139. width: 92%;
  140. margin: 0 auto;
  141. margin-top: 20px;
  142. padding-bottom: 20px;
  143. }
  144. .dingwei image{
  145. width: 20px;
  146. margin-right: 10px;
  147. }
  148. /deep/ .tm-col{
  149. width: 20% !important;
  150. }
  151. .zhuti{
  152. padding: 10px;
  153. }
  154. /deep/ .lunbo{
  155. margin:0 !important;
  156. padding: 8px !important;
  157. margin-top: 20px !important;
  158. }
  159. .dianz image{
  160. width: 30px;
  161. vertical-align: middle;
  162. margin-right: 10px;
  163. }
  164. /deep/ .text-size-s span,/deep/ .text-size-g{
  165. font-size: 15px;
  166. }
  167. .touxiang image{
  168. width: 35px;
  169. margin-right: 10px;
  170. vertical-align: middle;
  171. }
  172. .shoucang image{
  173. width: 45px;
  174. }
  175. </style>