Merge pull request #162 from bsinno/fix_create_filter_has_different_layout_than_rollout_and_the_other_widgets

Create filter has different layout than rollout and the other widgets
This commit is contained in:
Kai Zimmermann
2016-05-24 18:08:09 +02:00
3 changed files with 13 additions and 7 deletions

View File

@@ -13,7 +13,6 @@ import javax.annotation.PostConstruct;
import org.eclipse.hawkbit.repository.SpPermissionChecker;
import org.eclipse.hawkbit.ui.components.SPUIButton;
import org.eclipse.hawkbit.ui.components.SPUIComponentProvider;
import org.eclipse.hawkbit.ui.decorators.SPUIButtonStyleSmall;
import org.eclipse.hawkbit.ui.decorators.SPUIButtonStyleSmallNoBorder;
import org.eclipse.hawkbit.ui.filtermanagement.event.CustomFilterUIEvent;
import org.eclipse.hawkbit.ui.filtermanagement.state.FilterManagementUIState;
@@ -79,9 +78,8 @@ public class TargetFilterHeader extends VerticalLayout {
}
private Label createHeaderCaption() {
final Label captionLabel = SPUIComponentProvider.getLabel("Custom Filters",
return SPUIComponentProvider.getLabel(SPUIDefinitions.TARGET_FILTER_LIST_HEADER_CAPTION,
SPUILabelDefinitions.SP_WIDGET_CAPTION);
return captionLabel;
}
private void buildLayout() {
@@ -110,10 +108,9 @@ public class TargetFilterHeader extends VerticalLayout {
}
private Button createAddButton() {
final Button button = SPUIComponentProvider.getButton("camp.search.add.Id", "Create Filter", "Create Filter",
"", false, null, SPUIButtonStyleSmall.class);
final Button button = SPUIComponentProvider.getButton(SPUIComponetIdProvider.TARGET_FILTER_ADD_ICON_ID, "", "",
null, false, FontAwesome.PLUS, SPUIButtonStyleSmallNoBorder.class);
button.addClickListener(event -> addNewFilter());
button.addStyleName("on-focus-no-border link");
return button;
}

View File

@@ -75,6 +75,11 @@ public final class SPUIComponetIdProvider {
*/
public static final String TARGET_TEXT_FIELD = "target.search.textfield";
/**
* ID for add target filter icon
*/
public static final String TARGET_FILTER_ADD_ICON_ID = "target.filter.add.id";
/**
* ID-Dist.
*/

View File

@@ -922,6 +922,11 @@ public final class SPUIDefinitions {
*/
public static final String CUSTOM_FILTER_ASSIGNED_DS = "Assigned DS";
/**
* TARGET_FILTER_MANAGEMENT - header caption .
*/
public static final String TARGET_FILTER_LIST_HEADER_CAPTION = "Custom Filters";
/**
* CUSTOM_FILTER_STATUS.
*/
@@ -1001,7 +1006,6 @@ public final class SPUIDefinitions {
*/
public static final String ROLLOUT_GROUP_STARTED_DATE = "Started date";
/**
* Rollout group status column property.
*/