@@ -157,8 +157,8 @@
:width="300"
align="center"
>
-
-
+
+
{{ detailFile?.metadata?.FileName || detailFile?.name }}
{{ detailFile?.metadata?.FileType || '未知' }}
@@ -206,11 +206,11 @@ computed: {
const end = start + this.pageSize;
let data = sortedData.slice(start, end);
// 增加previewSrcList属性,用于预览图片
- const fullList = data.filter(file => !file.metadata?.FileType?.includes('video')).map(file => `/file/${file.name}`);
+ const fullList = data.filter(file => !file.metadata?.FileType?.includes('video')).map(file => `/file/${file.name}?from=admin`);
data.forEach(file => {
if (!file.metadata?.FileType?.includes('video')) {
// 重新排序,索引大于等于当前索引的元素在前,否则在后
- file.previewSrcList = fullList.slice(fullList.indexOf(`/file/${file.name}`)).concat(fullList.slice(0, fullList.indexOf(`/file/${file.name}`)));
+ file.previewSrcList = fullList.slice(fullList.indexOf(`/file/${file.name}?from=admin`)).concat(fullList.slice(0, fullList.indexOf(`/file/${file.name}?from=admin`)));
}
});
return data;
@@ -281,7 +281,7 @@ methods: {
},
handleDownload(key) {
const link = document.createElement('a');
- link.href = `/file/${key}`;
+ link.href = `/file/${key}?from=admin`;
link.download = key;
link.click();
},
@@ -558,7 +558,7 @@ methods: {
const fileNameCount = {}; // 用于跟踪文件名出现的次数
const downloadPromises = this.selectedFiles.map(file => {
- return fetch(`/file/${file.name}`)
+ return fetch(`/file/${file.name}?from=admin`)
.then(response => response.blob())
.then(blob => {
// 检查文件名是否已经存在
diff --git a/src/views/CustomerConfig.vue b/src/views/CustomerConfig.vue
index f0c03b5..cdba4b4 100644
--- a/src/views/CustomerConfig.vue
+++ b/src/views/CustomerConfig.vue
@@ -26,8 +26,8 @@
-
-
+
+