From 15178bafd7aa1827e6c48fda8e2cc3b8df0bbf5e Mon Sep 17 00:00:00 2001
From: wujianwei <wjw@11.com>
Date: 星期一, 19 一月 2026 15:24:25 +0800
Subject: [PATCH] 新增前后端

---
 ui/admin-ui3/src/components/ClaimBillDialog/index.vue |   90 +++++++++++++++++++++++++++++++++-----------
 1 files changed, 67 insertions(+), 23 deletions(-)

diff --git a/ui/admin-ui3/src/components/ClaimBillDialog/index.vue b/ui/admin-ui3/src/components/ClaimBillDialog/index.vue
index 2254f28..aa0f5fe 100644
--- a/ui/admin-ui3/src/components/ClaimBillDialog/index.vue
+++ b/ui/admin-ui3/src/components/ClaimBillDialog/index.vue
@@ -1,5 +1,11 @@
 <template>
   <el-dialog v-model="visible" title="璐﹀崟璁ら" width="1150px" destroy-on-close :close-on-click-modal="false">
+    <div style="text-align: right;margin-bottom: 10px;">
+      <el-button type="warning" v-if="isViewMode" plain icon="Download" @click="handleExport"
+        v-hasPermi="['cwgl:fundFlowClaimDetail:export']">瀵煎嚭
+      </el-button>
+      <!-- <el-button type="primary" @click="handleFinalSubmit">纭� 瀹�</el-button> -->
+    </div>
     <div class="claim-wrapper">
       <!-- <div class="section-header">娴佹按璇︾粏淇℃伅</div> -->
       <el-descriptions :column="3" border class="mb-20">
@@ -29,8 +35,16 @@
 
         <el-descriptions-item label="寰呰棰嗛噾棰�">
           <span class="text-danger font-bold">{{ remainingAmountDr }}</span>
+        </el-descriptions-item v-if="isViewMode">
+          <el-descriptions-item label="鍏宠仈璐﹀崟绫诲瀷">
+          <span  v-if="detail.incomeExpenseFlag == 0">
+            渚涘簲鍟�
+          </span>
+          <span  v-if="detail.incomeExpenseFlag == 1">
+            瀹㈡埛
+          </span>
         </el-descriptions-item>
-        <el-descriptions-item label="" :span="2"></el-descriptions-item>
+        <el-descriptions-item label="" :span="1"></el-descriptions-item>
       </el-descriptions>
 
       <div class="section-header">{{ isViewMode ? '璐﹀崟璁ら鏄庣粏' : '璐﹀崟璁ら' }}</div>
@@ -53,7 +67,7 @@
             <el-input v-model="row.billNo" @click="openReceivableDialog($index)" :disabled="!row.$edit" readonly
               placeholder="鐐瑰嚮閫夋嫨璐﹀崟">
               <template v-if="row.$edit" #append>
-                <el-button icon="Search"  @click="openReceivableDialog($index)" :disabled="!row.$edit" />
+                <el-button icon="Search" @click="openReceivableDialog($index)" :disabled="!row.$edit" />
               </template>
             </el-input>
           </template>
@@ -114,6 +128,10 @@
           </template>
         </el-table-column>
       </el-table>
+
+      <pagination v-show="total > 10" :total="total" v-model:page="queryParams.pageNum"
+        v-model:limit="queryParams.pageSize" @pagination="getList" />
+
     </div>
 
     <template #footer>
@@ -229,11 +247,50 @@
   resetForm();
 };
 const isViewMode = ref(false); // 鏂板锛氭ā寮忔帶鍒�
+
+// --- 鏂板锛氬垎椤典笌鎼滅储鐩稿叧鐨勫搷搴斿紡鍙橀噺 ---
+const total = ref(0);
+const loading = ref(false);
+const queryParams = ref({
+  pageNum: 1,
+  pageSize: 10,
+  fundFlowId: null as any // 鍏宠仈鐨勬祦姘碔D
+});
+
+// --- 鏂板锛氳幏鍙栧垪琛ㄦ暟鎹殑鏂规硶 ---
+const getList = async () => {
+  if (!detail.value.id) return;
+  
+  loading.value = true;
+  try {
+    const res = await listFundFlowClaimDetail({
+      ...queryParams.value,
+      fundFlowId: detail.value.id
+    });
+    if (res.code === 200) {
+      detail.value.claimDetails = res.rows;
+     detail.value.claimDetails.forEach((item: any) => {
+      if (item.$edit === undefined) {
+        item.$edit = false;
+      }
+    });
+      total.value = res.total;
+    }
+  } catch (error) {
+    console.error("鑾峰彇鏄庣粏鍒楄〃澶辫触", error);
+  } finally {
+    loading.value = false;
+  }
+};
+const handleExport =()=>{
+  proxy.download("/cwgl/fundFlowClaimDetail/export",{...queryParams.value})
+}
+
 // 鎵撳紑寮圭獥
 const open = (rowData: any, mode: 'view' | 'edit' = 'edit') => {
   // 1. 鍏堥噸缃竴娆★紝闃叉涓婃娈嬬暀
   resetForm();
-   isViewMode.value = mode === 'view'; // 璁剧疆妯″紡
+  isViewMode.value = mode === 'view'; // 璁剧疆妯″紡
   // 2. 娴呮嫹璐濆熀纭�鏁版嵁
   detail.value = {
     ...rowData,
@@ -249,13 +306,10 @@
     } else if (firstCompanyType === '渚涘簲鍟�') {
       billType.value = 'PAYABLE';
     }
-
+    // 濡傛灉鏈塈D锛屽垯璇锋眰鍚庣鏄庣粏鏁版嵁
+  
     // 纭繚宸叉湁鐨勬暟鎹涓嶄細鍙樻垚缂栬緫妯″紡
-    detail.value.claimDetails.forEach((item: any) => {
-      if (item.$edit === undefined) {
-        item.$edit = false;
-      }
-    });
+    getList()
   }
 
   visible.value = true;
@@ -335,14 +389,8 @@
   }
   addFundFlowClaimDetailClaim(row, detail.value.id).then((response) => {
     if (response.code == 200) {
-      listFundFlowClaimDetail({ fundFlowId: detail.value.id }).then((res) => {
-        if (res.code == 200) {
-          detail.value.claimDetails = res.rows;
-          proxy.$modal.msgSuccess("淇濆瓨鎴愬姛");
-          row.$edit = false;
-        }
-      })
-
+      proxy.$modal.msgSuccess("淇濆瓨鎴愬姛");
+      getList(); // 浣跨敤缁熶竴鐨� getList 鏂规硶
     }
   })
 };
@@ -352,12 +400,8 @@
     return delFundFlowClaimDetail(row.id);
   }).then((res) => {
     if (res.code == 200) {
-      listFundFlowClaimDetail({ fundFlowId: detail.value.id }).then((res) => {
-        if (res.code == 200) {
-          detail.value.claimDetails = res.rows;
-          proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
-        }
-      })
+    proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+      getList(); // 浣跨敤缁熶竴鐨� getList 鏂规硶
     }
 
 

--
Gitblit v1.8.0