There are cases where we dot NOT want to simply sum the quantities of all the
variants. For example when dealing with manufacturing capacities, we may have
to chose between variants because we can't make ALL of them with the same
components.
So instead of a simple non-modular implementation, we'll let each module define
his own implementation of how to compute the product template's quantity
available for sale.
Conflicts:
stock_available/__openerp__.py
stock_available_immediately/__openerp__.py
* fix the dependencies for the computed field
* use api.multi instead of api.one to avoid calling
super()._immediately_usable_qty in a loop (this improves perfs on a tree view
display)
The previous fix restored stock_available but then there was no way to exclude the incomming moves from the count. This belongs in stock_available_immediately, restoring it cleanly.
This commit also takes care to respect the distinction between templates and variants, so it should fix https://github.com/OCA/stock-logistics-warehouse/issues/73 too.