diff --git a/src/views/accounting/bankSlip/index.vue b/src/views/accounting/bankSlip/index.vue index a951373a..b03715b1 100644 --- a/src/views/accounting/bankSlip/index.vue +++ b/src/views/accounting/bankSlip/index.vue @@ -779,7 +779,7 @@ export default { this.$modal.msgError("密码错误"); return false; } else { - this.$download.excel(response, "发票元数据.xml"); + this.$download.excel(response, "银行回单元数据.xml"); this.open1 = false; } }) diff --git a/src/views/accounting/book/index.vue b/src/views/accounting/book/index.vue index f17ffe8b..f3b0d706 100644 --- a/src/views/accounting/book/index.vue +++ b/src/views/accounting/book/index.vue @@ -451,8 +451,14 @@ export default { let params = { ...this.queryParams }; downloadXml(params) .then((response) => { - this.$download.excel(response, "会计账簿元数据.xml"); - this.open1 = false; + console.log(response.size); + if (response.size == 39) { + this.$modal.msgError("密码错误"); + return false; + } else { + this.$download.excel(response, "会计账簿元数据.xml"); + this.open1 = false; + } }) .catch(() => {}); }); diff --git a/src/views/accounting/flow/index.vue b/src/views/accounting/flow/index.vue index 8622518a..60372c58 100644 --- a/src/views/accounting/flow/index.vue +++ b/src/views/accounting/flow/index.vue @@ -148,7 +148,28 @@ width="1000px" append-to-body > - + + +
将文件拖到此处,或点击上传
+
+ @@ -184,11 +205,11 @@ - + @@ -248,6 +269,7 @@ import { exportFlowExcel, downloadXml, } from "@/api/accounting/flow"; +import { getAccessToken, getTenantId } from "@/utils/auth"; export default { name: "Flow", @@ -269,6 +291,8 @@ export default { // 是否显示弹出层 open: false, open1: false, + fileList: [], + imgType: ".jpeg, .jpg, .png", // 查询参数 queryParams: { pageNo: 1, @@ -297,6 +321,13 @@ export default { form: {}, // 表单校验 rules: {}, + fileList: [], // 文件列表 + uploadUrl: + process.env.VUE_APP_BASE_API + "/admin-api//archives/flow/upload", // 上传地址地址 + headers: { + Authorization: "Bearer " + getAccessToken(), + "tenant-id": getTenantId(), + }, // 设置上传的请求头 }; }, created() { @@ -363,6 +394,7 @@ export default { /** 新增按钮操作 */ handleAdd() { this.reset(); + this.fileList = []; this.open = true; this.title = "添加审批流程"; }, @@ -399,6 +431,11 @@ export default { }); }); }, + // 上传成功的函数 + handleSuccess(res) { + console.log(res); + this.form.fileUrl = res.data.url; + }, /** 删除按钮操作 */ handleDelete(row) { const id = row.id; diff --git a/src/views/accounting/report/index.vue b/src/views/accounting/report/index.vue index 57a1b80c..240f18d5 100644 --- a/src/views/accounting/report/index.vue +++ b/src/views/accounting/report/index.vue @@ -435,8 +435,14 @@ export default { let params = { ...this.queryParams }; downloadXml(params) .then((response) => { - this.$download.excel(response, "会计账簿元数据.xml"); - this.open1 = false; + console.log(response.size); + if (response.size == 39) { + this.$modal.msgError("密码错误"); + return false; + } else { + this.$download.excel(response, "会计报表元数据.xml"); + this.open1 = false; + } }) .catch(() => {}); });