NatLibFi / Skosmos

Thesaurus and controlled vocabulary browser using SKOS and SPARQL
Other
229 stars 95 forks source link

Fallback languages are not correctly used in the hierarchy view #717

Open henriyli opened 6 years ago

henriyli commented 6 years ago

At which URL did you encounter the problem?

http://dev.finto.fi/hero/fi/page/p1535?clang=sv

What steps will reproduce the problem?

  1. Open the above URL

What is the expected output? What do you see instead?

Expected to see consistent fallback labels (in the same language) for the hierarchy view. However, each label seems to fallback to a random language.

This happens as the REST hierarchy query currently supports only using a single fallback. It should be refactored to support queries with a list of prioritized fallback languages.

osma commented 6 years ago

GenericSparql.queryParentList should be passed an array of fallback languages instead of just one. The generateParentListQuery method should then generate one OPTIONAL block per fallback language.

osma commented 6 years ago

Not critical for 2.0, moving to Next Tasks