Commit 2dd5ee3b authored by 王炽's avatar 王炽

6666

parents 177258bf a76179a2
......@@ -90,6 +90,8 @@ async function tryAssist() {
}
async function initComponent() {
await tryAssist()
await updateInvitationInfo()
updateShareData({
......@@ -105,8 +107,6 @@ async function initComponent() {
prizeImageUrl: firstPrize.prizeImageUrl,
})
}
await tryAssist()
}
watch(() => props.isLogin, async (newVal) => {
......
......@@ -55,7 +55,7 @@
pageName: '品牌故事-首屏页面',
buttonName: '腰部品牌Video'
}" :poster="video1Channel.posterUrl?.indexOf('http') === 0 ? video1Channel.posterUrl : $baseUrl + video1Channel.posterUrl"
object-fit="cover" @loadedmetadata="onVideoLoadedMeta" @play="onVideo1Play"></video>
object-fit="cover" @loadedmetadata="onVideoLoadedMeta" @play="onVideo1Play" @ended="onVideo1Ended"></video>
<image v-else :data-log="{
xcxClick: '品牌故事-次屏页面点击',
pageName: '品牌故事-首屏页面',
......@@ -69,7 +69,7 @@
:src="video1Channel.posterUrl?.indexOf('http') === 0 ? video1Channel.posterUrl : $baseUrl + video1Channel.posterUrl">
</image>
<view class="videoposterboxtitle">{{ video1Channel.title || "" }}</view>
<view class="videoposterboxtitle" v-if="showVideo1Title">{{ video1Channel.title || "" }}</view>
</view>
<view id="secondScreen" class="productcontai"
......@@ -161,7 +161,7 @@
:src="video2Channel.videoUrl?.indexOf('http') === 0 ? video2Channel.videoUrl : $baseUrl + video2Channel.videoUrl"
:autoplay="false"
:poster="video2Channel.posterUrl?.indexOf('http') === 0 ? video2Channel.posterUrl : $baseUrl + video2Channel.posterUrl"
object-fit="cover" @loadedmetadata="onVideoLoadedMeta" @play="onVideo2Play"></video>
object-fit="cover" @loadedmetadata="onVideoLoadedMeta" @play="onVideo2Play" @ended="onVideo2Ended"></video>
<image v-else class="videoposter" :data-comlog="{
xcxComponentClick: 'true',
pageName: '品牌故事页',
......@@ -170,7 +170,7 @@
}" @tap="openChannel(video2Channel, $event)"
:src="video2Channel.posterUrl?.indexOf('http') === 0 ? video2Channel.posterUrl : $baseUrl + video2Channel.posterUrl">
</image>
<view class="videoposterboxtitle">{{ video2Channel.title || "" }}</view>
<view class="videoposterboxtitle" v-if="showVideo2Title">{{ video2Channel.title || "" }}</view>
</view>
<view id="thirdScreen" class="ipbox" v-if="erqiPeizhi.appId1 && erqiPeizhi.appId2"
:style="{ background: `url(${$baseUrl}brandpage/hexiaofeiBg.png) no-repeat center/contain` }">
......@@ -262,7 +262,7 @@
componentName: '飞鹤ESG',
componentContent: infoItem.desc
}" @tap="jumpLink(infoItem.link, infoItem.videoUrl, $event)">
<image class="infoimg"
<image class="infoimg imgRaduis"
:src="infoItem.bgUrl?.indexOf('http') === 0 ? infoItem.bgUrl : $baseUrl + infoItem.bgUrl">
</image>
<view class="infotitle">{{ infoItem.desc }}</view>
......@@ -401,6 +401,8 @@ export default {
currentPlayingVideo: null, // 当前正在播放的视频标识
videoContexts: {}, // 存储视频上下文,使用id作为key
ipExStr: ['鹤小飞商品', '鹤小飞商品', '鹤小飞', '鹤小飞'],
showVideo1Title: true, // 控制视频1标题显示
showVideo2Title: true, // 控制视频2标题显示
}
},
mounted() {
......@@ -777,6 +779,7 @@ export default {
componentContent: this.video1Channel.title || ''
});
console.log('视频1开始播放');
this.showVideo1Title = false; // 隐藏标题
this.handleVideoPlay('brandVideo1');
},
// 视频2播放事件
......@@ -800,8 +803,29 @@ export default {
componentContent: this.video2Channel.title || ''
});
console.log('视频2开始播放');
this.showVideo2Title = false; // 隐藏标题
this.handleVideoPlay('brandVideo2');
},
// 视频1播放结束事件
onVideo1Ended() {
console.log('视频1播放结束');
this.showVideo1Title = true; // 显示标题
// 恢复展示海报(自动生效,因为video组件播放结束后会显示poster)
if (this.currentPlayingVideo === 'brandVideo1') {
this.currentPlayingVideo = null;
}
},
// 视频2播放结束事件
onVideo2Ended() {
console.log('视频2播放结束');
this.showVideo2Title = true; // 显示标题
// 恢复展示海报(自动生效,因为video组件播放结束后会显示poster)
if (this.currentPlayingVideo === 'brandVideo2') {
this.currentPlayingVideo = null;
}
},
// 处理视频播放(互斥逻辑)
handleVideoPlay(videoId) {
......@@ -1319,6 +1343,10 @@ export default {
height: 400rpx;
}
.imgRaduis{
border-radius: 24rpx 24rpx 0 0;
}
.infotitle {
color: @color-gold-main;
font-size: 32rpx;
......
<template>
<view class="home-container" @scroll="onPageScroll">
<!-- 可拖拽悬浮图片 -->
<view class="floating-image-container" v-if="floatIcon.imageUrl"
<view class="floating-image-container" v-if="floatIcon.imageUrl && !isAnyPopupVisible"
:style="{ left: floatIconPosition.left + 'px', top: floatIconPosition.top + 'px' }"
@touchstart="onTouchStart" @touchmove="onTouchMove" @touchend="onTouchEnd" @tap="onfloatIconClick">
<image class="floating-image"
......@@ -492,6 +492,9 @@ export default {
channelTabListMianTitle: '',
popupImageUrl: '',
popupImageObj: {},
// 新增变量用于跟踪弹窗状态
isNormalPopupVisible: false,
isImagePopupVisible: false
}
},
components: {
......@@ -501,7 +504,18 @@ export default {
homeStore() {
return useHomeStore();
},
// 检查是否有任何弹窗可见
isAnyPopupVisible() {
// 视频弹窗是否显示
if (this.showVideo) return true;
// 注册弹窗是否显示
if (this.showRegisterLayer) return true;
// 普通弹窗是否显示
if (this.isNormalPopupVisible) return true;
// 图片弹窗是否显示
if (this.isImagePopupVisible) return true;
return false;
}
},
props: {
scrollTop: {
......@@ -571,7 +585,7 @@ export default {
this.childrenInfoList = data.childrenInfoList || [];
this.bottomLinkList = data.bottomLinkList;
this.qrInfoList = data.qrInfoList || [];
this.toolList = data.toolList;
this.toolList = data.toolList || [];
this.expertTeam = data.expertTeam;
this.vipCardList = data.vipCardList;
this.voiceStory = data.voiceStory;
......@@ -801,6 +815,8 @@ export default {
}
this.popupIndex = _index;
this.$refs.popup.open(this.popType);
// 设置普通弹窗为可见状态
this.isNormalPopupVisible = true;
},
showPopup1(_index, type) {
md.sensorLogTake({
......@@ -824,9 +840,13 @@ export default {
}
this.popupIndex = _index;
this.$refs.popup.open(this.popType);
// 设置普通弹窗为可见状态
this.isNormalPopupVisible = true;
},
closePop() {
this.$refs.popup.close();
// 设置普通弹窗为不可见状态
this.isNormalPopupVisible = false;
},
goSearchHandler(e) {
md.sensorLog(e);
......@@ -1044,6 +1064,8 @@ export default {
},
closeImagePopup() {
this.$refs.imagePopup.close();
// 设置图片弹窗为不可见状态
this.isImagePopupVisible = false;
},
imagePopupJump() {
......@@ -1066,9 +1088,13 @@ export default {
popName: this.popupImageObj.title || "北纬47°鲜活溯源之旅"
});
this.$refs.imagePopup.open('center');
// 设置图片弹窗为可见状态
this.isImagePopupVisible = true;
},
closePop1() {
this.$refs.imagePopup.close();
// 设置图片弹窗为不可见状态
this.isImagePopupVisible = false;
},
// 重置弹窗状态(可在需要时调用)
......@@ -1171,6 +1197,7 @@ export default {
position: fixed;
width: 75px;
height: 75px;
z-index: -1;
z-index: 999;
touch-action: none; // 禁止默认触摸行为
border-radius: 50%;
......
......@@ -179,7 +179,7 @@
<view class="privilege-container">
<!-- 第一行 -->
<view class="privilege-header">
<text class="quanyi-title" :style="{ color: getColor('quanyiTitle')[itemIndex].titleColor }">LV{{
<text class="quanyi-title" :style="{ color: getColor('quanyiTitle')[itemIndex].titleColor }" @click="testGoto195">LV{{
(Number(itemIndex) + 1) }}专享权益</text>
<text class="title-text" :style="{ color: getColor('quanyiTitle')[itemIndex].quanyiNumColor }">当前可享<text
class="highlight"
......@@ -550,6 +550,13 @@ const onProgressBarError = (e) => {
// 可以设置默认样式或显示错误提示
}
function testGoto195() {
jump({
type: JumpType.INNER,
url: '/activities/1015/home'
})
}
const orderUpgrade = ref(false);
// const maxVal = ref([]);
const integralData = ref({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment