Merge branch 'main' into secondStage
# Conflicts: # src/views/dashboard/Analysis.vue # src/views/dashboard/modules/FriendLinkCard.vue # src/views/dashboard/modules/QuickEnterCard.vue # src/views/dashboard/modules/SearchAndWarningCard.vue # src/views/dashboard/modules/ToDoTaskCard.vue
This commit is contained in:
+1
-1
@@ -203,7 +203,7 @@ export function getFileAccessHttpUrl (avatar, subStr) {
|
|||||||
} else {
|
} else {
|
||||||
if (avatar && avatar.length > 0 && avatar.indexOf('[') === -1) {
|
if (avatar && avatar.length > 0 && avatar.indexOf('[') === -1) {
|
||||||
const token = Vue.ls.get(ACCESS_TOKEN)
|
const token = Vue.ls.get(ACCESS_TOKEN)
|
||||||
return window._CONFIG.staticDomainURL + '/' + avatar + '?token=' + token
|
return window._CONFIG.domianURL + '/sys/common/view' + '/' + avatar + '?token=' + token
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(file.id)
|
this.imageUrl = getFileAccessHttpUrl(file.id)
|
||||||
|
|||||||
@@ -286,7 +286,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(file.id)
|
this.imageUrl = getFileAccessHttpUrl(file.id)
|
||||||
|
|||||||
@@ -308,7 +308,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.response.result.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.name}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.response.result.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.name}`
|
||||||
console.log(fileSuffix)
|
console.log(fileSuffix)
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
||||||
|
|||||||
@@ -440,7 +440,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.response.result.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.name}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.response.result.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.name}`
|
||||||
console.log(fileSuffix)
|
console.log(fileSuffix)
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ const getToken = () => Vue.ls.get(ACCESS_TOKEN)
|
|||||||
|
|
||||||
// 预览pdf
|
// 预览pdf
|
||||||
const previewPdf = (id) => {
|
const previewPdf = (id) => {
|
||||||
const url = `${window._CONFIG.domianURL}/sys/common/download/${id}?type=view&token=${getToken()}`
|
const url = `${window._CONFIG.domianURL}/sys/common/view/${id}?type=view&token=${getToken()}`
|
||||||
return `${process.env.BASE_URL}pdfjs/web/viewer.html?file=` + encodeURIComponent(url) + '&.pdf'
|
return `${process.env.BASE_URL}pdfjs/web/viewer.html?file=` + encodeURIComponent(url) + '&.pdf'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -223,7 +223,7 @@ export default {
|
|||||||
handleAttachClick (record) {
|
handleAttachClick (record) {
|
||||||
// 截取文件后缀名
|
// 截取文件后缀名
|
||||||
const fileSuffix = record.declareFileName ? record.declareFileName.split('.')[record.declareFileName.split('.').length - 1] : ''
|
const fileSuffix = record.declareFileName ? record.declareFileName.split('.')[record.declareFileName.split('.').length - 1] : ''
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${record.declareFile}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.declareFileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${record.declareFile}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.declareFileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(record.declareFile)
|
this.imageUrl = getFileAccessHttpUrl(record.declareFile)
|
||||||
|
|||||||
@@ -211,7 +211,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(file.id)
|
this.imageUrl = getFileAccessHttpUrl(file.id)
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ export default {
|
|||||||
handleRelatedMaterialClick (record) {
|
handleRelatedMaterialClick (record) {
|
||||||
// 截取文件后缀名
|
// 截取文件后缀名
|
||||||
const fileSuffix = record.declareFileName ? record.declareFileName.split('.')[record.declareFileName.split('.').length - 1] : ''
|
const fileSuffix = record.declareFileName ? record.declareFileName.split('.')[record.declareFileName.split('.').length - 1] : ''
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${record.declareFile}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.declareFileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${record.declareFile}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.declareFileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(record.declareFile)
|
this.imageUrl = getFileAccessHttpUrl(record.declareFile)
|
||||||
|
|||||||
@@ -224,7 +224,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(file.id)
|
this.imageUrl = getFileAccessHttpUrl(file.id)
|
||||||
|
|||||||
@@ -207,7 +207,7 @@ export default {
|
|||||||
handleRelatedMaterialClick (record) {
|
handleRelatedMaterialClick (record) {
|
||||||
// 截取文件后缀名
|
// 截取文件后缀名
|
||||||
const fileSuffix = record.declareFileName ? record.declareFileName.split('.')[record.declareFileName.split('.').length - 1] : ''
|
const fileSuffix = record.declareFileName ? record.declareFileName.split('.')[record.declareFileName.split('.').length - 1] : ''
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${record.declareFile}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.declareFileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${record.declareFile}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.declareFileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
if (FILE_TYPE_IMGS.includes(fileSuffix)) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(record.declareFile)
|
this.imageUrl = getFileAccessHttpUrl(record.declareFile)
|
||||||
|
|||||||
@@ -274,7 +274,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(file.id)
|
this.imageUrl = getFileAccessHttpUrl(file.id)
|
||||||
|
|||||||
@@ -121,7 +121,7 @@ export default {
|
|||||||
const url = previewPdf(file.id)
|
const url = previewPdf(file.id)
|
||||||
this.iframeSrc = url
|
this.iframeSrc = url
|
||||||
} else if (fileSuffix === 'docx') {
|
} else if (fileSuffix === 'docx') {
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
// word文件仍使用KKFile进行预览
|
// word文件仍使用KKFile进行预览
|
||||||
const url = `${window._CONFIG.onlinePreviewDomainURL}?url=${encodeURIComponent(Base64.encode(fileFullUrl))}`
|
const url = `${window._CONFIG.onlinePreviewDomainURL}?url=${encodeURIComponent(Base64.encode(fileFullUrl))}`
|
||||||
this.iframeSrc = url
|
this.iframeSrc = url
|
||||||
|
|||||||
@@ -198,7 +198,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(file.id)
|
this.imageUrl = getFileAccessHttpUrl(file.id)
|
||||||
|
|||||||
@@ -377,7 +377,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
console.log(fileFullUrl)
|
console.log(fileFullUrl)
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix.toLowerCase())) {
|
||||||
|
|||||||
@@ -151,7 +151,7 @@ export default {
|
|||||||
const url = previewPdf(file.id)
|
const url = previewPdf(file.id)
|
||||||
this.iframeSrc = url
|
this.iframeSrc = url
|
||||||
} else if (fileSuffix === 'docx') {
|
} else if (fileSuffix === 'docx') {
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${file.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${file.fileName}`
|
||||||
// word文件仍使用KKFile进行预览
|
// word文件仍使用KKFile进行预览
|
||||||
const url = `${window._CONFIG.onlinePreviewDomainURL}?url=${encodeURIComponent(Base64.encode(fileFullUrl))}`
|
const url = `${window._CONFIG.onlinePreviewDomainURL}?url=${encodeURIComponent(Base64.encode(fileFullUrl))}`
|
||||||
this.iframeSrc = url
|
this.iframeSrc = url
|
||||||
|
|||||||
+1
-1
@@ -349,7 +349,7 @@ export default {
|
|||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${record.standardFile}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.standardFile_dictText}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${record.standardFile}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.standardFile_dictText}`
|
||||||
// 图片预览,使用自己添加的组件
|
// 图片预览,使用自己添加的组件
|
||||||
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix)) {
|
if (canPreview && FILE_TYPE_IMGS.includes(fileSuffix)) {
|
||||||
this.imageUrl = getFileAccessHttpUrl(record.standardFile)
|
this.imageUrl = getFileAccessHttpUrl(record.standardFile)
|
||||||
|
|||||||
@@ -158,7 +158,7 @@ export default {
|
|||||||
getFileInfo({ id: fileId }).then(res => {
|
getFileInfo({ id: fileId }).then(res => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
const fileInfo = res.result || {}
|
const fileInfo = res.result || {}
|
||||||
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${fileInfo.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${fileInfo.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/view/${fileInfo.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${fileInfo.fileName}`
|
||||||
// 截取文件后缀名
|
// 截取文件后缀名
|
||||||
const fileSuffix = (fileInfo.fileName ? fileInfo.fileName.split('.')[fileInfo.fileName.split('.').length - 1] : '').toLowerCase()
|
const fileSuffix = (fileInfo.fileName ? fileInfo.fileName.split('.')[fileInfo.fileName.split('.').length - 1] : '').toLowerCase()
|
||||||
switch (fileSuffix) {
|
switch (fileSuffix) {
|
||||||
|
|||||||
Reference in New Issue
Block a user