[bt#35230] Fix issue when uploading an invoice and changing the journal#37140
Open
BT-mromero wants to merge 1 commit into16.0.project_CO_286from
Open
[bt#35230] Fix issue when uploading an invoice and changing the journal#37140BT-mromero wants to merge 1 commit into16.0.project_CO_286from
BT-mromero wants to merge 1 commit into16.0.project_CO_286from
Conversation
…al_id key in write vals if they use import export or any automated action that write same journal then it's take new number. here assume that journal_id is only change on draft and if posted then it's raise error but not consider what is same journal_id come to write. closes odoo#196777 Signed-off-by: William André (wan) <wan@odoo.com>
BT-ssteiner
reviewed
Dec 1, 2025
Comment on lines
2357
to
2361
| # <PATCH> Don't recompute the name if it was already False | ||
| if not draft_move.name: | ||
| # </PATCH> | ||
| draft_move.name = False | ||
| draft_move._compute_name() |
There was a problem hiding this comment.
[question] we should not do changes in odoo core, only cherry picks. Is there really no other option?
The text would suggest the code to be like this:
if draft_move.name:
Because now, it will recompute, if the name was already False
Author
There was a problem hiding this comment.
You are right. I will probably patch the method, but then I will ask first for a change request approval. Thank you
2e265d7 to
ec1d0cd
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of the issue/feature this PR addresses: When changing the journal for a draft imported invoice, the name is being calculated, whereas it should actually remain unset (False).
Current behavior before PR:
Desired behavior after PR is merged:
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr