Tryton - Issues



Author bernatnan
Recipients ced, reviewbot
Date 2020-06-30.19:13:58
Sorry, that's not what I'm trying to explain on the comment that trigger this issue (from I suppose that I haven't explained well.

The problem is that when you make a sale with all the remaining stock that you have, when "do" de move and the product stock become 0, the price not become 0€, it's remain like the cost_price of the move. So the problem is not in the "recompute_cost_price_fifo" function, it's in the, and for me the solutions will be in the "_compute_product_cost_price" function, that it's in "stock" module, file:

Replacing the 498 line for:

if product_qty + qty == 0:
    new_cost_price = Decimal(0)
elif product_qty + qty > 0 and product_qty >= 0:
Date User Action Args
2020-06-30 19:13:59bernatnansetmessageid: <>
2020-06-30 19:13:59bernatnansetrecipients: + ced, reviewbot
2020-06-30 19:13:59bernatnanlinkissue9443 messages
2020-06-30 19:13:58bernatnancreate

Showing 10 items. Show all history (warning: this could be VERY long)