context = dict(self._context) or {}
context.update({
'manager_id': self.manager_id and self.manager_id.id or False
})
return {
'type': 'ir.actions.act_window',
'res_model': 'abc',
'views': [[self.env.ref('management_module.management_return_form_view').id, 'form']],
'context': context,
'target': 'new',
}
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Бухоблік
- Склад
- PoS
- Project
- MRP
Це запитання позначене
1
Відповісти
8032
Переглядів
update context value starting with default_
eg:
context.update({
'default_manager_id': self.manager_id and self.manager_id.id or False
})
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
РеєстраціяRelated Posts | Відповіді | Переглядів | Дія | |
---|---|---|---|---|
|
1
груд. 18
|
4360 | ||
|
2
трав. 24
|
2595 | ||
|
2
січ. 23
|
4113 | ||
|
0
січ. 21
|
2027 | ||
|
0
черв. 19
|
2603 |
Odoo Tips: https://old.reddit.com/r/learnopenerp/