Commit 40942b97 authored by azara's avatar azara
Browse files

BS-14227 Errors in tooltip of error decorator for invalid form entry

remove white space
parent 5d4a8557
......@@ -6,8 +6,8 @@ widgetRepository=Custom Widgets
externalURL=External URL
targetForm=Target form
url=URL
pageDoesntExists=Page with id "{0}" does not exist.
formDoesntExists=Form with id "{0}" does not exist.
pageDoesntExist=Page with id \"{0}\" does not exist.
formDoesntExist=Form with id \"{0}\" does not exist.
caseStartFormMappingDescription=Select the type of form used to instantiate the process. Subscription edition: With "Live Update", you can update your process live to map a different form after deployment.
entryFormMappingDescription=Select the type of form used to fulfill the contract. Subscription edition: With "Live Update", you can update your process live to map a different form after deployment.
caseOverviewFormMappingDescription=The overview page is displayed in Bonita BPM Portal when you click the Overview button in the Case details page. There are no restrictions on the information that this page can include. If you do not specify a page, a default overview page is provided.
......
......@@ -29,7 +29,7 @@ public class Messages extends NLS {
public static String externalURL;
public static String targetForm;
public static String url;
public static String pageDoesntExists;
public static String pageDoesntExist;
public static String caseStartFormMappingDescription;
public static String entryFormMappingDescription;
public static String caseOverviewFormMappingDescription;
......@@ -65,7 +65,7 @@ public class Messages extends NLS {
public static String noFormMessageOnTask;
public static String noFormMessageOnProcess;
public static String urlNotDefined;
public static String formDoesntExists;
public static String formDoesntExist;
static {
NLS.initializeMessages("messages", Messages.class);
......
......@@ -53,9 +53,12 @@ public class FormReferenceExpressionValidator implements IExpressionValidator {
public IStatus validate(final Object value) {
final String content = inputExpression.getContent();
final WebPageRepositoryStore repositoryStore = repositoryAccessor.getRepositoryStore(WebPageRepositoryStore.class);
final String errorMessage = ProcessPackage.Literals.RECAP_FLOW__OVERVIEW_FORM_MAPPING.equals(feature) ? Messages.bind(Messages.pageDoesntExists,
String.format("%s (%s)", inputExpression.getName(), content)) : Messages.bind(Messages.formDoesntExists,
String.format("%s (%s)", inputExpression.getName(), content));
String errorMessage = null;
if (ProcessPackage.Literals.RECAP_FLOW__OVERVIEW_FORM_MAPPING.equals(feature)) {
errorMessage = Messages.bind(Messages.pageDoesntExist, content);
} else {
errorMessage = Messages.bind(Messages.formDoesntExist, content);
}
return repositoryStore.getChild(content) == null ? ValidationStatus.error(errorMessage) : ValidationStatus.ok();
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment