From b417a422c08ceabd31fa7feaba42fd8a7b1e86d2 Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期六, 18 一月 2025 09:14:08 +0800
Subject: [PATCH] 1

---
 admin/src/views/contract/components/contractDetail.vue |   20 +++++++++++++++++---
 1 files changed, 17 insertions(+), 3 deletions(-)

diff --git a/admin/src/views/contract/components/contractDetail.vue b/admin/src/views/contract/components/contractDetail.vue
index 64cb0d9..5683288 100644
--- a/admin/src/views/contract/components/contractDetail.vue
+++ b/admin/src/views/contract/components/contractDetail.vue
@@ -17,8 +17,8 @@
           <el-tag type="info" v-if="info.status === 4">宸查��绉�</el-tag>
         </div>
         <div>
-          <el-button type="primary" @click="$refs.pendingBills.open('寰呭鐞嗚处鍗�')">鏌ョ湅寰呭鐞嗚处鍗�</el-button>
-          <el-button @click="$refs.terminationAgreement.open('閫�绉熷崗璁�')">鏌ョ湅閫�绉熷崗璁�</el-button>
+          <el-button type="primary" @click="$refs.pendingBills.open('寰呭鐞嗚处鍗�', id)" v-if="info.status === 3">鏌ョ湅寰呭鐞嗚处鍗�</el-button>
+          <el-button @click="$refs.terminationAgreement.open('閫�绉熷崗璁�', id)" v-if="[3,4].includes(info.status)">鏌ョ湅閫�绉熷崗璁�</el-button>
           <el-button plain type="danger" v-if="[0, 1, 2].includes(info.status)" @click="refund">閫�绉�</el-button>
         </div>
       </div>
@@ -197,6 +197,13 @@
         v-loading="loading"
         style="width: 100%">
         <el-table-column
+          width="150"
+          label="璐﹀崟缂栧彿">
+          <template slot-scope="{row}">
+            <el-button type="text" @click="openBill(row.id)">{{row.code}}</el-button>
+          </template>
+        </el-table-column>
+        <el-table-column
           label="璐圭敤绫诲瀷">
           <template slot-scope="{row}">
             <span v-if="row.costType === 0">绉熻祦璐�</span>
@@ -327,6 +334,8 @@
     <PendingBills ref="pendingBills" />
     <!--  閫�绉熷崗璁�  -->
     <TerminationAgreement ref="terminationAgreement" />
+    <!--  璐﹀崟璇︽儏  -->
+    <BullDetail ref="bullDetail" />
   </GlobalWindow>
 </template>
 
@@ -336,6 +345,7 @@
 import TerminateLease from './terminateLease'
 import PendingBills from './pendingBills'
 import TerminationAgreement from './terminationAgreement'
+import BullDetail from '../../finance/components/bullDetail'
 import { getById } from '@/api/contract'
 import { fetchList } from '@/api/bill'
 export default {
@@ -343,7 +353,8 @@
     GlobalWindow,
     TerminateLease,
     PendingBills,
-    TerminationAgreement
+    TerminationAgreement,
+    BullDetail
   },
   extends: BaseOpera,
   data() {
@@ -375,6 +386,9 @@
     xiazai (url) {
       window.open(url)
     },
+    openBill(id) {
+      this.$refs.bullDetail.open('璐﹀崟璇︽儏', id)
+    },
     returnUnit (type) {
       switch (type) {
         case 0:

--
Gitblit v1.9.3