Compare commits

..
7 Commits
Author SHA1 Message Date
jacobxu666andClaude Fable 5 6bc9b2c0d7 fix: 云闪付控件唤不起修复——upsdk.js 改为 main.js 挂载前 document-start 预热注入(HBuilderX 构建不吃根 index.html 静态标签),确认订单页轮询复用预热标签防重复加载
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-28 14:26:14 +08:00
jacobxu666andClaude Fable 5 9f02144df7 feat: 文旅场馆列表卡片去掉点击进入详情(本页列表仅展示,详情页仍由折扣页等入口使用)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-28 10:59:32 +08:00
jacobxu666andClaude Fable 5 88f4d48c80 feat: 活动指南两张图片URL加版本参数?v=20260928,击穿各平台WebView与CDN旧缓存,强制拉取10:18更新后的新图(约定:后续换图需同步更新版本参数)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-28 10:37:29 +08:00
jacobxu666andClaude Fable 5 ffe42d48c5 feat: 中奖名单页副标题改为「总计10,000份权益包,全程公证抽取」(原文案为分三期公证抽取)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-28 10:27:39 +08:00
jacobxu666andClaude Fable 5 4daa4f3f5f feat: 首页活动指南卡片去掉图片上叠加的文字层,只保留图片(图内已自带标题/副标题/官方指南角标,叠字导致重复;同步清理无用的title/sub数据与样式)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-28 10:22:52 +08:00
jacobxu666andClaude Fable 5 1005f6bd22 fix: 文旅场馆列表地址行超出容器——去掉卡片702rpx写死宽度与地址200px上限,card-info补min-width:0,改为随容器流动、本列宽度内省略(同型隐患暂留discount/rights页702rpx未动)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-28 09:16:47 +08:00
jacobxu666andClaude Fable 5 b9895049d1 fix: 默认导航栏顶部超宽空白——微信Android WebView在viewport-fit=cover下误报safe-area-inset-top,将uni内置H5导航栏(calc(44px+env))垫高;App.vue全局强制回固定44px(影响参加/使用指南、协议、权益详情等默认导航栏页面)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-09-28 09:16:47 +08:00
7 changed files with 55 additions and 54 deletions
+19
View File
@@ -23,4 +23,23 @@
Arial, Helvetica, sans-serif;
-webkit-font-smoothing: antialiased;
}
/* xuchao: 修复默认导航栏在微信 WebView 内顶部超宽空白(参加/使用指南、协议等页)——
uni-app 内置 H5 导航栏高度为 calc(44px + env(safe-area-inset-top)),页面模板带
viewport-fit=cover 时,部分 Android 微信 WebView 会误报状态栏高度(而 H5 视口本
就位于微信原生标题栏下方、并未被遮挡),导致导航栏被垫高。强制回退固定 44px。
标准浏览器/ iOS 中该 env 值为 0,此覆盖无副作用 */
uni-page-head .uni-page-head {
height: 44px !important;
padding-top: 7px !important;
}
uni-page-head .uni-page-head ~ .uni-placeholder {
height: 44px !important;
}
uni-page-head[uni-page-head-type='default'] ~ uni-page-wrapper {
height: calc(100% - 44px) !important;
}
.uni-app--showtabbar uni-page-head[uni-page-head-type='default'] ~ uni-page-wrapper {
height: calc(100% - 44px) !important;
}
</style>
+13
View File
@@ -22,6 +22,19 @@ export const VOUCHER_USE_FLOW = [
'支付差额可选:油卡 / 现金等'
]
// xuchao: 云闪付 SDK 前置预热注入。HBuilderX 的 H5 构建不吃项目根 index.html(静态标签会被丢),
// 只能在 main.js 最早期(document-start、App 挂载前)动态注入,逼近 xghmall 的 head 静态加载时机,
// 让云闪付原生控件桥在首屏就注册,避免到确认订单页才注入导致 upsdk.pay 唤不起。
// 与 orderConfirm 页的 loadUpSdk 共用同一 script[data-upsdk] 标记,全局只注入一次。
export function injectUpSdk() {
if (typeof document === 'undefined' || typeof window === 'undefined') return
if (window.upsdk || document.querySelector('script[data-upsdk]')) return
const s = document.createElement('script')
s.src = 'https://open.95516.com/s/open/js/upsdk.js'
s.setAttribute('data-upsdk', '1')
document.head.appendChild(s)
}
// xuchao: 云闪付容器判定只看 UA——不能掺 window.upsdk 是否已加载(SDK 是异步注入的,
// 首屏点击时可能还没 load 完,会把云闪付内首点误判为站外)。UA 关键字真机实测后定稿。
export function isUnionPayApp() {
+5
View File
@@ -1,4 +1,9 @@
import App from './App'
import { injectUpSdk } from '@/common/petrolVoucher.js'
// xuchao: 云闪付控件 SDK 预热——HBuilderX 构建不吃根 index.html,静态标签无效,
// 在 App 挂载前(document-start 最早 JS 点)注入,逼近静态 head 加载时机(石油券支付修复)
injectUpSdk()
// #ifndef VUE3
import Vue from 'vue'
+4 -47
View File
@@ -19,14 +19,10 @@
<view class="title-line"></view>
<text class="title-text">活动指南</text>
</view>
<!-- xuchao: 图内已带标题/副标题/官方指南角标,不再叠加文字层,只保留图片 -->
<view class="guide-list">
<view class="guide-card" v-for="(item, index) in guideList" :key="index" @click="goPage(item.url)">
<image class="guide-bg" :src="item.bg" mode="scaleToFill"></image>
<view class="guide-info">
<text class="guide-title">{{ item.title }}</text>
<text class="guide-sub">{{ item.sub }}</text>
<view class="guide-tag">官方指南</view>
</view>
</view>
</view>
</view>
@@ -47,15 +43,12 @@
],
guideList: [
{
title: '“千万好礼促消费”活动指南',
sub: '千元权益包、商户惠民福利',
bg: 'https://aliyunoss.hn12301.net/hhrs/hhrs_cjzn.png',
// xuchao: ?v= 为图片版本参数,运营换图必须同步更新日期,否则各平台 WebView/CDN 会继续命中旧缓存
bg: 'https://aliyunoss.hn12301.net/hhrs/hhrs_cjzn.png?v=20260928',
url: '/pages/guide/join'
},
{
title: '社保卡领取及使用指南',
sub: '全流程办理及激活指引',
bg: 'https://aliyunoss.hn12301.net/hhrs/hhrs_syzn.png',
bg: 'https://aliyunoss.hn12301.net/hhrs/hhrs_syzn.png?v=20260928',
url: '/pages/guide/use'
}
],
@@ -266,7 +259,6 @@
}
.guide-card {
position: relative;
width: 100%;
height: 252rpx;
border-radius: 16rpx;
@@ -279,40 +271,5 @@
border-radius: 16rpx;
}
.guide-info {
position: absolute;
top: 0;
left: 0;
display: flex;
flex-direction: column;
justify-content: center;
width: 100%;
height: 100%;
padding: 0 30rpx;
}
.guide-title {
font-size: 16px;
font-weight: 600;
color: #0088FF;
margin-bottom: 10rpx;
}
.guide-sub {
font-size: 12px;
color: #949AA0;
margin-bottom: 16rpx;
}
.guide-tag {
display: inline-block;
width: fit-content;
padding: 4px 10px;
background-color: #e6f2ff;
color: #0088FF;
font-size: 12px;
border-radius: 6rpx;
}
</style>
+10
View File
@@ -95,6 +95,16 @@ export default {
const loading = new Promise(resolve => {
let done = false
const finish = v => { if (!done) { done = true; resolve(v) } }
const exists = document.querySelector('script[data-upsdk]')
if (exists) {
// main.js 已预热注入:轮询等 window.upsdk 出现(避免重复插标签)
const t0 = Date.now()
const timer = setInterval(() => {
if (window.upsdk) { clearInterval(timer); finish(true) }
else if (Date.now() - t0 > timeout) { clearInterval(timer); finish(false) }
}, 200)
return
}
const s = document.createElement('script')
s.src = 'https://open.95516.com/s/open/js/upsdk.js'
s.setAttribute('data-upsdk', '1')
+3 -6
View File
@@ -17,7 +17,7 @@
<!-- 场馆列表 -->
<view class="list-area">
<view class="venue-card" v-for="item in list" :key="item.shopId" @click="goDetail(item)">
<view class="venue-card" v-for="item in list" :key="item.shopId">
<image class="card-img" :src="item.image" mode="aspectFill" />
<view class="card-info">
<text class="card-name">{{ item.name }}</text>
@@ -122,9 +122,6 @@ export default {
uni.reLaunch({ url: '/pages/index/index' })
}
},
goDetail(item) {
uni.navigateTo({ url: '/pages/venue/detail?id=' + item.shopId })
},
onSearch() {
this.pageNo = 1
this.list = []
@@ -207,7 +204,6 @@ export default {
background-color: #ffffff;
border: 1px solid #f2f2f7;
border-radius: 6px;
width: 702rpx;
padding: 24px 12px;
gap: 12px;
box-shadow: 0 2px 3px #f2f2f7;
@@ -223,6 +219,8 @@ export default {
.card-info {
flex: 1;
/* xuchao: flex 项默认 min-width:auto,nowrap 地址会把列宽撑破卡片;置 0 后子元素在实宽内省略 */
min-width: 0;
display: flex;
flex-direction: column;
gap: 0;
@@ -250,7 +248,6 @@ export default {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
max-width: 200px;
}
.card-distance {
+1 -1
View File
@@ -11,7 +11,7 @@
<image class="banner-icon" src="https://aliyunoss.hn12301.net/hhrs/hhrs_zjgs.png" mode="aspectFit"></image>
<text class="banner-title">中奖名单公示</text>
</view>
<text class="banner-subtitle">总计 10,000份权益包,分三期公证抽取</text>
<text class="banner-subtitle">总计 10,000份权益包,全程公证抽取</text>
<view class="stats-card">
<image class="stats-gift" src="https://aliyunoss.hn12301.net/hhrs/hhrs_xyckr.png" mode="aspectFit"></image>
<text class="stats-label">已产生</text>