fix
This commit is contained in:
@@ -18,16 +18,19 @@
|
|||||||
const {t:$t} = useI18n()
|
const {t:$t} = useI18n()
|
||||||
const open = async (options) => {
|
const open = async (options) => {
|
||||||
let json = []
|
let json = []
|
||||||
|
let isGetJson = false
|
||||||
await new Promise((resolve) => {
|
await new Promise((resolve) => {
|
||||||
getSketchFlowCanvas({ id: options.imgId },true).then((res:any) => {
|
getSketchFlowCanvas({ id: options.imgId },true).then((res:any) => {
|
||||||
if (res) {
|
if (res) {
|
||||||
json = JSON.parse(res)
|
json = JSON.parse(res)
|
||||||
}
|
}
|
||||||
|
isGetJson = true
|
||||||
resolve(true)
|
resolve(true)
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
resolve(true)
|
resolve(false)
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
if(!isGetJson)return
|
||||||
config.value = options || {}
|
config.value = options || {}
|
||||||
config.value.json = json
|
config.value.json = json
|
||||||
dialogVisible.value = true
|
dialogVisible.value = true
|
||||||
|
|||||||
Reference in New Issue
Block a user