-
Notifications
You must be signed in to change notification settings - Fork 2
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
[IMP] improve selection of invoices to pay #5
[IMP] improve selection of invoices to pay #5
Conversation
Since the field is required and payment modes may exist when account_banking_payment_export is installed, a default value is necessary to let Odoo set the required database constraint.
…method on account_banking_payment_export addons
[IMP] sepa: make it easier to extend structured communication types
[FIX] Bug OCA#96 bad use of new API
@@ -45,9 +46,33 @@ def default_get(self, field_list): | |||
def extend_payment_order_domain(self, payment_order, domain): | |||
if payment_order.payment_order_type == 'payment': | |||
domain += [('account_id.type', 'in', ('payable', 'receivable')), | |||
('amount_to_pay', '>', 0)] | |||
('credit', '>', 0)] |
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.
amount_to_pay still exists in account_payment. I think we should use that amount to take into account also possible refunds.
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.
@pedrobaeza can you point me where? On my local copy of the 8.0 branch I can't find amount_to_pay anywhere in the code. I may have missed something.
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.
Sorry, it was in 7.0 (https://github.com/odoo/odoo/blob/7.0/addons/account_payment/account_move_line.py#L29), but it has been removed in 8.0.
Are you taken into account currencies and so on?
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 should be ok wrt currencies. See amount_residual_currency below.
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 not using then amount_residual_currency?
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.
For several reasons:
- amount_residual_currency is not searchable
- it is done this way in the official module
- it would not be better than credit > 0 for the purpose of searching lines to pay
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'm still not sure about this serving for refunds, but I need to investigate. In direct debit we will need something similar (remove amount_to_receive). Doesn't it?
…g party identifier
Replace tabs by spaces in mandate views account_banking_mandate/views/account_banking_mandate_view.xml: convert from dos to unix format
Use widget=selection for payment_mode_id fields Update demo data
account_payment_partner : remove unused file + cleanup code
1f533d9
to
9473250
Compare
Rebased |
👍 |
[IMP] set default value for payment.mode.type
…export-ape [IMP] set complete domain before calling extend_payment_order_domain met...
…yment-sbi 8.0 migration of account_banking_payment
[Usability] mandates: search by reference, add group_by, add seq type in tree view
…r_fix [FIX] account_banking_pain_base: Set a general rule for the initiating party identifier
…selection [FIX] Cannot extend selection if object is not fully initialized
…selection [FIX] Don't break inheritance chain
…idget 8.0 use sale_ok and purchase_ok filters in partner/sale/purchase form views
This fixes OCA#93. - filter invoices that are already in draft and open payment orders. - use residual amount to care for partial reconciliations and align with official 8.0
5a6dcdc
to
cb02532
Compare
…nciled then write new values on this partial reconcile
[FIX] better filtering of move lines already included in open payment order
This fixes OCA#93.