From 2dfc8dc4bcd3d3cd4aed1b6054e073e140eba9c8 Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Mon, 19 May 2025 16:05:50 +0800
Subject: [PATCH] Merge branch 'master' into jiangwu

---
 src/views/tickets/orderLog.vue |   56 +++++++++++++++++++++++++++++---------------------------
 1 files changed, 29 insertions(+), 27 deletions(-)

diff --git a/src/views/tickets/orderLog.vue b/src/views/tickets/orderLog.vue
index 177f6ce..38f11de 100644
--- a/src/views/tickets/orderLog.vue
+++ b/src/views/tickets/orderLog.vue
@@ -31,12 +31,7 @@
               </div>
 
               <div class="search-bar-box-item">
-                <el-select
-                  placeholder="请选择所属单位"
-                  v-model="filters.create_dept"
-                 
-                  clearable
-                >
+                <el-select placeholder="请选择所属单位" v-model="filters.create_dept" clearable>
                   <el-option
                     v-for="dept in departments"
                     :key="dept.value"
@@ -181,15 +176,14 @@
                     >审核</el-button
                   >
                 </template>
-
-                <template
+                 <template
                   v-if="
                     (userInfo.user_id == row.create_user || hasRecallPaddingBtnPermission()) &&
                     row.status == 1
                   "
                 >
                   <!--待审核状态-->
-                  <el-button type="text" icon="el-icon-warning" @click="orderLogRecall(row.id)"
+                  <el-button  type="text" icon="el-icon-warning" @click="orderLogRecall(row.id)"
                     >撤回</el-button
                   >
                 </template>
@@ -198,20 +192,26 @@
                   <el-button type="text" icon="el-icon-warning" @click="rejectDetail(row.id)"
                     >驳回原因</el-button
                   >
-                </template>
-                <!--草稿-->
-                <el-button type="text" icon="el-icon-edit" @click="handleViewDetail(row)"
-                  >编辑</el-button
-                >
-                <el-button type="text" icon="el-icon-position" @click="userPublishPush(row.id)"
-                  >发起</el-button
-                >
-                <el-button type="text" icon="el-icon-delete" @click="deleteOrderLog(row.id)"
-                  >删除</el-button
-                >
-                <template v-if="row.status == 3 || row.status == 1 || row.status == 2">
                   <el-button type="text" icon="el-icon-view" @click="handleViewDetail(row)"
                     >详情</el-button
+                  >
+                </template>
+                <!-- 已通过 -->
+                <template v-if="row.status == 3">
+                  <el-button type="text" icon="el-icon-view" @click="handleViewDetail(row)"
+                    >详情</el-button
+                  >
+                </template>
+                <!--草稿-->
+                <template v-if="row.status == 0">
+                  <el-button type="text" icon="el-icon-edit" @click="handleViewDetail(row)"
+                    >编辑</el-button
+                  >
+                  <el-button type="text" icon="el-icon-position" @click="userPublishPush(row.id)"
+                    >发布</el-button
+                  >
+                  <el-button type="text" icon="el-icon-delete" @click="deleteOrderLog(row.id)"
+                    >删除</el-button
                   >
                 </template>
               </div>
@@ -907,11 +907,12 @@
   mounted() {
     this.fetchTableData();
     const id = this.$route.query.id;
-   if (id) { // 确保 id 存在
-    this.handleViewDetail({ id });
-  } else {
-    console.error('工单ID不存在!');
-  }
+    if (id) {
+      // 确保 id 存在
+      this.handleViewDetail({ id });
+    } else {
+      console.error('工单ID不存在!');
+    }
   },
   computed: {
     ...mapGetters(['userInfo', 'permission']),
@@ -1247,6 +1248,7 @@
     hasRecallPaddingBtnPermission() {
       // undefined 或 false 都返回 false,只有 true 返回 true
       // console.log('权限检查:', this.permission)
+      // 智飞工单撤回
       return this.permission && this.permission.order_log_recall === true;
     },
     //驳回按钮权限
@@ -1339,7 +1341,7 @@
       //按照航线来
       const params = {
         type: 0,
-        waylineId: waylineId,
+        wayline_id: waylineId,
       };
       var wayLineListResponse = await getFlyingNestBy(params);
       this.device_sns = wayLineListResponse.data.data;

--
Gitblit v1.9.3