summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--addons/point_of_sale/models/pos_session.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/point_of_sale/models/pos_session.py b/addons/point_of_sale/models/pos_session.py
index 2c0e64986bb..e7feb929024 100644
--- a/addons/point_of_sale/models/pos_session.py
+++ b/addons/point_of_sale/models/pos_session.py
@@ -729,9 +729,9 @@ class PosSession(models.Model):
stock_moves = self.env['stock.move'].search([('picking_id', 'in', pickings.ids)])
stock_account_move_lines = self.env['account.move'].search([('stock_move_id', 'in', stock_moves.ids)]).mapped('line_ids')
for account_id in stock_output_lines:
- ( stock_output_lines[account_id].filtered(lambda aml: not aml.reconciled)
+ ( stock_output_lines[account_id]
| stock_account_move_lines.filtered(lambda aml: aml.account_id == account_id)
- ).reconcile()
+ ).filtered(lambda aml: not aml.reconciled).reconcile()
return data
def _prepare_line(self, order_line):