<template>
  <view class="page">
    <image src="../../static/HomeBackground.png" class="HomeBackground"></image>
  </view>
  <view class="top-navigation-container">
    <top-navigation></top-navigation>
  </view>
  <view class="Advertisement" @click="goAdvertisement">
    <advertisement></advertisement>
  </view>
  <view class="contentList">
    <contentList></contentList>
  </view>
  <view class="tabBar">
    <tabBar></tabBar>
  </view>
</template>

<script>
import topNavigation from "../../components/topNavigation/topNavigation";
import Advertisement from "../../components/Advertisement/Advertisement";
import contentList from "../../components/contentList/contentList";
import tabBar from "../../components/tabBar/tabBar";
export default {
  inject: ['$global'],
  data() {
    return {};
  },
  onLoad() {
    // this.requestSomething();
  },
  methods: {
    goAdvertisement(){
      this.$global.lastPage = getCurrentPages().router;
      uni.navigateTo({ url: '/pages/login/login' })
    }
  },
  components: {
    topNavigation,
    Advertisement,
    contentList,
    tabBar,
  },
};
</script>

<style scoped>
.page {
  position: relative;
  width: 750rpx;
  height: 1620rpx;
}

.HomeBackground {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}
.top-navigation-container {
  position: fixed;
  top: 160rpx;
  left: 0;
  width: 100%;
  height: 114.5rpx;
}
.Advertisement {
  position: fixed;
  top: 300rpx;
  left: 0;
  width: 100%;
  height: 100rpx;
  z-index: 100;
}
.contentList {
  position: fixed;
  top: 400rpx;
  left: 0;
  width: 100%;
  height: 1300rpx;
}
</style>
