Make it possible to export and properly query values in components
|Reported by:||Nicklas Nordborg||Owned by:||Nicklas Nordborg|
The ColoringData component is the first component class we use in BASE. However, it came with some limitations. The query system always assumes that property paths with dots (for example scan.protocol.name) are references to other object, but this is not the case for components (for example coloring.minValue). As a result it is not possible to use the auto-join feature of the query. It works for the moment with formulas since the don't have any references and we can safely disable the auto-join. The current implementation will not work if we mix components with references. The problematic code is in the ItemContext.configureQuery method.
The export function doesn't work for a similar reason. The Metadata class can handle property paths with dots (for example: scan.protocol.name) but it assumes that they are references. The Metadata class needs to check the ClassMetadata.getPropertyType() in Hibernate to find out if it is a component or an entity.