Compare commits

...

6 Commits

Author SHA1 Message Date
丁杰 ee20019de3 9800活动上线,营业资质非必填 2026-06-22 14:35:50 +08:00
丁杰 fd5923a4dc 修改request结构 2026-06-18 14:58:10 +08:00
丁杰 cd4373f91f 缺省图+非必填 2026-06-18 14:38:29 +08:00
BAKEYi 93133dc460 Merge branch 'master' of https://gitee.com/qtvbidt/mrr.sj.front 2026-06-18 14:06:04 +08:00
BAKEYi 466d1e4d2e 门店信息地址回显 2026-06-18 14:05:59 +08:00
丁杰 122c19909c 新增成长礼包活动页 2026-06-18 14:02:08 +08:00
23 changed files with 677 additions and 123 deletions

View File

@ -7,8 +7,8 @@
"type" : "uni-app:app-ios" "type" : "uni-app:app-ios"
}, },
{ {
"customPlaygroundType" : "device", "customPlaygroundType" : "local",
"playground" : "standard", "playground" : "custom",
"type" : "uni-app:app-android" "type" : "uni-app:app-android"
} }
] ]

32
App.vue
View File

@ -16,6 +16,9 @@ import request from './utils/request'
import { import {
setVersion setVersion
} from './utils/version.js' } from './utils/version.js'
import {
APP_BACK_BASE_URL
} from './utils/appBackBase.js'
// //
const aLiSDKModule = uni.requireNativePlugin('AliCloud-NirvanaPns'); const aLiSDKModule = uni.requireNativePlugin('AliCloud-NirvanaPns');
export default { export default {
@ -66,38 +69,13 @@ export default {
// await setVersion() // await setVersion()
//访 //访
// GET
let version = uni.getStorageSync('setVersion')
let baseUrl
await uni.request({
url: 'https://api.mrrwlkj.top/api/openPuc/getSjApiUrl', //
method: 'GET', // GET
header: {
'Content-Type': 'application/json', //
'VersionCode': version.VersionCode,
'DeviceBrand': version.DeviceBrand,
'DeviceType': version.DeviceType
},
success: (res) => {
if (res.data.code == 200) {
// #ifndef MP-WEIXIN // #ifndef MP-WEIXIN
uni.setStorageSync('baseUrl', res.data.data.url) uni.setStorageSync('baseUrl', APP_BACK_BASE_URL)
// #endif // #endif
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
wx.setStorageSync('baseUrl', res.data.data.url) wx.setStorageSync('baseUrl', APP_BACK_BASE_URL)
// #endif // #endif
this.$store.commit("setLocation", true) this.$store.commit("setLocation", true)
}
console.log('请求成功', res.data);
},
fail: (err) => {
console.log('请求失败', err);
},
complete: () => {
console.log('请求完成(无论成功失败都会执行)');
}
});
// #ifdef APP-PLUS // #ifdef APP-PLUS
// //

View File

@ -2,8 +2,8 @@
"name" : "美融融商家", "name" : "美融融商家",
"appid" : "__UNI__BBE6285", "appid" : "__UNI__BBE6285",
"description" : "同城便捷到家美业“技术外卖”服务、同城预约到店服务平台美融融为同城爱美人群提供更优质的更全面的服务。", "description" : "同城便捷到家美业“技术外卖”服务、同城预约到店服务平台美融融为同城爱美人群提供更优质的更全面的服务。",
"versionName" : "1.0.21", "versionName" : "1.0.22",
"versionCode" : 1021, "versionCode" : 1022,
"transformPx" : false, "transformPx" : false,
/* 5+App */ /* 5+App */
"app-plus" : { "app-plus" : {

View File

@ -31,6 +31,20 @@
"enablePullDownRefresh": true "enablePullDownRefresh": true
} }
}, },
{
"path": "pages/home/growth-package",
"style": {
"navigationBarTitleText": "",
"navigationStyle": "custom"
}
},
{
"path": "pages/home/growth-package-result",
"style": {
"navigationBarTitleText": "支付结果",
"navigationStyle": "custom"
}
},
{ {
"path": "pages/message/message", "path": "pages/message/message",
"style": { "style": {

View File

@ -0,0 +1,167 @@
<template>
<view class="growth-package-result-page">
<custom-navbar
title="支付结果"
:showBack="true"
backgroundColor="#F7F7F7"
borderBottom="none"
></custom-navbar>
<view class="result-main">
<view class="result-icon" :class="isFail ? 'is-fail' : 'is-success'">
<block v-if="isFail">
<view class="fail-line"></view>
<view class="fail-dot"></view>
</block>
<view v-else class="success-check"></view>
</view>
<view class="result-title">{{ resultInfo.title }}</view>
<view class="result-desc">{{ resultInfo.desc }}</view>
<view class="primary-btn" @tap="handlePrimaryTap">{{ isFail ? "重新支付" : "返回首页" }}</view>
</view>
</view>
</template>
<script>
import CustomNavbar from "@/components/custom-navbar/custom-navbar.vue";
export default {
components: {
CustomNavbar,
},
data() {
return {
status: "success",
};
},
computed: {
isFail() {
return this.status === "fail";
},
resultInfo() {
if (this.isFail) {
return {
title: "报名失败",
desc: "最后一步出了点问题 请重新支付",
};
}
return {
title: "报名成功",
desc: "您已完成支付 感谢你对美融融的支持",
};
},
},
onLoad(options) {
this.status = options.status === "fail" ? "fail" : "success";
},
methods: {
handlePrimaryTap() {
if (this.isFail) {
uni.redirectTo({
url: "/pages/home/growth-package",
});
return;
}
uni.switchTab({
url: "/pages/home/home",
});
},
},
};
</script>
<style lang="scss" scoped>
page {
background: #ffffff;
}
.growth-package-result-page {
min-height: 100vh;
background: #ffffff;
padding-bottom: env(safe-area-inset-bottom);
}
.result-main {
display: flex;
flex-direction: column;
align-items: center;
padding: 246rpx 40rpx 0;
}
.result-icon {
width: 104rpx;
height: 104rpx;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
}
.result-icon.is-success {
background: #12c76b;
}
.result-icon.is-fail {
background: #ff4652;
}
.success-check {
width: 44rpx;
height: 24rpx;
border-left: 8rpx solid #ffffff;
border-bottom: 8rpx solid #ffffff;
transform: rotate(-45deg);
margin-top: -8rpx;
}
.fail-line {
width: 8rpx;
height: 46rpx;
border-radius: 8rpx;
background: #ffffff;
}
.fail-dot {
width: 8rpx;
height: 8rpx;
margin-left: -8rpx;
margin-top: 58rpx;
border-radius: 50%;
background: #ffffff;
}
.result-title {
margin-top: 34rpx;
font-weight: 600;
font-size: 40rpx;
color: #333333;
line-height: 56rpx;
text-align: center;
}
.result-desc {
margin-top: 8rpx;
font-weight: 400;
font-size: 26rpx;
color: #b9b9b9;
line-height: 38rpx;
text-align: center;
}
.primary-btn {
width: 350rpx;
height: 80rpx;
margin-top: 144rpx;
border: 1rpx solid #ff4b67;
border-radius: 40rpx;
box-sizing: border-box;
background: #ffffff;
display: flex;
align-items: center;
justify-content: center;
font-weight: 400;
font-size: 30rpx;
color: #ff4767;
line-height: 42rpx;
}
</style>

View File

@ -0,0 +1,348 @@
<template>
<view class="growth-package-page">
<image class="content-image" src="@/static/images/home/growth-package/intro.png" mode="widthFix"></image>
<view class="deal-carousel">
<swiper class="deal-swiper" autoplay circular :interval="3000" previous-margin="40rpx"
next-margin="40rpx" :current="dealCurrentIndex" @change="handleDealChange">
<swiper-item v-for="(item, index) in dealSlides" :key="item">
<view class="deal-slide" :class="getDealSlideClass(index)">
<image class="deal-slide-image" :src="item" mode="aspectFit"></image>
</view>
</swiper-item>
</swiper>
<view class="deal-indicator">
<view class="indicator-track" v-for="(item, index) in dealSlides" :key="item"
:class="{ active: index === dealCurrentIndex }"></view>
</view>
</view>
<image class="content-image" src="@/static/images/home/growth-package/plan.png" mode="widthFix"></image>
<view class="fixed-action" @tap="handlePayTap">
<image class="action-image" :src="actionImage" mode="widthFix"></image>
</view>
</view>
</template>
<script>
import request from "@/utils/request";
export default {
name: "GrowthPackage",
data() {
return {
dealCurrentIndex: 0,
isPaying: false,
isJoined: false,
dealSlides: [
"/static/images/home/growth-package/deal-1.png",
"/static/images/home/growth-package/deal-2.png",
"/static/images/home/growth-package/deal-3.png",
],
};
},
computed: {
actionImage() {
return this.isJoined
? "/static/images/home/growth-package/action-success.png"
: "/static/images/home/growth-package/action.png";
},
},
onShow() {
this.getGrowthPackageStatus();
},
methods: {
async getGrowthPackageStatus() {
if (!uni.getStorageSync("accessToken")) {
this.isJoined = false;
return;
}
if (this.isPaying) return;
uni.showLoading({
title: "查询报名状态...",
mask: true,
});
try {
const res = await request.post(
"/sj/growthPackage/status",
{},
{
hideLoading: true,
}
);
this.isJoined = !!(res && res.code === 200 && res.data && Number(res.data.is_joined) === 1);
} catch (error) {
console.log("growthPackageStatus error", error);
} finally {
uni.hideLoading();
}
},
handleDealChange(event) {
this.dealCurrentIndex = event.detail.current;
},
getDealSlideClass(index) {
const length = this.dealSlides.length;
const prevIndex = (this.dealCurrentIndex + length - 1) % length;
const nextIndex = (this.dealCurrentIndex + 1) % length;
if (index === this.dealCurrentIndex) {
return "is-active";
}
if (index === prevIndex) {
return "is-prev";
}
if (index === nextIndex) {
return "is-next";
}
return "";
},
handlePayTap() {
if (this.isPaying) return;
if (this.isJoined) return;
if (!uni.getStorageSync("accessToken")) {
uni.navigateTo({
url: "/pages/blogPopup/blogPopup",
});
return;
}
uni.showActionSheet({
itemList: ["微信支付", "支付宝支付"],
success: (res) => {
const payKind = res.tapIndex === 0 ? 2 : 3;
this.createGrowthPackagePay(payKind);
},
});
},
async createGrowthPackagePay(payKind) {
this.isPaying = true;
uni.showLoading({
title: "支付中...",
mask: true,
});
try {
const payRes = await request.post(
"/sj/growthPackage/pay",
{
pay_kind: payKind,
},
{
hideLoading: true,
}
);
if (!payRes || payRes.code !== 200) {
uni.hideLoading();
this.isPaying = false;
if (payRes && payRes.data && (payRes.data.id || payRes.data.number)) {
this.goToPayResult("fail", payRes.data);
return;
}
uni.showToast({
title: (payRes && payRes.msg) || "支付请求失败",
icon: "none",
});
return;
}
const orderInfo = payRes.data || {};
if (Number(orderInfo.is_joined) === 1) {
uni.hideLoading();
this.isPaying = false;
this.isJoined = true;
this.goToPayResult("success", orderInfo.order || {});
return;
}
const paymentParams = orderInfo.pay_params || orderInfo.orderInfo;
if (!paymentParams) {
uni.hideLoading();
this.isPaying = false;
if (orderInfo.id || orderInfo.number) {
this.goToPayResult("fail", orderInfo);
return;
}
uni.showToast({
title: "支付参数缺失",
icon: "none",
});
return;
}
uni.hideLoading();
this.requestGrowthPackagePayment(payKind, paymentParams, orderInfo);
} catch (error) {
uni.hideLoading();
uni.showToast({
title: "支付请求失败",
icon: "none",
});
this.isPaying = false;
console.log("growthPackagePay error", error);
}
},
requestGrowthPackagePayment(payKind, paymentParams, orderInfo) {
const provider = payKind === 2 ? "wxpay" : "alipay";
let payOrderInfo = paymentParams;
if (payKind === 2 && paymentParams && typeof paymentParams === "object") {
payOrderInfo = {
...paymentParams,
};
const systemInfo = uni.getSystemInfoSync();
if (systemInfo.platform === "ios" && payOrderInfo.appid) {
payOrderInfo.appId = payOrderInfo.appid;
delete payOrderInfo.appid;
}
}
uni.requestPayment({
provider,
orderInfo: payOrderInfo,
success: () => {
this.queryGrowthPackagePay(orderInfo);
},
fail: (err) => {
this.isPaying = false;
console.log("growthPackage requestPayment fail", err);
this.goToPayResult("fail", orderInfo);
},
});
},
async queryGrowthPackagePay(orderInfo) {
try {
const queryRes = await request.post(
"/sj/growthPackage/queryPay",
{
id: orderInfo.id,
number: orderInfo.number,
},
{
hideLoading: true,
}
);
const order = queryRes && queryRes.data && queryRes.data.order;
if (queryRes && queryRes.code === 200 && order && Number(order.state) === 2) {
this.isJoined = true;
this.goToPayResult("success", order);
return;
}
this.goToPayResult("fail", orderInfo);
} catch (error) {
console.log("growthPackageQueryPay error", error);
this.goToPayResult("fail", orderInfo);
} finally {
this.isPaying = false;
}
},
goToPayResult(status, orderInfo = {}) {
const params = [`status=${status}`];
if (orderInfo.number) {
params.push(`number=${encodeURIComponent(orderInfo.number)}`);
}
if (orderInfo.pay_money || orderInfo.order_money) {
params.push(`money=${encodeURIComponent(orderInfo.pay_money || orderInfo.order_money)}`);
}
uni.redirectTo({
url: `/pages/home/growth-package-result?${params.join("&")}`,
});
},
},
}
</script>
<style lang="scss">
page {
background: #150903;
}
.growth-package-page {
min-height: 100vh;
padding-bottom: 259rpx;
background: #150903;
.content-image {
display: block;
width: 750rpx;
}
.deal-carousel {
position: relative;
width: 750rpx;
height: 1342rpx;
background: #000000;
overflow: hidden;
}
.deal-swiper {
width: 750rpx;
height: 1280rpx;
background: #000000;
}
.deal-slide {
position: relative;
width: 670rpx;
height: 1280rpx;
background: #000000;
overflow: hidden;
}
.deal-slide-image {
display: block;
width: 670rpx;
height: 1280rpx;
}
.deal-slide.is-prev,
.deal-slide.is-next {
height: 1169rpx;
margin-top: 56rpx;
}
.deal-slide.is-prev .deal-slide-image,
.deal-slide.is-next .deal-slide-image {
position: absolute;
top: -56rpx;
}
.deal-slide.is-prev .deal-slide-image {
right: 10rpx;
border-top-right-radius: 20rpx;
border-bottom-right-radius: 20rpx;
}
.deal-slide.is-next .deal-slide-image {
left: 10rpx;
border-top-left-radius: 20rpx;
border-bottom-left-radius: 20rpx;
}
.deal-indicator {
display: flex;
align-items: center;
justify-content: center;
height: 62rpx;
column-gap: 8rpx;
background: #000000;
}
.indicator-track {
width: 146rpx;
height: 8rpx;
border-radius: 999rpx;
background: rgba(255, 255, 255, 0.42);
}
.indicator-track.active {
background: #ffffff;
}
.fixed-action {
position: fixed;
left: 0;
right: 0;
bottom: 0;
z-index: 20;
width: 750rpx;
height: 259rpx;
background: #150903;
}
.action-image {
display: block;
width: 750rpx;
}
}
</style>

View File

@ -20,6 +20,10 @@
</view> </view>
</view> </view>
<view class="home-banner" @tap="goToGrowthPackage">
<image class="home-banner-img" src="@/static/images/home/banner.png" mode="aspectFill"></image>
</view>
<view class="setup-modal-mask" v-if="showSetupModal" catchtouchmove="true"> <view class="setup-modal-mask" v-if="showSetupModal" catchtouchmove="true">
<view class="setup-modal-content"> <view class="setup-modal-content">
<image class="modal-bg" <image class="modal-bg"
@ -181,7 +185,7 @@
</view> </view>
</view> </view>
<view class="notice-bar card-box"> <view class="notice-bar card-box" v-if="noticeList.length > 0">
<image class="notice-icon" <image class="notice-icon"
src="https://mrrplus.oss-cn-beijing.aliyuncs.com/photo/system/75f624b8-a6ed-4787-9380-1a087062805b.png"> src="https://mrrplus.oss-cn-beijing.aliyuncs.com/photo/system/75f624b8-a6ed-4787-9380-1a087062805b.png">
</image> </image>
@ -206,6 +210,9 @@
<brand-card class="brand-card-wrap" v-for="(item, index) in brands" :key="index" :item="item" <brand-card class="brand-card-wrap" v-for="(item, index) in brands" :key="index" :item="item"
:tagKeys="item.tagKeys"></brand-card> :tagKeys="item.tagKeys"></brand-card>
</view> </view>
<view class="home-empty" v-if="brands.length === 0">
<noData top="20rpx"></noData>
</view>
</view> </view>
<view class="skills-section card-box"> <view class="skills-section card-box">
@ -219,6 +226,9 @@
<view class="skill-list"> <view class="skill-list">
<skill-card v-for="(item, index) in skills" :key="index" :item="item"></skill-card> <skill-card v-for="(item, index) in skills" :key="index" :item="item"></skill-card>
</view> </view>
<view class="home-empty" v-if="skills.length === 0">
<noData top="20rpx"></noData>
</view>
</view> </view>
<view style="height: 120rpx;"></view> <view style="height: 120rpx;"></view>
@ -260,11 +270,7 @@ export default {
displayScore: 0, displayScore: 0,
animationTimer: null, animationTimer: null,
noticeList: [{ noticeList: [],
id: 0,
title: '',
url: ''
}],
quickActions: [{ quickActions: [{
name: '扫码验券', name: '扫码验券',
@ -472,6 +478,11 @@ export default {
}); });
} }
}, },
goToGrowthPackage() {
uni.navigateTo({
url: '/pages/home/growth-package'
});
},
// //
closeSetupModal() { closeSetupModal() {
this.showSetupModal = false; this.showSetupModal = false;
@ -544,7 +555,14 @@ export default {
uni.navigateTo({ uni.navigateTo({
url: '/pages/blogPopup/blogPopup' url: '/pages/blogPopup/blogPopup'
}); });
return return;
}
if (this.brands.length === 0) {
uni.showToast({
title: '暂无数据',
icon: 'none'
});
return;
} }
uni.navigateTo({ uni.navigateTo({
url: '/pages/jingxuan/selected-brands' url: '/pages/jingxuan/selected-brands'
@ -555,7 +573,14 @@ export default {
uni.navigateTo({ uni.navigateTo({
url: '/pages/blogPopup/blogPopup' url: '/pages/blogPopup/blogPopup'
}); });
return return;
}
if (this.skills.length === 0) {
uni.showToast({
title: '暂无数据',
icon: 'none'
});
return;
} }
uni.navigateTo({ uni.navigateTo({
url: '/pages/jingxuan/selected-skills' url: '/pages/jingxuan/selected-skills'
@ -717,7 +742,11 @@ export default {
tagKeys: tags tagKeys: tags
}; };
}); });
} else {
this.brands = [];
} }
}).catch(() => {
this.brands = [];
}); });
}, },
@ -742,7 +771,11 @@ export default {
video: item.video || '' video: item.video || ''
}; };
}); });
} else {
this.skills = [];
} }
}).catch(() => {
this.skills = [];
}); });
}, },
@ -1100,7 +1133,7 @@ page {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
margin-bottom: 40rpx; margin-bottom: 24rpx;
.user-info { .user-info {
display: flex; display: flex;
@ -1203,6 +1236,23 @@ page {
} }
} }
.home-banner {
position: relative;
z-index: 1;
width: 710rpx;
height: 266rpx;
margin-left: -4rpx;
margin-bottom: 24rpx;
border-radius: 24rpx;
overflow: hidden;
.home-banner-img {
display: block;
width: 100%;
height: 100%;
}
}
.settlement-guide { .settlement-guide {
padding: 0; padding: 0;
overflow: hidden; overflow: hidden;
@ -1488,6 +1538,12 @@ page {
} }
} }
.home-empty {
height: 360rpx;
display: flex;
justify-content: center;
}
.skills-section { .skills-section {
.skill-list { .skill-list {
display: flex; display: flex;

View File

@ -181,7 +181,7 @@
</view> </view>
<view class="form-item-one box-cont"> <view class="form-item-one box-cont">
<text class="label required">行业资质</text> <text class="label">行业资质</text>
<view class="image-list"> <view class="image-list">
<view class="image-item" v-for="(img, index) in formData.qualifications_sector" :key="'industry-' + index"> <view class="image-item" v-for="(img, index) in formData.qualifications_sector" :key="'industry-' + index">
<image :src="img" mode="aspectFill" class="qualification-image"></image> <image :src="img" mode="aspectFill" class="qualification-image"></image>
@ -1080,13 +1080,6 @@ export default {
}); });
return false; return false;
} }
if (!this.formData.qualifications_sector || this.formData.qualifications_sector.length === 0) {
uni.showToast({
title: '请上传行业资质',
icon: 'none'
});
return false;
}
return true; return true;
} }
} }

View File

@ -372,7 +372,7 @@ export default {
this.formData.id = options.id; this.formData.id = options.id;
this.getInit(); this.getInit();
} else { } else {
request.post("/sj/firstclass", {}).then((res) => { request.post("/sj/firstclass", { id: uni.getStorageSync("sjId") }).then((res) => {
this.serviceTypes = this.serviceTypes.concat(res.data); this.serviceTypes = this.serviceTypes.concat(res.data);
}); });
} }
@ -539,7 +539,7 @@ export default {
this.formData.video = null; this.formData.video = null;
}, },
async getInit() { async getInit() {
const firstclass = await request.post("/sj/firstclass"); const firstclass = await request.post("/sj/firstclass", { id: uni.getStorageSync("sjId") });
this.serviceTypes = this.serviceTypes.concat(firstclass.data); this.serviceTypes = this.serviceTypes.concat(firstclass.data);
await request await request

View File

@ -225,7 +225,7 @@
</view> </view>
<view class="form-item-image-box box-cont"> <view class="form-item-image-box box-cont">
<text class="label required">行业资质</text> <text class="label">行业资质</text>
<view class="image-list"> <view class="image-list">
<view class="image-item" v-for="(img, index) in displayData.qualifications_sector" <view class="image-item" v-for="(img, index) in displayData.qualifications_sector"
:key="'industry-' + index"> :key="'industry-' + index">

View File

@ -331,7 +331,47 @@
} catch (e) {} } catch (e) {}
}, },
// //
pickFirst(data, fields) {
for (const field of fields) {
const value = data && data[field];
if (value !== undefined && value !== null && String(value).trim() !== '') {
return value;
}
}
return '';
},
normalizeStoreInfo(data = {}) {
return {
head_photo: this.pickFirst(data, ['head_photo', 'shop_head_photo']),
name: this.pickFirst(data, ['name', 'shop_name']),
dependency: this.pickFirst(data, ['dependency', 'shop_dependency', 'uscc_dependency']),
address: this.pickFirst(data, ['address', 'shop_address', 'uscc_address']),
dependency_code: this.pickFirst(data, ['dependency_code', 'shop_dependency_code', 'uscc_area']),
dependency_province: this.pickFirst(data, ['dependency_province', 'shop_dependency_province', 'uscc_province']),
dependency_city: this.pickFirst(data, ['dependency_city', 'shop_dependency_city', 'uscc_city']),
longitude: this.pickFirst(data, ['longitude', 'shop_longitude']),
latitude: this.pickFirst(data, ['latitude', 'shop_latitude'])
};
},
mergeStoreInfoWithOriginal(data = {}) {
const storeInfo = this.normalizeStoreInfo(data);
return {
head_photo: storeInfo.head_photo || this.originalData.head_photo,
name: storeInfo.name || this.originalData.name,
dependency: storeInfo.dependency || this.originalData.dependency,
address: storeInfo.address || this.originalData.address,
dependency_code: storeInfo.dependency_code || this.originalData.dependency_code,
dependency_province: storeInfo.dependency_province || this.originalData.dependency_province,
dependency_city: storeInfo.dependency_city || this.originalData.dependency_city,
longitude: storeInfo.longitude || this.originalData.longitude,
latitude: storeInfo.latitude || this.originalData.latitude
};
},
//
getUserInfo() { getUserInfo() {
console.log('开始获取用户信息...'); console.log('开始获取用户信息...');
const type = 3; const type = 3;
@ -347,23 +387,13 @@
this.userId = userData.id; this.userId = userData.id;
this.originalData = { this.originalData = this.normalizeStoreInfo(userData);
head_photo: userData.head_photo || '',
name: userData.name || '',
dependency: userData.dependency || '',
address: userData.address || '',
dependency_code: userData.dependency_code || '',
dependency_province: userData.dependency_province || '',
dependency_city: userData.dependency_city || '',
longitude: userData.longitude || '',
latitude: userData.latitude || ''
};
this.dependency_code = userData.dependency_code || ''; this.dependency_code = this.originalData.dependency_code || '';
this.dependency_province = userData.dependency_province || ''; this.dependency_province = this.originalData.dependency_province || '';
this.dependency_city = userData.dependency_city || ''; this.dependency_city = this.originalData.dependency_city || '';
this.longitude = userData.longitude || ''; this.longitude = this.originalData.longitude || '';
this.latitude = userData.latitude || ''; this.latitude = this.originalData.latitude || '';
this.pendingData = { this.pendingData = {
...this.originalData ...this.originalData
@ -444,18 +474,7 @@
} }
if (this.auditStatus === 1 || this.auditStatus === 3) { if (this.auditStatus === 1 || this.auditStatus === 3) {
this.pendingData = { this.pendingData = this.mergeStoreInfoWithOriginal(detail);
head_photo: detail.head_photo || this.originalData.head_photo,
name: detail.name || this.originalData.name,
dependency: detail.dependency || this.originalData.dependency,
address: detail.address || this.originalData.address,
dependency_code: detail.dependency_code || this.originalData.dependency_code,
dependency_province: detail.dependency_province || this.originalData
.dependency_province,
dependency_city: detail.dependency_city || this.originalData.dependency_city,
longitude: detail.longitude || this.originalData.longitude,
latitude: detail.latitude || this.originalData.latitude
};
} }
if (this.auditStatus === 2) { if (this.auditStatus === 2) {

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 486 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 509 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 MiB

1
utils/appBackBase.js Normal file
View File

@ -0,0 +1 @@
export const APP_BACK_BASE_URL = "http://test.mrrwlkj.top";

View File

@ -120,14 +120,14 @@ const request = async (options, isUpdate) => {
if (process.env.NODE_ENV === "development") { if (process.env.NODE_ENV === "development") {
baseURL = url; // 发布到生产环境时,此处代码会被摇树移除掉。 baseURL = url; // 发布到生产环境时,此处代码会被摇树移除掉。
baseURL = "http://test.mrrwlkj.top"; // 发布到生产环境时,此处代码会被摇树移除掉。 // baseURL = "http://test.mrrwlkj.top"; // 发布到生产环境时,此处代码会被摇树移除掉。
// baseURL = 'http://dev.mrrwlkj.top'; // 发布到生产环境时,此处代码会被摇树移除掉。 // baseURL = 'http://dev.mrrwlkj.top'; // 发布到生产环境时,此处代码会被摇树移除掉。
// baseURL = "https://app.mrrweb.com.cn"; baseURL = "https://app.mrrweb.com.cn";
} else { } else {
baseURL = url; // 发布到生产环境时,此处代码会被摇树移除掉。 baseURL = url; // 发布到生产环境时,此处代码会被摇树移除掉。
baseURL = "http://test.mrrwlkj.top"; // 发布到生产环境时,此处代码会被摇树移除掉。 // baseURL = "http://test.mrrwlkj.top"; // 发布到生产环境时,此处代码会被摇树移除掉。
// baseURL = 'http://dev.mrrwlkj.top'; // 发布到生产环境时,此处代码会被摇树移除掉。 // baseURL = 'http://dev.mrrwlkj.top'; // 发布到生产环境时,此处代码会被摇树移除掉。
// baseURL = "https://app.mrrweb.com.cn"; baseURL = "https://app.mrrweb.com.cn";
console.log("生产环境"); console.log("生产环境");
} }

View File

@ -1,4 +1,6 @@
import { APP_BACK_BASE_URL } from './appBackBase.js'
let VersionCode = ''; let VersionCode = '';
let DeviceType = ''; let DeviceType = '';
let platform = ''; let platform = '';
@ -60,30 +62,6 @@ export function setVersion() {
} }
export async function getBaseUrl() { export async function getBaseUrl() {
let version = uni.getStorageSync('setVersion') uni.setStorageSync('baseUrl', APP_BACK_BASE_URL)
await uni.request({ return APP_BACK_BASE_URL
url: 'https://api.mrrwlkj.top/api/openPuc/getSjApiUrl', // 接口地址
method: 'GET', // 请求方法(默认 GET
header: {
'Content-Type': 'application/json', // 请求头
'VersionCode': version.VersionCode,
'DeviceBrand': version.DeviceBrand,
'DeviceType': version.DeviceType
},
success: (res) => {
if (res.data.code == 200) {
uni.setStorageSync('baseUrl', res.data.data.url)
// store.commit('setBaseUrl', res.data.data.url)
}
return res.data.data.url;
console.log('请求成功', res.data);
},
fail: (err) => {
console.log('请求失败', err);
return 'http://60.247.146.5:93';
},
complete: () => {
console.log('请求完成(无论成功失败都会执行)');
}
});
} }