From 8b3b36310ee2166d21bcf69f35914421e27fe5f0 Mon Sep 17 00:00:00 2001
From: yangys <y_ys79@sina.com>
Date: 星期日, 14 一月 2024 17:16:50 +0800
Subject: [PATCH] 调整删除功能

---
 src/container/workshop/device.vue |   19 ++++++++++++-------
 1 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/src/container/workshop/device.vue b/src/container/workshop/device.vue
index 0cb8376..f383439 100644
--- a/src/container/workshop/device.vue
+++ b/src/container/workshop/device.vue
@@ -1,7 +1,7 @@
 <!--
  * @Date: 2024-01-13 20:46:33
  * @LastEditors: Sneed
- * @LastEditTime: 2024-01-13 21:37:22
+ * @LastEditTime: 2024-01-13 23:35:27
  * @FilePath: /belleson-frontend/Users/mache/Documents/demo/mdc/src/container/workshop/device.vue
 -->
 <template>
@@ -20,21 +20,21 @@
                 <li>
                     <img src="./img/sd.png" alt="">
                     <div>
-                        <p>{{ item.cycleCount }}</p>
+                        <p>{{ item.cycleCount || 0 }}</p>
                         <p>鑳藉姏鍒╃敤鐜�</p>
                     </div>
                 </li>
                 <li>
                     <img src="./img/sd.png" alt="">
                     <div>
-                        <p>{{ item.cycleCount }}</p>
+                        <p>{{ item.cycleCount || 0 }}</p>
                         <p>鏃ュ埄鐢ㄧ巼</p>
                     </div>
                 </li>
                 <li>
                     <img src="./img/sd.png" alt="">
                     <div>
-                        <p>{{ item.cycleCount }}</p>
+                        <p>{{ item.cycleCount || 0 }}</p>
                         <p>瀹屽伐浠舵暟</p>
                     </div>
                 </li>
@@ -45,10 +45,11 @@
 <script>
 import { getRequest,getUrl } from '@/api/Api'
 export default {
-    props: ['item'],
+    props: ['id'],
     data () {
         return {
             care: false,
+            item: {}
         }
     },
     methods: {
@@ -57,6 +58,9 @@
             getRequest('machineConcern',{concern: val ? 1 : 0,id: this.item.id}).then(res => {
                 console.log(res)
             })
+        },
+        getInfo () {
+            this.item = {}
         }
     },
 }
@@ -89,10 +93,11 @@
     &>p:before {
         content: '';
         position: absolute;
+        z-index: 0;
         top: 50%;
         left: 0;
         transform: translateY(-50%);
-        width: 60px;
+        width: 30px;
         height: 1px;
         background: linear-gradient(270deg, #65A5D6 0%, rgba(11,70,115,0) 100%);
     }
@@ -102,7 +107,7 @@
         top: 50%;
         right: 0;
         transform: translateY(-50%);
-        width: 60px;
+        width: 30px;
         height: 1px;
         background: linear-gradient(90deg, #65A5D6 0%, rgba(11,70,115,0) 100%);
     }

--
Gitblit v1.9.3