Skip to content

Commit

Permalink
fix for label of options on details page (MID-7271)
Browse files Browse the repository at this point in the history
  • Loading branch information
skublik committed Oct 8, 2021
1 parent a7db70a commit 4d67acf
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ public void onClick(AjaxRequestTarget target) {
return fragment;
}

private boolean isTracingEnabled() {
public boolean isTracingEnabled() {
boolean canRecordTrace;
try {
canRecordTrace = getPageBase().isAuthorized(ModelAuthorizationAction.RECORD_TRACE.getUrl());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<wicket:panel>
<wicket:extend>
<fieldset class="objectButtons">
<legend><wicket:message key="FocusOperationalButtonsPanel.options.tracing"/></legend>
<legend wicket:id="executeOptionsLegend"/>
<div wicket:id="executeOptions"/>
</fieldset>
</wicket:extend>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

import org.apache.wicket.ajax.AjaxRequestTarget;
import org.apache.wicket.behavior.AttributeAppender;
import org.apache.wicket.markup.html.basic.Label;
import org.apache.wicket.markup.repeater.RepeatingView;
import org.apache.wicket.model.Model;

Expand All @@ -30,6 +31,7 @@

public class FocusOperationalButtonsPanel<F extends FocusType> extends AssignmentHolderOperationalButtonsPanel<F> {

private static final String ID_EXECUTE_OPTIONS_LEGEND = "executeOptionsLegend";
private static final String ID_EXECUTE_OPTIONS = "executeOptions";

private final LoadableModel<ExecuteChangeOptionsDto> executeOptionsModel;
Expand Down Expand Up @@ -64,6 +66,10 @@ public boolean isVisible() {

});
add(optionsPanel);

Label legend = new Label(ID_EXECUTE_OPTIONS_LEGEND,
getPageBase().createStringResource("FocusOperationalButtonsPanel.options.tracing." + optionsPanel.isTracingEnabled()));
add(legend);
}

@Override
Expand Down

0 comments on commit 4d67acf

Please sign in to comment.