修复分享链接错误,修复在线预览按钮(同步更新)。尝试优化缩略图。

This commit is contained in:
chuzhongzai
2023-02-19 22:36:35 +08:00
parent 8ab862093b
commit b1bd4d8a34
2 changed files with 7 additions and 8 deletions
+2 -3
View File
@@ -314,8 +314,7 @@ function shareGallery(data){
axios.post("http://downloader.lionwebsite.xyz/GalleryManage/share?userId=3&expireHour=3&gid=" + gid).then((res) => {
if(res.data.result === "success"){
let data = JSON.parse(res.data.data)
link = 'http://lionwebsite.xyz/GetFile/{1}?ShareCode={2}'.replace("{1}", shortName).replace("{2}", data.shareCode)
console.log(data)
link = 'http://lionwebsite.xyz/GetFile/{0}?ShareCode={1}'.replace('{0}', encodeURIComponent(shortName)).replace('{1}', data.shareCode)
ElMessage({dangerouslyUseHTMLString: true,
message: "<span>分享成功, 过期时间:" + data.expireTime + "</span><br><a href=" + link + ">链接</a>",
duration: 0,
@@ -330,7 +329,7 @@ function shareGallery(data){
//显示缩略图
function showThumbnail(gallery){
if(gallery.download !== undefined)
if(gallery.download !== undefined && gallery.status === "下载完成")
clearTimeout(debounceTimer)
debounceTimer = setTimeout(() => {
store.commit("_changeThumbnailGallery", gallery)