index.vue 890 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. <template>
  2. <view class="content">
  3. <top-search :isSearch="false" @searchClick="searchClick"></top-search>
  4. <my-swiper :datas="swiperDatas" />
  5. <view class="index-comp w-full padding-lr-sm padding-bottom">
  6. <view class="img-block margin-top"></view>
  7. <view class="img-block margin-top"></view>
  8. </view>
  9. </view>
  10. </template>
  11. <script>
  12. export default {
  13. data() {
  14. return {
  15. // 轮播区
  16. swiperDatas: [{
  17. img:'../../static/banner1.jpg'
  18. },{
  19. img:'../../static/banner2.png'
  20. }],
  21. }
  22. },
  23. onLoad() {
  24. },
  25. methods: {
  26. searchClick(){
  27. uni.navigateTo({
  28. url:'/pages/searchSchool/searchSchool'
  29. })
  30. }
  31. }
  32. }
  33. </script>
  34. <style scoped lang="scss">
  35. .content {
  36. width: 100%;
  37. .index-comp{
  38. box-sizing: border-box;
  39. .img-block{
  40. width: 100%;
  41. height: 400rpx;
  42. background-color: #EEE;
  43. border-radius: 20rpx;
  44. }
  45. }
  46. }
  47. </style>