Revision 2b30a230
Added by Andreas Kohlbecker about 6 years ago
src/main/java/eu/etaxonomy/cdm/service/RegistrationWorkingSetService.java | ||
---|---|---|
57 | 57 |
"typeDesignations.typeStatus", |
58 | 58 |
"typeDesignations.typifiedNames.typeDesignations", // important !! |
59 | 59 |
"typeDesignations.typeSpecimen", |
60 |
"typeDesignations.typeName", |
|
60 |
"typeDesignations.typeName.$",
|
|
61 | 61 |
"typeDesignations.citation", |
62 | 62 |
"typeDesignations.citation.authorship.$", |
63 | 63 |
// name |
... | ... | |
79 | 79 |
private List<String> DERIVEDUNIT_INIT_STRATEGY = Arrays.asList(new String[]{ |
80 | 80 |
"*", // initialize all related entities to allow DerivedUnit conversion, see DerivedUnitConverter.copyPropertiesTo() |
81 | 81 |
"derivedFrom.$", |
82 |
"derivedFrom.type", |
|
82 |
"derivedFrom.type", // TODO remove?
|
|
83 | 83 |
"derivedFrom.originals.derivationEvents", // important!! |
84 | 84 |
"specimenTypeDesignations.typifiedNames.typeDesignations", // important!! |
85 | 85 |
"mediaSpecimen.sources" |
... | ... | |
122 | 122 |
*/ |
123 | 123 |
@Override |
124 | 124 |
public RegistrationDTO loadDtoById(Integer id) { |
125 |
Registration reg = repo.getRegistrationService().find(id);
|
|
125 |
Registration reg = repo.getRegistrationService().load(id, REGISTRATION_INIT_STRATEGY);
|
|
126 | 126 |
inititializeSpecimen(reg); |
127 | 127 |
return new RegistrationDTO(reg); |
128 | 128 |
} |
... | ... | |
200 | 200 |
DerivedUnit derivedUnit = ((SpecimenTypeDesignation) td).getTypeSpecimen(); |
201 | 201 |
@SuppressWarnings("rawtypes") |
202 | 202 |
Set<SpecimenOrObservationBase> sobs = new HashSet<>(); |
203 |
sobs.add(derivedUnit);
|
|
203 |
sobs.add(HibernateProxyHelper.deproxy(derivedUnit));
|
|
204 | 204 |
|
205 | 205 |
while(sobs != null && !sobs.isEmpty()){ |
206 | 206 |
@SuppressWarnings("rawtypes") |
Also available in: Unified diff
adding missing init strategies