From 2fdc3dc444a2f8199866780205c0fa4b5ac40522 Mon Sep 17 00:00:00 2001
From: liuwh <hugeinfo123>
Date: Fri, 29 May 2020 10:38:46 +0800
Subject: [PATCH] 指纹登记与对比

---
 SunshineIns/src/page/CareList.jsx |   24 ++++++++----------------
 1 files changed, 8 insertions(+), 16 deletions(-)

diff --git a/SunshineIns/src/page/CareList.jsx b/SunshineIns/src/page/CareList.jsx
index 4cb2b8d..797843c 100644
--- a/SunshineIns/src/page/CareList.jsx
+++ b/SunshineIns/src/page/CareList.jsx
@@ -142,13 +142,13 @@
         }, this.getData);
     }
 
-    reboot = (e,status) => {
+    reboot = (e, status) => {
         this.setState({ loading: true })
         Fetch.socialUpdate(e, status).then(res => {
             if (res.code == 0) {
                 console.log(res)
                 this.setState({ loading: false })
-                message.success(status==0?'重启任务成功':'暂停任务成功');
+                message.success(status == 0 ? '重启任务成功' : '暂停任务成功');
                 this.getData();
             } else {
                 this.setState({ loading: false })
@@ -215,7 +215,7 @@
                     {
                         record.status == 0 ?
                             <React.Fragment>
-                                <a onClick={() => this.showModal(record.id)}>编辑</a>
+                                <a onClick={() => this.showModal(record.id)}>查看</a>
                                 <Divider type="vertical" />
                                 <Popconfirm
                                     title="确认删除任务吗?"
@@ -229,19 +229,11 @@
                                 </Popconfirm>
                                 <a onClick={() => this.reboot(record.id, 99)}>暂停</a>
                             </React.Fragment> :
-                            record.status == 1 ?
-                                <React.Fragment>
-                                    <a onClick={() => this.showModal(record.id)}>查看</a>
-                                    <Divider type="vertical" />
-                                    <a onClick={() => this.showModal(record.id)}>结束任务</a>
-                                    <Divider type="vertical" />
-                                    <a onClick={() => this.reboot(record.id, 99)}>暂停</a>
-                                </React.Fragment> :
-                                <React.Fragment>
-                                    <a onClick={() => this.showModal(record.id)}>查看</a>
-                                    <Divider type="vertical" />
-                                    <a onClick={() => this.reboot(record.id, 0)}>重启</a>
-                                </React.Fragment>
+                            <React.Fragment>
+                                <a onClick={() => this.showModal(record.id)}>查看</a>
+                                <Divider type="vertical" />
+                                <a onClick={() => this.reboot(record.id, 0)}>重启</a>
+                            </React.Fragment>
                     }
                 </span>
             ),

--
Gitblit v1.8.0