yuuvis® RAD Q&A

0 votes
by (890 points)

Hello OS-Team,

We are working on an application to display information about different documents stored in yuuvis. The application uses the REST interface to get the information.

Because we have users from all over the world we want to publish the application also in other languages then German.

Unfortunately I am not able to get values from a codesystem in another language. It seems that the returned value in label is always the default representation, which is german.

I tried the endpoints "/rest-ws/service/system/cs/list?elements=true", "/rest-ws/service/dms/{0}" and "/rest-ws/service/system/type/list"

Changing the language in the client manually to English or changing the language via REST-Call "/rest-ws/service/user/locale/" does not change the language of the value returned.

Is there a possibility to get a value of a codesystem-entry in a specific language or to get all languages of a codesystem-entry?

Thank you for the help in advance.

schulerb

1 Answer

0 votes
by (19.6k points)
selected by
 
Best answer

Hello schulerb,

in general, passing the header "accept-language" with the desired language abbreviation (de, en, fr, pt, zh etc.) as the value will give you the translateable fields, like the title, in the desired language.
The indexdata fields, including the catalogs, are only returned with their data value. To also get the translated display values of the catalogs, you have to append the url-parameter "datameta=true".
If you really want to have all available translations, you further have to append the url-parameter "_alllocales=true". This only works in combination with the "datameta" parameter. So the url should look like this "...?datameta=true&_alllocales=true".

Best regards
Nicolai

by (890 points)
This works. Thank you!
by (890 points)
Hello,

is seems the mentions solution doesn't work fo the Search Service API.
It seems to always return the german language.

Is it also possible to get a specific language via the Search Service API?

Greetings,
schulerb
by (890 points)
I figured it out myself. The DMS Service accepts "EN" and "en" as  accept-language.
The Search Service API only accepts "en".

Related questions

...