From 82100d611b8b7bd33ee8d199d07a4797e781d6cc Mon Sep 17 00:00:00 2001
From: zhizhijie <zhizhijie@users.noreply.gitee.com>
Date: 星期二, 15 九月 2026 23:56:56 +0800
Subject: [PATCH] docs(工作日结): 自检触发时间改为 08:35,并补记公司 gitea 推送待授权
---
traffic-audit-web/src/views/DataImport.vue | 16 +++++++++++++++-
1 files changed, 15 insertions(+), 1 deletions(-)
diff --git a/traffic-audit-web/src/views/DataImport.vue b/traffic-audit-web/src/views/DataImport.vue
index b9c83e7..f7f6638 100644
--- a/traffic-audit-web/src/views/DataImport.vue
+++ b/traffic-audit-web/src/views/DataImport.vue
@@ -1,3 +1,4 @@
+<template>
<el-container direction="vertical">
<app-header title="浜ら�氱粺璁℃姤琛ㄥ鏍哥郴缁� - 鏁版嵁瀵煎叆"></app-header>
<el-container>
@@ -333,7 +334,20 @@
typeLabel(t) { return TYPE_LABELS[t] || t },
downloadTemplate() {
if (!this.templateUrl) return
- window.open('/api/templates/' + this.templateUrl)
+ const name = this.templateUrl.split('/').pop()
+ api.get('/templates/' + this.templateUrl, { responseType: 'blob' })
+ .then(res => {
+ const blob = res instanceof Blob ? res : new Blob([res])
+ const url = window.URL.createObjectURL(blob)
+ const a = document.createElement('a')
+ a.href = url
+ a.download = name
+ document.body.appendChild(a)
+ a.click()
+ window.URL.revokeObjectURL(url)
+ document.body.removeChild(a)
+ })
+ .catch(() => this.$message.error('妯℃澘涓嬭浇澶辫触锛岃绋嶅悗閲嶈瘯'))
},
onModuleChange(key) {
this.importType = this.moduleSel[key] || ''
--
Gitblit v1.9.1