[IMP]name get when filling form sale order lines

This commit is contained in:
aaron
2018-05-25 16:48:50 +02:00
committed by ahenriquez
parent d848eacf06
commit 16f3d7a7a0
2 changed files with 4 additions and 1 deletions

View File

@@ -33,8 +33,10 @@ class SaleOrderLine(models.Model):
if self.env.context.get('rma'):
for sale in self:
if sale.order_id.name:
res.append((sale.id, "%s %s qty:%s" % (
res.append((sale.id, "%s %s, %s qty:%s" % (
sale.order_id.name,
" ".join(str(x) for x in [
inv.number for inv in sale.order_id.invoice_ids]),
sale.product_id.name, sale.product_uom_qty)))
else:
res.append(super(SaleOrderLine, sale).name_get()[0])

View File

@@ -17,6 +17,7 @@
</div>
<group name="main_info" position="inside">
<field name="sale_line_id"
context="{'rma': True}"
options="{'no_create': True}"/>
</group>
<group name="quantities" position="inside">