解决了iPhone背景图片发白的问题
This commit is contained in:
parent
aabda4cca2
commit
939b49072c
App.vue
common
manifest.jsonpages
Shopping-cart/productmain
home
mine/main
store-home/main
subPack/book/myPhotoProductsOrderDetail
1
App.vue
1
App.vue
|
@ -6,7 +6,6 @@
|
|||
import { onLaunch } from '@dcloudio/uni-app'
|
||||
import { reactive } from 'vue'
|
||||
//小程序加载的时候调用该方法
|
||||
const globalData = reactive({});
|
||||
onLaunch( async ()=>{
|
||||
if (!wx.cloud) {
|
||||
console.error('请使用 2.2.3 或以上的基础库以使用云能力');
|
||||
|
|
|
@ -26,7 +26,6 @@ text {
|
|||
width: 100vw;
|
||||
height: 100vh;
|
||||
}
|
||||
|
||||
.flex-row {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
|
|
|
@ -1,39 +1,40 @@
|
|||
import { bkgPubilcPath,loginUrl } from "./globalImagesUrl";
|
||||
import { ref } from 'vue';
|
||||
const bkgUrl = ref(loginUrl + '/bkg.png')
|
||||
// const bkgUrl = ref('https://www.carboner.cn:8888/api/file/downloadFile?objectKey=feiyi/miniProgram/login/bkg.png')
|
||||
//缓存背景图片
|
||||
const bkgCache = 'bkgCache'; //缓存的键
|
||||
// const bkgCache = 'bkgCache'; //缓存的键
|
||||
|
||||
|
||||
export const getFonts =()=>{ //改为查询背景图片
|
||||
wx.getStorage({
|
||||
key: bkgCache,
|
||||
success: (res) => {
|
||||
// console.log('缓存图片的路径--->',res.data);
|
||||
bkgPubilcPath.value = res.data
|
||||
},
|
||||
fail: ()=> {
|
||||
wx.downloadFile({
|
||||
url: bkgUrl.value,
|
||||
success: (res) => {
|
||||
console.log('成功res--->',res);
|
||||
if(res.statusCode === 200) {
|
||||
const filePath = res.tempFilePath;
|
||||
wx.setStorage({
|
||||
key: bkgCache,
|
||||
data: filePath
|
||||
});
|
||||
// console.log('图片下载并缓存成功,本地路径--->',filePath);
|
||||
bkgPubilcPath.value= filePath
|
||||
} else {
|
||||
console.log('图片下载失败');
|
||||
}
|
||||
},
|
||||
fail: (err) => {
|
||||
console.log('下载失败',err);
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
// wx.getStorage({
|
||||
// key: bkgCache,
|
||||
// success: (res) => {
|
||||
// console.log('缓存图片的路径--->',res.data);
|
||||
// bkgPubilcPath.value = res.data
|
||||
// },
|
||||
// fail: ()=> {
|
||||
// wx.downloadFile({
|
||||
// url: 'https://www.carboner.cn:8888/api/file/downloadFile?objectKey=feiyi/miniProgram/login/bkg.png',
|
||||
// success: (res) => {
|
||||
// console.log('成功res--->',res);
|
||||
// if(res.statusCode === 200) {
|
||||
// const filePath = res.tempFilePath;
|
||||
// wx.setStorage({
|
||||
// key: bkgCache,
|
||||
// data: filePath
|
||||
// });
|
||||
// console.log('图片下载并缓存成功,本地路径--->',filePath);
|
||||
// bkgPubilcPath.value= filePath
|
||||
// } else {
|
||||
// console.log('图片下载失败');
|
||||
// }
|
||||
// },
|
||||
// fail: (err) => {
|
||||
// console.log('下载失败',err);
|
||||
// }
|
||||
// })
|
||||
// }
|
||||
// })
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -16,4 +16,4 @@ export const storeHomeUrl = publicPath + subPath + '/store-home'
|
|||
export const mineUrl = publicPath + subPath + '/mine'
|
||||
export const clothesRentUrl = publicPath + subPath + '/clothesRent'
|
||||
|
||||
export const bkgPubilcPath = ref('')
|
||||
export const bkgPubilcPath = ref('https://www.carboner.cn:8888/api/file/downloadFile?objectKey=feiyi/miniProgram/login/bkg.png')
|
|
@ -53,8 +53,8 @@
|
|||
"appid" : "wx61b63e27bddf4ea2",
|
||||
"setting" : {
|
||||
"urlCheck" : false,
|
||||
"minified" : true,
|
||||
"es6" : false,
|
||||
"minified" : false,
|
||||
"es6" : true,
|
||||
"postcss" : true
|
||||
},
|
||||
"usingComponents" : true,
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -7,7 +7,8 @@
|
|||
<view class="flex-col group">
|
||||
<view class="flex-row items-center group_2">
|
||||
<button class="avatar_button" open-type="chooseAvatar" @chooseavatar="onChooseAvatar" >
|
||||
<image class="avatar_son" mode="aspectFill" :src="publicPath + myAvatar" />
|
||||
<image v-if="nickName === '未登录'" class="avatar_son" mode="aspectFill" :src="myAvatar" />
|
||||
<image v-if="nickName !== '未登录'" class="avatar_son" mode="aspectFill" :src="publicPath + myAvatar" />
|
||||
</button>
|
||||
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -150,6 +150,7 @@
|
|||
id: val
|
||||
}
|
||||
})
|
||||
console.log('订单信息--->',res.data.data);
|
||||
order.value = res.data.data
|
||||
orderStatusObj.value = photoOrderMap.get(res.data.data.orderStatus)
|
||||
console.log('orderStatusObj--->',orderStatusObj.value);
|
||||
|
@ -158,7 +159,7 @@
|
|||
} else if (order.value.orderStatus === '待发货') {
|
||||
order.value.operationList = [false, false, true]
|
||||
} else if (order.value.orderStatus === '已退款') {
|
||||
order.value.operationList = [false, false, true]
|
||||
order.value.operationList = [false, true, false]
|
||||
} else if (order.value.orderStatus === '交易成功') {
|
||||
order.value.operationList = [false, false, true]
|
||||
} else if (order.value.orderStatus === '交易关闭') {
|
||||
|
|
Loading…
Reference in New Issue
Block a user