On 18/01/2017 13:44, Francesco Chicchiriccò wrote:
On 18/01/2017 13:40, Tech wrote:
Dear all,
we need to create custom attributes in Syncope, but we realized the
correspondence 1:1 with Key/Column/Label.
For example we might need to display some attributes that should not
be read necessary in English and that could contain accents.
For example we imagine something like this:
firstname: {
"lang":"en" {
"value":"Name"
},
"lang":"fr": {
"value":"Prénom"
}
}
In this case we could keep a stick reference for the name, in our
case "firstname", but after display in a different way (and language)
and being able to implement also accents: is there a way to do it?
The EndUser UI already provides translation features: take a look at
the JSON files available under
enduser/src/main/webapp/app/languages/
You have a directory for each language available, and two files in
each directory: 'static.json' for application messages and
'dynamic.json' for labels (including attributes).
I have added this information (and a bit more) to the reference guide:
https://ci.apache.org/projects/syncope/reference-guide.html#customization-enduser-translations
Regards.
--
Francesco Chicchiriccò
Tirasa - Open Source Excellence
http://www.tirasa.net/
Member at The Apache Software Foundation
Syncope, Cocoon, Olingo, CXF, OpenJPA, PonyMail
http://home.apache.org/~ilgrosso/