From 0647a7a6251c05466c2ea5c64878959da4b1b625 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期四, 21 一月 2021 12:06:21 +0800
Subject: [PATCH] 增加check验证

---
 src/templates/comtableconfig/index.jsx |   19 +++++++++++++++++++
 1 files changed, 19 insertions(+), 0 deletions(-)

diff --git a/src/templates/comtableconfig/index.jsx b/src/templates/comtableconfig/index.jsx
index df83c9e..5fdc681 100644
--- a/src/templates/comtableconfig/index.jsx
+++ b/src/templates/comtableconfig/index.jsx
@@ -973,6 +973,25 @@
       }
     })
     
+    config.action && config.action.forEach((btn) => {
+      if (['prompt', 'exec', 'pop'].includes(btn.OpenType) && btn.Ot === 'required' && btn.verify && btn.verify.scripts && btn.verify.scripts.length > 0) {
+        let hascheck = false
+        btn.verify.scripts.forEach(item => {
+          if (item.status === 'false') return
+    
+          if (/\$check@|@check\$/ig.test(item.sql)) {
+            hascheck = true
+          }
+        })
+        if (hascheck) {
+          notification.warning({
+            top: 92,
+            message: `鍙�夋嫨澶氳鐨勬寜閽��${btn.label}銆嬩腑 $check@ 鎴� @check$ 灏嗕笉浼氱敓鏁堬紒`,
+            duration: 5
+          })
+        }
+      }
+    })
 
     if (config.setting.interType === 'system' && config.setting.default !== 'false' && !config.setting.dataresource) {
       return '鑿滃崟灏氭湭璁剧疆鏁版嵁婧愶紝涓嶅彲鍚敤锛�'

--
Gitblit v1.8.0