2024-12-03 09:34:24 +08:00
|
|
|
<template>
|
|
|
|
<view>
|
|
|
|
<el-container class="pc-container">
|
|
|
|
<view class="pc-header">
|
2025-01-06 00:54:54 +08:00
|
|
|
<Header :isLogin="isLogin" />
|
2024-12-03 09:34:24 +08:00
|
|
|
</view>
|
|
|
|
<view style="width: 100%;height: 100rpx;"></view>
|
|
|
|
<view class="pc-main">
|
2025-01-06 00:54:54 +08:00
|
|
|
<component ref="pageRef" :is="refs[current]" />
|
2024-12-03 09:34:24 +08:00
|
|
|
</view>
|
|
|
|
</el-container>
|
2025-01-06 00:54:54 +08:00
|
|
|
<Loading :show="loading" />
|
|
|
|
<u-back-top class="back-top" :scrollTop="scrollTop" zIndex="100" :iconStyle="{ color: '#fff', fontSize: '50rpx' }"
|
|
|
|
:customStyle="{background: 'linear-gradient(180deg, #96fe11 0%, #f0fdbf 100%)',
|
|
|
|
filter: 'opacity(0.96)', width: '120rpx', height: '120rpx'}" />
|
2024-12-03 09:34:24 +08:00
|
|
|
</view>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
import Header from './components/header.vue';
|
2025-01-06 00:54:54 +08:00
|
|
|
import Home from '@/pages/pc_web/home/home.vue';
|
2024-12-03 09:34:24 +08:00
|
|
|
export default {
|
|
|
|
components:{
|
2025-01-06 00:54:54 +08:00
|
|
|
Header, Home
|
2024-12-03 09:34:24 +08:00
|
|
|
},
|
|
|
|
data(){
|
|
|
|
return{
|
2025-01-06 00:54:54 +08:00
|
|
|
// 当前页码下标
|
|
|
|
current: uni.getStorageSync('pc_current')||0,
|
|
|
|
// refs组件列表
|
|
|
|
refs: ['home'],
|
|
|
|
// 加载
|
|
|
|
loading: false,
|
|
|
|
// 滚动顶部
|
|
|
|
scrollTop: 0,
|
2024-12-03 09:34:24 +08:00
|
|
|
}
|
|
|
|
},
|
2025-01-06 00:54:54 +08:00
|
|
|
computed: {
|
|
|
|
// 登录状态
|
|
|
|
isLogin(){
|
|
|
|
return this.$store.state.vuex_token;
|
|
|
|
}
|
|
|
|
},
|
|
|
|
onPageScroll(e) {
|
|
|
|
this.scrollTop = e.scrollTop;
|
|
|
|
},
|
2024-12-03 09:34:24 +08:00
|
|
|
onLoad() {
|
|
|
|
},
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style scoped lang="scss">
|
|
|
|
.pc-container{
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
}
|
|
|
|
.pc-header{
|
|
|
|
width: 100%;
|
2025-01-06 00:54:54 +08:00
|
|
|
height: 120rpx;
|
|
|
|
z-index: 90;
|
2024-12-03 09:34:24 +08:00
|
|
|
box-shadow: 0 5rpx 10rpx 0 #dcdae4;
|
|
|
|
position: fixed;
|
|
|
|
}
|
|
|
|
.pc-main{
|
|
|
|
background-color: #edecf1;
|
2025-01-06 00:54:54 +08:00
|
|
|
}
|
|
|
|
.back-top{
|
|
|
|
cursor: pointer;
|
|
|
|
&:hover{
|
|
|
|
box-shadow: 0 0 20rpx #d8fc92;
|
2024-12-03 09:34:24 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
</style>
|