diff options
| author | Goffin Simon <sig@odoo.com> | 2018-09-13 16:21:40 +0200 |
|---|---|---|
| committer | Goffin Simon <sig@odoo.com> | 2018-09-17 09:53:25 +0200 |
| commit | a9670cfce5eb81b971f71a38b68351b7e654f3e6 (patch) | |
| tree | bb17b16ce8fcce83a979c54a2211a79efa0f30ff | |
| parent | 2bf3c29b0c2751f994ecc879cceed898ac4ca0c8 (diff) | |
[FIX] account: Reconcile a statement with move line from partner
Steps to reproduce the bug:
- Create a journal "Temporary" with default account
(don't care about the names) with Fixed asset type and reconcile = True
- Create a vendor bill
- Create a payment from this vendor bill in the temporary journal
- Create a bank statement and with a line where you specify the vendor
- Try to reconcile the temporary account with the bank account
Bug:
Impossible because the temporary account item was not displayed
opw:1884376
| -rw-r--r-- | addons/account/models/account_bank_statement.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/account/models/account_bank_statement.py b/addons/account/models/account_bank_statement.py index 54a61a986e6..9db78e9b5d2 100644 --- a/addons/account/models/account_bank_statement.py +++ b/addons/account/models/account_bank_statement.py @@ -569,7 +569,7 @@ class AccountBankStatementLine(models.Model): # Black lines = unreconciled & (not linked to a payment or open balance created by statement domain_matching = [('reconciled', '=', False)] if partner_id or overlook_partner: - domain_matching = expression.AND([domain_matching, [('account_id.internal_type', 'in', ['payable', 'receivable'])]]) + domain_matching = expression.AND([domain_matching, ['|', ('account_id.internal_type', 'in', ['payable', 'receivable']), '&', ('account_id.internal_type', '=', 'other'), ('account_id.reconcile', '=', True)]]) else: # TODO : find out what use case this permits (match a check payment, registered on a journal whose account type is other instead of liquidity) domain_matching = expression.AND([domain_matching, [('account_id.reconcile', '=', True)]]) |
