Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions addons/stock/models/stock_quant.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,11 +147,12 @@ def quants_reserve(self, quants, move, link=False):
reserved_availability = move.reserved_availability
# split quants if needed
for quant, qty in quants:
if qty <= 0.0 or (quant and quant.qty <= 0.0):
#El siguiente codigo fue modificado por TRESCLOUD
raise UserError(_('No puede reservar una cantidad o un quant negativo, ' + \
'el proceso esta fallando con el siguiente producto: %s.') %
(move.product_id.name_get()[0][1]))
# Se comenta momentaneamenta para escenario de Aditmaq 30-12-2021
# if qty <= 0.0 or (quant and quant.qty <= 0.0):
# #El siguiente codigo fue modificado por TRESCLOUD
# raise UserError(_('No puede reservar una cantidad o un quant negativo, ' + \
# 'el proceso esta fallando con el siguiente producto: %s.') %
# (move.product_id.name_get()[0][1]))
if not quant:
continue
quant._quant_split(qty)
Expand Down