-
-
Notifications
You must be signed in to change notification settings - Fork 387
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
[16.0][IMP] account_reconcile_oca: Add auto-reconcile compatibility (Example: Rule to match invoices/bills) #762
base: 16.0
Are you sure you want to change the base?
Conversation
Hi @etobella, |
…e: Rule to match invoices/bills) TT52146
52b89e6
to
839e42d
Compare
…fields Related to odoo/odoo@8948b31 TT52146
@@ -745,6 +754,7 @@ def create(self, mvals): | |||
models = self.env["account.reconcile.model"].search( | |||
[ | |||
("rule_type", "in", ["invoice_matching", "writeoff_suggestion"]), | |||
("company_id", "in", result.mapped("company_id").ids), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With relation fields, no need to put mapped
:
("company_id", "in", result.mapped("company_id").ids), | |
("company_id", "in", result.company_id.ids), |
@@ -10,6 +10,16 @@ class TestReconciliationWidget(TestAccountReconciliationCommon): | |||
@classmethod | |||
def setUpClass(cls, chart_template_ref=None): | |||
super().setUpClass(chart_template_ref=chart_template_ref) | |||
# Auto-disable reconciliation model created automatically with | |||
# generate_account_reconcile_model() to avoid side effects in tests | |||
cls.invoice_matching_model = cls.env["account.reconcile.model"].search( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it can be more than one, the variable name is not correct
@@ -999,6 +999,7 @@ def test_partner_name_with_parent(self): | |||
) | |||
|
|||
self.invoice_matching_model.active = True | |||
self.invoice_matching_model.match_text_location_label = False |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why a separated commit just for this?
Add auto-reconcile compatibility (Example: Rule to match invoices/bills)
Please @pedrobaeza and @chienandalu can you review it?
@Tecnativa TT52146