Currently develop external ecommerce website for a customer, Is it possible to call "product.category" in other language in Odoo16. Since now there is only english and I already add more language on translation page.
What I do before with Product name is that adding "context": {"lang": "ko_KR"} to the code.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Księgowość
- Zapasy
- PoS
- Project
- MRP
To pytanie dostało ostrzeżenie
1
Odpowiedz
2119
Widoki
To display the "product.category" field in Korean (ko_KR), you can modify your code as follows:
category_name = product.category.display_name
translated_category_name = product.category.with_context(lang='ko_KR').display_name
Podoba Ci się ta dyskusja? Dołącz do niej!
Stwórz konto dzisiaj, aby cieszyć się ekskluzywnymi funkcjami i wchodzić w interakcje z naszą wspaniałą społecznością!
Zarejestruj sięPowiązane posty | Odpowiedzi | Widoki | Czynność | |
---|---|---|---|---|
|
0
kwi 23
|
2568 | ||
Odoo 16
Rozwiązane
|
|
1
gru 22
|
4584 | |
Translations in Odoo 16 Online
Rozwiązane
|
|
8
paź 25
|
7409 | |
|
3
mar 24
|
3455 | ||
|
1
lut 24
|
3410 |