From 1c20c8231980a8d4b91688ff8641a06d3b2f68ab Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期二, 14 十月 2025 16:34:22 +0800
Subject: [PATCH] 改bug

---
 admin/src/views/platform/components/PlatformQueuing.vue |   71 +++++++++++++++++++++++++++--------
 1 files changed, 55 insertions(+), 16 deletions(-)

diff --git a/admin/src/views/platform/components/PlatformQueuing.vue b/admin/src/views/platform/components/PlatformQueuing.vue
index 973220c..0a4c2ca 100644
--- a/admin/src/views/platform/components/PlatformQueuing.vue
+++ b/admin/src/views/platform/components/PlatformQueuing.vue
@@ -20,13 +20,13 @@
             <div class="status">{{ statusMap[item.status] }}</div>
           </div>
           <div class="info">
-            <div v-if="item.type == 4" class="ite">
-              <span>鍚堝悓鍗曞彿锛�</span>
-              <span>{{ item.contractNum }}</span>
-            </div>
-            <div v-else class="ite">
+            <div v-if="item.billCode" class="ite">
               <span>杩愯緭鍗曞彿锛�</span>
               <span>{{ item.billCode }}</span>
+            </div>
+            <div v-else class="ite">
+              <span>鍚堝悓鍗曞彿锛�</span>
+              <span>{{ item.contractNum }}</span>
             </div>
             <div class="ite">
               <span>椹鹃┒鍛橈細</span>
@@ -38,23 +38,31 @@
             </div>
             <div class="ite">
               <span>鎬昏繍杈撻噺锛�</span>
-              <span>{{ item.totalNum }}涓囨敮</span>
+              <span>{{ item.totalNum || item.ioQty }}涓囨敮</span>
             </div>
-            <div v-if="item.type != 4" class="ite" style="width: 66%">
+            <div v-if="item.billCode" class="ite" style="width: 66%">
               <span>杩愯緭鍏徃锛�</span>
               <span>{{ item.carrierName }}</span>
             </div>
           </div>
           <div class="footer df_sb">
-            <div v-if="item.type != 4" class="detail">杩愬崟璇︽儏</div>
-            <div v-else></div>
-            <el-button type="primary" @click="handleCall(item)">鍙彿</el-button>
+            <div v-if="item.billCode" @click="handleDetail(item)" class="detail">杩愬崟璇︽儏</div>
+            <div v-else class="detail"  @click="subDetail(item)">棰勭害璇︽儏</div>
+            <div style="display: flex; align-items: center;">
+              <div style="margin-right: 15px; color: #207FF7; font-size: 13px; font-weight: 400;" v-if="item.signDate">
+                绛惧埌鏃堕棿锛歿{item.signDate.substring(5, 10)}} {{item.signDate.substring(11, 16)}}
+              </div>
+              <el-button v-preventReClick :loading="loadingCall" type="primary" @click="handleCall(item)">鍙彿</el-button>
+            </div>
           </div>
         </div>
       </div>
       <pagination @size-change="handleSizeChange" @current-change="handlePageChange" :pagination="pagination">
       </pagination>
     </div>
+    <!--  -->
+    <WaybillDetail ref="WaybillDetailRef" v-if="isShowDetail" @success="getList" @close="isShowDetail = false" />
+    <DriverDetail v-if="isShowDriver" ref="DriverDetailRef" />
   </GlobalWindow>
 </template>
 
@@ -64,10 +72,14 @@
 import { platformCallList, platformCallNumber, platformInPark } from '@/api'
 import { statusMap } from '../config'
 import { Message } from 'element-ui'
+import WaybillDetail from './WaybillDetail.vue'
+import DriverDetail from "@/views/task/driverDetail.vue"
 export default {
   components: {
     GlobalWindow,
-    Pagination
+    Pagination,
+    WaybillDetail,
+    DriverDetail
   },
   data() {
     return {
@@ -83,29 +95,53 @@
       title: '',
       callType: '1',
       activePlat: {},
-      dataList: []
+      dataList: [],
+      isShowDetail: false, // 杩愬崟璇︽儏
+      isShowDriver: false, // 棰勭害璇︽儏
+      loadingCall: false
 
     }
   },
   methods: {
     handleCall(item) {
       const { activePlat, callType } = this
+      this.loadingCall = true
       if (callType == 1) { // 鍏ュ洯鍙彿
         platformInPark({
           jobId: item.id,
           platformId: activePlat.id
         }).then(() => {
+          this.loadingCall = false
           Message.success('鍙彿鎴愬姛')
           this.$emit('success')
           this.getList()
-        })
+        },() => {this.loadingCall = false})
       } else {
+        this.loadingCall = true
         platformCallNumber({ platformId: activePlat.id, jobId: item.id }).then(res => {
+          this.loadingCall = false
           Message.success('鍙彿鎴愬姛')
           this.$emit('success')
           this.getList()
-        })
+        },()=> {this.loadingCall = false})
       }
+    },
+    subDetail(row) {
+      this.isShowDriver = true
+      this.$nextTick(() => {
+        this.$refs.DriverDetailRef.id = row.bookId
+        this.$refs.DriverDetailRef.type = row.objType
+        this.$refs.DriverDetailRef.getDetail()
+        this.$refs.DriverDetailRef.isShowModal = true
+      })
+    },
+    handleDetail(row) {
+      this.isShowDetail = true
+      this.$nextTick(() => {
+        this.$refs.WaybillDetailRef.isShowModal = true
+        this.$refs.WaybillDetailRef.id = row.id
+        this.$refs.WaybillDetailRef.getDetail()
+      })
     },
     getList() {
       const { activePlat, pagination, carCodeFront, callType } = this
@@ -126,7 +162,7 @@
     },
     handleSizeChange(e) {
       this.pagination.pageSize = e
-      this.getList()
+      this.getList(1)
     },
     handlePageChange(e) {
       this.pagination.page = e
@@ -153,7 +189,9 @@
 
 <style lang="scss" scoped>
 @import "@/assets/style/variables.scss";
-
+.table-pagination {
+  bottom: 0px !important;
+}
 .queuing_modal {
   padding: 10px 30px;
 
@@ -228,6 +266,7 @@
       .footer {
         .detail {
           color: $primaryColor;
+          cursor: pointer;
         }
       }
     }

--
Gitblit v1.9.3