How to set default language at moodle app

How to set default language at moodle app

por VItalii Hamash -
Número de respostas: 12

If set another language by default, it's doesn't change.

i was attached file below.

at config.json and configconstants.ts  i made changes

"default_lang": "ka",

After building and running, language by default stay english.

I tried set different languages.

but it's doesn't work

Anexo Screenshot from 2020-09-16 04-08-37.png
Anexo Screenshot from 2020-09-16 04-13-14.png
Média das avaliações:  -
Em resposta à VItalii Hamash

Re: How to set default language at moodle app

por Kako Kvantaliani -

I believe, you mean that when you set parameters in config.json and configconstants.ts (like suteurl or default_lang) they are cleared after you run the project right?

Em resposta à VItalii Hamash

Re: How to set default language at moodle app

por Javier Tejera -
Hi there,

you can add forcedefaultlang = true in config.js.

This worked for me.
Em resposta à Javier Tejera

Re: How to set default language at moodle app

por VItalii Hamash -
Hi, Javier
Where is it that file config.js ?
Can you send a path to this file from the root folder to config.js ?
Em resposta à VItalii Hamash

Re: How to set default language at moodle app

por Javier Tejera -
Sure:

src/config.js
Em resposta à Javier Tejera

Re: How to set default language at moodle app

por VItalii Hamash -
Maybe config.json? Because config.js file does not exist.
Anexo Screenshot from 2021-02-04 06-08-06.png
Em resposta à VItalii Hamash

Re: How to set default language at moodle app

por VItalii Hamash -
Or we must create it?
Em resposta à VItalii Hamash

Re: How to set default language at moodle app

por Javier Tejera -
Yes, sorry, it is config.json:


Em resposta à Javier Tejera

Re: How to set default language at moodle app

por VItalii Hamash -
Hello, Javier.
it's not working
By default still, the English language is selected.
Anexo Screenshot from 2021-02-05 07-05-47.png
Em resposta à VItalii Hamash

Re: How to set default language at moodle app

por Javier Tejera -
That's strange, it works for me. Try clearing cache and cookies, run npm start again and also try other browsers.
Em resposta à Javier Tejera

Re: How to set default language at moodle app

por VItalii Hamash -
and for android or ios?
Em resposta à VItalii Hamash

Re: How to set default language at moodle app

por VItalii Hamash -
in production for AOT ?
Em resposta à VItalii Hamash

Re: How to set default language at moodle app

por Javier Tejera -
In my local machine, tried AOT production but I couldn't manage to deploy the app, so not really sure whether it works or not.