|
|
|
@ -136,22 +136,16 @@ |
|
|
|
|
fileId:item.fileId |
|
|
|
|
},function(res) { |
|
|
|
|
if(res.code==='200'){ |
|
|
|
|
fetch(`${that.GLOBAL.server_address}${res.msg}`).then(res=>res.text()).then(res=>{ |
|
|
|
|
item.content=res |
|
|
|
|
loadingInstance.close() |
|
|
|
|
that.$store.commit('menus/read') |
|
|
|
|
that.$store.commit('read/open', item) |
|
|
|
|
that.$router.push(that.localePath('/read')) |
|
|
|
|
}).catch(err=>{ |
|
|
|
|
console.error(err) |
|
|
|
|
loadingInstance.close() |
|
|
|
|
}) |
|
|
|
|
}else{ |
|
|
|
|
item.content=res.msg |
|
|
|
|
that.$store.commit('menus/read') |
|
|
|
|
that.$store.commit('read/open', item) |
|
|
|
|
that.$router.push(that.localePath('/read')) |
|
|
|
|
loadingInstance.close() |
|
|
|
|
}else{ |
|
|
|
|
that.$message.error(that.$t('error_500').toString()) |
|
|
|
|
} |
|
|
|
|
loadingInstance.close() |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
query(){ |
|
|
|
|
let that=this |
|
|
|
|