Condition depends on the instance language

Tal5
Giga Guru

Hi, everyone,
I would like to get help with issue I am facing.
I have a catalog client script where I remove all options from a variable called category.
I created a condition that the user who has role itil will see a list of categories, otherwise a different list will be displayed.
I want to add a condition that will show me the list in 2 different languages and it all depends on which language the instance is running
Has anyone done this before and can help?
Thanks in advance to all helpers.

2 REPLIES 2

James Chun
Kilo Patron

Hi @Tal5,

 

Are you saying the 'Category' variable should display a list of categories in the user's language?

e.g. if the user's preferred language is English, the category will be in English and if the user's preferred language is French, the list will be in French.

 

If so, sounds like you should activate the Internationalization plugin. Can you elaborate on the requirement/use case bit further?

 

Cheers

Ill try be more specific.

i create new catalog client script,

i used g_form.clearOptions('category')

if(g_user.hasRole('iti'l){

g_form.addOption('category','software'.Software');

...

in this case the list displayed in English no matter what language the instance runs. 

***i allready checked and there is a diffrent label for each language.

 

hope i explain myself clearly  

]