Commit 7975fd33 authored by Romain Bioteau's avatar Romain Bioteau
Browse files

EA-266 Add a warning

Alert user that only process scope variables can be used here 
parent 862f8bcf
......@@ -260,7 +260,7 @@ public class GroovyViewer implements IDocumentListener {
if (context != null && filters != null) {
for (final Expression exp : expressions) {
for (final ViewerFilter filter : filters) {
if (filter != null && !filter.select(viewer, input, exp)) {
if (filter != null && !filter.select(viewer, context, exp)) {
filteredExpressions.remove(exp);
}
}
......
......@@ -322,3 +322,4 @@ targetParameterForInput=Target in called process
sectionDescriptionOverviewForm=Legacy mode for backward compatibility.\nYou can maintain an existing overview here until it is migrated.\nYou can create an overview using the legacy tooling, but we recommend that you use the UI Designer to create any new overview.\nThere is also a default overview page available if you choose the UI Designer type.If you use a 6.x overview pageflow, go to Execution > Overview page and select the type 6.x
sectionDescriptionEntryForm=Legacy mode for backward compatibility.\nYou can maintain existing forms here until they are migrated.\nYou can create a form using the legacy tooling, but we recommend that you create a contract and use the UI Designer to create any new form. If you use a 6.x form, go to Execution > Form and select the type 6.x
sectionDescriptionProcessEntryForm=Legacy mode for backward compatibility.\nYou can maintain existing forms here until they are migrated.\nYou can create a form using the legacy tooling, but we recommend that you create a contract and use the UI Designer to create any new form. If you use a 6.x form, go to Execution > Instantiation form and select the type 6.x
processScopeVariableWarning=Only process scope variables can be used in expressions below
\ No newline at end of file
......@@ -454,6 +454,8 @@ public class Messages extends NLS {
public static String sectionDescriptionEntryForm;
public static String sectionDescriptionProcessEntryForm;
public static String processScopeVariableWarning;
static {
// initialize resource bundle
NLS.initializeMessages(BUNDLE_NAME, Messages.class);
......
......@@ -26,6 +26,7 @@ import org.bonitasoft.studio.common.emf.tools.ModelHelper;
import org.bonitasoft.studio.common.jface.databinding.CustomEMFEditObservables;
import org.bonitasoft.studio.common.log.BonitaStudioLog;
import org.bonitasoft.studio.common.properties.AbstractBonitaDescriptionSection;
import org.bonitasoft.studio.common.properties.Well;
import org.bonitasoft.studio.common.repository.RepositoryManager;
import org.bonitasoft.studio.data.ui.property.section.DataLabelProvider;
import org.bonitasoft.studio.expression.editor.constant.ExpressionReturnTypeContentProvider;
......@@ -184,9 +185,14 @@ public class IterationPropertySection extends AbstractBonitaDescriptionSection {
private Composite createStandardLoopContent(final Composite stackedComposite, final TabbedPropertySheetWidgetFactory widgetFactory) {
final Composite standardLoopComposite = widgetFactory.createPlainComposite(stackedComposite, SWT.NONE);
standardLoopComposite.setLayout(GridLayoutFactory.fillDefaults().numColumns(3).extendedMargins(0, 0, 20, 0).create());
standardLoopComposite.setLayout(GridLayoutFactory.fillDefaults().numColumns(3).extendedMargins(0, 0, 10, 0).create());
widgetFactory.createLabel(standardLoopComposite, "", SWT.NONE);//FIILER
widgetFactory.createLabel(standardLoopComposite, "", SWT.NONE);//FILLER
final Well well = new Well(standardLoopComposite, Messages.processScopeVariableWarning, widgetFactory, IStatus.WARNING);
well.setLayoutData(GridDataFactory.swtDefaults().grab(false, false).span(2, 1).create());
widgetFactory.createLabel(standardLoopComposite, "", SWT.NONE);//FILLER
final Button testAfterButton = widgetFactory.createButton(standardLoopComposite, Messages.testAfterLabel, SWT.RADIO);
testAfterButton.setLayoutData(GridDataFactory.swtDefaults().create());
......@@ -222,6 +228,7 @@ public class IterationPropertySection extends AbstractBonitaDescriptionSection {
context.bindValue(ViewersObservables.observeSingleSelection(loopConditionExpressionViewer), CustomEMFEditObservables.observeDetailValue(
Realm.getDefault(), selectionObservable, ProcessPackage.Literals.MULTI_INSTANTIABLE__LOOP_CONDITION));
widgetFactory.createLabel(standardLoopComposite, Messages.maximumLoopLabel).setLayoutData(
GridDataFactory.fillDefaults().align(SWT.END, SWT.CENTER).create());
......
Markdown is supported
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