Browse Source

规则判断

liuwenwen 2 years ago
parent
commit
14e6ccf275

+ 9 - 1
server/src/main/java/edp/davinci/service/impl/DataRulesServiceImpl.java

@@ -29,9 +29,17 @@ public class DataRulesServiceImpl implements DataRulesService
     {
         if (null == dataRules)
         {
-
             throw new ServerException("dataRules is null ");
+        }
+
+        if(dataRules.getRuleType() == null ){
+
+            throw new ServerException("标准类型 ruleType is null ");
+        }
+
+        if(dataRules.getRuleConfig() ==  null || dataRules.getRuleConfig().equals("{}")){
 
+            throw new ServerException("规则配置 ruleConfig is null ");
         }
 
         if(dataRules.getSubjectId() == null ){