1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
<template>
<view class="contents">
<!-- 视频区 -->
<view class="banner"></view>
<login></login>
<tabs @skipComponent = "skip"></tabs>
<!-- 聊天 -->
<component :is="currentTabComponent" :specialUrl="special"></component>
<!-- 底部 -->
<view class="footer" v-show="currentTabComponent == 'chat'">
<foot @specialShow="specialShow"></foot>
</view>
</view>
</template>
<script>
import login from "@/components/login/login.vue"
import tabs from "@/components/tabs/tabs.vue"
import foot from "@/components/footer/footer.vue"
import chat from "@/components/chat/chat.vue"
import sinatv from "@/components/tabs/sinaTv/sinaTv.vue"
import courseware from "@/components/tabs/courseware/courseware.vue"
export default {
components: {
foot,chat,login,tabs,sinatv,courseware
},
data() {
return {
loading: true,
value:'',
currentTabComponent:'chat',
special:""
}
},
onLoad() {
},
onshow() {
},
methods: {
skip(value){
this.currentTabComponent = value
},
specialShow(url){
this.special = url
let _this = this
let timer = setTimeout(() => {
_this.special = ''
},1000)
},
}
}
</script>
<style lang="scss">
.contents {
width: 750rpx;
display: flex;
flex-direction: column;
.banner {
width: 100%;
height: 420rpx;
background-image: url("../../static/images/banner.png");
background-repeat: no-repeat;
background-size: contain;
}
.title {
height: 72rpx;
background-color: #5E6DF0;
color: white;
display: flex;
align-items: center;
padding-left: 20rpx;
}
.footer {
height: 88rpx;
position: fixed;
left: 0;
right: 0;
bottom: 0;
display: flex;
background-color: white;
box-shadow: 0 -2rpx 30rpx #dadada;;
}
}
</style>