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

[14.0, 15.0] account_move_name_sequence error with credit note on supplier bill #1501

Closed
remi-filament opened this issue Nov 22, 2022 · 2 comments · Fixed by #1514
Closed
Labels

Comments

@remi-filament
Copy link
Contributor

remi-filament commented Nov 22, 2022

Module

account_move_name_sequence

Describe the bug

When creating a credit note on supplier bill, the following validation error is raised :

A move can not be posted with name "/" or empty value
Check the journal sequence, please

To Reproduce

Affected versions: 14.0, 15.0

Steps to reproduce the behavior:

  1. Create a vendor bill and post it
  2. Click on Add credit note
  3. Select "Full refund" or "Full refund and new draft invoice" on wizard then click on Reverse

Expected behavior
Supplier bill should be properly reversed.

Additional context
It took me a while to figure out why this happened only on vendor bills (not on customer invoices) and only when using this reversal wizard, not when posting a proper vendor bill (otherwise it would have been spotted before !).

It seems that the issue is linked to the flushing of account_move fields in account_move _check_duplicate_supplier_reference() function here : https://github.com/odoo/odoo/blob/17a182fb3ee652a8a52654c5707c0ed265404630/addons/account/models/account_move.py#L1798-L1801
Because of new constraint added on account_move from account_move_name_sequence here, this raises the reported ValidationError.

@remi-filament remi-filament changed the title [14.0] account_move_name_sequence error with credit note on supplier bill [14.0, 15.0] account_move_name_sequence error with credit note on supplier bill Nov 22, 2022
@remi-filament
Copy link
Contributor Author

Hi @alexis-via @moylop260 I am not sure how to properly handle this issue, if you have any idea, let me know I could try to propose a PR accordingly !

Thanks !

@fernandahf
Copy link
Contributor

@remi-filament

Could you test the fix, please?

#1514

RodrigoBM added a commit to factorlibre/account-financial-tools that referenced this issue Dec 2, 2022
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
RodrigoBM added a commit to factorlibre/account-financial-tools that referenced this issue Dec 2, 2022
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
RodrigoBM added a commit to factorlibre/account-financial-tools that referenced this issue Dec 2, 2022
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
RodrigoBM added a commit to factorlibre/account-financial-tools that referenced this issue Dec 8, 2022
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
andreagidaltig pushed a commit to vauxoo-dev/account-financial-tools that referenced this issue Sep 30, 2023
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
andreagidaltig pushed a commit to vauxoo-dev/account-financial-tools that referenced this issue Oct 9, 2023
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
andreagidaltig pushed a commit to vauxoo-dev/account-financial-tools that referenced this issue Oct 9, 2023
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
moitabenfdz pushed a commit to DynAppsNV/account-financial-tools that referenced this issue Nov 13, 2023
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
keylor2906 pushed a commit to vauxoo-dev/account-financial-tools that referenced this issue Dec 5, 2023
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
keylor2906 pushed a commit to Vauxoo/account-financial-tools that referenced this issue Dec 5, 2023
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
cormaza pushed a commit to cormaza/account-financial-reporting that referenced this issue Jun 2, 2024
BertVGroenendael pushed a commit to DynAppsNV/account-financial-tools that referenced this issue Oct 16, 2024
…supplier_reference method

same issue OCA#1501
this fix not working for v16 OCA#1514
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants