[16.0][IMP] Take allow_out_payment into account on payment order#1340
[16.0][IMP] Take allow_out_payment into account on payment order#1340lmarion-source wants to merge 3 commits intoOCA:16.0from
Conversation
9a523ec to
386628a
Compare
acsonefho
left a comment
There was a problem hiding this comment.
GJ 💪
Just a minor change 🙏
386628a to
5f1064e
Compare
5f1064e to
a02bcff
Compare
|
/ocabot merge minor |
|
Hey, thanks for contributing! Proceeding to merge this for you. |
pedrobaeza
left a comment
There was a problem hiding this comment.
I have stopped the merge. AFAIK, @sbidoul commented that wants to be able to add the lines, but not to confirm the order, and this is pre-filtering the non-allowed bank accounts previously if I understand the code right.
|
@adrienpeiffer your merge command was aborted due to failed check(s), which you can inspect on this commit of 16.0-ocabot-merge-pr-1340-by-adrienpeiffer-bump-minor. After fixing the problem, you can re-issue a merge command. Please refrain from merging manually as it will most probably make the target branch red. |
|
@pedrobaeza Not sure to understand. The check is done in draft2open method. |
|
I mean this code for example: It's avoiding to include the lines in the order. |
|
Isn't that exactly the code approved in #1177 ? |
|
OK, I based my review in #1177 (comment). Let me check again. |
|
@lmarion-source Could you remove blank lines (cfr pedro's review) |
It is my impression that Odoo Enterprise works like that, and it makes sense to me, since the process of preparing payment orders is distinct from the process of validating bank accounts, and often done by different persons. So I think it's better to let both processes run in parallel and block at the last moment. Cherry on the cake would be a warning when an non validated bank account is used in a payment line, but that can be done in another PR. |
a02bcff to
565a13b
Compare
|
Hmm, we solved this completely differently. I get the minimal touch here, but we made a seperate module that hit all the places Odoo gets this wrong, mostly purchase order and account move but also payment with a single function on bank to get a valid out payment bank account. Then overrode |
1cd2603 to
adb3c59
Compare
|
@lmarion-source Could you please resolve conflicts ? |
|
ping @lmarion-source |
092cb52 to
534deff
Compare
534deff to
f97f52f
Compare
|
@pedrobaeza can you update your review here? |
| .sudo() | ||
| .get_param("account_payment_order.use_allow_out_payment") | ||
| ): | ||
| payline._check_bank_allows_out_payments() |
There was a problem hiding this comment.
Don't we need to check that payment_type is outbound here? Because this check does not make sense for a debit order.
There was a problem hiding this comment.
@lmarion-source I looks like you have not handled this comment?
|
@lmarion-source can you please check the latest comments? |
f97f52f to
bba476a
Compare
bba476a to
0437b98
Compare
| related="company_id.transfer_journal_id", readonly=False | ||
| ) | ||
| use_allow_out_payment = fields.Boolean( | ||
| string=" Use allow out payment on partner bank", |
There was a problem hiding this comment.
| string=" Use allow out payment on partner bank", | |
| string="Verify that Send Money is enabled on partner bank accounts", |
Is this easier to understand by non technical users?
| </div> | ||
| </div> | ||
| </div> | ||
| </div> |
| .sudo() | ||
| .get_param("account_payment_order.use_allow_out_payment") | ||
| ): | ||
| payline._check_bank_allows_out_payments() |
There was a problem hiding this comment.
@lmarion-source I looks like you have not handled this comment?
A previous MR existed but only when payment order was triggered from invoices. We added the case also directement from confirm button on payment order original PR: OCA#1177
0437b98 to
4ad0f67
Compare
|
rebased |
|
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. |
marcos-mendez
left a comment
There was a problem hiding this comment.
Automated Review -- Tests Passed
All tests for account_payment_order passed successfully on Odoo 16.0.
Environment: Minikube + K8s Job + oca-ci/py3.10-odoo16.0
⚠️ PR Aging Alert: CRITICAL
This PR by @lmarion-source has been waiting for 561 days — that is over 18 months without being merged or closed.
Every ignored PR is a contributor who might not come back. Review time matters. (OCA Aging Report)
Reciprocal Review Request
Hi everyone! Thanks for your contribution to OCA. I reviewed and approved this PR. If any of you have a moment, I would really appreciate a review on my open PR(s):
My open PRs across OCA:
- hr-attendance#262 [16.0][ADD] Hr_attendance_idsecure: iDSecure (ControliD) attendance integration
- stock-logistics-workflow#2276 [16.0][ADD] stock_move_line_devaluation
- stock-logistics-workflow#2275 [16.0][ADD] Stock move line analytic account
- stock-logistics-workflow#2268 [16.0][ADD] stock_move_line_picking_partner
- purchase-workflow#2694 [16.0][IMP]Purchase workflow added to review state & exception fix
Reviewing each other's work helps the whole community move forward faster. Thank you!
Automated review by OCA Neural Reviewer + qwen3-coder:30b

A previous MR existed but only when payment order was triggered from invoices.
We added the case also directly from confirm button on payment order
Original PR: #1177
Closes #1330