Browse Source

REPORT-54887 公式编辑器优化一期

1.修改一些规范;
2.补充condition逻辑
research/11.0
Hoky 3 years ago
parent
commit
508d9d7cfb
  1. 6
      designer-base/src/main/java/com/fr/design/formula/FormulaPane.java

6
designer-base/src/main/java/com/fr/design/formula/FormulaPane.java

@ -38,6 +38,7 @@ import com.fr.report.core.namespace.SimpleCellValueNameSpace;
import com.fr.script.Calculator;
import com.fr.script.ScriptConstants;
import com.fr.script.checker.FunctionCheckerDispatcher;
import com.fr.script.checker.exception.ConditionCheckWrongException;
import com.fr.script.checker.exception.FunctionCheckWrongException;
import com.fr.script.rules.FunctionParameterType;
import com.fr.script.rules.FunctionRule;
@ -663,6 +664,11 @@ public class FormulaPane extends BasicPane implements KeyListener, UIFormula {
return FunctionCheckerDispatcher.getInstance()
.getFunctionChecker(node)
.checkFunction(node) ? VALID_FORMULA : INVALID_FORMULA;
} catch (ConditionCheckWrongException cce) {
List<FunctionRule> rules = cce.getRules();
String functionName = cce.getFunctionName();
StringBuilder errorMsg = new StringBuilder(functionName + com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Formula_Check_Condition_Tips") + ":");
return errorMsg.toString();
} catch (FunctionCheckWrongException ce) {
List<FunctionRule> rules = ce.getRules();
String functionName = ce.getFunctionName();

Loading…
Cancel
Save