From a3258c7402ca0da86315d8eba0e48d4b629e6b32 Mon Sep 17 00:00:00 2001 From: tpylak <tpylak> Date: Wed, 6 Oct 2010 11:38:16 +0000 Subject: [PATCH] minor: do not show material type in the well tooltip SVN: 18181 --- .../application/detailviewers/PlateLayouter.java | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/screening/source/java/ch/systemsx/cisd/openbis/plugin/screening/client/web/client/application/detailviewers/PlateLayouter.java b/screening/source/java/ch/systemsx/cisd/openbis/plugin/screening/client/web/client/application/detailviewers/PlateLayouter.java index c3b8fff18ab..8d5f261ab38 100644 --- a/screening/source/java/ch/systemsx/cisd/openbis/plugin/screening/client/web/client/application/detailviewers/PlateLayouter.java +++ b/screening/source/java/ch/systemsx/cisd/openbis/plugin/screening/client/web/client/application/detailviewers/PlateLayouter.java @@ -317,7 +317,7 @@ public class PlateLayouter for (IEntityProperty property : properties) { PropertyType propertyType = property.getPropertyType(); - tooltip += "<br>" + propertyType.getLabel() + ": " + property.tryGetAsString(); + tooltip += "<br>" + propertyType.getLabel() + ": " + getPropertyDisplayText(property); Material material = property.getMaterial(); if (material != null && material.getMaterialType().getCode() @@ -338,6 +338,18 @@ public class PlateLayouter } + private static String getPropertyDisplayText(IEntityProperty property) + { + Material material = property.getMaterial(); + if (material != null) + { + return material.getCode(); + } else + { + return property.tryGetAsString(); + } + } + private static String getWellDescription(WellMetadata metadata) { return "Well: " + metadata.getWellSample().getSubCode(); -- GitLab