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

[11.0][MIG] account_invoice_ubl #46

Merged
merged 24 commits into from
Aug 2, 2018
Merged

[11.0][MIG] account_invoice_ubl #46

merged 24 commits into from
Aug 2, 2018

Conversation

astirpe
Copy link
Member

@astirpe astirpe commented Feb 9, 2018

@astirpe astirpe mentioned this pull request Feb 9, 2018
27 tasks
@pedrobaeza pedrobaeza added this to the 11.0 milestone Feb 9, 2018
@pedrobaeza
Copy link
Member

Please rebase removing last WIP commit.

@pedrobaeza pedrobaeza requested a review from cubells July 5, 2018 15:54
Account Invoice UBL
===================

This module adds support for UBL, the `Universal Business Language (UBL) <http://ubl.xml.org/>`_ standard, on invoices. The UBL 2.1 standard became the `ISO/IEC 19845 <http://www.iso.org/iso/catalogue_detail.htm?csnumber=66370>`_ standard in December 2015 (cf the `official announce <http://www.prweb.com/releases/2016/01/prweb13186919.htm>_`).
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

Too large. Change to

This module adds support for UBL, the `Universal Business Language (UBL)
<http://ubl.xml.org/>`_ standard, on invoices. The UBL 2.1 standard became the
`ISO/IEC 19845 <http://www.iso.org/iso/catalogue_detail.htm?csnumber=66370>`_
standard in December 2015 (cf the `official announce
<http://www.prweb.com/releases/2016/01/prweb13186919.htm>`_).

Copy link
Sponsor Member

Choose a reason for hiding this comment

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

symbol _ after `

Configuration
=============

In the menu *Invoicing > Configuration > Settings > Invoicing*, under *Electronic Invoices*, check the value of 2 options:
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

Too large. Change to

In the menu *Invoicing > Configuration > Settings > Invoicing*, under
*Electronic Invoices*, check the value of 2 options:


In the menu *Invoicing > Configuration > Settings > Invoicing*, under *Electronic Invoices*, check the value of 2 options:

* *XML Format embedded in PDF invoice* : if you want to have an UBL XML file embedded inside the PDF invoice, set it to *Universal Business Language (UBL)*
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

Too large. Change to

* *XML Format embedded in PDF invoice* : if you want to have an UBL XML file
   embedded inside the PDF invoice, set it to
   *Universal Business Language (UBL)*

In the menu *Invoicing > Configuration > Settings > Invoicing*, under *Electronic Invoices*, check the value of 2 options:

* *XML Format embedded in PDF invoice* : if you want to have an UBL XML file embedded inside the PDF invoice, set it to *Universal Business Language (UBL)*
* if you work directly with XML invoices and you want to have the PDF invoice in base64 inside the XML file, enable the *Embed PDF in UBL XML Invoice*.
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

Too large. Change to:

* if you work directly with XML invoices and you want to have the PDF invoice
  in base64 inside the XML file, enable the *Embed PDF in UBL XML Invoice*.

@@ -0,0 +1,23 @@
# © 2016-2018 Akretion (Alexis de Lattre <alexis.delattre@akretion.com>)
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

Change symbol © to Copyright

@@ -0,0 +1,26 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
© 2017 Akretion (Alexis de Lattre <alexis.delattre@akretion.com>)
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

Change symbol © to Copyright

@@ -1,2 +1,6 @@
partner-contact
community-data-files
edi https://github.com/onesteinbv/edi 11_mig_base_ubl
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

All these lines are not necessary if you rebase your pr.

order_ref_id.text = self.name

@api.multi
def _ubl_get_contract_document_reference_dict(self):
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

I don't understand why this method. One record is ensured in parent method, and this do nothing.

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't understand either 🤔

Copy link
Member Author

Choose a reason for hiding this comment

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

@cubells is it ok for you to leave this method as it is and move forward?

ns, version=version)

@api.multi
def get_delivery_partner(self):
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

This method either. This is not used anymore in module. And if is an inheritance, class method is name def get_delivery_partner_id() in AccountInvoice class.

Copy link
Member Author

Choose a reason for hiding this comment

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

I will cherry pick commit 4ac8b4a that removes this method and the other useless code

self._ubl_add_customer_party(
self.partner_id, False, 'AccountingCustomerParty', xml_root, ns,
version=version)
# delivery_partner = self.get_delivery_partner()
Copy link
Sponsor Member

Choose a reason for hiding this comment

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

These commented lines are correct?

Copy link
Sponsor Member

@cubells cubells left a comment

Choose a reason for hiding this comment

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

Check tests. Fail in local database.

alexis-via and others added 19 commits July 5, 2018 19:07
Print numbers with the approriate number of digits in the XML
Add support for partner bank matching on invoice update (before, it was only supported on invoice creation)
Rename __openerp__.py to __manifest__.py and set installable to False
Also port all the modules that generate the XML documents: account_invoice_ubl, account_invoice_zugferd, purchase_order_ubl and sale_order_ubl
Rename account_invoice_import_zugferd to account_invoice_import_factur-x
Add module to support py3o reporting engine:
Add active buttons on invoice import config
… module

Fix spelling mistake and other remarks on README by Tarteo
Add ubl invoice generation option in accounting config page
…xist in v10) in account_invoice_factur-x and account_invoice_ubl
Add script mass_invoice_import.py
Code cleanup
* sale_order_ubl + purchase_order_ubl: restore get_pdf() in tests using HttpCase

* Restore get_pdf() in tests of account_invoice_factur-x and account_invoice_ubl modules

* Update oca_dependencies.txt
… embedding in PDF between account_invoice_factur-x and account_invoice_ubl
@astirpe
Copy link
Member Author

astirpe commented Jul 6, 2018

Tests are failing because of these two lines in Odoo V11.

When running tests, if the test_report_directory is not set in the configuration, the method render_qweb_pdf() will not return a PDF; instead it returns the HTML by invoking render_qweb_html().

I tried locally: commenting out the two lines above will make the tests passing.

Is there a way to set test_report_directory for this repo, in order to make tests passing?

@astirpe astirpe mentioned this pull request Jul 6, 2018
1 task
@coveralls
Copy link

coveralls commented Jul 6, 2018

Coverage Status

Coverage increased (+28.7%) to 64.789% when pulling a07ca34 on onesteinbv:11_mig_account_invoice_ubl into 85144d0 on OCA:11.0.

@astirpe
Copy link
Member Author

astirpe commented Jul 6, 2018

For this branch I'm passing the option --test-report-directory=/tmp to Odoo, in order to make tests running properly.
See a07ca34

@pedrobaeza pedrobaeza merged commit 25b27c6 into OCA:11.0 Aug 2, 2018
@astirpe astirpe deleted the 11_mig_account_invoice_ubl branch August 2, 2018 08:41
@astirpe
Copy link
Member Author

astirpe commented Aug 2, 2018

Thanks!

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.

None yet

6 participants