Skip to content
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

8.0 Add support for partner bank matching on invoice update #6

Merged
merged 2 commits into from
Oct 18, 2016

Conversation

alexis-via
Copy link
Contributor

Add support for partner bank matching on invoice update. Before, this feature was only supported on invoice creation. I developed this new feature this afternoon for my demo at my Odoo experience conference.

@coveralls
Copy link

coveralls commented Oct 5, 2016

Coverage Status

Coverage increased (+0.002%) to 81.938% when pulling c9beb1c on akretion:8odoo-experience-improvements into 684c8ea on OCA:8.0.

iban = iban.replace(' ', '')
rpbo = self.env['res.partner.bank']
self._cr.execute(
"""SELECT id FROM res_partner_bank
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why make this with SQL?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I need the replace() method in SQL because the IBAN can have spaces in res_partner_bank. In v9, this problem is solved by the acc_number_sanitized field, so I will remove this SQL request in v9 and use the ORM instead.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK

'acc_number': iban,
'bank_bic': bic,
})
chatter_msg.append(_(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have to modify the translations due to this file change I think

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Translations are handled automatically via transifex, no ?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but you will lose any of the already present translations. It's just to check and modify translation files to see the comment line about the code that contains this sentence.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are no translation for this module so far.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK

@@ -238,6 +238,36 @@ def _match_shipping_partner(self, shipping_dict, partner, chatter_msg):
return partner

@api.model
def _match_partner_bank(
self, partner, iban, bic, chatter_msg, create_if_not_found=False):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To make it more tolerant, put chatter_msg as optional.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mmm, it is that way in all the other methods of this module.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But you can start with this one being more tolerant 😉 for reusing it in models without chatter.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When I'll change that, I'll change it everywhere ; I don't want to do it partially.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a good moment for that 😉, but I know that you're not going to do it, hehe

I didn't update sale_commercial_partner because this module will have to be moved to sale-workflow
@coveralls
Copy link

coveralls commented Oct 11, 2016

Coverage Status

Coverage increased (+0.002%) to 81.938% when pulling 3337d07 on akretion:8odoo-experience-improvements into 684c8ea on OCA:8.0.

Copy link
Member

@pedrobaeza pedrobaeza left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Squashing on merging

@pedrobaeza
Copy link
Member

@alexis-via, what are the plans for bringing this to v9?

@alexis-via
Copy link
Contributor Author

I'll port it to v10 in December 2016 or January 2017 (when my customers will go live on v10) ; I don't want to start the port too early because I still have things that I want to change on v8 and I would like to avoid too much backporting work. The 2 points I want to address are:

  • the support of sale order import when your products have a price-include=True taxes
  • add support for importing an invoice from a foreign country with VAT that you can't get back

I don't have any plans for v9, but my port to v10 should be compatible with v9 I guess.

@pedrobaeza
Copy link
Member

OK, thanks for sharing your plans. I'm not sure how to act because we need it on v9, but only for commodity (not mandatory requirement), but we want it now. I'll tell you later.

@pedrobaeza pedrobaeza merged commit 4ef7cb6 into OCA:8.0 Oct 18, 2016
njeudy pushed a commit to njeudy/edi that referenced this pull request Jan 27, 2018
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
njeudy pushed a commit to njeudy/edi that referenced this pull request Jan 27, 2018
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
hbrunn pushed a commit that referenced this pull request Feb 21, 2018
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
njeudy pushed a commit to njeudy/edi that referenced this pull request Oct 2, 2018
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
astirpe pushed a commit to njeudy/edi that referenced this pull request Oct 12, 2018
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
aronabencherif pushed a commit to xcgd/edi that referenced this pull request Nov 7, 2023
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
TDu pushed a commit to camptocamp/edi that referenced this pull request Nov 22, 2023
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
TDu pushed a commit to camptocamp/edi that referenced this pull request Nov 22, 2023
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
TDu pushed a commit to camptocamp/edi that referenced this pull request Nov 22, 2023
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
IT-Ideas pushed a commit to acsone/edi that referenced this pull request Nov 23, 2023
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
jbaudoux pushed a commit to jbaudoux/edi that referenced this pull request Dec 11, 2023
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
jbaudoux pushed a commit to jbaudoux/edi that referenced this pull request Dec 15, 2023
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
thienvh332 pushed a commit to camptocamp/edi that referenced this pull request Dec 28, 2023
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
JaumeBforgeFlow pushed a commit to ForgeFlow/edi that referenced this pull request Jan 22, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
JaumeBforgeFlow pushed a commit to ForgeFlow/edi that referenced this pull request Jan 22, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
gurneyalex pushed a commit to gurneyalex/edi that referenced this pull request Feb 20, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
nguyenminhchien pushed a commit to nguyenminhchien/edi that referenced this pull request Feb 20, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
nguyenminhchien pushed a commit to nguyenminhchien/edi that referenced this pull request Feb 20, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
Wodran14 pushed a commit to DynAppsNV/edi that referenced this pull request Jun 3, 2024
PEP8 fix

8.0 Add support for partner bank matching on invoice update (OCA#6)

Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)

8.0 Use try/except when importing external libs (OCA#8)

[FIX] LINT

Use try/except when importing external libs
Remove self.ensure_one() that has nothing to do in an api.model method
Wodran14 pushed a commit to DynAppsNV/edi that referenced this pull request Jun 4, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
antonioburic pushed a commit to antonioburic/edi that referenced this pull request Jul 8, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Nov 7, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Nov 7, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Nov 7, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Nov 7, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
jbaudoux pushed a commit to jbaudoux/edi that referenced this pull request Dec 4, 2024
Add ecino as switzerland maintainer
jbaudoux pushed a commit to jbaudoux/edi that referenced this pull request Dec 4, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
jbaudoux pushed a commit to jbaudoux/edi that referenced this pull request Dec 4, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Dec 5, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Dec 5, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Dec 5, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
HeliconiaSolutions pushed a commit to HeliconiaIO/edi that referenced this pull request Dec 9, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
baguenth referenced this pull request in AmetrasIntelligence/edi Dec 10, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Dec 11, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
V3st1g3 pushed a commit to V3st1g3/oca-edi that referenced this pull request Dec 11, 2024
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants