|
@@ -24,8 +24,17 @@
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- 右下按钮 -->
|
|
<!-- 右下按钮 -->
|
|
- <Rbottom ref="RbottomRef" @cutKankan="cutKankan" @daoLanCut="daoLanCut" @stopPlay="stopPlay" :acList="partId"
|
|
|
|
- :playing="playing" :progressPart="progressPart" :clickBottomAc.sync="clickBottomAc" @openHot='openHot' />
|
|
|
|
|
|
+ <Rbottom
|
|
|
|
+ ref="RbottomRef"
|
|
|
|
+ @cutKankan="cutKankan"
|
|
|
|
+ @daoLanCut="daoLanCut"
|
|
|
|
+ @stopPlay="stopPlay"
|
|
|
|
+ :acList="partId"
|
|
|
|
+ :playing="playing"
|
|
|
|
+ :progressPart="progressPart"
|
|
|
|
+ :clickBottomAc.sync="clickBottomAc"
|
|
|
|
+ @openHot="openHot"
|
|
|
|
+ />
|
|
|
|
|
|
<!-- 左上名字和介绍 -->
|
|
<!-- 左上名字和介绍 -->
|
|
<div class="Ltitle" :class="{ open: title }">
|
|
<div class="Ltitle" :class="{ open: title }">
|
|
@@ -53,7 +62,7 @@ import Rbottom from "../components/Rbottom.vue";
|
|
export default {
|
|
export default {
|
|
name: "Home",
|
|
name: "Home",
|
|
//import引入的组件需要注入到对象中才能使用
|
|
//import引入的组件需要注入到对象中才能使用
|
|
- components: { Rbottom, Hot,Guide },
|
|
|
|
|
|
+ components: { Rbottom, Hot, Guide },
|
|
data() {
|
|
data() {
|
|
//这里存放数据
|
|
//这里存放数据
|
|
return {
|
|
return {
|
|
@@ -129,7 +138,6 @@ export default {
|
|
await player.selectPart(index);
|
|
await player.selectPart(index);
|
|
this.disable = false;
|
|
this.disable = false;
|
|
|
|
|
|
-
|
|
|
|
this.clickBottomAc = true;
|
|
this.clickBottomAc = true;
|
|
},
|
|
},
|
|
|
|
|
|
@@ -154,9 +162,8 @@ export default {
|
|
else if (ind === 4) this.kankan.Camera.floorplan();
|
|
else if (ind === 4) this.kankan.Camera.floorplan();
|
|
},
|
|
},
|
|
|
|
|
|
-
|
|
|
|
- openHot(data){
|
|
|
|
- this.openHotFu(data)
|
|
|
|
|
|
+ openHot(data) {
|
|
|
|
+ this.openHotFu(data);
|
|
},
|
|
},
|
|
// 封装点击热点的函数
|
|
// 封装点击热点的函数
|
|
openHotFu(data) {
|
|
openHotFu(data) {
|
|
@@ -205,11 +212,10 @@ export default {
|
|
|
|
|
|
// 聚焦当前点击的热点
|
|
// 聚焦当前点击的热点
|
|
window.TagView.focus(data.sid);
|
|
window.TagView.focus(data.sid);
|
|
- }
|
|
|
|
-
|
|
|
|
|
|
+ },
|
|
},
|
|
},
|
|
//生命周期 - 创建完成(可以访问当前this实例)
|
|
//生命周期 - 创建完成(可以访问当前this实例)
|
|
- created() { },
|
|
|
|
|
|
+ created() {},
|
|
//生命周期 - 挂载完成(可以访问DOM元素)
|
|
//生命周期 - 挂载完成(可以访问DOM元素)
|
|
mounted() {
|
|
mounted() {
|
|
let num = this.$route.params.id;
|
|
let num = this.$route.params.id;
|
|
@@ -273,7 +279,7 @@ export default {
|
|
|
|
|
|
// 有关球幕视频控制背景音乐
|
|
// 有关球幕视频控制背景音乐
|
|
kankan.Scene.on("panorama.videorenderer.startvideo", () => {
|
|
kankan.Scene.on("panorama.videorenderer.startvideo", () => {
|
|
- // 点击热点的时候当前背景音乐的播放状态
|
|
|
|
|
|
+ // 进入球幕视频
|
|
let dom = document.querySelector("#bacMusic");
|
|
let dom = document.querySelector("#bacMusic");
|
|
window.bacMusic = !dom.paused;
|
|
window.bacMusic = !dom.paused;
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
@@ -282,7 +288,7 @@ export default {
|
|
// 暂停背景音乐
|
|
// 暂停背景音乐
|
|
});
|
|
});
|
|
kankan.Scene.on("panorama.videorenderer.resumerender", () => {
|
|
kankan.Scene.on("panorama.videorenderer.resumerender", () => {
|
|
- // 点击热点的时候当前背景音乐的播放状态
|
|
|
|
|
|
+ // 进入球幕视频
|
|
let dom = document.querySelector("#bacMusic");
|
|
let dom = document.querySelector("#bacMusic");
|
|
window.bacMusic = !dom.paused;
|
|
window.bacMusic = !dom.paused;
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
@@ -291,6 +297,7 @@ export default {
|
|
// 暂停背景音乐
|
|
// 暂停背景音乐
|
|
});
|
|
});
|
|
kankan.Scene.on("panorama.videorenderer.suspendrender", () => {
|
|
kankan.Scene.on("panorama.videorenderer.suspendrender", () => {
|
|
|
|
+ // 退出球幕视频
|
|
if (window.bacMusic) {
|
|
if (window.bacMusic) {
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
this.$refs.RbottomRef.opMusic(true);
|
|
this.$refs.RbottomRef.opMusic(true);
|
|
@@ -308,7 +315,7 @@ export default {
|
|
|
|
|
|
// 全部热点数据
|
|
// 全部热点数据
|
|
kankan.store.on("tags", (tags) => {
|
|
kankan.store.on("tags", (tags) => {
|
|
- this.$refs.RbottomRef.getHotListToFather(tags.tags)
|
|
|
|
|
|
+ this.$refs.RbottomRef.getHotListToFather(tags.tags);
|
|
this.baseHotData = tags.tags.reverse();
|
|
this.baseHotData = tags.tags.reverse();
|
|
});
|
|
});
|
|
|
|
|
|
@@ -322,15 +329,16 @@ export default {
|
|
|
|
|
|
let title = data.title.split("&")[0];
|
|
let title = data.title.split("&")[0];
|
|
|
|
|
|
- return `<span class="tag-icon animate" title=${title} style="${flag ? "" : "display: none;"
|
|
|
|
- };background-image:url({{icon}})"></span><div class="tag-body"></div>`;
|
|
|
|
|
|
+ return `<span class="tag-icon animate" title=${title} style="${
|
|
|
|
+ flag ? "" : "display: none;"
|
|
|
|
+ };background-image:url({{icon}})"></span><div class="tag-body"></div>`;
|
|
},
|
|
},
|
|
})
|
|
})
|
|
.then((TagView) => {
|
|
.then((TagView) => {
|
|
- window.TagView = TagView
|
|
|
|
|
|
+ window.TagView = TagView;
|
|
// 监听手动点击事件
|
|
// 监听手动点击事件
|
|
TagView.on("click", (e) => {
|
|
TagView.on("click", (e) => {
|
|
- this.openHotFu(e.data)
|
|
|
|
|
|
+ this.openHotFu(e.data);
|
|
});
|
|
});
|
|
});
|
|
});
|
|
|
|
|
|
@@ -364,13 +372,13 @@ export default {
|
|
});
|
|
});
|
|
this.kankan = kankan;
|
|
this.kankan = kankan;
|
|
},
|
|
},
|
|
- beforeCreate() { }, //生命周期 - 创建之前
|
|
|
|
- beforeMount() { }, //生命周期 - 挂载之前
|
|
|
|
- beforeUpdate() { }, //生命周期 - 更新之前
|
|
|
|
- updated() { }, //生命周期 - 更新之后
|
|
|
|
- beforeDestroy() { }, //生命周期 - 销毁之前
|
|
|
|
- destroyed() { }, //生命周期 - 销毁完成
|
|
|
|
- activated() { }, //如果页面有keep-alive缓存功能,这个函数会触发
|
|
|
|
|
|
+ beforeCreate() {}, //生命周期 - 创建之前
|
|
|
|
+ beforeMount() {}, //生命周期 - 挂载之前
|
|
|
|
+ beforeUpdate() {}, //生命周期 - 更新之前
|
|
|
|
+ updated() {}, //生命周期 - 更新之后
|
|
|
|
+ beforeDestroy() {}, //生命周期 - 销毁之前
|
|
|
|
+ destroyed() {}, //生命周期 - 销毁完成
|
|
|
|
+ activated() {}, //如果页面有keep-alive缓存功能,这个函数会触发
|
|
};
|
|
};
|
|
</script>
|
|
</script>
|
|
<style lang='less' scoped>
|
|
<style lang='less' scoped>
|
|
@@ -519,7 +527,7 @@ export default {
|
|
height: 100%;
|
|
height: 100%;
|
|
padding: 6px 0 0px 10px;
|
|
padding: 6px 0 0px 10px;
|
|
|
|
|
|
- &>img {
|
|
|
|
|
|
+ & > img {
|
|
width: 8px;
|
|
width: 8px;
|
|
height: 13px;
|
|
height: 13px;
|
|
}
|
|
}
|