From c7aece35a62b6e91fd98a625bf0e53f64bfbd18d Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期四, 17 八月 2023 16:22:15 +0800
Subject: [PATCH] 2023-08-17

---
 src/templates/sharecomponent/actioncomponent/verifyexcelout/index.jsx |   31 +++++++++++++++++++------------
 1 files changed, 19 insertions(+), 12 deletions(-)

diff --git a/src/templates/sharecomponent/actioncomponent/verifyexcelout/index.jsx b/src/templates/sharecomponent/actioncomponent/verifyexcelout/index.jsx
index 8e04fc0..99a32d2 100644
--- a/src/templates/sharecomponent/actioncomponent/verifyexcelout/index.jsx
+++ b/src/templates/sharecomponent/actioncomponent/verifyexcelout/index.jsx
@@ -135,7 +135,7 @@
         width: '10%',
         editable: true,
         inputType: 'radio',
-        render: (text, record) => record.required === 'true' ? '鏄�' : '鍚�',
+        render: (text, record) => record.required === 'true' ? <span style={{color: 'red'}}>鏄�</span> : '鍚�',
         options: [
           {value: 'true', text: '鏄�'},
           {value: 'false', text: '鍚�'}
@@ -975,7 +975,7 @@
     }
   }
 
-  scriptsChange = (values, callback) => {
+  scriptsChange = (values, callback, skip) => {
     let verify = JSON.parse(JSON.stringify(this.state.verify))
 
     if (values.uuid) {
@@ -991,20 +991,27 @@
       verify.scripts.push(values)
     }
 
-    this.setState({loading: true})
-
-    this.sqlverify(() => { // 楠岃瘉鎴愬姛
+    if (skip) {
       this.setState({
-        loading: false,
         verify: verify
       })
       callback(true)
-    }, () => {             // 楠岃瘉澶辫触
-      this.setState({
-        loading: false
-      })
-      callback(false)
-    }, verify.scripts)
+    } else {
+      this.setState({loading: true})
+  
+      this.sqlverify(() => { // 楠岃瘉鎴愬姛
+        this.setState({
+          loading: false,
+          verify: verify
+        })
+        callback(true)
+      }, () => {             // 楠岃瘉澶辫触
+        this.setState({
+          loading: false
+        })
+        callback(false)
+      }, verify.scripts)
+    }
   }
 
   sqlverify = (_resolve, _reject, scripts) => {

--
Gitblit v1.8.0