mirror of
https://github.com/OCA/stock-logistics-warehouse.git
synced 2025-01-21 14:27:28 +02:00
remove field 'available', as it was not correctly defined
This commit is contained in:
committed by
Jordi Ballester Alomar
parent
4e9cde50d4
commit
9937f763f1
@@ -41,10 +41,6 @@ class StockWarehouseOrderpoint(models.Model):
|
||||
virtual_location_qty = fields.Float(
|
||||
string='Forecast On Location',
|
||||
compute='_compute_product_available_qty')
|
||||
|
||||
available = fields.Boolean(
|
||||
string='Is enough product available?',
|
||||
compute='_compute_product_available')
|
||||
product_category = fields.Many2one(string='Product Category',
|
||||
related='product_id.categ_id',
|
||||
store=True)
|
||||
|
||||
@@ -78,9 +78,6 @@ class TestStockWarehouseOrderpoint(common.TransactionCase):
|
||||
|
||||
def test_product_qty(self):
|
||||
"""Tests the product quantity in the Reordering rules"""
|
||||
# Checks the product availability
|
||||
self.reordering_record.refresh()
|
||||
self.assertFalse(self.reordering_record.available)
|
||||
# Create & process moves to test the product quantity
|
||||
move = self.create_stock_move()
|
||||
self.reordering_record.refresh()
|
||||
@@ -98,6 +95,3 @@ class TestStockWarehouseOrderpoint(common.TransactionCase):
|
||||
self.assertEqual(self.reordering_record.virtual_location_qty,
|
||||
self.product.virtual_available,
|
||||
'Virtual Qty does not match')
|
||||
# Checks the product availability after moves processed
|
||||
self.reordering_record.refresh()
|
||||
self.assertTrue(self.reordering_record.available)
|
||||
|
||||
@@ -14,7 +14,6 @@
|
||||
<field name="incoming_location_qty" />
|
||||
<field name="outgoing_location_qty" />
|
||||
<field name="virtual_location_qty" />
|
||||
<field name="available" invisible="1" />
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
@@ -51,11 +50,6 @@
|
||||
domain="[]"
|
||||
context="{'group_by':'product_category'}"/>
|
||||
</filter>
|
||||
<group string="Group By" position="before">
|
||||
<filter string="Availability under minimum"
|
||||
domain="[('available', '=', False)]"
|
||||
context="{}" />
|
||||
</group>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user