Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] rma_lot: don't restrict lot if return product is different #442

Draft
wants to merge 1 commit into
base: 16.0
Choose a base branch
from
Draft
Show file tree
Hide file tree
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
3 changes: 2 additions & 1 deletion rma_lot/wizards/stock_return_picking_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,6 @@ class StockReturnPickingLine(models.TransientModel):

def _prepare_rma_vals(self):
vals = super()._prepare_rma_vals()
vals.update({"lot_id": self.lot_id.id})
if not self.rma_operation_id.different_return_product:
vals.update({"lot_id": self.lot_id.id})
return vals
3 changes: 2 additions & 1 deletion rma_sale_lot/wizards/sale_order_line_rma_wizard.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,6 @@ def _compute_lots_visible(self):
def _prepare_rma_values(self):
self.ensure_one()
values = super()._prepare_rma_values()
values["lot_id"] = self.lot_id.id
if not self.operation_id.different_return_product:
values["lot_id"] = self.lot_id.id
return values
Loading