Commit 51549197 authored by spc's avatar spc

fixed home and brand

parent c57e08d0
This diff is collapsed.
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
</view> </view>
</view> </view>
</view> </view>
<view class="videoposterbox"> <view class="videoposterbox" v-if="video1Channel.videoUrl">
<video v-if="video1Channel.videoUrl" ref="brandVideo1Ref" id="brandVideo1" class="videoposter" <video v-if="video1Channel.videoUrl" ref="brandVideo1Ref" id="brandVideo1" class="videoposter"
:src="$baseUrl + video1Channel.videoUrl" :autoplay="false" :data-log="{ :src="$baseUrl + video1Channel.videoUrl" :autoplay="false" :data-log="{
xcxClick: '品牌故事-次屏页面点击', xcxClick: '品牌故事-次屏页面点击',
...@@ -61,8 +61,11 @@ ...@@ -61,8 +61,11 @@
}" @tap="openChannel(video1Channel, $event)" class="videoposter" :src="$baseUrl + video1Channel.posterUrl"> }" @tap="openChannel(video1Channel, $event)" class="videoposter" :src="$baseUrl + video1Channel.posterUrl">
</image> </image>
<view class="videoposterboxtitle">{{ video1Channel.title || "" }}</view>
</view> </view>
<view id="secondScreen" class="productcontai"> <view id="secondScreen" class="productcontai"
v-if="productTabList.length > 0 && productInfoList.length > 0">
<text class="maintitle">{{ erqiPeizhi.title1 }}</text> <text class="maintitle">{{ erqiPeizhi.title1 }}</text>
<scroll-view class="listbox" scroll-x="true" show-scrollbar="false" <scroll-view class="listbox" scroll-x="true" show-scrollbar="false"
:scroll-into-view="'tab-' + channelTabIndex" :scroll-with-animation="true"> :scroll-into-view="'tab-' + channelTabIndex" :scroll-with-animation="true">
...@@ -140,7 +143,7 @@ ...@@ -140,7 +143,7 @@
</view> </view>
<view class="videoposterbox"> <view class="videoposterbox" v-if="video2Channel.videoUrl">
<video v-if="video2Channel.videoUrl" ref="brandVideo2Ref" id="brandVideo2" class="videoposter" <video v-if="video2Channel.videoUrl" ref="brandVideo2Ref" id="brandVideo2" class="videoposter"
:src="$baseUrl + video2Channel.videoUrl" :autoplay="false" :src="$baseUrl + video2Channel.videoUrl" :autoplay="false"
:poster="video2Channel.posterUrl ? $baseUrl + video2Channel.posterUrl : ''" object-fit="cover" :poster="video2Channel.posterUrl ? $baseUrl + video2Channel.posterUrl : ''" object-fit="cover"
...@@ -152,15 +155,18 @@ ...@@ -152,15 +155,18 @@
componentContent: video2Channel.title || '' componentContent: video2Channel.title || ''
}" @tap="openChannel(video2Channel, $event)" :src="$baseUrl + video2Channel.posterUrl"> }" @tap="openChannel(video2Channel, $event)" :src="$baseUrl + video2Channel.posterUrl">
</image> </image>
<view class="videoposterboxtitle">{{ video2Channel.title || "" }}</view>
</view> </view>
<view id="thirdScreen" class="ipbox" <view id="thirdScreen" class="ipbox" v-if="erqiPeizhi.appId1 && erqiPeizhi.appId2"
:style="{ background: `url(${$baseUrl}brandpage/hexiaofeiBg.png) no-repeat center/contain` }"> :style="{ background: `url(${$baseUrl}brandpage/hexiaofeiBg.png) no-repeat center/contain` }">
<!-- <store-product appid="wx1ad0903b95889ea1" product-id="10000239570622" custom-content="true"> --> <!-- <store-product appid="wx1ad0903b95889ea1" product-id="10000239570622" custom-content="true"> -->
<image :data-log="{ <image :data-log="{
xcxClick: '品牌故事-三屏页面点击', xcxClick: '品牌故事-三屏页面点击',
pageName: '品牌故事-三屏页面', pageName: '品牌故事-三屏页面',
buttonName: `全家形象` buttonName: `全家形象`
}" class="iphexiaofei" :src="erqiPeizhi.iphexiaofeiUrl"></image> }" class="iphexiaofei" @tap="jumpLink(erqiPeizhi.link, erqiPeizhi.videoUrl, $event)"
:src="erqiPeizhi.iphexiaofeiUrl">
</image>
<!-- </store-product> --> <!-- </store-product> -->
<view class="ipcard"> <view class="ipcard">
<view class="title"> <view class="title">
...@@ -172,7 +178,8 @@ ...@@ -172,7 +178,8 @@
</view> </view>
<view class="ipflex"> <view class="ipflex">
<view class="ipbg ip1" id="ip1" @tap="ipTapEvent(1, $event)"> <view class="ipbg ip1" id="ip1" @tap="ipTapEvent(1, $event)">
<store-product appid="wx1ad0903b95889ea1" product-id="10000239570622" custom-content="true"> <store-product appid={erqiPeizhi.appId1} product-id={erqiPeizhi.productId1}
custom-content="true">
<image :data-log="{ <image :data-log="{
xcxClick: '品牌故事-三屏页面点击', xcxClick: '品牌故事-三屏页面点击',
pageName: '品牌故事-三屏页面', pageName: '品牌故事-三屏页面',
...@@ -184,7 +191,7 @@ ...@@ -184,7 +191,7 @@
<view class="ipright"> <view class="ipright">
<view class="ipbg ip2" id="ip2" @tap="ipTapEvent(2, $event)"> <view class="ipbg ip2" id="ip2" @tap="ipTapEvent(2, $event)">
<store-product appid="wx1ad0903b95889ea1" product-id="10000239356280" <store-product appid={erqiPeizhi.appId2} product-id={erqiPeizhi.productId2}
custom-content="true"> custom-content="true">
<image :data-log="{ <image :data-log="{
xcxClick: '品牌故事-三屏页面点击', xcxClick: '品牌故事-三屏页面点击',
...@@ -224,7 +231,8 @@ ...@@ -224,7 +231,8 @@
<!-- <text class="subtitle">关注祖国下一代的营养、教育和陪伴</text> --> <!-- <text class="subtitle">关注祖国下一代的营养、教育和陪伴</text> -->
<view class="channelscroll"> <view class="channelscroll">
<view class="box"> <view class="box">
<view class="infobox" :key="index" v-for="(infoItem, index) in esgInfoList" :id="'esg' + (index + 1)" <view class="infobox" :key="index" v-for="(infoItem, index) in esgInfoList"
:id="'esg' + (index + 1)"
:style="{ background: `url(${$baseUrl}brandpage/esgItemBg.png) no-repeat center/505rpx 638rpx` }" :style="{ background: `url(${$baseUrl}brandpage/esgItemBg.png) no-repeat center/505rpx 638rpx` }"
:data-log="{ :data-log="{
xcxClick: `品牌故事-三屏页面点击`, xcxClick: `品牌故事-三屏页面点击`,
...@@ -372,7 +380,7 @@ export default { ...@@ -372,7 +380,7 @@ export default {
video2Channel: {}, video2Channel: {},
currentPlayingVideo: null, // 当前正在播放的视频标识 currentPlayingVideo: null, // 当前正在播放的视频标识
videoContexts: {}, // 存储视频上下文,使用id作为key videoContexts: {}, // 存储视频上下文,使用id作为key
ipExStr:['鹤小飞商品', '鹤小飞商品', '鹤小飞', '鹤小飞'], ipExStr: ['鹤小飞商品', '鹤小飞商品', '鹤小飞', '鹤小飞'],
} }
}, },
mounted() { mounted() {
...@@ -534,10 +542,10 @@ export default { ...@@ -534,10 +542,10 @@ export default {
md.sensorComponentLogTake(evt.currentTarget.dataset.comlog); md.sensorComponentLogTake(evt.currentTarget.dataset.comlog);
} }
} }
const { productId, skuId, contentImg, contentImgLen, shareTitle, shareImg, title } = item; const { productId, skuId, contentImg, contentImgLen, shareTitle, shareImg, title, link } = item;
const tabName = this.productTabList[this.channelTabIndex]; const tabName = this.productTabList[this.channelTabIndex];
if(productId && skuId){ if (productId && skuId) {
const url = `subPackages/shopMainProcess/product/index?productId=${productId}&skuId=${skuId}`; const url = `subPackages/shopMainProcess/product/index?productId=${productId}&skuId=${skuId}`;
const type = JumpType.MINI; const type = JumpType.MINI;
const extra = { const extra = {
...@@ -550,12 +558,14 @@ export default { ...@@ -550,12 +558,14 @@ export default {
jump({ jump({
type: type, type: type,
url: url, url: url,
extra:extra extra: extra
})
}else{
uni.navigateTo({
url: "/pages/product/product?productId=" + productId + "&skuId=" + skuId + "&contentImg=" + contentImg + "&contentImgLen=" + contentImgLen + "&shareTitle=" + shareTitle + "&shareImg=" + shareImg + "&tabName=" + tabName + "&title=" + title
}) })
} else {
jump(link)
// console.warn("/pages/product/product?productId=" + productId + "&skuId=" + skuId + "&contentImg=" + contentImg + "&contentImgLen=" + contentImgLen + "&shareTitle=" + shareTitle + "&shareImg=" + shareImg + "&tabName=" + tabName + "&title=" + title)
// uni.navigateTo({
// url: "/pages/product/product?productId=" + productId + "&skuId=" + skuId + "&contentImg=" + contentImg + "&contentImgLen=" + contentImgLen + "&shareTitle=" + shareTitle + "&shareImg=" + shareImg + "&tabName=" + tabName + "&title=" + title
// })
} }
}, },
channelTabHandler(_index, evt) { channelTabHandler(_index, evt) {
...@@ -665,7 +675,7 @@ export default { ...@@ -665,7 +675,7 @@ export default {
openChannel(videoChannel, evt) { openChannel(videoChannel, evt) {
if (evt) { if (evt) {
md.sensorLog(evt); md.sensorLog(evt);
if (evt.currentTarget.dataset.comlog) { if (evt.currentTarget.dataset.comlog) {
md.sensorComponentLogTake(evt.currentTarget.dataset.comlog); md.sensorComponentLogTake(evt.currentTarget.dataset.comlog);
} }
} }
...@@ -947,8 +957,28 @@ export default { ...@@ -947,8 +957,28 @@ export default {
object-fit: cover; object-fit: cover;
} }
.videoposterboxtitle {
font-size: 28rpx;
color: #ffffff;
font-weight: 500;
margin-left: 20rpx;
line-height: 1.4;
margin-top: -56rpx;
z-index: 2;
position: relative;
// padding: 8rpx 16rpx;
// background-color: rgba(0, 0, 0, 0.5);
border-radius: 8rpx;
width: 476rpx;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
} }
.productcontai { .productcontai {
margin-top: 32rpx; margin-top: 32rpx;
margin-left: 32rpx; margin-left: 32rpx;
......
This diff is collapsed.
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