|
@@ -1027,13 +1027,17 @@
|
|
|
:on-exceed="handleExceed"
|
|
|
:before-upload="beforeUpload"
|
|
|
>
|
|
|
- <div class="text-80px text-gray">
|
|
|
- <i class="ri-upload-cloud-line" />
|
|
|
- </div>
|
|
|
- <div class="mt-24px text-black">将文件拖动到此处,或点击上传</div>
|
|
|
+ <div class="mt-24px text-black">将文件拖动到此处,<span class="text-blue">或点击上传</span></div>
|
|
|
<div class="mt-8px text-12px">支持的文件格式:.xls,.xlsx</div>
|
|
|
</el-upload>
|
|
|
+ <div class="text-right">
|
|
|
+ <el-button hc-btn type="success" :loading="downLoadTemplateLoading" @click="downLoadTemplate">
|
|
|
+ <HcIcon name="download-2" />
|
|
|
+ 导入模板
|
|
|
+ </el-button>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
+
|
|
|
<template #footer>
|
|
|
<el-button @click="divisionImportDialog = false">取消</el-button>
|
|
|
<el-button type="primary" :loading="confirmLoading" @click="confirmTap">确认上传</el-button>
|
|
@@ -1093,6 +1097,7 @@ import {
|
|
|
arrIndex,
|
|
|
arrToId,
|
|
|
deepClone,
|
|
|
+ downloadBlob,
|
|
|
formValidate,
|
|
|
getArrValue,
|
|
|
getObjValue,
|
|
@@ -2687,6 +2692,20 @@ const confirmTap = ()=>{
|
|
|
|
|
|
|
|
|
}
|
|
|
+//导入模板
|
|
|
+const downLoadTemplate = async ()=>{
|
|
|
+ downLoadTemplateLoading.value = true
|
|
|
+ const { error, disposition, res, msg } = await divisionApi.downloadGongChengExcel()
|
|
|
+ downLoadTemplateLoading.value = false
|
|
|
+ if (!error) {
|
|
|
+ if (disposition) {
|
|
|
+ downloadBlob(res, disposition)
|
|
|
+ } else {
|
|
|
+ window.$message?.error(msg || '数据异常')
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+const downLoadTemplateLoading = ref(false)
|
|
|
//节点命名配置
|
|
|
const nodeNameDialogShow = ref(false)
|
|
|
const editNamingConfigClick = async ()=>{
|