From 2d3ce57395190ed350aff9a14dfe429d01148d30 Mon Sep 17 00:00:00 2001
From: gpawel <gpawel>
Date: Mon, 18 Jul 2011 07:19:31 +0000
Subject: [PATCH] [LMS-2387] - YeastLab fixes

SVN: 22163
---
 .../dss/generic/server/AbstractDatasetDownloadServlet.java | 1 +
 .../bo/managed_property/EntityInformationProvider.java     | 7 ++-----
 .../bsse/cisd/plasmid/dss/PlasmidStorageProcessor.java     | 4 ++--
 3 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/datastore_server/source/java/ch/systemsx/cisd/openbis/dss/generic/server/AbstractDatasetDownloadServlet.java b/datastore_server/source/java/ch/systemsx/cisd/openbis/dss/generic/server/AbstractDatasetDownloadServlet.java
index 96b2de6be57..28502c54b29 100644
--- a/datastore_server/source/java/ch/systemsx/cisd/openbis/dss/generic/server/AbstractDatasetDownloadServlet.java
+++ b/datastore_server/source/java/ch/systemsx/cisd/openbis/dss/generic/server/AbstractDatasetDownloadServlet.java
@@ -95,6 +95,7 @@ abstract public class AbstractDatasetDownloadServlet extends HttpServlet
     static
     {
         MIMETYPES.addMimeTypes("application/pdf pdf");
+        MIMETYPES.addMimeTypes("image/svg+xml svg");
     }
 
     public AbstractDatasetDownloadServlet()
diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/generic/server/business/bo/managed_property/EntityInformationProvider.java b/openbis/source/java/ch/systemsx/cisd/openbis/generic/server/business/bo/managed_property/EntityInformationProvider.java
index d4fb54228b2..077807f19ba 100644
--- a/openbis/source/java/ch/systemsx/cisd/openbis/generic/server/business/bo/managed_property/EntityInformationProvider.java
+++ b/openbis/source/java/ch/systemsx/cisd/openbis/generic/server/business/bo/managed_property/EntityInformationProvider.java
@@ -38,7 +38,6 @@ import ch.systemsx.cisd.openbis.generic.shared.dto.identifier.SampleIdentifierFa
 import ch.systemsx.cisd.openbis.generic.shared.managed_property.EntityLinkElementTranslator;
 import ch.systemsx.cisd.openbis.generic.shared.managed_property.api.IEntityInformationProvider;
 import ch.systemsx.cisd.openbis.generic.shared.managed_property.api.IEntityLinkElement;
-import ch.systemsx.cisd.openbis.generic.shared.util.HibernateUtils;
 
 /**
  * @author Piotr Buczek
@@ -194,12 +193,10 @@ public class EntityInformationProvider implements IEntityInformationProvider
     public String getSamplePropertyValue(String permId, String propertyCode)
     {
         SamplePE sample = getSampleByPermId(permId);
-
-        HibernateUtils.initialize(sample.getProperties());
         for (SamplePropertyPE property : sample.getProperties())
         {
-            if (propertyCode.equalsIgnoreCase(property.getEntityTypePropertyType().getEntityType()
-                    .getCode()))
+            if (propertyCode.equalsIgnoreCase(property.getEntityTypePropertyType()
+                    .getPropertyType().getCode()))
             {
                 return property.getValue();
             }
diff --git a/plasmid/source/java/ch/ethz/bsse/cisd/plasmid/dss/PlasmidStorageProcessor.java b/plasmid/source/java/ch/ethz/bsse/cisd/plasmid/dss/PlasmidStorageProcessor.java
index 9046a3913a5..60595fc53f4 100644
--- a/plasmid/source/java/ch/ethz/bsse/cisd/plasmid/dss/PlasmidStorageProcessor.java
+++ b/plasmid/source/java/ch/ethz/bsse/cisd/plasmid/dss/PlasmidStorageProcessor.java
@@ -67,7 +67,7 @@ public class PlasmidStorageProcessor extends AbstractDelegatingStorageProcessor
 
     private static final String GB_FILE_EXTENSION = ".gb";
 
-    private static final String PNG_FILE_EXTENSION = ".png";
+    private static final String SVG_FILE_EXTENSION = ".svg";
 
     private final PlasMapperUploader uploader;
 
@@ -116,7 +116,7 @@ public class PlasmidStorageProcessor extends AbstractDelegatingStorageProcessor
                         File seqFile = files[0];
 
                         String baseFileName = FilenameUtils.getBaseName(seqFile.getName());
-                        String pngFileName = baseFileName + PNG_FILE_EXTENSION;
+                        String pngFileName = baseFileName + SVG_FILE_EXTENSION;
                         String gbFileName = baseFileName + GB_FILE_EXTENSION;
 
                         File generatedDir = new File(answer, GENERATED_DIR);
-- 
GitLab