folder tree translation

Hello,

I am trying to configure Nuxeo to pass from English to French and vice versa. So I set up messages_FR and _EN.properties files in STUDIO interface and the translation works perfectly.

However I did not find how to translate the folder tree. Is this provided in STUDIO? If not, is there a solution outside STUDIO that allows to translate the records of the tree?

0 votes

2 answers

1786 views

ANSWER



Thanks Marwane.

If I understood correctly, your solution does not translate others views/layouts where the folder name could appear?

And if a user create new folder, as Nuxeo Administrator I need to add it in my messages_EN.properties and so on…?

Adding a new field in the folder's create/edit layout, allowing users to type both folders names, the english one and french one, isn't it the right solution?

Thanks for your help :)

0 votes



It depends on what you want to do indeed.

If you need the folders to be translated everywhere and new folders to be translated by any user, what you mention would certainly be best, unfortunately it would also require far more work than the tweak above (maybe… 3-4 days of work from an experienced developer?).

12/16/2013


Indeed you could make it so the folder tree is translated, except not through Studio. You'll have to package a Nuxeo bundle by yourself to override the /incl/tree_explorer.xhtml template, replacing

<h:outputText value="#{nxd:titleOrId(node.document)}" />

(~line 52) with

<h:outputText value="#{messages[nxd:titleOrId(node.document)]}" />

That should do the trick.

However, what complicates things a bit more is that folder labels are used in a lot of other places where you'd have to make the same change: in content views, in the document header, in the breadcrumbs links, etc. So to make Nuxeo consistent in translating such labels everywhere is not that easy.

0 votes