From d1d3ea967d916d798dbb1979130137bdd5b6152c Mon Sep 17 00:00:00 2001
From: yuan <123@>
Date: 星期一, 18 五月 2026 10:22:37 +0800
Subject: [PATCH] feat(search): 基础产品维护子节点模糊查询
---
src/plugins/download.js | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/src/plugins/download.js b/src/plugins/download.js
index 2705310..35ac92f 100644
--- a/src/plugins/download.js
+++ b/src/plugins/download.js
@@ -82,6 +82,16 @@
saveAs(text, name, opts) {
saveAs(text, name, opts);
},
+ byUrl(url, filename) {
+ // 灏哢RL涓殑preview鏇挎崲鎴恉ownload
+ const downloadUrl = url.replace(/preview/g, 'download')
+ const link = document.createElement('a')
+ link.href = downloadUrl
+ link.download = filename || ''
+ document.body.appendChild(link)
+ link.click()
+ document.body.removeChild(link)
+ },
async printErrMsg(data) {
const resText = await data.text();
const rspObj = JSON.parse(resText);
--
Gitblit v1.9.3