Browse Source

[IMP] cpo: add forecast qty to cpo view

pull/145/head
robin.keunen 6 years ago
parent
commit
6154a98329
  1. 2
      compute_purchase_order/models/computed_purchase_order_line.py
  2. 1
      compute_purchase_order/views/computed_purchase_order.xml

2
compute_purchase_order/models/computed_purchase_order_line.py

@ -56,7 +56,7 @@ class ComputedPurchaseOrderLine(models.Model):
'into account incoming orders.') 'into account incoming orders.')
virtual_available = fields.Float( virtual_available = fields.Float(
string='Stock Quantity',
string='Forecast Quantity',
related='product_template_id.virtual_available', related='product_template_id.virtual_available',
read_only=True, read_only=True,
help='Virtual quantity taking into account current stock, incoming ' help='Virtual quantity taking into account current stock, incoming '

1
compute_purchase_order/views/computed_purchase_order.xml

@ -58,6 +58,7 @@
<tree string="Order Lines" editable='bottom'> <tree string="Order Lines" editable='bottom'>
<field name="product_template_id" domain="[('main_seller_id', '=', cpo_seller_id)]"/> <field name="product_template_id" domain="[('main_seller_id', '=', cpo_seller_id)]"/>
<field name="qty_available" readonly='1'/> <field name="qty_available" readonly='1'/>
<field name="virtual_available" readonly='1'/>
<field name="uom_id" readonly='1'/> <field name="uom_id" readonly='1'/>
<field name="average_consumption" readonly='1'/> <field name="average_consumption" readonly='1'/>
<field name="stock_coverage" readonly='1'/> <field name="stock_coverage" readonly='1'/>

Loading…
Cancel
Save