Commit d2dd73bd by yuzhenWang

Merge branch 'dev' into 'master'

Dev

See merge request !134
parents 5c652ce3 e876d89a
...@@ -11,10 +11,14 @@ ...@@ -11,10 +11,14 @@
return { return {
invitationHandled: false ,// 在data中明确定义, invitationHandled: false ,// 在data中明确定义,
dataToken:'', dataToken:'',
loginType:''
} }
}, },
onLaunch: function() { onLaunch: function() {
console.log('App Launch'); console.log('App Launch');
if(uni.getStorageSync('loginType')){
this.loginType = uni.getStorageSync('loginType')
}
if(uni.getStorageSync('dataToken')){ if(uni.getStorageSync('dataToken')){
uni.removeStorageSync('dataToken') uni.removeStorageSync('dataToken')
} }
...@@ -249,11 +253,12 @@ ...@@ -249,11 +253,12 @@
uni.setStorageSync('dataToken',decodeURIComponent(params.dataToken)); uni.setStorageSync('dataToken',decodeURIComponent(params.dataToken));
} }
//家办商城跳转未登录状态下 //家办商城跳转未登录状态下
if(params.noLogin){ if(params.mpCffp&&(params.noLogin ||!params.dataToken)){
uni.removeStorageSync('userIsActive') uni.removeStorageSync('userIsActive')
uni.removeStorageSync('dataToken') uni.removeStorageSync('dataToken')
uni.setStorageSync('loginType','visitor'); uni.setStorageSync('loginType','visitor');
} }
if(params.addSystemType){ if(params.addSystemType){
uni.setStorageSync('addSystemType', params.addSystemType); uni.setStorageSync('addSystemType', params.addSystemType);
} }
......
...@@ -199,16 +199,28 @@ export default { ...@@ -199,16 +199,28 @@ export default {
* 检测设备信息 * 检测设备信息
* deviceType:PC为1,移动端为2,微信为3 * deviceType:PC为1,移动端为2,微信为3
*/ */
// checkDeviceType() {
// let deviceType = null;
// if (/Android|webOS|iPhone|iPod|iPad|BlackBerry/i.test(navigator.userAgent)) {
// if (navigator.userAgent.toLowerCase().indexOf('micromessenger') !== -1) {
// deviceType = '3';
// } else {
// deviceType = '2';
// }
// } else {
// deviceType = '1';
// }
// return deviceType;
// },
checkDeviceType() { checkDeviceType() {
let deviceType = null; let deviceType = null;
if (/Android|webOS|iPhone|iPod|iPad|BlackBerry/i.test(navigator.userAgent)) { // 优先判断是否在微信环境(包含手机微信、电脑微信的 WebView)
if (navigator.userAgent.toLowerCase().indexOf('micromessenger') !== -1) { if (navigator.userAgent.toLowerCase().indexOf('micromessenger') !== -1) {
deviceType = '3'; deviceType = '3';
} else { } else if (/Android|webOS|iPhone|iPod|iPad|BlackBerry/i.test(navigator.userAgent)) {
deviceType = '2'; deviceType = '2';
}
} else { } else {
deviceType = '1'; deviceType = '1';
} }
return deviceType; return deviceType;
}, },
......
...@@ -122,7 +122,9 @@ import { ref, computed, onMounted, onUnmounted } from 'vue'; ...@@ -122,7 +122,9 @@ import { ref, computed, onMounted, onUnmounted } from 'vue';
// import pdfjsWorker from 'pdfjs-dist/build/pdf.worker?url'; // import pdfjsWorker from 'pdfjs-dist/build/pdf.worker?url';
import * as pdfjsLib from 'pdfjs-dist/es5/build/pdf'; import * as pdfjsLib from 'pdfjs-dist/es5/build/pdf';
import pdfjsWorker from 'pdfjs-dist/es5/build/pdf.worker.js?url'; import pdfjsWorker from 'pdfjs-dist/build/pdf.worker.min.js?url';
// ================== PROPS ================== // ================== PROPS ==================
interface PdfInfo { interface PdfInfo {
......
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<script> <!-- ===== vConsole 提前加载 ===== -->
// ============ 新增:解析 URL 参数并设置状态栏占位 ============ <!-- <script src="https://unpkg.com/vconsole@latest/dist/vconsole.min.js"></script> -->
//解决项目以h5的方式内嵌到app的webview中,手机状态栏和页面顶部内容重叠的问题 <!-- <script>
(function() { // 立即初始化,不依赖任何框架
function getQueryParam(name) { var vConsole = new window.VConsole();
// 从 hash 中提取查询参数 console.log('[vConsole] 已初始化');
const hash = window.location.hash; </script> -->
const queryIndex = hash.indexOf('?'); <!-- ===== vConsole 加载结束 ===== -->
console.log('queryIndex', queryIndex); <!-- ===== 1. 状态栏占位 ===== -->
if (queryIndex === -1) return null; <script>
const queryString = hash.substring(queryIndex + 1); (function() {
const reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)'); function getQueryParam(name) {
const r = queryString.match(reg); var searchParams = new URLSearchParams(window.location.search);
console.log('匹配结果', r); if (searchParams.has(name)) return searchParams.get(name);
if (r != null) return decodeURIComponent(r[2]); var hash = window.location.hash;
return null; var queryIndex = hash.indexOf('?');
} if (queryIndex !== -1) {
const statusBarHeight = getQueryParam('statusBarHeight'); var params = new URLSearchParams(hash.substring(queryIndex + 1));
console.log('状态栏高度', statusBarHeight); if (params.has(name)) return params.get(name);
if (statusBarHeight) { }
const height = parseInt(statusBarHeight, 10); return null;
if (!isNaN(height) && height > 0) { }
document.write('<style>' +
'html, body { margin:0; padding:0; height:100%; overflow:hidden; }' +
'body { padding-top: ' + height + 'px; box-sizing: border-box; }' +
'#app { height: 100%; overflow-y: auto; }' +
'</style>');
}
}
})();
// ============ 新增结束 ============
var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') ||
CSS.supports('top: constant(a)'))
document.write(
'<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' +
(coverSupport ? ', viewport-fit=cover' : '') + '" />')
// 判断是否在小程序Webview环境中 var statusBarHeight = getQueryParam('statusBarHeight');
function isInMiniProgram() { if (statusBarHeight) {
// 更安全的小程序环境判断 var height = parseInt(statusBarHeight, 10);
try { if (!isNaN(height) && height > 0) {
return typeof wx !== 'undefined' && wx.miniProgram && wx.miniProgram.getEnv; var style = document.createElement('style');
} catch (e) { style.textContent =
return false; 'html, body { margin:0; padding:0; height:100%; overflow:hidden; }' +
} 'body { padding-top: ' + height + 'px; box-sizing: border-box; }' +
} '#app { height: 100%; overflow-y: auto; }';
document.head.appendChild(style);
}
}
})();
</script>
// 页面加载完成后执行 <!-- ===== 2. Viewport ===== -->
document.addEventListener('DOMContentLoaded', function() { <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, viewport-fit=cover" />
// 非小程序环境才加载微信JS-SDK
if (!isInMiniProgram()) { <title>银盾家办</title>
var script = document.createElement('script'); <link rel="stylesheet" href="./static/font/iconfont.css">
script.src = 'https://res2.wx.qq.com/open/js/jweixin-1.6.0.js'; <link rel="shortcut icon" href="./static/suplogo.ico">
document.head.appendChild(script); </head>
console.log('加载微信JS-SDK'); <body>
} else { <div id="app"></div>
console.log('小程序Webview环境,不加载微信JS-SDK'); <script type="module" src="/main.js"></script>
} </body>
});
</script>
<title>银盾家办</title>
<link rel="stylesheet" href="./static/font/iconfont.css">
<link rel="shortcut icon" href="./static/suplogo.ico">
</head>
<body>
<div id="app">
<!--app-html-->
</div>
<script type="module" src="/main.js"></script>
</body>
</html> </html>
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
{ {
"id": "vcode-input",
"name": "验证码输入框",
"version": "2.0",
"description": "验证码输入框,密码输入框",
"keywords": [
"验证码输入框",
"支付密码输入框"
],
"displayName": "验证码输入框",
"dcloudext": {
"category": [
"前端组件",
"通用组件"
]
},
"dependencies": { "dependencies": {
"@dcloudio/uni-ui": "^1.5.11", "@dcloudio/uni-ui": "^1.5.11",
"@uqrcode/js": "^4.0.7", "@uqrcode/js": "^4.0.7",
...@@ -29,7 +14,6 @@ ...@@ -29,7 +14,6 @@
"qrcode": "^1.5.4", "qrcode": "^1.5.4",
"qrcodejs2": "^0.0.2", "qrcodejs2": "^0.0.2",
"uqrcodejs": "^4.0.7", "uqrcodejs": "^4.0.7",
"vite-plugin-top-level-await": "^1.6.0",
"weixin-js-sdk": "^1.6.5" "weixin-js-sdk": "^1.6.5"
}, },
"devDependencies": { "devDependencies": {
......
...@@ -150,6 +150,7 @@ ...@@ -150,6 +150,7 @@
<text>{{showName}}</text> <text>{{showName}}</text>
</view> </view>
</view> </view>
<!-- 小程序的购买 -->
<view v-if="mpCffp" class="shareBuyBox"> <view v-if="mpCffp" class="shareBuyBox">
<view class="rightShare" @click="reinvite"> <view class="rightShare" @click="reinvite">
<loadingIcon :loading="isLoading" v-if="isLoading" loadColor="#20269B" /> <loadingIcon :loading="isLoading" v-if="isLoading" loadColor="#20269B" />
...@@ -394,7 +395,7 @@ ...@@ -394,7 +395,7 @@
// 打开微信分享啊 // 打开微信分享啊
reinvite() { reinvite() {
//小程序没登录进入到系统,要回到小程序去登录 //小程序没登录进入到系统,要回到小程序去登录
if (uni.getStorageSync('mpCffp') && !uni.getStorageSync('dataToken')) { if (uni.getStorageSync('mpCffp') && !uni.getStorageSync('dataToken')&&this.loginType === 'visitor') {
this.jumpMplogin() this.jumpMplogin()
return return
} }
...@@ -481,7 +482,8 @@ ...@@ -481,7 +482,8 @@
// desc: '加入我们开启学习之旅', // desc: '加入我们开启学习之旅',
desc: this.courseInfo.fileSynopsis, desc: this.courseInfo.fileSynopsis,
link: `${shareURL}/pages/lanch/index?fileId=${this.fileId}&coursesharing=1&serialsNo=${nanoid()}&shareCode=${shareCode}&shareUserId=${this.userId}&jumpUrl=${jumptime}&landingPage=courseDetail&miniShare=1`, link: `${shareURL}/pages/lanch/index?fileId=${this.fileId}&coursesharing=1&serialsNo=${nanoid()}&shareCode=${shareCode}&shareUserId=${this.userId}&jumpUrl=${jumptime}&landingPage=courseDetail&miniShare=1`,
imgUrl: this.courseInfo.displayImage, //图片 // imgUrl: this.courseInfo.displayImage, //图片
imgUrl: this.courseInfo.shareImg, //图片
sharePage: 'courseDetail', //分享的哪个页面 sharePage: 'courseDetail', //分享的哪个页面
commonId: shareCode, commonId: shareCode,
userId: this.userId, userId: this.userId,
...@@ -492,7 +494,8 @@ ...@@ -492,7 +494,8 @@
wx.miniProgram.postMessage({ wx.miniProgram.postMessage({
data: { data: {
type: 'share', type: 'share',
shareData: JSON.stringify(shareInfo) shareData: JSON.stringify(shareInfo),
messageId: nanoid() // 唯一消息ID
} }
}) })
...@@ -636,12 +639,14 @@ ...@@ -636,12 +639,14 @@
}, },
// 订单保存 // 订单保存
saveOrder() { saveOrder() {
//小程序没登录进入到系统,要回到小程序去登录 this.loginType = uni.getStorageSync('loginType');
if (uni.getStorageSync('mpCffp') && !uni.getStorageSync('dataToken')) {
//小程序没登录进入到分销系统,并且分销系统也没登录要回到小程序去登录 (比如在申请加盟那登录了,可以直接在分销系统中购买)
if (uni.getStorageSync('mpCffp') && !uni.getStorageSync('dataToken')&&this.loginType === 'visitor') {
this.jumpMplogin() this.jumpMplogin()
return return
} }
this.loginType = uni.getStorageSync('loginType');
if (this.loginType === 'visitor') { if (this.loginType === 'visitor') {
this.wayType = '1' this.wayType = '1'
if (this.systemType == 'IOS') { if (this.systemType == 'IOS') {
...@@ -1088,7 +1093,8 @@ ...@@ -1088,7 +1093,8 @@
// desc: '加入我们开启学习之旅', // desc: '加入我们开启学习之旅',
desc: this.courseInfo.fileSynopsis, desc: this.courseInfo.fileSynopsis,
link: newLink, //分享链接 link: newLink, //分享链接
imgUrl: this.courseInfo.displayImage, //图片 // imgUrl: this.courseInfo.displayImage, //图片
imgUrl: this.courseInfo.shareImg, //图片
} }
console.log('data', data); console.log('data', data);
//安卓机型获取当前页面路径 //安卓机型获取当前页面路径
......
...@@ -302,6 +302,7 @@ ...@@ -302,6 +302,7 @@
if (uni.getStorageSync('cffp_userInfo')) { if (uni.getStorageSync('cffp_userInfo')) {
this.userInfo = JSON.parse(uni.getStorageSync('cffp_userInfo')) this.userInfo = JSON.parse(uni.getStorageSync('cffp_userInfo'))
} }
this.shareItem = JSON.parse(JSON.stringify(item))
// return // return
// 未登录去登录 // 未登录去登录
if (uni.getStorageSync('loginType') !== 'codelogin') { if (uni.getStorageSync('loginType') !== 'codelogin') {
...@@ -320,7 +321,7 @@ ...@@ -320,7 +321,7 @@
this.sharelogin = true this.sharelogin = true
return return
} }
this.shareItem = JSON.parse(JSON.stringify(item)) // this.shareItem = JSON.parse(JSON.stringify(item))
// 已登录,未成为合伙人 // 已登录,未成为合伙人
if (this.userInfo && !this.userInfo['partnerType']) { if (this.userInfo && !this.userInfo['partnerType']) {
dataHandling.pocessTracking( dataHandling.pocessTracking(
...@@ -395,7 +396,8 @@ ...@@ -395,7 +396,8 @@
title: this.shareItem.fileTitle, title: this.shareItem.fileTitle,
desc: this.shareItem.fileSynopsis, desc: this.shareItem.fileSynopsis,
link: `${shareURL}/pages/lanch/index?fileId=${this.shareItem.fileId}&coursesharing=1&serialsNo=${nanoid()}&shareCode=${shareCode}&shareUserId=${this.userId}&jumpUrl=${jumptime}&landingPage=courseDetail&miniShare=1`, link: `${shareURL}/pages/lanch/index?fileId=${this.shareItem.fileId}&coursesharing=1&serialsNo=${nanoid()}&shareCode=${shareCode}&shareUserId=${this.userId}&jumpUrl=${jumptime}&landingPage=courseDetail&miniShare=1`,
imgUrl: this.shareItem.displayImage, //图片 // imgUrl: this.shareItem.displayImage, //图片
imgUrl: this.shareItem.shareImg, //图片
commonId: this.shareItem.fileId, commonId: this.shareItem.fileId,
sharePage: 'courseDetail', //分享出去得页面 sharePage: 'courseDetail', //分享出去得页面
userId:this.userId, userId:this.userId,
...@@ -427,7 +429,8 @@ ...@@ -427,7 +429,8 @@
link: shareURL + "/pages/courseDetail/courseDetail?fileId=" + item.fileId + link: shareURL + "/pages/courseDetail/courseDetail?fileId=" + item.fileId +
'&coursesharing=1' + '&serialsNo=' + nanoid() + '&shareCode=' + shareCode + '&shareUserId=' + '&coursesharing=1' + '&serialsNo=' + nanoid() + '&shareCode=' + shareCode + '&shareUserId=' +
this.userId + '&jumpUrl=' + jumptime + "&", //分享链接 this.userId + '&jumpUrl=' + jumptime + "&", //分享链接
imgUrl: item.displayImage, //图片 // imgUrl: item.displayImage, //图片
imgUrl: item.shareImg, //图片
} }
//安卓机型获取当前页面路径 //安卓机型获取当前页面路径
let url = window.location.href.split('#')[0]; let url = window.location.href.split('#')[0];
......
...@@ -38,6 +38,7 @@ ...@@ -38,6 +38,7 @@
</view> </view>
</view> </view>
<!-- 支付方式 --> <!-- 支付方式 -->
<view class="paymentMethodContent"> <view class="paymentMethodContent">
<h4>选择支付方式</h4> <h4>选择支付方式</h4>
<view @click="selectPaymentMethod(2)"> <view @click="selectPaymentMethod(2)">
...@@ -61,17 +62,7 @@ ...@@ -61,17 +62,7 @@
<i class="iconfont icon-duihao txtFont"></i> <i class="iconfont icon-duihao txtFont"></i>
</view> </view>
</view> </view>
<!-- #ifdef APP-PLUS -->
<!-- <view class="paymentItem" @click="selectPaymentMethod(1)">
<view>
<i class="iconfont icon-py_weixinzhifu"></i>
<text>微信支付</text>
</view>
<view class="selectRadio" :class="{'actived':paymentMethod===1}">
<i class="iconfont icon-duihao"></i>
</view>
</view> -->
<!-- #endif -->
</view> </view>
</view> </view>
......
...@@ -109,6 +109,20 @@ ...@@ -109,6 +109,20 @@
<view class="subtit"> <view class="subtit">
晋升下一级目标 晋升下一级目标
</view> </view>
<view class="" >
<view class="">
<text class="iconfont icon-xiaoshoue leftIcon"></text>
<text>购买分销系统内任一产品(含自购)</text>
<!-- <text class="iconfont icon-duihao2 rightIcon" ></text> -->
<text v-if="partnerStatistic.hasCompletedFirstOrder!='1'"
class="iconfont icon-weiwancheng rightIcon"></text>
<text v-else class="iconfont icon-duihao2 rightIcon"></text>
</view>
<!-- <view class="num">
<text>{{partnerStatistic.totalSingeSaleNum.toFixed(2)}}元 /
{{partnerStatistic.reachSingeSaleNum.toFixed(2)}}</text>
</view> -->
</view>
<view class="" v-if="partnerStatistic.reachPeopleNum>0"> <view class="" v-if="partnerStatistic.reachPeopleNum>0">
<view class=""> <view class="">
<text class="iconfont icon-a-tuandui3 leftIcon"></text> <text class="iconfont icon-a-tuandui3 leftIcon"></text>
...@@ -123,20 +137,7 @@ ...@@ -123,20 +137,7 @@
<text v-if="partnerStatistic.peopleNum>0">(相差{{partnerStatistic.peopleNum}}人)</text> <text v-if="partnerStatistic.peopleNum>0">(相差{{partnerStatistic.peopleNum}}人)</text>
</view> </view>
</view> </view>
<view class="" v-if="partnerStatistic.reachSingeSaleNum>0">
<view class="">
<text class="iconfont icon-xiaoshoue leftIcon"></text>
<text>个人标准销售累计金额</text>
<!-- <text class="iconfont icon-duihao2 rightIcon" ></text> -->
<text v-if="partnerStatistic.totalSingeSaleNum<partnerStatistic.reachSingeSaleNum"
class="iconfont icon-weiwancheng rightIcon"></text>
<text v-else class="iconfont icon-duihao2 rightIcon"></text>
</view>
<view class="num">
<text>{{partnerStatistic.totalSingeSaleNum.toFixed(2)}}元 /
{{partnerStatistic.reachSingeSaleNum.toFixed(2)}}</text>
</view>
</view>
<view class="" v-if="partnerStatistic.reachSaleNum>0"> <view class="" v-if="partnerStatistic.reachSaleNum>0">
<view class=""> <view class="">
<text class="iconfont icon-ddailirenshu leftIcon"></text> <text class="iconfont icon-ddailirenshu leftIcon"></text>
...@@ -1309,7 +1310,7 @@ ...@@ -1309,7 +1310,7 @@
} }
.applyBox { .applyBox {
width: 500rpx; width: 600rpx;
border-radius: 30rpx; border-radius: 30rpx;
background-color: #ffff; background-color: #ffff;
padding: 30rpx; padding: 30rpx;
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<view class="banner"> <view class="banner">
<!--头部技术支持组件--> <!--头部技术支持组件-->
<!-- <commonHead></commonHead> --> <!-- <commonHead></commonHead> -->
<image src="../../static/images/banner.png" mode="widthFix"></image> <image src="../../static/images/banner.webp" mode="widthFix"></image>
</view> </view>
<scroll-view scroll-y="true" class="formInfoContainer" id="formInfoContainer"> <scroll-view scroll-y="true" class="formInfoContainer" id="formInfoContainer">
<form> <form>
...@@ -181,7 +181,7 @@ ...@@ -181,7 +181,7 @@
<view v-if="resultInfos.code == 'B001' || resultInfos.code =='B002'" style="display: flex;align-items: center;"> <view v-if="resultInfos.code == 'B001' || resultInfos.code =='B002'" style="display: flex;align-items: center;">
<!-- <view style="display: flex;align-items: center;"> --> <!-- <view style="display: flex;align-items: center;"> -->
<view style="margin-right: 16rpx;"> <view style="margin-right: 16rpx;">
<image src="../../static/images/happy.png" mode="widthFix"></image> <image src="../../static/images/happy.webp" mode="widthFix"></image>
</view> </view>
<view> <view>
<view>恭喜您!</view> <view>恭喜您!</view>
...@@ -191,7 +191,7 @@ ...@@ -191,7 +191,7 @@
<view v-if="resultInfos.code == 'A001' || resultInfos.code =='A002'" style="display: flex;align-items: center;"> <view v-if="resultInfos.code == 'A001' || resultInfos.code =='A002'" style="display: flex;align-items: center;">
<!-- <view style="display: flex;align-items: center;"> --> <!-- <view style="display: flex;align-items: center;"> -->
<view style="margin-right: 16rpx;"> <view style="margin-right: 16rpx;">
<image src="../../static/images/sad.png" mode="widthFix"></image> <image src="../../static/images/sad.webp" mode="widthFix"></image>
</view> </view>
<view> <view>
<view>很遗憾!</view> <view>很遗憾!</view>
...@@ -216,8 +216,8 @@ ...@@ -216,8 +216,8 @@
</view> </view>
<view class="line" v-for="houseItem in housePurchasePrices"> <view class="line" v-for="houseItem in housePurchasePrices">
<view class="line_title">{{getResultTitle(houseItem.priceType)}} <view class="line_title">{{getResultTitle(houseItem.priceType)}}
<image src="../../static/images/can.png" v-show="houseItem.fvDifference <= 0" mode="widthFix"></image> <image src="../../static/images/can.webp" v-show="houseItem.fvDifference <= 0" mode="widthFix"></image>
<image src="../../static/images/cannot.png" v-show="houseItem.fvDifference > 0" mode="widthFix"></image> <image src="../../static/images/cannot.webp" v-show="houseItem.fvDifference > 0" mode="widthFix"></image>
</view> </view>
<view class="content"> <view class="content">
<view class="left"> <view class="left">
...@@ -227,7 +227,7 @@ ...@@ -227,7 +227,7 @@
现值:{{numberConverter(houseItem.pvPriceRealization)}} 现值:{{numberConverter(houseItem.pvPriceRealization)}}
</view> --> </view> -->
</view> </view>
<image src="../../static/images/vs.png" mode="widthFix"></image> <image src="../../static/images/vs.webp" mode="widthFix"></image>
<view class="right"> <view class="right">
<view class="realizable">你想要的</view> <view class="realizable">你想要的</view>
<view>{{housePurchaseInfo.nyear}}年后:{{formatFloat(houseItem.fvPriceDesired/10000)}}万元</view> <view>{{housePurchaseInfo.nyear}}年后:{{formatFloat(houseItem.fvPriceDesired/10000)}}万元</view>
......
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n():"function"==typeof define&&define.amd?define(n):(e=e||self).uni=n()}(this,(function(){"use strict";try{var e={};Object.defineProperty(e,"passive",{get:function(){!0}}),window.addEventListener("test-passive",null,e)}catch(e){}var n=Object.prototype.hasOwnProperty;function i(e,i){return n.call(e,i)}Object.assign({},{unit:"rem",unitRatio:10/320,unitPrecision:5});var t=[];function o(){return window.__dcloud_weex_postMessage||window.__dcloud_weex_}function a(){return window.__uniapp_x_postMessage||window.__uniapp_x_}var r=function(e,n){var i={options:{timestamp:+new Date},name:e,arg:n};if(a()){if("postMessage"===e){var r={data:n};return window.__uniapp_x_postMessage?window.__uniapp_x_postMessage(r):window.__uniapp_x_.postMessage(JSON.stringify(r))}var d={type:"WEB_INVOKE_APPSERVICE",args:{data:i,webviewIds:t}};window.__uniapp_x_postMessage?window.__uniapp_x_postMessageToService(d):window.__uniapp_x_.postMessageToService(JSON.stringify(d))}else if(o()){if("postMessage"===e){var s={data:[n]};return window.__dcloud_weex_postMessage?window.__dcloud_weex_postMessage(s):window.__dcloud_weex_.postMessage(JSON.stringify(s))}var w={type:"WEB_INVOKE_APPSERVICE",args:{data:i,webviewIds:t}};window.__dcloud_weex_postMessage?window.__dcloud_weex_postMessageToService(w):window.__dcloud_weex_.postMessageToService(JSON.stringify(w))}else{if(!window.plus)return window.parent.postMessage({type:"WEB_INVOKE_APPSERVICE",data:i,pageId:""},"*");if(0===t.length){var u=plus.webview.currentWebview();if(!u)throw new Error("plus.webview.currentWebview() is undefined");var g=u.parent(),c="";c=g?g.id:u.id,t.push(c)}if(plus.webview.getWebviewById("__uniapp__service"))plus.webview.postMessageToUniNView({type:"WEB_INVOKE_APPSERVICE",args:{data:i,webviewIds:t}},"__uniapp__service");else{var v=JSON.stringify(i);plus.webview.getLaunchWebview().evalJS('UniPlusBridge.subscribeHandler("'.concat("WEB_INVOKE_APPSERVICE",'",').concat(v,",").concat(JSON.stringify(t),");"))}}},d={navigateTo:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.url;r("navigateTo",{url:encodeURI(n)})},navigateBack:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.delta;r("navigateBack",{delta:parseInt(n)||1})},switchTab:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.url;r("switchTab",{url:encodeURI(n)})},reLaunch:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.url;r("reLaunch",{url:encodeURI(n)})},redirectTo:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.url;r("redirectTo",{url:encodeURI(n)})},getEnv:function(e){if(a()){var n=navigator.userAgent.includes("uni-app"),i=navigator.userAgent.includes("OpenHarmony"),t={uvue:!0};n&&i&&(t.harmony=!0),e(t)}else o()?e({nvue:!0}):window.plus?e({plus:!0}):e({h5:!0})},postMessage:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};r("postMessage",e.data||{})}},s=/uni-app/i.test(navigator.userAgent),w=/Html5Plus/i.test(navigator.userAgent),u=/complete|loaded|interactive/;var g=window.my&&navigator.userAgent.indexOf(["t","n","e","i","l","C","y","a","p","i","l","A"].reverse().join(""))>-1;var c=window.swan&&window.swan.webView&&/swan/i.test(navigator.userAgent);var v=window.qq&&window.qq.miniProgram&&/QQ/i.test(navigator.userAgent)&&/miniProgram/i.test(navigator.userAgent);var p=window.tt&&window.tt.miniProgram&&/toutiaomicroapp/i.test(navigator.userAgent);var _=window.wx&&window.wx.miniProgram&&/micromessenger/i.test(navigator.userAgent)&&/miniProgram/i.test(navigator.userAgent);var m=window.qa&&/quickapp/i.test(navigator.userAgent);var f=window.ascfwebProxy&&window.ascfwebProxy.invokeJsApi&&/ASCF/i.test(navigator.userAgent);var l=window.ks&&window.ks.miniProgram&&/micromessenger/i.test(navigator.userAgent)&&/miniProgram/i.test(navigator.userAgent);var E=window.tt&&window.tt.miniProgram&&/Lark|Feishu/i.test(navigator.userAgent);var y=window.jd&&window.jd.miniProgram&&/jdmp/i.test(navigator.userAgent);var x=window.xhs&&window.xhs.miniProgram&&/xhsminiapp/i.test(navigator.userAgent);for(var S,h=function(){window.UniAppJSBridge=!0,document.dispatchEvent(new CustomEvent("UniAppJSBridgeReady",{bubbles:!0,cancelable:!0}))},b=[function(e){if(s||w)return window.__uniapp_x_postMessage||window.__uniapp_x_||window.__dcloud_weex_postMessage||window.__dcloud_weex_?document.addEventListener("DOMContentLoaded",e):window.plus&&u.test(document.readyState)?setTimeout(e,0):document.addEventListener("plusready",e),d},function(e){if(_)return window.WeixinJSBridge&&window.WeixinJSBridge.invoke?setTimeout(e,0):document.addEventListener("WeixinJSBridgeReady",e),window.wx.miniProgram},function(e){if(v)return window.QQJSBridge&&window.QQJSBridge.invoke?setTimeout(e,0):document.addEventListener("QQJSBridgeReady",e),window.qq.miniProgram},function(e){if(g){"loading"!==document.readyState?setTimeout(e,0):document.addEventListener("DOMContentLoaded",e);var n=window.my;return{navigateTo:n.navigateTo,navigateBack:n.navigateBack,switchTab:n.switchTab,reLaunch:n.reLaunch,redirectTo:n.redirectTo,postMessage:n.postMessage,getEnv:n.getEnv}}},function(e){if(c)return"loading"!==document.readyState?setTimeout(e,0):document.addEventListener("DOMContentLoaded",e),window.swan.webView},function(e){if(p)return document.addEventListener("DOMContentLoaded",e),window.tt.miniProgram},function(e){if(m){window.QaJSBridge&&window.QaJSBridge.invoke?setTimeout(e,0):document.addEventListener("QaJSBridgeReady",e);var n=window.qa;return{navigateTo:n.navigateTo,navigateBack:n.navigateBack,switchTab:n.switchTab,reLaunch:n.reLaunch,redirectTo:n.redirectTo,postMessage:n.postMessage,getEnv:n.getEnv}}},function(e){if(f)return document.addEventListener("DOMContentLoaded",e),Object.assign({},window.has,window.has.ascfweb)},function(e){if(l)return window.WeixinJSBridge&&window.WeixinJSBridge.invoke?setTimeout(e,0):document.addEventListener("WeixinJSBridgeReady",e),window.ks.miniProgram},function(e){if(E)return"loading"!==document.readyState?setTimeout(e,0):document.addEventListener("DOMContentLoaded",e),window.tt.miniProgram},function(e){if(y)return window.JDJSBridgeReady&&window.JDJSBridgeReady.invoke?setTimeout(e,0):document.addEventListener("JDJSBridgeReady",e),window.jd.miniProgram},function(e){if(x)return window.xhs.miniProgram},function(e){return document.addEventListener("DOMContentLoaded",e),d}],P=0;P<b.length&&!(S=b[P](h));P++);S||(S={});var M="undefined"!=typeof uni?uni:{};if(!M.navigateTo)for(var T in S)i(S,T)&&(M[T]=S[T]);return M.webView=S,M}));
...@@ -22,9 +22,9 @@ export default [ ...@@ -22,9 +22,9 @@ export default [
{ {
"Q": "合伙人晋升条件", "Q": "合伙人晋升条件",
"A": [ "A": [
"见习合伙人:完成加盟申请", "见习合伙人:申请加盟成功",
"新锐合伙人:个人标准销售额≥198元", "新锐合伙人:申请加盟成功且购买分销系统内任一产品(含自购)",
"资深合伙人:个人标准销售额≥198元 + 团队有效人数≥5人 + 团队标准销售额≥5万元", "资深合伙人:申请加盟成功且购买分销系统内任一产品(含自购)+团队≥5人+团队标准销售额≥5万",
], ],
"isActive": 1, "isActive": 1,
"isMore": true "isMore": true
......
// vite.config.js
import { defineConfig } from 'vite'
import uni from '@dcloudio/vite-plugin-uni'
// 自定义插件:移除 CSS 中的 shadow-grey.png 引用
function removeShadowGrey() {
return {
name: 'remove-shadow-grey',
transform(code, id) {
// 只处理 CSS 和 Vue 文件(含 <style>)
if (id.endsWith('.css') || id.endsWith('.scss') || id.endsWith('.vue')) {
// 将 url(...) 中包含 shadow-grey.png 的替换为 none
const newCode = code.replace(
/url\([^)]*shadow-grey\.png[^)]*\)/g,
'none' // 或 '""' 或 '#000',可根据需要调整
)
if (newCode !== code) {
return { code: newCode, map: null }
}
}
return null // 不处理其他文件
}
}
}
export default defineConfig({
plugins: [
uni(),
removeShadowGrey() // 加入自定义插件
],
build: {
cssCodeSplit: true
// 不再配置 rollupOptions.output.manualChunks,使用 Vite 默认分包策略
}
})
\ No newline at end of file
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