[FIX] mrp: bom cost report without lines traceback
Usecase to reproduce: - Create a bom without line - Add a new line without filling the product_id Click on bom cost button that appears It crashes because the xml try to access item dict instead of using get and 'components' and 'lines' both not exist.
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
<template id="report_mrp_bom">
|
||||
<t t-raw="'<base href=%s>' % base_url"/>
|
||||
<div class="container o_mrp_bom_report_page">
|
||||
<t t-if="data['components'] or data['lines']">
|
||||
<t t-if="data.get('components') or data.get('lines')">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<h1>BoM Structure & Cost</h1>
|
||||
|
||||
Reference in New Issue
Block a user