Commit 951fbef2 authored by Damon's avatar Damon

fix: 相册不授权处理

parent ae4c5cc8
...@@ -75,26 +75,30 @@ ...@@ -75,26 +75,30 @@
if(photo.tempPath.origin && photo?.waterSetting?.hasOrigin){ if(photo.tempPath.origin && photo?.waterSetting?.hasOrigin){
// 保存原图到本地 // 保存原图到本地
path = photo.tempPath.origin path = photo.tempPath.origin
let result = await this.saveLocal(path) this.saveLocal(path).then(res => {
if(result){
uni.showToast({ uni.showToast({
icon: 'none', icon: 'none',
title: '已将照片原图保存到本地相册' title: '已将照片原图保存到本地相册'
}) })
} })
} }
if(photo.tempPath.mixWater){ if(photo.tempPath.mixWater){
// 保存水印处理图片到本地 // 保存水印处理图片到本地
path = photo.tempPath.mixWater path = photo.tempPath.mixWater
let result1 = await this.saveLocal(path) this.saveLocal(path).then(res => {
if(result1){
uni.showToast({ uni.showToast({
icon: 'none', icon: 'none',
title: '已将水印图片保存到本地相册' title: '已将水印图片保存到本地相册'
}) })
resolve() resolve()
} }).catch(e => {
uni.showToast({
icon: 'none',
title: e
})
resolve()
})
} }
}) })
}, },
...@@ -105,7 +109,7 @@ ...@@ -105,7 +109,7 @@
success() { success() {
resolve(true) resolve(true)
}, },
fail() { fail(e) {
reject('保存失败') reject('保存失败')
} }
}) })
......
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