[IMP] crm, hr_recruitment: add default model when creating activity types

Purpose is to help managers in their daily use of activities. When creating
a new activity type through an app-dedicated menu we should pre-fill the
model with the main app model. This is already done in several applications.
This commit fixes some applications where it was not done.

This commit is linked to task ID 1844644 and PR #25843.
This commit is contained in:
Thibault Delavallée
2018-07-26 17:14:46 +02:00
parent 0bf4986cf6
commit ec2b6d5b63
2 changed files with 2 additions and 0 deletions
+1
View File
@@ -258,6 +258,7 @@
<record id="sales_team.mail_activity_type_action_config_sales" model="ir.actions.act_window">
<field name="domain">['|', ('res_model_id', '=', False), ('res_model_id.model', 'in', ['crm.lead', 'res.partner'])]</field>
<field name="context">{'default_res_model': 'crm.lead'}</field>
</record>
</odoo>
@@ -7,6 +7,7 @@
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="domain">['|', ('res_model_id', '=', False), ('res_model_id.model', '=', 'hr.applicant')]</field>
<field name="context">{'default_res_model': 'hr.applicant'}</field>
</record>
<menuitem id="hr_recruitment_menu_config_activity_type"
action="mail_activity_type_action_config_hr_applicant"