From a28cc75da8ca4d7b129f361fe6dd7a15d074b93c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E4=B8=81=E6=9D=B0?= <727475508@qq.com>
Date: Fri, 5 Jun 2026 18:20:19 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages/jingxuan/brand-detail.vue | 119 ++++++++++++++++------
pages/my/myFavorite.vue | 1 -
pages/shop/verify/manual-verify.vue | 49 +++++----
pages/shop/verify/verify-order-detail.vue | 32 ++++--
pages/shop/verify/verify-order.nvue | 11 +-
5 files changed, 143 insertions(+), 69 deletions(-)
diff --git a/pages/jingxuan/brand-detail.vue b/pages/jingxuan/brand-detail.vue
index 1edc59c..96d01d6 100644
--- a/pages/jingxuan/brand-detail.vue
+++ b/pages/jingxuan/brand-detail.vue
@@ -20,22 +20,32 @@
-
-
-
-
-
-
+
+
+
+
+
- {{ currentBannerIndex + 1 }} / {{ totalSlides }}
+ {{ currentBannerIndex + 1 }} / {{ bannerList.length }}
+
+
+
+
+
@@ -216,6 +226,8 @@ export default {
phoneIconRight: 50, // 顶部电话图标初始Right
currentBannerIndex: 0,
+ showVideo: false,
+ isVideoPlaying: false,
isExpanded: false,
activeTab: 0,
@@ -303,10 +315,7 @@ export default {
showTabSection() {
return this.availableTabs.length > 0;
},
- // 总轮播数(视频+图片)
- totalSlides() {
- return this.bannerList.length + (this.info.video ? 1 : 0);
- },
+
canSubmit() {
const d = this.formData;
const baseValid = d.contact_name && d.contact_phone && d.province_code && d.city_code && d.area_code && d.intention;
@@ -336,6 +345,13 @@ export default {
// 每次进入页面时,根据 accessToken 刷新登录状态,就像 my-page 里面写的一样
this.isLogin = uni.getStorageSync("accessToken") ? true : false;
},
+ onBackPress() {
+ if (this.showVideo) {
+ this.closeVideo();
+ return true;
+ }
+ return false;
+ },
methods: {
// 弹窗组件相关方法
closePopup() {
@@ -502,17 +518,24 @@ export default {
},
// 视频事件处理
+ playVideo() {
+ this.showVideo = true;
+ },
+ closeVideo() {
+ const videoContext = uni.createVideoContext('myVideo', this);
+ videoContext.stop();
+ this.showVideo = false;
+ this.isVideoPlaying = false;
+ },
onVideoPlay() {
- console.log('视频开始播放');
+ this.isVideoPlaying = true;
},
onVideoPause() {
- console.log('视频暂停');
+ this.isVideoPlaying = false;
},
onVideoEnded() {
- // 视频播放结束,切换到下一张图片
- if (this.bannerList.length > 0) {
- this.currentBannerIndex = 1;
- }
+ // 视频播放结束,关闭视频层
+ this.closeVideo();
},
// 悬浮按钮切换 Mock 数据
@@ -749,6 +772,10 @@ export default {
.banner-swiper {
width: 100%;
height: 100%;
+
+ swiper-item {
+ position: relative;
+ }
}
.banner-img {
@@ -756,19 +783,51 @@ export default {
height: 100%;
}
- .center-play-icon {
+ .video-play-overlay {
position: absolute;
- top: 50%;
- left: 50%;
- transform: translate(-50%, -50%);
- width: 120rpx;
- height: 120rpx;
- z-index: 20;
- transition: opacity 0.3s;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ z-index: 10;
+ }
- &:active {
- opacity: 0.8;
- }
+ .video-play-icon {
+ width: 100rpx;
+ height: 100rpx;
+ }
+
+ .video-fullscreen-mask {
+ position: fixed;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ background-color: #000;
+ z-index: 9999;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ }
+
+ .video-close-btn {
+ position: absolute;
+ top: 140rpx;
+ right: 60rpx;
+ z-index: 10000;
+ }
+
+ .video-close-icon {
+ color: #fff;
+ font-size: 40rpx;
+ }
+
+ .fullscreen-video {
+ width: 100%;
+ height: 100%;
}
.album {
diff --git a/pages/my/myFavorite.vue b/pages/my/myFavorite.vue
index 10a1417..439c663 100644
--- a/pages/my/myFavorite.vue
+++ b/pages/my/myFavorite.vue
@@ -444,7 +444,6 @@ export default {
border-radius: 27rpx;
margin-right: 40rpx;
padding: 9rpx 24rpx;
- transition: all 0.3s ease;
&.active {
color: #FF4767;
diff --git a/pages/shop/verify/manual-verify.vue b/pages/shop/verify/manual-verify.vue
index 5ccb819..2e6aabd 100644
--- a/pages/shop/verify/manual-verify.vue
+++ b/pages/shop/verify/manual-verify.vue
@@ -6,26 +6,13 @@
请输入6位核销码
-
- {{ code[i-1] || '' }}
+
+ {{ code[i - 1] || '' }}
-
+