summaryrefslogtreecommitdiff
path: root/addons/sale_project
diff options
context:
space:
mode:
authorLaurent Stukkens (LTU) <ltu@odoo.com>2020-12-09 12:16:13 +0100
committerXavier BOL (xbo) <xbo@odoo.com>2020-12-21 15:35:20 +0100
commite18229b9a4335e2cfa9d01d11f9e99be2bd99f9c (patch)
treefe745103c238a1b6262539fb64cc31b5c855b15b /addons/sale_project
parent659418a695b9e8ae32ed1ab4aa88b9ebe2b9c665 (diff)
[IMP] project,sale_project: have partner_id many2One behave as in sale.order
Prior to this commit the partners where sorted out by display_name in the task form view. After this commit the will be sorted out by their ranking, as it is the case in sale.order form view. task-2409761
Diffstat (limited to 'addons/sale_project')
-rw-r--r--addons/sale_project/views/project_task_views.xml4
1 files changed, 4 insertions, 0 deletions
diff --git a/addons/sale_project/views/project_task_views.xml b/addons/sale_project/views/project_task_views.xml
index 436eeb0b020..6cb6eb36b28 100644
--- a/addons/sale_project/views/project_task_views.xml
+++ b/addons/sale_project/views/project_task_views.xml
@@ -26,6 +26,10 @@
string="Sales Order"
groups="sales_team.group_sale_salesman"/>
</div>
+ <xpath expr="//field[@name='partner_id']" position="attributes">
+ <attribute name="options">{'always_reload': True}</attribute>
+ <attribute name="context">{'res_partner_search_mode': 'customer'}</attribute>
+ </xpath>
<xpath expr="//field[@name='partner_phone']" position="after">
<field name="sale_order_id" attrs="{'invisible': [('project_id', '!=', False)]}" groups="sales_team.group_sale_salesman"/>
<field name="sale_line_id" string="Sales Order Item" attrs="{'invisible': [('partner_id', '=', False)]}" options='{"no_open": True}' readonly="1" context="{'create': False, 'edit': False, 'delete': False}" groups="sales_team.group_sale_salesman"/>