Jacob
2026-10-12 254f055d485935c8408942987f38f75b78e2136d
pages/zone/index.vue
....@@ -25,6 +25,24 @@
2525 <view class="head_img">
2626 <image :src="info.image"></image>
2727 </view>
28
+ <view v-if="info.zoneType == 8 && info.info" class="rich-content">
29
+ <rich-text :nodes="info.info"></rich-text>
30
+ </view>
31
+ <view v-if="info.zoneType == 8 && info.uploadVideo" class="video-wrap">
32
+ <view v-show="!videoControls" style="width:100%;height:750rpx">
33
+ <video id="zoneVideo" :src='info.uploadVideo' objectFit="contain" controls
34
+ style="width:100%;height:100%" show-center-play-btn="true" show-mute-btn="true" muted="true"
35
+ show-fullscreen-btn="true" auto-pause-if-navigate :custom-cache="false"
36
+ :enable-progress-gesture="true" show-progress="false"
37
+ :poster="info.uploadVideoImg || info.image" @pause="zoneVideoPause"></video>
38
+ </view>
39
+ <view class="video-poster" v-show="videoControls">
40
+ <image class="image" :src="info.uploadVideoImg || info.image"></image>
41
+ </view>
42
+ <view class="video-stop" v-show="videoControls" @tap="bindZoneVideoPlay">
43
+ <image class="image" src="https://ossacmall.bluedeer.com.cn/app/static/images/stop.png"></image>
44
+ </view>
45
+ </view>
2846 <view class="tag-wrap-container" :style="'top:' + (marTop) + 'px;'" v-if="info.zoneType == 7">
2947 <view class="tag-wrap">
3048 <!-- 标签列表 -->
....@@ -495,7 +513,7 @@
495513
496514 <script>
497515 import {
498
- HTTP_REQUEST_URL
516
+ WEB_ACTIVITY_BASE
499517 } from '@/config/app';
500518 import {
501519 mapGetters
....@@ -596,6 +614,8 @@
596614 isYueyangZone: false,
597615 isOpen: false, // 默认收起,false收起/true展开
598616 currentIndex: -1, // 默认选中第一个【全部】
617
+ videoControls: true, // 专区活动视频是否显示海报+播放按钮
618
+ zoneVideoContext: '', // 活动视频播放上下文
599619 partitionList: [],
600620 partitionProject: {},
601621 tagList: [],
....@@ -835,6 +855,17 @@
835855 }
836856 },
837857 methods: {
858
+ /**
859
+ * 专区活动视频:点击海报播放按钮后播放
860
+ */
861
+ bindZoneVideoPlay() {
862
+ if (!this.zoneVideoContext) {
863
+ this.zoneVideoContext = uni.createVideoContext('zoneVideo', this);
864
+ }
865
+ this.$set(this, 'videoControls', false);
866
+ this.zoneVideoContext.play();
867
+ },
868
+ zoneVideoPause() { },
838869 handleCouponRule() {
839870 this.$refs.personalAndShareCouponRuleRef.show(this.info.ruleContentText)
840871 },
....@@ -1206,11 +1237,7 @@
12061237 this.addTrack('yy_marketPageClick', data);
12071238
12081239 function go() {
1209
- let webUrl = 'https://ossacmall.bluedeer.com.cn/acmall_lottery/index.html'
1210
- if (HTTP_REQUEST_URL.indexOf('tohours') > 0) {
1211
- webUrl = webUrl.replace('https://ossacmall.bluedeer.com.cn',
1212
- 'https://sit.tohours.com/crmeb_web')
1213
- }
1240
+ let webUrl = `${WEB_ACTIVITY_BASE}/acmall_lottery/index.html`
12141241 webUrl += '?token=' +
12151242 that.$store.getters.token + '&unionId=' + that.$store.getters.unionId + '&mdayId=' + that.info
12161243 .mdayId
....@@ -1449,6 +1476,7 @@
14491476 console.log('专区详情入参::', params)
14501477 getZoneDetail(that.id, params).then(res => {
14511478 that.info = res.data;
1479
+ //that.info.zoneType=8;
14521480 that.updateZoneShareMenu();
14531481 if (res.data.zoneType == 6) {
14541482 that.setYueyangZone()
....@@ -1850,6 +1878,48 @@
18501878 }
18511879 }
18521880
1881
+.rich-content {
1882
+ padding: 24rpx 30rpx;
1883
+ background-color: #fff;
1884
+}
1885
+
1886
+.video-wrap {
1887
+ position: relative;
1888
+ width: 100%;
1889
+ height: 750rpx;
1890
+ background-color: #000;
1891
+}
1892
+
1893
+.video-wrap .video-poster {
1894
+ position: absolute;
1895
+ top: 0;
1896
+ left: 0;
1897
+ width: 100%;
1898
+ height: 750rpx;
1899
+ z-index: 9;
1900
+}
1901
+
1902
+.video-wrap .video-poster .image {
1903
+ width: 100%;
1904
+ height: 100%;
1905
+}
1906
+
1907
+.video-wrap .video-stop {
1908
+ position: absolute;
1909
+ top: 50%;
1910
+ left: 50%;
1911
+ width: 136rpx;
1912
+ height: 136rpx;
1913
+ margin-top: -68rpx;
1914
+ margin-left: -68rpx;
1915
+ z-index: 9;
1916
+}
1917
+
1918
+.video-wrap .video-stop .image {
1919
+ width: 100%;
1920
+ height: 100%;
1921
+}
1922
+
18531923 .toolbarList {
18541924 width: 750rpx;
18551925 position: -webkit-sticky;