fix kkFile预览提出公共方法,加水印

This commit is contained in:
赵霄
2024-01-02 14:39:35 +08:00
parent d930b8b79c
commit f193b3f528
6 changed files with 29 additions and 10 deletions
@@ -139,6 +139,7 @@ import { ACCESS_TOKEN } from '../../../store/mutation-types.js'
import { downloadFile, getFileAccessHttpUrl } from '../../../api/manage.js'
import { previewPdf } from '../../../utils/previewPdf.js'
import { Base64 } from 'js-base64'
import { kkFilePreview } from '../../../utils/kkFilePreview'
// 国内标准权限
const DomesticStandardPermission = {
@@ -396,8 +397,7 @@ export default {
return
}
// 其余可预览文件仍使用KKFile进行预览
const url = `${window._CONFIG.onlinePreviewDomainURL}?url=${encodeURIComponent(Base64.encode(fileFullUrl))}`
window.open(url)
kkFilePreview(fileFullUrl)
},
/**
* 无水印下载