📜  将参数传递给 odoo 向导 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:13.399000             🧑  作者: Mango

代码示例1
def create_field(self):
    form_view = self.env.ref("your_wizard_form_view_external_id")
    
    return{
       'name': 'Wizard Name',
       'views': [
            (form_view.id, 'form'),
            ],
       'res_model': 'dieu.chinh',
       'target': 'new',
       'type': 'ir.actions.act_window',
       'context': {
             'default_wizard_field_name': self.name.id,  # for passing Many2One field context value in Wizard form view
            },
       }