Alona Kaplan has uploaded a new change for review. Change subject: webadmin: Vlan id should be shown next to vlan device name ......................................................................
webadmin: Vlan id should be shown next to vlan device name In order to show the vlan id next to the vlan device name some changes were done to the host interface sub tab. 1. Removing the address from the brackets next to the vlan device and bond name. 2. Moving the adress column to the VLanPanel next to the network column. All the addresses, vlan and non-vlan will be shown in this column. 3. Splitting the Interface panel into two panels- InterfacePanel and StatisticsPanel. The StatisticsPanel will be the last panel- after the VLanPanel. Notice: there were some look-and-feel issues caused to this tab in commit 0248286a6b70ffe9076731aea406fdbfd6a97b0a. This patch doesn't fix them. Change-Id: Ia900e7d293df479cd9c98cfe66dcd0cb8b1f4fe4 Signed-off-by: Alona Kaplan <[email protected]> --- M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/hosts/HostInterfaceListModel.java M frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/section/main/view/tab/host/SubTabHostInterfaceView.java M frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/BondPanel.java M frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/HostInterfaceForm.java M frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/InterfacePanel.java A frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/StatisticsPanel.java M frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/VLanPanel.java D frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostInterfaceBondNameRenderer.java M frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostVLanNameRenderer.java 9 files changed, 162 insertions(+), 106 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/31/27631/1 diff --git a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/hosts/HostInterfaceListModel.java b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/hosts/HostInterfaceListModel.java index b395f7f..7834111 100644 --- a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/hosts/HostInterfaceListModel.java +++ b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/hosts/HostInterfaceListModel.java @@ -534,6 +534,7 @@ model.setVLans(new ArrayList<HostVLan>()); model.setNetworkName(nic.getNetworkName()); model.setIsManagement(nic.getIsManagement()); + model.setAddress(nic.getAddress()); return model; } diff --git a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/section/main/view/tab/host/SubTabHostInterfaceView.java b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/section/main/view/tab/host/SubTabHostInterfaceView.java index 0d2ef93..c870593 100644 --- a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/section/main/view/tab/host/SubTabHostInterfaceView.java +++ b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/section/main/view/tab/host/SubTabHostInterfaceView.java @@ -28,7 +28,7 @@ import com.google.gwt.user.client.ui.VerticalPanel; public class SubTabHostInterfaceView extends AbstractSubTabFormView<VDS, HostListModel, HostInterfaceListModel> - implements SubTabHostInterfacePresenter.ViewDef { + implements SubTabHostInterfacePresenter.ViewDef { interface ViewIdHandler extends ElementIdHandler<SubTabHostInterfaceView> { ViewIdHandler idHandler = GWT.create(ViewIdHandler.class); @@ -51,7 +51,10 @@ @Inject public SubTabHostInterfaceView(SearchableDetailModelProvider<HostInterfaceLineModel, HostListModel, HostInterfaceListModel> modelProvider, - EventBus eventBus, ClientStorage clientStorage, ApplicationConstants constants, ApplicationTemplates templates) { + EventBus eventBus, + ClientStorage clientStorage, + ApplicationConstants constants, + ApplicationTemplates templates) { super(modelProvider); table = new SimpleActionTable<HostInterfaceLineModel>(modelProvider, @@ -74,17 +77,28 @@ } void initTable(ApplicationConstants constants, ApplicationTemplates templates) { + // Interface Panel table.addColumn(new EmptyColumn(), constants.empty(), "30px"); //$NON-NLS-1$ table.addColumn(new EmptyColumn(), constants.nameInterface(), "210px"); //$NON-NLS-1$ - table.addColumn(new EmptyColumn(), constants.addressInterface(), "210px"); //$NON-NLS-1$ - table.addColumn(new EmptyColumn(), constants.macInterface(), "210px"); //$NON-NLS-1$ - table.addColumnWithHtmlHeader(new EmptyColumn(), templates.sub(constants.speedInterface(), constants.mbps()).asString(), "105px"); //$NON-NLS-1$ - table.addColumnWithHtmlHeader(new EmptyColumn(), templates.sub(constants.rxInterface(), constants.mbps()).asString(), "105px"); //$NON-NLS-1$ - table.addColumnWithHtmlHeader(new EmptyColumn(), templates.sub(constants.txInterface(), constants.mbps()).asString(), "105px"); //$NON-NLS-1$ - table.addColumnWithHtmlHeader(new EmptyColumn(), templates.sub(constants.dropsInterface(), constants.pkts()).asString(), "105px"); //$NON-NLS-1$ + + // Bond Panel table.addColumn(new EmptyColumn(), constants.bondInterface(), "210px"); //$NON-NLS-1$ + + // Vlan Panel table.addColumn(new EmptyColumn(), constants.vlanInterface(), "210px"); //$NON-NLS-1$ table.addColumn(new EmptyColumn(), constants.networkNameInterface(), "210px"); //$NON-NLS-1$ + table.addColumn(new EmptyColumn(), constants.addressInterface(), "210px"); //$NON-NLS-1$ + + // Statistics Panel + table.addColumn(new EmptyColumn(), constants.macInterface(), "210px"); //$NON-NLS-1$ + table.addColumnWithHtmlHeader(new EmptyColumn(), templates.sub(constants.speedInterface(), constants.mbps()) + .asString(), "105px"); //$NON-NLS-1$ + table.addColumnWithHtmlHeader(new EmptyColumn(), templates.sub(constants.rxInterface(), constants.mbps()) + .asString(), "105px"); //$NON-NLS-1$ + table.addColumnWithHtmlHeader(new EmptyColumn(), templates.sub(constants.txInterface(), constants.mbps()) + .asString(), "105px"); //$NON-NLS-1$ + table.addColumnWithHtmlHeader(new EmptyColumn(), templates.sub(constants.dropsInterface(), constants.pkts()) + .asString(), "105px"); //$NON-NLS-1$ table.addActionButton(new WebAdminButtonDefinition<HostInterfaceLineModel>(constants.addEditInterface()) { @Override @@ -126,7 +140,8 @@ } }); - //The table items are in the form, so the table itself will never have items, so don't display the 'empty message' + // The table items are in the form, so the table itself will never have items, so don't display the 'empty + // message' table.table.setEmptyTableWidget(null); } diff --git a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/BondPanel.java b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/BondPanel.java index ade78cd..694bacb 100644 --- a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/BondPanel.java +++ b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/BondPanel.java @@ -40,7 +40,7 @@ } // Bond name - add(new Label(new HostInterfaceBondNameRenderer().render(lineModel))); + add(new Label(lineModel.getBondName())); } else { add(new Label("")); //$NON-NLS-1$ } diff --git a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/HostInterfaceForm.java b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/HostInterfaceForm.java index 8ef2e14..4aaecda 100644 --- a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/HostInterfaceForm.java +++ b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/HostInterfaceForm.java @@ -21,10 +21,11 @@ @SuppressWarnings("unchecked") public HostInterfaceForm(final HostInterfaceListModel listModel) { isSelectionAvailable = listModel.getIsSelectionAvailable(); - grid = new Grid(1, 3); - grid.getColumnFormatter().setWidth(0, "1080px"); //$NON-NLS-1$ + grid = new Grid(1, 4); + grid.getColumnFormatter().setWidth(0, "240px"); //$NON-NLS-1$ grid.getColumnFormatter().setWidth(1, "210px"); //$NON-NLS-1$ - grid.getColumnFormatter().setWidth(2, "420px"); //$NON-NLS-1$ + grid.getColumnFormatter().setWidth(2, "630px"); //$NON-NLS-1$ + grid.getColumnFormatter().setWidth(3, "630px"); //$NON-NLS-1$ grid.setWidth("100%"); //$NON-NLS-1$ grid.setHeight("100%"); //$NON-NLS-1$ initWidget(grid); @@ -81,6 +82,14 @@ return panel; } + StatisticsPanel createStatisticsPanel(HostInterfaceLineModel lineModel) { + StatisticsPanel panel = new StatisticsPanel(); + panel.setWidth("100%"); //$NON-NLS-1$ + panel.setHeight("100%"); //$NON-NLS-1$ + panel.addInterfaces(lineModel.getInterfaces()); + return panel; + } + void showModels(List<HostInterfaceLineModel> interfaceLineModels) { this.setVisible(true); grid.resizeRows(interfaceLineModels.size()); @@ -90,6 +99,7 @@ setGridWidget(row, 0, createInterfacePanel(lineModel)); setGridWidget(row, 1, createBondPanel(lineModel)); setGridWidget(row, 2, createVLanPanel(lineModel)); + setGridWidget(row, 3, createStatisticsPanel(lineModel)); row++; } } diff --git a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/InterfacePanel.java b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/InterfacePanel.java index 398b7a2..6ba130f 100644 --- a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/InterfacePanel.java +++ b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/InterfacePanel.java @@ -3,11 +3,7 @@ import java.util.List; import org.ovirt.engine.ui.common.widget.TogglePanel; -import org.ovirt.engine.ui.common.widget.renderer.RxTxRateRenderer; -import org.ovirt.engine.ui.common.widget.renderer.SumUpRenderer; import org.ovirt.engine.ui.uicommonweb.models.hosts.HostInterface; -import org.ovirt.engine.ui.webadmin.gin.ClientGinjectorProvider; -import org.ovirt.engine.ui.webadmin.widget.label.LabelWithToolTip; import com.google.gwt.dom.client.Style; import com.google.gwt.dom.client.Style.BorderStyle; @@ -25,6 +21,7 @@ super(); this.isSelectionAvailable = isSelectionEnabled; } + public void addInterfaces(List<HostInterface> interfaces) { for (HostInterface hostInterface : interfaces) { add(new InterfaceElementPanel(hostInterface, isSelectionAvailable)); @@ -43,7 +40,7 @@ } Grid createRow(final HostInterface hostInterface) { - Grid row = new Grid(1, 8); + Grid row = new Grid(1, 2); row.setHeight("100%"); //$NON-NLS-1$ row.setWidth("100%"); //$NON-NLS-1$ @@ -54,17 +51,11 @@ row.getColumnFormatter().setWidth(0, "30px"); //$NON-NLS-1$ row.getColumnFormatter().setWidth(1, "210px"); //$NON-NLS-1$ - row.getColumnFormatter().setWidth(2, "210px"); //$NON-NLS-1$ - row.getColumnFormatter().setWidth(3, "210px"); //$NON-NLS-1$ - row.getColumnFormatter().setWidth(4, "105px"); //$NON-NLS-1$ - row.getColumnFormatter().setWidth(5, "105px"); //$NON-NLS-1$ - row.getColumnFormatter().setWidth(6, "105px"); //$NON-NLS-1$ - row.getColumnFormatter().setWidth(7, "105px"); //$NON-NLS-1$ // Check box and interface status icon row.setWidget(0, 0, new FlowPanel() { { - if (isSelectionAvailable){ + if (isSelectionAvailable) { add(getCheckBox()); } @@ -74,54 +65,6 @@ // Name row.setWidget(0, 1, new Label(hostInterface.getName())); - - // Address - row.setWidget(0, 2, new Label(hostInterface.getAddress())); - - // MAC - LabelWithToolTip macLabel = new LabelWithToolTip(hostInterface.getMAC(), 17); - row.setWidget(0, 3, macLabel); - - // Speed - row.setWidget(0, 4, new Label() { - { - if (hostInterface.getSpeed() != null) { - setText(String.valueOf(hostInterface.getSpeed())); - } else { - setText(ClientGinjectorProvider.getApplicationConstants().unAvailablePropertyLabel()); - } - } - }); - - // Rx rate - row.setWidget(0, 5, new Label() { - { - setText(new RxTxRateRenderer().render(new Double[] { - hostInterface.getRxRate(), - hostInterface.getSpeed() != null ? hostInterface.getSpeed().doubleValue() : null - })); - } - }); - - // Tx rate - row.setWidget(0, 6, new Label() { - { - setText(new RxTxRateRenderer().render(new Double[] { - hostInterface.getTxRate(), - hostInterface.getSpeed() != null ? hostInterface.getSpeed().doubleValue() : null - })); - } - }); - - // Drops - row.setWidget(0, 7, new Label() { - { - setText(new SumUpRenderer().render(new Double[] { - hostInterface.getRxDrop(), - hostInterface.getTxDrop() - })); - } - }); return row; } diff --git a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/StatisticsPanel.java b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/StatisticsPanel.java new file mode 100644 index 0000000..907a4b1 --- /dev/null +++ b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/StatisticsPanel.java @@ -0,0 +1,99 @@ +package org.ovirt.engine.ui.webadmin.widget.host; + +import java.util.List; + +import org.ovirt.engine.ui.common.widget.TogglePanel; +import org.ovirt.engine.ui.common.widget.renderer.RxTxRateRenderer; +import org.ovirt.engine.ui.common.widget.renderer.SumUpRenderer; +import org.ovirt.engine.ui.uicommonweb.models.hosts.HostInterface; +import org.ovirt.engine.ui.webadmin.gin.ClientGinjectorProvider; +import org.ovirt.engine.ui.webadmin.widget.label.LabelWithToolTip; + +import com.google.gwt.dom.client.Style; +import com.google.gwt.dom.client.Style.BorderStyle; +import com.google.gwt.dom.client.Style.Unit; +import com.google.gwt.user.client.ui.Grid; +import com.google.gwt.user.client.ui.Label; +import com.google.gwt.user.client.ui.VerticalPanel; + +public class StatisticsPanel extends VerticalPanel { + + public void addInterfaces(List<HostInterface> interfaces) { + for (HostInterface hostInterface : interfaces) { + add(new StatisticsElementPanel(hostInterface)); + } + } +} + +class StatisticsElementPanel extends TogglePanel { + + public StatisticsElementPanel(HostInterface hostInterface) { + super(hostInterface); + add(createRow(hostInterface)); + } + + Grid createRow(final HostInterface hostInterface) { + Grid row = new Grid(1, 5); + row.setHeight("100%"); //$NON-NLS-1$ + row.setWidth("100%"); //$NON-NLS-1$ + + Style gridStyle = row.getElement().getStyle(); + gridStyle.setBorderColor("white"); //$NON-NLS-1$ + gridStyle.setBorderWidth(1, Unit.PX); + gridStyle.setBorderStyle(BorderStyle.SOLID); + + row.getColumnFormatter().setWidth(0, "210px"); //$NON-NLS-1$ + row.getColumnFormatter().setWidth(1, "105px"); //$NON-NLS-1$ + row.getColumnFormatter().setWidth(2, "105px"); //$NON-NLS-1$ + row.getColumnFormatter().setWidth(3, "105px"); //$NON-NLS-1$ + row.getColumnFormatter().setWidth(4, "105px"); //$NON-NLS-1$ + + // MAC + LabelWithToolTip macLabel = new LabelWithToolTip(hostInterface.getMAC(), 17); + row.setWidget(0, 0, macLabel); + + // Speed + row.setWidget(0, 1, new Label() { + { + if (hostInterface.getSpeed() != null) { + setText(String.valueOf(hostInterface.getSpeed())); + } else { + setText(ClientGinjectorProvider.getApplicationConstants().unAvailablePropertyLabel()); + } + } + }); + + // Rx rate + row.setWidget(0, 2, new Label() { + { + setText(new RxTxRateRenderer().render(new Double[] { + hostInterface.getRxRate(), + hostInterface.getSpeed() != null ? hostInterface.getSpeed().doubleValue() : null + })); + } + }); + + // Tx rate + row.setWidget(0, 3, new Label() { + { + setText(new RxTxRateRenderer().render(new Double[] { + hostInterface.getTxRate(), + hostInterface.getSpeed() != null ? hostInterface.getSpeed().doubleValue() : null + })); + } + }); + + // Drops + row.setWidget(0, 4, new Label() { + { + setText(new SumUpRenderer().render(new Double[] { + hostInterface.getRxDrop(), + hostInterface.getTxDrop() + })); + } + }); + + return row; + } + +} diff --git a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/VLanPanel.java b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/VLanPanel.java index 62f01b4..0584332 100644 --- a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/VLanPanel.java +++ b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/host/VLanPanel.java @@ -19,8 +19,9 @@ public class VLanPanel extends VerticalPanel { - public static final String CHECK_BOX_COLUMN_WIDTH = "50%"; //$NON-NLS-1$ - public static final String NETWORK_NAME_COLUMN_WIDTH = "50%"; //$NON-NLS-1$ + public static final String CHECK_BOX_COLUMN_WIDTH = "210px"; //$NON-NLS-1$ + public static final String NETWORK_NAME_COLUMN_WIDTH = "210px"; //$NON-NLS-1$ + public static final String ADDRESS_COLUMN_WIDTH = "210px"; //$NON-NLS-1$ private final boolean isSelectionAvailable; @@ -28,17 +29,18 @@ super(); this.isSelectionAvailable = isSelectionEnabled; } + public void addVLans(HostInterfaceLineModel lineModel) { boolean hasVlan = lineModel.getVlanSize() != 0; for (HostVLan hostVLan : lineModel.getVLans()) { add(new VLanElementPanel(hostVLan, isSelectionAvailable)); } - if (!hasVlan || !StringHelper.isNullOrEmpty(lineModel.getNetworkName())){ + if (!hasVlan || !StringHelper.isNullOrEmpty(lineModel.getNetworkName()) + || !StringHelper.isNullOrEmpty(lineModel.getAddress())) { add(new VLanElementPanel(lineModel)); } } - } class VLanElementPanel extends TogglePanel { @@ -57,11 +59,11 @@ } Grid createRow(final HostVLan hostVLan) { - Grid row = new Grid(1, 2); + Grid row = new Grid(1, 3); row.getColumnFormatter().setWidth(0, VLanPanel.CHECK_BOX_COLUMN_WIDTH); row.getColumnFormatter().setWidth(1, VLanPanel.NETWORK_NAME_COLUMN_WIDTH); - row.getCellFormatter().setHeight(0, 0, "100%"); //$NON-NLS-1$ - row.getCellFormatter().setHeight(0, 1, "100%"); //$NON-NLS-1$ + row.getColumnFormatter().setWidth(2, VLanPanel.ADDRESS_COLUMN_WIDTH); + row.setWidth("100%"); //$NON-NLS-1$ row.setHeight("100%"); //$NON-NLS-1$ @@ -74,7 +76,7 @@ HorizontalPanel chekboxPanel = new HorizontalPanel(); chekboxPanel.setWidth("100%"); //$NON-NLS-1$ - if (isSelectionAvailable){ + if (isSelectionAvailable) { chekboxPanel.add(getCheckBox()); } chekboxPanel.add(new Image(ClientGinjectorProvider.getApplicationResources().splitRotateImage())); @@ -92,15 +94,18 @@ row.setWidget(0, 1, networkName); + // Address + row.setWidget(0, 2, new Label(hostVLan.getAddress())); + return row; } Grid createBlankRow(final HostInterfaceLineModel lineModel) { - Grid row = new Grid(1, 2); + Grid row = new Grid(1, 3); row.getColumnFormatter().setWidth(0, VLanPanel.CHECK_BOX_COLUMN_WIDTH); row.getColumnFormatter().setWidth(1, VLanPanel.NETWORK_NAME_COLUMN_WIDTH); - row.getCellFormatter().setHeight(0, 0, "100%"); //$NON-NLS-1$ - row.getCellFormatter().setHeight(0, 1, "100%"); //$NON-NLS-1$ + row.getColumnFormatter().setWidth(2, VLanPanel.ADDRESS_COLUMN_WIDTH); + row.setWidth("100%"); //$NON-NLS-1$ row.setHeight("100%"); //$NON-NLS-1$ @@ -117,6 +122,9 @@ row.setWidget(0, 1, networkName); + // Address + row.setWidget(0, 2, new Label(lineModel.getAddress())); + return row; } diff --git a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostInterfaceBondNameRenderer.java b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostInterfaceBondNameRenderer.java deleted file mode 100644 index 7e3f9dc..0000000 --- a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostInterfaceBondNameRenderer.java +++ /dev/null @@ -1,20 +0,0 @@ -package org.ovirt.engine.ui.webadmin.widget.renderer; - -import org.ovirt.engine.ui.uicommonweb.models.hosts.HostInterfaceLineModel; - -import com.google.gwt.text.shared.AbstractRenderer; - -public class HostInterfaceBondNameRenderer extends AbstractRenderer<HostInterfaceLineModel> { - - @Override - public String render(HostInterfaceLineModel object) { - StringBuilder sb = new StringBuilder(object.getBondName()); - - if (object.getAddress() != null && !object.getAddress().isEmpty()) { - sb.append(" (").append(object.getAddress()).append(")"); //$NON-NLS-1$ //$NON-NLS-2$ - } - - return sb.toString(); - } - -} diff --git a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostVLanNameRenderer.java b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostVLanNameRenderer.java index 9200366..9cbc943 100644 --- a/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostVLanNameRenderer.java +++ b/frontend/webadmin/modules/webadmin/src/main/java/org/ovirt/engine/ui/webadmin/widget/renderer/HostVLanNameRenderer.java @@ -10,8 +10,8 @@ public String render(HostVLan object) { StringBuilder sb = new StringBuilder(object.getName()); - if (object.getAddress() != null && !object.getAddress().isEmpty()) { - sb.append(" (").append(object.getAddress()).append(")"); //$NON-NLS-1$ //$NON-NLS-2$ + if (object.getInterface().getVlanId() != null) { + sb.append(" (").append(object.getInterface().getVlanId()).append(")"); //$NON-NLS-1$ //$NON-NLS-2$ } return sb.toString(); -- To view, visit http://gerrit.ovirt.org/27631 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia900e7d293df479cd9c98cfe66dcd0cb8b1f4fe4 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Alona Kaplan <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
