Browse Source

REPORT-64245 公式错误提示描述再优化

1.特殊处理一下括号
feature/x
Hoky 3 years ago
parent
commit
8e10bef6cf
  1. 2
      designer-base/src/main/java/com/fr/design/formula/exception/function/MismatchedTokenFunction.java

2
designer-base/src/main/java/com/fr/design/formula/exception/function/MismatchedTokenFunction.java

@ -90,6 +90,8 @@ public class MismatchedTokenFunction implements Function<Exception, FormulaCheck
private String tokenName(int tokenType, MismatchedTokenException exception) {
if (tokenType == 0) {
return "<Set of tokens>";
} else if (tokenType == 33 || tokenType == 26 || tokenType == 31) {
return Toolkit.i18nText("Fine-Design_Basic_Formula_Right_Closing_Symbol");
} else {
String[] tokenNames = (String[]) getFieldValue(exception, "tokenNames");
return tokenType >= 0 && tokenType < tokenNames.length ? TranslateTokenUtils.translateToken(tokenNames[tokenType]) : "<" + tokenType + ">";

Loading…
Cancel
Save