From 84e3953ec23a393fdfdadb21463ed502a494e27f Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期五, 31 十月 2025 16:22:28 +0800
Subject: [PATCH] 采购管理-添加导出功能
---
src/views/procurementManagement/invoiceEntry/index.vue | 24 ++++++++++++++++++++----
1 files changed, 20 insertions(+), 4 deletions(-)
diff --git a/src/views/procurementManagement/invoiceEntry/index.vue b/src/views/procurementManagement/invoiceEntry/index.vue
index 256377f..87e08e9 100644
--- a/src/views/procurementManagement/invoiceEntry/index.vue
+++ b/src/views/procurementManagement/invoiceEntry/index.vue
@@ -45,10 +45,10 @@
<div class="actions">
<div></div>
<div>
+ <el-button @click="handleExport" style="margin-right: 10px">瀵煎嚭</el-button>
<el-button type="primary" @click="handleAdd('add')">
鏂板鐧昏
</el-button>
-<!-- <el-button @click="handleOut">瀵煎嚭</el-button>-->
<!-- <el-button type="danger" plain @click="handleDelete">鍒犻櫎</el-button>-->
</div>
</div>
@@ -92,7 +92,7 @@
<script setup>
import { usePaginationApi } from "@/hooks/usePaginationApi";
import {delRegistration, gePurchaseListPage} from "@/api/procurementManagement/invoiceEntry.js";
-import { nextTick, onMounted, getCurrentInstance } from "vue";
+import { nextTick, onMounted, getCurrentInstance, ref } from "vue";
import ExpandTable from "./components/ExpandTable.vue";
import Modal from "./components/Modal.vue";
import {ElMessageBox} from "element-plus";
@@ -165,7 +165,7 @@
},
},
{
- label: "宸插紑绁ㄩ噾棰�(鍏�)",
+ label: "宸叉潵绁ㄩ噾棰�(鍏�)",
prop: "receiptPaymentAmount",
width:200,
formatData: (val) => {
@@ -173,7 +173,7 @@
},
},
{
- label: "寰呭紑绁ㄩ噾棰�(鍏�)",
+ label: "寰呮潵绁ㄩ噾棰�(鍏�)",
prop: "unReceiptPaymentAmount",
width:200,
formatData: (val) => {
@@ -223,6 +223,22 @@
proxy.$modal.msg("宸插彇娑�");
});
};
+
+// 瀵煎嚭閲囪喘鍙拌处
+const handleExport = () => {
+ ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚鍑猴紝鏄惁纭瀵煎嚭锛�", "瀵煎嚭", {
+ confirmButtonText: "纭",
+ cancelButtonText: "鍙栨秷",
+ type: "warning",
+ })
+ .then(() => {
+ proxy.download("/purchase/ledger/exportOne", {}, "鏉ョエ鐧昏.xlsx");
+ })
+ .catch(() => {
+ proxy.$modal.msg("宸插彇娑�");
+ });
+};
+
// 鍒犻櫎
const handleDelete = () => {
let ids = [];
--
Gitblit v1.9.3