From c5f708c49c4f6c3d7b2728e9027fb670bd52c04b Mon Sep 17 00:00:00 2001
From: yuan <123@>
Date: 星期六, 16 五月 2026 21:27:47 +0800
Subject: [PATCH] 新增晋和园logo

---
 src/views/financialManagement/assets/fixedAssets.vue |   23 ++++++++++++++++++++---
 1 files changed, 20 insertions(+), 3 deletions(-)

diff --git a/src/views/financialManagement/assets/fixedAssets.vue b/src/views/financialManagement/assets/fixedAssets.vue
index c713b52..24b4cc3 100644
--- a/src/views/financialManagement/assets/fixedAssets.vue
+++ b/src/views/financialManagement/assets/fixedAssets.vue
@@ -38,11 +38,12 @@
         <div>
           <el-button type="primary" @click="add" icon="Plus">鏂板璧勪骇</el-button>
           <el-button type="warning" @click="handleDepreciation" icon="Money">鎶樻棫璁℃彁</el-button>
-          <el-button @click="handleOut" icon="Download">瀵煎嚭</el-button>
+          <!-- <el-button @click="handleOut" icon="Download">瀵煎嚭</el-button> -->
         </div>
       </div>
       <PIMTable
         rowKey="id"
+        isSelection
         :column="columns"
         :tableData="dataList"
         :page="{
@@ -50,6 +51,7 @@
           size: pagination.pageSize,
           total: pagination.total,
         }"
+        @selection-change="handleSelectionChange"
         @pagination="changePage"
       >
         <template #originalValue="{ row }">
@@ -227,12 +229,18 @@
 ];
 
 const dataList = ref([]);
+const multipleList = ref([]);
 const dialogVisible = ref(false);
 const dialogTitle = ref("");
 const formRef = ref(null);
 const isEdit = ref(false);
 const isView = ref(false);
 const currentId = ref(null);
+const selectedIds = computed(() =>
+  multipleList.value
+    .map(item => item?.id)
+    .filter(id => id !== undefined && id !== null && id !== "")
+);
 
 const createDefaultForm = () => ({
   assetCode: "",
@@ -322,10 +330,15 @@
       status: filters.status,
     });
     dataList.value = data?.records || [];
+    multipleList.value = [];
     pagination.total = Number(data?.total || 0);
   } catch (error) {
     // 鎻愮ず鐢卞叏灞�璇锋眰鎷︽埅鍣ㄥ鐞嗭紝杩欓噷浠呴槻姝㈡湭鎹曡幏寮傚父
   }
+};
+
+const handleSelectionChange = (selectionList) => {
+  multipleList.value = selectionList;
 };
 
 const resetFilters = () => {
@@ -388,12 +401,16 @@
 };
 
 const handleDepreciation = () => {
-  ElMessageBox.confirm("纭杩涜鏈湀鎶樻棫璁℃彁鍚楋紵", "鎻愮ず", {
+  const ids = selectedIds.value;
+  const confirmText = ids.length
+    ? `纭瀵归�変腑鐨� ${ids.length} 鏉¤祫浜ц繘琛屾湰鏈堟姌鏃ц鎻愬悧锛焋
+    : "纭杩涜鏈湀鎶樻棫璁℃彁鍚楋紵";
+  ElMessageBox.confirm(confirmText, "鎻愮ず", {
     confirmButtonText: "纭",
     cancelButtonText: "鍙栨秷",
     type: "info",
   }).then(async () => {
-    await depreciateFixedAsset({});
+    await depreciateFixedAsset({ ids });
     ElMessage.success("鎶樻棫璁℃彁瀹屾垚");
     await getTableData();
   });

--
Gitblit v1.9.3