[FIX] mrp: quick create bom on new mo

Before this commit, an error was raised when you tried to create a
new bill of material on a new manufacturing order.
In fact, the name_create RPC returned 'false' and slow_create()
wasn't executed.

By adding _rec_name (as in 10.0) on the corresponding model, the RPC
call will raise an error that will be caught by quick_create and
forces slow_create().

Closes #9761
This commit is contained in:
Adrien Dieudonne
2018-04-12 11:24:54 +02:00
parent c09b89596e
commit 8c0b23c239
+1
View File
@@ -148,6 +148,7 @@ class mrp_bom(osv.osv):
_name = 'mrp.bom'
_description = 'Bill of Material'
_inherit = ['mail.thread']
_rec_name = 'product_tmpl_id'
_columns = {
'code': fields.char('Reference', size=16),