openerp - 如何在 'actions' 菜单下为 odoo 10 中的一个模型创建多个向导?

标签 openerp odoo-10

如何在一个模型的“ Action ”菜单下创建多个 Action 向导。 例如,我需要在模型 (MyModel) 的“操作”菜单下创建“向导 1、向导 2 和向导 3”。

最佳答案

您可以使用不同的外部 ID 创建。

<act_window name="string"  context="{}" res_model="res_model"
src_model="src_model" id="act_unique_id"/>

<act_window name="string"  context="{}" res_model="res_model"
src_model="src_model" id="act_unique_id1"/>

You need to set context in the action, so when action will call you will get context in python file.

Based on context value you can easily execute your code.

这可能对你有帮助。

关于openerp - 如何在 'actions' 菜单下为 odoo 10 中的一个模型创建多个向导?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45324095/

相关文章:

python - 如何让 OpenERP 中的字段仅在特定的工作流程状态下需要?

openerp - Odoo 未知 currency_field 'currency_id'

wordpress - 在 odoo 中安装 woocommerce 连接器

python - 错误 : "External ID not found in the system" in OpenERP

odoo - Odoo常用方法 'execute_kw'中,后缀 'kw'指的是什么?

model - 如何制作字段取决于 product.product 的 lst_price 但可以编辑

configuration - 如何在不同的机器上运行 OpenERP 6.1 Web

python-3.x - 我可以从odoo 10,11中的location_id获取warehouse_id吗

jquery - 如何在 odoo 9 中使用 jQuery 显示警告消息

database - Odoo 客户端错误 : "Widget type ' html' is not implemented"after database transfer (Odoo 10. 0-20170708)