From d33d00cafeea2c4f980ea3af268d9260269edcc1 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期一, 25 一月 2021 18:24:20 +0800
Subject: [PATCH] 2021-01-25

---
 src/templates/subtableconfig/index.jsx |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/src/templates/subtableconfig/index.jsx b/src/templates/subtableconfig/index.jsx
index d91ad53..3980fef 100644
--- a/src/templates/subtableconfig/index.jsx
+++ b/src/templates/subtableconfig/index.jsx
@@ -836,8 +836,12 @@
       }
     })
 
-    if (config.setting.interType === 'system' && config.setting.default !== 'false' && !config.setting.dataresource) {
-      return '灏氭湭璁剧疆鏁版嵁婧愶紝涓嶅彲鍚敤锛�'
+    if ((config.setting.interType === 'system' || config.setting.requestMode === 'system') && config.setting.default === 'false' && config.setting.scripts && config.setting.scripts.filter(item => item.status !== 'false').length === 0) {
+      return '鏁版嵁婧愪腑涓嶆墽琛岄粯璁ql锛屼笖鏈坊鍔犺嚜瀹氫箟鑴氭湰锛屼笉鍙惎鐢紒'
+    } else if (config.setting.interType === 'custom' && config.setting.procMode !== 'inner' && config.setting.preScripts && config.setting.preScripts.filter(item => item.status !== 'false').length === 0) {
+      return '鏁版嵁婧愭湭璁剧疆鍓嶇疆鑴氭湰锛屼笉鍙惎鐢紒'
+    } else if (config.setting.interType === 'custom' && config.setting.callbackType === 'script' && config.setting.cbScripts && config.setting.cbScripts.filter(item => item.status !== 'false').length === 0) {
+      return '鏁版嵁婧愭湭璁剧疆鍥炶皟鑴氭湰锛屼笉鍙惎鐢紒'
     } else if (!config.setting.primaryKey) {
       return '灏氭湭璁剧疆涓婚敭锛屼笉鍙惎鐢紒'
     }  else if (config.columns.length === 0) {

--
Gitblit v1.8.0