Files
tk-mini-program/pages/Home/Home.vue
pengxiaolong 838cfd9986 消息
2025-05-14 16:09:14 +08:00

92 lines
1.8 KiB
Vue

<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">
<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 {
data() {
return {};
},
onLoad() {
// this.requestSomething();
},
methods: {
// requestSomething() {
// wx.request({
// url: "http://192.168.0.218:8086/user/login", // 请求的 URL
// method: "POST", // 请求方式
// success: (res) => {
// console.log("请求成功", res.data); // 处理成功的响应
// },
// fail: (err) => {
// console.error("请求失败", err); // 处理失败的响应
// },
// });
// },
},
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: 300rpx;
left: 0;
width: 100%;
height: 1300rpx;
}
</style>