diff --git a/.env.development b/.env.development index 500d6b0..2ef074f 100644 --- a/.env.development +++ b/.env.development @@ -6,7 +6,7 @@ VITE_APP_ENV = 'development' # 开发环境 # 李陈杰 209 -VITE_APP_BASE_API = 'http://192.168.110.209:8899' +VITE_APP_BASE_API = 'http://192.168.110.180:8899' # 曾涛 # VITE_APP_BASE_API = 'http://192.168.110.180:8899' # 罗成 diff --git a/public/catalog.xlsx b/public/catalog.xlsx new file mode 100644 index 0000000..1cca466 Binary files /dev/null and b/public/catalog.xlsx differ diff --git a/src/views/design/condition/comm/filePage.vue b/src/views/design/condition/comm/filePage.vue index df3d89d..1a69993 100644 --- a/src/views/design/condition/comm/filePage.vue +++ b/src/views/design/condition/comm/filePage.vue @@ -17,7 +17,13 @@ - + + + @@ -607,6 +610,24 @@ const getVolumeFileList = async (type) => { fileList.value = res.rows; } }; +const exportFile = () => { + // 导出模版文件 + try { + // 创建a标签 + const link = document.createElement('a'); + // 设置PDF文件路径 - 相对于public目录 + link.href = '/catalog.xlsx'; + // 设置下载后的文件名 + link.download = '设计出图计划导入模版.xlsx'; + // 触发点击 + document.body.appendChild(link); + link.click(); + // 清理 + document.body.removeChild(link); + } catch (error) { + alert('下载失败,请重试'); + } +}; // 切换 const handleClick = (val) => { getVolumeFileList(val.props.name); diff --git a/src/views/materials/materialsEquipment/materialReceive/index.vue b/src/views/materials/materialsEquipment/materialReceive/index.vue index ab997cf..d7c1b27 100644 --- a/src/views/materials/materialsEquipment/materialReceive/index.vue +++ b/src/views/materials/materialsEquipment/materialReceive/index.vue @@ -1,7 +1,6 @@