Skip to content

Commit a5b2d50

Browse files
manuelregidorangel
authored and
angel
committed
[15.0][FIX]purchase_allowed_product: search product by vendor reference
1 parent d717f93 commit a5b2d50

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

purchase_allowed_product/__manifest__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"website": "https://github.com/OCA/purchase-workflow",
1212
"author": "Akretion, Odoo Community Association (OCA)",
1313
"license": "AGPL-3",
14-
"depends": ["purchase"],
14+
"depends": ["purchase", "base_view_inheritance_extension"],
1515
"data": [
1616
"views/res_partner_views.xml",
1717
"views/account_move_views.xml",

purchase_allowed_product/views/purchase_order_views.xml

+8-8
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,19 @@
2020
expr="//field[@name='order_line']/tree/field[@name='product_id']"
2121
position="attributes"
2222
>
23-
<attribute name="context">{
24-
'restrict_supplier_id': parent.partner_id,
25-
'use_only_supplied_product': parent.use_only_supplied_product
26-
}</attribute>
23+
<attribute name="context" operation="update">
24+
{'restrict_supplier_id': parent.partner_id,
25+
'use_only_supplied_product': parent.use_only_supplied_product}
26+
</attribute>
2727
</xpath>
2828
<xpath
2929
expr="//field[@name='order_line']/form//field[@name='product_id']"
3030
position="attributes"
3131
>
32-
<attribute name="context">{
33-
'restrict_supplier_id': parent.partner_id,
34-
'use_only_supplied_product': parent.use_only_supplied_product
35-
}</attribute>
32+
<attribute name="context" operation="update">
33+
{'restrict_supplier_id': parent.partner_id,
34+
'use_only_supplied_product': parent.use_only_supplied_product}
35+
</attribute>
3636
</xpath>
3737
</field>
3838
</record>

0 commit comments

Comments
 (0)