Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
2 Trả lời
4545 Lượt xem

I am working on an add-on for Odoo. For that, I want to get the Odoo version add-on is running.


I found a way to find the running Odoo version with Python.

Eg :

version = odoo.release.version


How can I get the Odoo version on a JavaScript add-on file?


Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Hi,

you can get the ODOO Version via the below way and also know the Edition of ODOO from JS.


>> odoo.session_info.server_version_info -->

  1. 013
  2. 10
  3. 20
  4. 3"final"
  5. 40
  6. 5""
 >> odoo.session_info.server_version_info[0]
## 14 (you get ODOO Version Number i.e. 12, 13, 14,...) 
ODOO Edition via this way
>> var isEnterprise = odoo.session_info.server_version_info[5] === 'e';

Thanks & Regards,
Sunny Sheth


Ảnh đại diện
Huỷ bỏ
Tác giả Câu trả lời hay nhất

Thank you, Sunny Sheth. I could get the Odoo version with odoo.session_info.server_version_info[0].

Ảnh đại diện
Huỷ bỏ

Can you please upvote my answer?

so other people can search for a correct answers when they want help on a similar point.

Thanks Wikum

Tác giả

I am sorry. I couldn't do it because I don't have enough karma.

Thanks Wikum

Bài viết liên quan Trả lời Lượt xem Hoạt động
2
thg 2 23
3677
0
thg 2 19
3798
2
thg 7 18
8475
1
thg 12 23
5060
1
thg 12 22
9638