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 account invoice split modules #97
Conversation
d4c9aca
to
70d4ee9
Compare
- TESTS="1" ODOO_REPO="odoo/odoo" INCLUDE="account_invoice_validation_workflow" | ||
- TESTS="1" ODOO_REPO="OCA/OCB" INCLUDE="account_invoice_validation_workflow" | ||
- TESTS="1" ODOO_REPO="odoo/odoo" INCLUDE="account_invoice_split_sale,account_invoice_split" |
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 this can't be tested together with the rest?
2505c2b
to
785cfda
Compare
I did a functional test for a purchase and sale workflow on runbot. It works well. In the split wizard, the notebook is not necessary: a label would be nicer. Otherwise can you look ater @pedrobaeza 's comments and check why travis is red? |
if vals['invoice_line']: | ||
new_invoice = self.env['account.invoice'].create(vals) | ||
if not new_invoice: | ||
raise exceptions.Warning(_('Nothing to split')) |
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.
Can you write: "There is nothing to split. Please fill the 'quantities to split' column." This would be more explicit for the user.
781a360
to
c0403bc
Compare
FIELD_MAPPING = [('id', 'origin_invoice_line_id'), | ||
('product_id', 'product_id'), | ||
('name', 'name'), | ||
('quantity', 'total_quantity')] |
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.
It's better to have globals immutables. Make FIELD_MAPPING
a tuple instead of a list.
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 you make it inmutable, then you can't extend it, which is the purpose I think
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.
#98 (comment) wisely taught us that its not a good way to extend. So making it immutable will force us to resist the temptation.
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.
OK, I remember. Well then
Travis is red because of odoo/odoo#8593 |
41c048a
to
e6f0cf4
Compare
…alues to create a new record
…ng the previous commit change with copy method
df70d0d
to
4d9fa0b
Compare
Hi @adrienpeiffer what's the state of this? |
@adrienpeiffer Can you have a look? |
There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days. |
This PR adds invoice split functionality.
First, account_invoice_split module which is the main module that allow to split invoice.
After that, there are several auto_install modules that provide a compatibility with other Odoo/OCA modules :
I propose all modules directly because they are all necessary for efficiency with an installation of all modules