[FIX] purchase_product_matrix: Fix product creation from PO line

closes odoo/odoo#49829

Taskid: 2234570
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
This commit is contained in:
Yannick Tivisse
2020-04-21 08:19:20 +00:00
parent 1d30a4cd44
commit 1ba9bef148
@@ -103,7 +103,7 @@ var MatrixConfiguratorWidget = relationalFields.FieldMany2One.extend({
this._super.apply(this, arguments);
if (ev.data.changes && ev.data.changes.product_template_id) {
if (ev.data.changes && ev.data.changes.product_template_id && ev.data.changes.product_template_id.id) {
self._onTemplateChange(ev.data.changes.product_template_id.id, ev.data.dataPointID);
}
},