From a704c987f86cf077727eceeffe38732428085c85 Mon Sep 17 00:00:00 2001 From: gpawel <gpawel> Date: Wed, 7 Nov 2012 14:17:18 +0000 Subject: [PATCH] getting closer with metaproject updates SVN: 27546 --- .../etlserver/registrator/api/v1/impl/ConversionUtils.java | 4 ++-- .../generic/shared/basic/dto/BasicMetaprojectUpdates.java | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/datastore_server/source/java/ch/systemsx/cisd/etlserver/registrator/api/v1/impl/ConversionUtils.java b/datastore_server/source/java/ch/systemsx/cisd/etlserver/registrator/api/v1/impl/ConversionUtils.java index 859b2e5e596..6cb203478b8 100644 --- a/datastore_server/source/java/ch/systemsx/cisd/etlserver/registrator/api/v1/impl/ConversionUtils.java +++ b/datastore_server/source/java/ch/systemsx/cisd/etlserver/registrator/api/v1/impl/ConversionUtils.java @@ -396,7 +396,7 @@ public class ConversionUtils { NewMetaproject newMetaproject = new NewMetaproject(metaproject.getName(), metaproject.getDescription(), - metaproject.getOwnerId()); + metaproject.getOwnerId()); newMetaproject.setEntities(metaproject.getAddedEntities()); return newMetaproject; } @@ -406,7 +406,7 @@ public class ConversionUtils MetaprojectUpdatesDTO update = new MetaprojectUpdatesDTO(); update.setMetaprojectId(new TechId(metaproject.getId())); update.setAddedEntities(metaproject.getAddedEntities()); - update.setRemovedEntities(metaproject.getAddedEntities()); + update.setRemovedEntities(metaproject.getRemovedEntities()); return update; } } diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/generic/shared/basic/dto/BasicMetaprojectUpdates.java b/openbis/source/java/ch/systemsx/cisd/openbis/generic/shared/basic/dto/BasicMetaprojectUpdates.java index 649c59f76d9..b7866636b09 100644 --- a/openbis/source/java/ch/systemsx/cisd/openbis/generic/shared/basic/dto/BasicMetaprojectUpdates.java +++ b/openbis/source/java/ch/systemsx/cisd/openbis/generic/shared/basic/dto/BasicMetaprojectUpdates.java @@ -63,11 +63,17 @@ public class BasicMetaprojectUpdates public void setAddedEntities(Collection<? extends IObjectId> addedEntities) { addedSamples = Collections.unmodifiableList(filterSamples(addedEntities)); + addedDataSets = Collections.unmodifiableList(filterDataSets(addedEntities)); + addedExperiments = Collections.unmodifiableList(filterExperiments(addedEntities)); + addedMaterials = Collections.unmodifiableList(filterMaterials(addedEntities)); } public void setRemovedEntities(Collection<? extends IObjectId> removedEntities) { removedSamples = Collections.unmodifiableList(filterSamples(removedEntities)); + removedDataSets = Collections.unmodifiableList(filterDataSets(removedEntities)); + removedExperiments = Collections.unmodifiableList(filterExperiments(removedEntities)); + removedMaterials = Collections.unmodifiableList(filterMaterials(removedEntities)); } public List<ISampleId> getAddedSamples() -- GitLab