From 2b1db166900b75df2cff639aec9c6ee9ce708735 Mon Sep 17 00:00:00 2001
From: 祖安之光 <11848914+light-of-zuan@user.noreply.gitee.com>
Date: Mon, 02 Feb 2026 14:17:04 +0800
Subject: [PATCH] 修改新增
---
src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/workInstruct/index.vue | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/workInstruct/index.vue b/src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/workInstruct/index.vue
index fcb47c9..6a99ac0 100644
--- a/src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/workInstruct/index.vue
+++ b/src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/workInstruct/index.vue
@@ -33,7 +33,8 @@
<el-table-column label="名称" prop="templateName" align="center"/>
<el-table-column label="文件" align="center">
<template #default="scope">
- <el-link type="primary" @click="openFile(scope.row.filePath)">{{scope.row.templateName + '模板' + scope.row.format}}</el-link>
+ <el-link v-if="scope.row.filePath && scope.row.filePath !== ''" type="primary" @click="openFile(scope.row.filePath)">{{scope.row.templateName + scope.row.format}}</el-link>
+ <span v-else></span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" >
@@ -102,7 +103,7 @@
const openFile = async(path)=>{
const ext = path.split('.').pop().toLowerCase();
if (ext === 'doc') {
- ElMessageBox.confirm('暂不支持线上预览.doc文件,是否下载查看?', '提示', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
+ ElMessageBox.confirm('暂不支持线上预览.doc、.xls、.xlsx文件,是否下载查看?', '提示', { confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning' }).then(() => {
window.open(`${import.meta.env.VITE_APP_BASE_API}/${path}`, '_blank');
}).catch(() => {
console.log('取消预览')
--
Gitblit v1.9.2