i want to get current company id not user default company id ..
Need current Company ID which is selected at the top
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
i want to get current company id not user default company id ..
Need current Company ID which is selected at the top
Hi,
You can get current company from self.env.user.company_id. Company id will change according to the selection in the company switcher.
Thank you
HI,
You can get current user id using
user_id = self.env.user
and you want to user company than use
company_id = user_id.company_id
I think work for you
THANKS
can i get currency_id like this ?
currency_id = user_id.currency_id
Yes, you can get using dot notation as well as the search method.
Create an account today to enjoy exclusive features and engage with our awesome community!
Sign upRelated Posts | Replies | Views | Activity | |
---|---|---|---|---|
|
3
Nov 24
|
346 | ||
|
0
Nov 24
|
149 | ||
|
4
Sep 24
|
1484 | ||
|
2
Aug 24
|
348 | ||
|
0
May 24
|
281 |