'Implementation of removal strategies.
:return: a structure containing an ordered list of tuples: quants and
the quantity to remove from them. A tuple (None, qty)
represents a qty not possible to reserve.'

def _quants_get_reservation(self, quantity, move, ops=False, domain=None, orderby=None, removal_strategy=None):

    if removal_strategy:
        order = self._quants_removal_get_order(removal_strategy)
    elif orderby:
        order = orderby
    else:
        order = 'in_date'
    rounding = move.product_id.uom_id.rounding
    domain = (domain if (domain is not None) else [('qty', '>', 0.0)])
    res = []
    offset = 0
    remaining_quantity = quantity
    quants = self.search(domain, order=order, limit=10, offset=offset)
    while ((float_compare(remaining_quantity, 0, precision_rounding=rounding) > 0) and quants):
        for quant in quants:
            if (float_compare(remaining_quantity, abs(quant.qty), precision_rounding=rounding) >= 0):
                res += [(quant, abs(quant.qty))]
                remaining_quantity -= abs(quant.qty)
            elif (float_compare(remaining_quantity, 0.0, precision_rounding=rounding) != 0):
                res += [(quant, remaining_quantity)]
                remaining_quantity = 0
        offset += 10
        quants = self.search(domain, order=order, limit=10, offset=offset)
    if (float_compare(remaining_quantity, 0, precision_rounding=rounding) > 0):
        res.append((None, remaining_quantity))
    return res
