Skip to content

Commit

Permalink
Merge PR #1380 into 17.0
Browse files Browse the repository at this point in the history
Signed-off-by pedrobaeza
  • Loading branch information
OCA-git-bot committed Nov 28, 2024
2 parents 8db0718 + 9963b79 commit 924660f
Showing 1 changed file with 9 additions and 11 deletions.
20 changes: 9 additions & 11 deletions account_payment_order/models/account_move.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,19 +78,17 @@ def _get_payment_order_communication_full(self):
reference_moves |= self.reversal_move_id
# Retrieve partial payments - e.g.: manual credit notes
(
# List of triplets
# (account.partial.reconcile record, amount, account.move.line record)
invoice_partials,
exchange_diff_moves,
# List of account.move IDs
exchange_diff_move_ids,
) = self._get_reconciled_invoices_partials()
for (
_x,
_y,
payment_move_line,
) in invoice_partials + exchange_diff_moves:
payment_move = payment_move_line.move_id
if payment_move not in reference_moves:
references.append(
payment_move._get_payment_order_communication_direct()
)
move_ids = [x[2].move_id.id for x in invoice_partials] + exchange_diff_move_ids
for move in self.browse(move_ids):
if move not in reference_moves:
references.append(move._get_payment_order_communication_direct())
reference_moves |= move
# Add references to communication from lines move
if references:
communication += " " + " ".join(references)
Expand Down

0 comments on commit 924660f

Please sign in to comment.