多个bug修改
This commit is contained in:
parent
e4b7646da9
commit
35dca559d3
|
|
@ -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"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
"apps": [],
|
"apps": [],
|
||||||
"details": [
|
"details": [
|
||||||
{
|
{
|
||||||
"appID": "wx5b1c0c8d01ded35d",
|
"appID": "wx17eef65c270b4869",
|
||||||
"paths": ["*"]
|
"paths": ["*"]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -107,7 +107,7 @@
|
||||||
"payment" : {
|
"payment" : {
|
||||||
"weixin" : {
|
"weixin" : {
|
||||||
"__platform__" : [ "ios", "android" ],
|
"__platform__" : [ "ios", "android" ],
|
||||||
"appid" : "wx2381a791a52a402d",
|
"appid" : "wx17eef65c270b4869",
|
||||||
"UniversalLinks" : "https://app.mrrweb.com.cn/"
|
"UniversalLinks" : "https://app.mrrweb.com.cn/"
|
||||||
},
|
},
|
||||||
"appleiap" : {},
|
"appleiap" : {},
|
||||||
|
|
@ -117,7 +117,7 @@
|
||||||
},
|
},
|
||||||
"share" : {
|
"share" : {
|
||||||
"weixin" : {
|
"weixin" : {
|
||||||
"appid" : "wx2381a791a52a402d",
|
"appid" : "wx17eef65c270b4869",
|
||||||
"UniversalLinks" : "https://app.mrrweb.com.cn/"
|
"UniversalLinks" : "https://app.mrrweb.com.cn/"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
@ -134,7 +134,7 @@
|
||||||
},
|
},
|
||||||
"oauth" : {
|
"oauth" : {
|
||||||
"weixin" : {
|
"weixin" : {
|
||||||
"appid" : "wx2381a791a52a402d",
|
"appid" : "wx17eef65c270b4869",
|
||||||
"UniversalLinks" : "https://app.mrrweb.com.cn/"
|
"UniversalLinks" : "https://app.mrrweb.com.cn/"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -197,7 +197,7 @@
|
||||||
"quickapp" : {},
|
"quickapp" : {},
|
||||||
/* 小程序特有相关 */
|
/* 小程序特有相关 */
|
||||||
"mp-weixin" : {
|
"mp-weixin" : {
|
||||||
"appid" : "wxb486b10a60d2c78d",
|
"appid" : "wx17eef65c270b4869",
|
||||||
"privacy" : {
|
"privacy" : {
|
||||||
"requiredPrivateInfos" : [ "getBackgroundFetchData" ]
|
"requiredPrivateInfos" : [ "getBackgroundFetchData" ]
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -868,6 +868,16 @@
|
||||||
} else {
|
} else {
|
||||||
url = "/user/serverupdate";
|
url = "/user/serverupdate";
|
||||||
}
|
}
|
||||||
|
console.log(this.formData, '-0-0-0-0-0-');
|
||||||
|
delete this.formData.shop_business_time
|
||||||
|
delete this.formData.shop_head_photo
|
||||||
|
delete this.formData.shop_address
|
||||||
|
delete this.formData.shop_dependency
|
||||||
|
delete this.formData.shop_class
|
||||||
|
delete this.formData.team_buy
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
request.post(url, this.formData).then((res) => {
|
request.post(url, this.formData).then((res) => {
|
||||||
if (res.state == 1) {
|
if (res.state == 1) {
|
||||||
const pages = getCurrentPages();
|
const pages = getCurrentPages();
|
||||||
|
|
|
||||||
|
|
@ -226,10 +226,11 @@
|
||||||
console.log("wechatpayfor", wechatpayfor);
|
console.log("wechatpayfor", wechatpayfor);
|
||||||
const systemInfo = uni.getSystemInfoSync();
|
const systemInfo = uni.getSystemInfoSync();
|
||||||
if (systemInfo.platform === "ios") {
|
if (systemInfo.platform === "ios") {
|
||||||
let appId = wechatpayfor.data.appid;
|
let appId = wechatpayfor.data.appId;
|
||||||
delete wechatpayfor.data.appid;
|
// delete wechatpayfor.data.appid;
|
||||||
wechatpayfor.data["appId"] = appId;
|
wechatpayfor.data["appId"] = appId;
|
||||||
console.log("wechatpayfor2", wechatpayfor);
|
console.log("wechatpayfor2", wechatpayfor);
|
||||||
|
console.log(that.orderInfo, 'that.orderInfothat.orderInfo');
|
||||||
}
|
}
|
||||||
console.log("================================");
|
console.log("================================");
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
|
|
@ -267,6 +268,7 @@
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
fail: function(err) {
|
fail: function(err) {
|
||||||
|
console.log(err,'erererererer');
|
||||||
uni.showModal({
|
uni.showModal({
|
||||||
title: "提示",
|
title: "提示",
|
||||||
content: "该订单未成功支付",
|
content: "该订单未成功支付",
|
||||||
|
|
@ -545,7 +547,7 @@
|
||||||
.pay-btn {
|
.pay-btn {
|
||||||
width: 680rpx;
|
width: 680rpx;
|
||||||
height: 88rpx;
|
height: 88rpx;
|
||||||
background: linear-gradient( 180deg, #F52540 0%, #E8101E 100%);
|
background: linear-gradient(180deg, #F52540 0%, #E8101E 100%);
|
||||||
border-radius: 43rpx;
|
border-radius: 43rpx;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
font-size: 30rpx;
|
font-size: 30rpx;
|
||||||
|
|
|
||||||
|
|
@ -369,6 +369,7 @@
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title: '上传中'
|
title: '上传中'
|
||||||
})
|
})
|
||||||
|
console.log(this.formData,'=============================');
|
||||||
if (this.formData.type == 1) {
|
if (this.formData.type == 1) {
|
||||||
res = await uploadImage.handleUpload(this.userInfo.id, 3);
|
res = await uploadImage.handleUpload(this.userInfo.id, 3);
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
|
|
@ -9,13 +9,14 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="titles-right">
|
<view class="titles-right">
|
||||||
<text class="titles-text">展示位置及拍摄技巧</text>
|
<text class="titles-text">展示位置及拍摄技巧</text>
|
||||||
|
<image src="https://mrrplus.oss-cn-beijing.aliyuncs.com/photo/system/b153e8d5-37b1-4205-a4a1-9f6603f30c2a.png" mode="widthFix" style="width: 24rpx;margin-top: 2rpx;margin-left: 6rpx;"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="container-card" v-for="(item,index) in cardList[type]" :key="index">
|
<view class="container-card" v-for="(item,index) in cardList[type]" :key="index">
|
||||||
<view class="card-header flex-row-center-between">
|
<view class="card-header flex-row-center-between">
|
||||||
<text class="card-title">{{ item.title }}</text>
|
<text class="card-title">{{ item.title }}</text>
|
||||||
<view class="card-header-right" @click="goList(item.id)">
|
<view class="card-header-right" @click="goList(item.id)">
|
||||||
<text class="card-header-right-text">查看详情</text>
|
<text class="card-header-right-text">查看全部</text>
|
||||||
<image class="card-header-right-img" src="/static/images/icons/right_gray14.png"></image>
|
<image class="card-header-right-img" src="/static/images/icons/right_gray14.png"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -142,6 +143,7 @@
|
||||||
return obj
|
return obj
|
||||||
},
|
},
|
||||||
goList(id) {
|
goList(id) {
|
||||||
|
console.log(id,'ididididididi');
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/shop/photoAlbum/videoList?id=${id}&type=${this.type}`
|
url: `/pages/shop/photoAlbum/videoList?id=${id}&type=${this.type}`
|
||||||
});
|
});
|
||||||
|
|
@ -156,7 +158,7 @@
|
||||||
},
|
},
|
||||||
goAdd(id, item) {
|
goAdd(id, item) {
|
||||||
if (this.type == 1) {
|
if (this.type == 1) {
|
||||||
if ( this.imgVideoList[id] && this.imgVideoList[id].length >= 20) {
|
if ( this.imgVideoList[id] && this.imgVideoList[id].length >= 21) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '最多上传20张图片',
|
title: '最多上传20张图片',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
|
|
@ -255,6 +257,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.titles-right {
|
.titles-right {
|
||||||
|
display: flex;
|
||||||
.titles-text {
|
.titles-text {
|
||||||
font-family: PingFangSC, PingFang SC;
|
font-family: PingFangSC, PingFang SC;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<view class="container">
|
<view class="container">
|
||||||
<custom-navbar title="店铺图片" :leftImg="'/static/images/back.png'" :showUser="true" backgroundColor="#fff"
|
<custom-navbar :title="pagestitle" :leftImg="'/static/images/back.png'" :showUser="true" backgroundColor="#fff"
|
||||||
titleColor="#000" borderBottom="none">
|
titleColor="#000" borderBottom="none">
|
||||||
<template #right>
|
<template #right>
|
||||||
<text class="custom-right" @click="toggleManage">{{ isManage ? '取消' : '管理' }}</text>
|
<text class="custom-right" @click="toggleManage">{{ isManage ? '取消' : '管理' }}</text>
|
||||||
|
|
@ -8,13 +8,13 @@
|
||||||
</custom-navbar>
|
</custom-navbar>
|
||||||
<view class="review">
|
<view class="review">
|
||||||
<view class="review-title">
|
<view class="review-title">
|
||||||
<text class="review-title-text">添加环境图片,吸引更多顾客到店消费</text>
|
<text class="review-title-text">添加{{pagestitle}},吸引更多顾客到店消费</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="container-card">
|
<view class="container-card">
|
||||||
|
|
||||||
<view class="card-content flex-row-center" v-if="type==1">
|
<view class="card-content flex-row-center" v-if="type==1">
|
||||||
<view class="card-content-page">{{ imgVideoList.length }}/20张</view>
|
<view class="card-content-page" v-if="class_type!=1">{{ imgVideoList.length }}/20张</view>
|
||||||
<view class="content-default" @click="goAdd(class_type)"
|
<view class="content-default" @click="goAdd(class_type)"
|
||||||
v-if="!(class_type == 1 && imgVideoList && imgVideoList.length)">
|
v-if="!(class_type == 1 && imgVideoList && imgVideoList.length)">
|
||||||
<image class="content-default-img" src="/static/images/icons/addPhoto.png"></image>
|
<image class="content-default-img" src="/static/images/icons/addPhoto.png"></image>
|
||||||
|
|
@ -84,18 +84,29 @@
|
||||||
type: 2, //1图片 2视频
|
type: 2, //1图片 2视频
|
||||||
class_type: 4, //1主(图片/视频) 2环境(图片/视频) 3作品(图片/视频) 4其它(图片/视频)
|
class_type: 4, //1主(图片/视频) 2环境(图片/视频) 3作品(图片/视频) 4其它(图片/视频)
|
||||||
isManage: false, // 管理模式状态
|
isManage: false, // 管理模式状态
|
||||||
selectedItems: [] // 选中的项索引数组
|
selectedItems: [], // 选中的项索引数组
|
||||||
|
pagestitle: "店铺图片"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
async onShow() {
|
async onShow() {
|
||||||
await this.getList()
|
await this.getList()
|
||||||
},
|
},
|
||||||
async onLoad(options) {
|
async onLoad(options) {
|
||||||
|
console.log(options, '查看option');
|
||||||
if (options.type) {
|
if (options.type) {
|
||||||
this.type = options.type
|
this.type = options.type
|
||||||
}
|
}
|
||||||
if (options.id) {
|
if (options.id) {
|
||||||
this.class_type = options.id
|
this.class_type = options.id
|
||||||
|
if (this.class_type == 2) {
|
||||||
|
this.pagestitle = "环境图片"
|
||||||
|
} else if (this.class_type == 3) {
|
||||||
|
this.pagestitle = "作品图片"
|
||||||
|
} else if (this.class_type == 4) {
|
||||||
|
this.pagestitle = "其它图片"
|
||||||
|
} else {
|
||||||
|
this.pagestitle = "店铺图片"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
@ -210,8 +221,7 @@
|
||||||
});
|
});
|
||||||
// 核心修复:逐层可选链保护 + 兜底空数组,彻底避免属性访问错误
|
// 核心修复:逐层可选链保护 + 兜底空数组,彻底避免属性访问错误
|
||||||
this.imgVideoList = res.code === 200 ?
|
this.imgVideoList = res.code === 200 ?
|
||||||
res.data?.list?.[this.type]?.[this.class_type] || [] :
|
res.data?.list?.[this.type]?.[this.class_type] || [] : [];
|
||||||
[];
|
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
// 网络错误、接口报错等所有异常的兜底处理
|
// 网络错误、接口报错等所有异常的兜底处理
|
||||||
console.error("获取媒体列表失败:", err);
|
console.error("获取媒体列表失败:", err);
|
||||||
|
|
|
||||||
|
|
@ -173,7 +173,7 @@ const uploadFile = async (file, userId, type, uploadType) => {
|
||||||
let imageType;
|
let imageType;
|
||||||
if (uploadType == 'image') {
|
if (uploadType == 'image') {
|
||||||
//imageType = file.path.split('.')
|
//imageType = file.path.split('.')
|
||||||
imageType = file.name.split('.')
|
imageType = file.path.split('.')
|
||||||
} else if (uploadType == 'video') {
|
} else if (uploadType == 'video') {
|
||||||
// #ifdef H5
|
// #ifdef H5
|
||||||
imageType = file.name.split('.')
|
imageType = file.name.split('.')
|
||||||
|
|
@ -252,7 +252,9 @@ const uploadToOss = (file, ossConfig, name, uploadType) => {
|
||||||
if (uploadType == 'image') {
|
if (uploadType == 'image') {
|
||||||
path = file.path
|
path = file.path
|
||||||
// 获取文件扩展名并设置 Content-Type
|
// 获取文件扩展名并设置 Content-Type
|
||||||
|
console.log('111111');
|
||||||
const ext = file.path.split('.').pop().toLowerCase()
|
const ext = file.path.split('.').pop().toLowerCase()
|
||||||
|
console.log('33333333');
|
||||||
const mimeTypes = {
|
const mimeTypes = {
|
||||||
jpg: 'image/jpeg',
|
jpg: 'image/jpeg',
|
||||||
jpeg: 'image/jpeg',
|
jpeg: 'image/jpeg',
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue