2
0

[FIX] account_asset_management: pass for context correct active_id. If not specified the value of active_id will be that of account.asset.line.

This commit is contained in:
Rodrigo 2023-07-05 09:49:37 +02:00
parent e642974d15
commit 03418626d3

View File

@ -40,7 +40,9 @@ class WizAssetMoveReverse(models.TransientModel):
move = self.line_id.move_id
move_reversal = (
self.env["account.move.reversal"]
.with_context(active_model="account.move", active_ids=move.ids)
.with_context(
active_model="account.move", active_ids=move.ids, active_id=move.id
)
.create(
{
"date": fields.Date.today(),