index.vue 956 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  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. dinnerId:''
  22. }
  23. },
  24. onLoad() {
  25. this.dinnerId = uni.getStorageSync('dinnerId');
  26. },
  27. methods: {
  28. searchClick(){
  29. uni.navigateTo({
  30. url:'/pages/searchSchool/searchSchool'
  31. })
  32. }
  33. }
  34. }
  35. </script>
  36. <style scoped lang="scss">
  37. .content {
  38. width: 100%;
  39. .index-comp{
  40. box-sizing: border-box;
  41. .img-block{
  42. width: 100%;
  43. height: 400rpx;
  44. background-color: #EEE;
  45. border-radius: 20rpx;
  46. }
  47. }
  48. }
  49. </style>