Skip to content

Commit

Permalink
Fixed refreshing of iterative info and actions executed panels. Fixed…
Browse files Browse the repository at this point in the history
… setting dryRun.
  • Loading branch information
mederly committed Apr 19, 2016
1 parent a1775ac commit 9937279
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 5 deletions.
Expand Up @@ -47,6 +47,7 @@ public class TaskProgressTabPanel extends AbstractObjectTabPanel<TaskType> imple

private static final Trace LOGGER = TraceManager.getTrace(TaskProgressTabPanel.class);

private IterativeInformationPanel iterativeInformationPanel;
private SynchronizationInformationPanel synchronizationInformationPanelBefore;
private SynchronizationInformationPanel synchronizationInformationPanelAfter;
private ActionsExecutedInformationPanel actionsExecutedInformationPanel;
Expand All @@ -61,13 +62,14 @@ public TaskProgressTabPanel(String id, Form mainForm,

private void initLayout(final IModel<TaskDto> taskDtoModel, PageBase pageBase) {
final TaskCurrentStateDtoModel model = new TaskCurrentStateDtoModel(taskDtoModel);
final IterativeInformationPanel iterativeInformationPanel = new IterativeInformationPanel(ID_ITERATIVE_INFORMATION_PANEL, model, pageBase);
iterativeInformationPanel = new IterativeInformationPanel(ID_ITERATIVE_INFORMATION_PANEL, model, pageBase);
iterativeInformationPanel.add(new VisibleEnableBehaviour() {
@Override
public boolean isVisible() {
return model.getObject().getIterativeTaskInformationType() != null;
}
});
iterativeInformationPanel.setOutputMarkupId(true);
add(iterativeInformationPanel);

synchronizationInformationPanelBefore = new SynchronizationInformationPanel(ID_SYNCHRONIZATION_INFORMATION_PANEL_BEFORE,
Expand Down Expand Up @@ -108,6 +110,7 @@ public boolean isVisible() {
@Override
public Collection<Component> getComponentsToUpdate() {
List<Component> rv = new ArrayList<>();
rv.add(iterativeInformationPanel);
rv.add(synchronizationInformationPanelBefore);
rv.add(synchronizationInformationPanelAfter);
rv.addAll(actionsExecutedInformationPanel.getComponentsToUpdate());
Expand Down
Expand Up @@ -138,7 +138,7 @@ public String getObject() {
@Override
public void onClick(AjaxRequestTarget ajaxRequestTarget) {
showResultingActionsOnly = !showResultingActionsOnly;
ajaxRequestTarget.add(this);
ajaxRequestTarget.add(ActionsExecutedInformationPanel.this);
}
});

Expand Down
Expand Up @@ -222,7 +222,7 @@ public boolean isVisible() {
}
});
optionsContainer.add(dryRunContainer);
CheckBox dryRun = new CheckBox(ID_DRY_RUN, new PropertyModel<Boolean>(getModelObject(), ResourceRelatedHandlerDto.F_DRY_RUN));
CheckBox dryRun = new CheckBox(ID_DRY_RUN, new PropertyModel<Boolean>(getModel(), ResourceRelatedHandlerDto.F_DRY_RUN));
dryRun.add(enabledIfEdit);
dryRunContainer.add(dryRun);
}
Expand Down
Expand Up @@ -40,8 +40,8 @@ public class ResourceRelatedHandlerDto extends HandlerDto {
public static final String F_OBJECT_CLASS = "objectClass";
public static final String F_RESOURCE_REFERENCE = "resourceRef";

public static final String CLASS_DOT = ResourceRelatedHandlerDto.class.getName() + ".";
public static final String OPERATION_LOAD_RESOURCE = CLASS_DOT + "loadResource";
private static final String CLASS_DOT = ResourceRelatedHandlerDto.class.getName() + ".";
private static final String OPERATION_LOAD_RESOURCE = CLASS_DOT + "loadResource";

private static final transient Trace LOGGER = TraceManager.getTrace(ResourceRelatedHandlerDto.class);

Expand Down

0 comments on commit 9937279

Please sign in to comment.