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][MIG] account_consolidation: Migration to 14.0 #38

Closed
wants to merge 57 commits into from

Conversation

kaynnan
Copy link

@kaynnan kaynnan commented Jun 13, 2023

cc @marcelsavegnago

Adapted some functionalities to be used as auto_post instead of the no longer present auto_reverse in addons account.

Due to pylint detecting duplicate ID for the demo consolidation_company when accessing the consolidation account, please go to:

  • Settings -> Invoicing -> Consolidation
  • Choose "Consolidation differences" as "CED Consolidation Exchange Differences"
  • Choose "Consolidation journal" as "Consolidation journal."

Below is a screenshot of how it should look like.

Captura de tela de 2023-06-24 03-24-53

@kaynnan kaynnan force-pushed the 14.0-mig-account_consolidation branch 2 times, most recently from cf758ce to ed24e8a Compare June 14, 2023 10:24
@kaynnan kaynnan marked this pull request as ready for review June 14, 2023 10:27
@kaynnan kaynnan force-pushed the 14.0-mig-account_consolidation branch 2 times, most recently from bc26f87 to 3de125f Compare June 14, 2023 20:37
@kaynnan kaynnan marked this pull request as draft June 20, 2023 13:12
@kaynnan kaynnan force-pushed the 14.0-mig-account_consolidation branch 2 times, most recently from 39c7ca4 to 3152616 Compare June 24, 2023 06:19
@kaynnan kaynnan marked this pull request as ready for review June 24, 2023 06:25
Copy link
Member

@douglascstd douglascstd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[FUNCIONAL TEST] NOT APPROVED

There is a problem with calculating the correct currency conversion rate.

Follow the steps to perform the test.
1.Create Jornal Entries in the subsidiaries (A and B)
image
image

  1. Create an entry to currency rate (same month)
    image

  2. Run the consolidation function
    image

  3. Check the created Jornal Entries . (There is an rrror on the currency exchange rate)
    image

I ran the same scenario in the v.12 application, which suggests that the flaw doesn't occur in the v12 application.

@kaynnan
Copy link
Author

kaynnan commented Jun 24, 2023

[FUNCIONAL TEST] NOT APPROVED

There is a problem with calculating the correct currency conversion rate.

Follow the steps to perform the test. 1.Create Jornal Entries in the subsidiaries (A and B) image image

2. Create an entry to currency rate (same month)
   ![image](https://user-images.githubusercontent.com/20867090/248509521-3b4ac750-ef85-4bd2-b0f4-0d415534e537.png)

3. Run the consolidation function
   ![image](https://user-images.githubusercontent.com/20867090/248509527-259a71a3-07d6-4c11-9a4b-a6148129855b.png)

4. Check the created Jornal Entries . (There is an rrror on the currency exchange rate)
   ![image](https://user-images.githubusercontent.com/20867090/248509554-a833209d-9671-4266-9370-83ef79c6d728.png)

I ran the same scenario in the v.12 application, which suggests that the flaw doesn't occur in the v12 application.

I checked the incident, and it's not an error but rather the way the Currency Monthly Rate is configured for the EUR Currency in versions 12 and 14.

In version 12.0, there is no monthly rate defined, whereas in version 14 it was defined as 1.5.

Steps for set rate for Currency Monthly Rate

  • Invoicing -> Configurations ->Accounting -> Currencies
  • Select EUR or USD
  • Set the rate by the Currency Monthly Rate button according to the current month

Currency Monthly Rate not defined
image

Currency Monthly Rate defined in 1.5
image

@hitrosol
Copy link

Having the account_consolidation module is interesting thing, since the Consolidation Module has been moved to the EE version.

I have curious questions:

  1. Any plan to add the features to make different base of exhange rate per group of account ? Usually, the Account in the Income Statement will be factored by the historical exchange rate and the balance sheet account figures are converted using the exhange rate per certain date of report ?
  2. Since the journal entries are created in the Consolidation Company, is there any way to link the consolidated journal entries in the Consolidation Company with the original Journal entries ?

Thanks

@kaynnan
Copy link
Author

kaynnan commented Jun 30, 2023

Having the account_consolidation module is interesting thing, since the Consolidation Module has been moved to the EE version.

I have curious questions:

1. Any plan to add the features to make different base of exhange rate per group of account ? Usually, the Account in the Income Statement will be factored by the historical exchange rate and the balance sheet account figures are converted using the exhange rate per certain date of report ?

2. Since the journal entries are created in the Consolidation Company, is there any way to link the consolidated journal entries in the Consolidation Company with the original Journal entries ?

Thanks

Thank you for expressing your suggestions regarding the account_consolidation module. Currently, our focus is on the migration process. However, I appreciate your input, and I encourage you to create an issue on the account-consolidation repository for further discussion.

@kaynnan kaynnan force-pushed the 14.0-mig-account_consolidation branch from 3152616 to 8312658 Compare August 30, 2023 14:24
Copy link
Member

@douglascstd douglascstd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[FUNCIONAL TEST] APPROVED

image
image
image

@kaynnan
Copy link
Author

kaynnan commented Aug 31, 2023

ping @OCA/accounting-maintainers

Copy link
Sponsor Member

@marcelsavegnago marcelsavegnago left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

grindtildeath and others added 16 commits September 26, 2023 18:45
Currently translated at 98.1% (104 of 106 strings)

Translation: account-consolidation-12.0/account-consolidation-12.0-account_consolidation
Translate-URL: https://translation.odoo-community.org/projects/account-consolidation-12-0/account-consolidation-12-0-account_consolidation/pt_BR/
Currently translated at 89.6% (95 of 106 strings)

Translation: account-consolidation-12.0/account-consolidation-12.0-account_consolidation
Translate-URL: https://translation.odoo-community.org/projects/account-consolidation-12-0/account-consolidation-12-0-account_consolidation/es/
Currently translated at 9.4% (10 of 106 strings)

Translation: account-consolidation-12.0/account-consolidation-12.0-account_consolidation
Translate-URL: https://translation.odoo-community.org/projects/account-consolidation-12-0/account-consolidation-12-0-account_consolidation/hr/
Currently translated at 100.0% (106 of 106 strings)

Translation: account-consolidation-12.0/account-consolidation-12.0-account_consolidation
Translate-URL: https://translation.odoo-community.org/projects/account-consolidation-12-0/account-consolidation-12-0-account_consolidation/pt_BR/
Currently translated at 100.0% (106 of 106 strings)

Translation: account-consolidation-12.0/account-consolidation-12.0-account_consolidation
Translate-URL: https://translation.odoo-community.org/projects/account-consolidation-12-0/account-consolidation-12-0-account_consolidation/pt/
Copy link
Member

@etobella etobella left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When I tried to reexecute on a finalized month, the move was not reversed. You can see it on runboat.

@kaynnan kaynnan force-pushed the 14.0-mig-account_consolidation branch 2 times, most recently from 33fc00a to 9808f86 Compare October 4, 2023 21:00
@etobella
Copy link
Member

etobella commented Oct 4, 2023

BTW, about the renaiming, can you use the following script in order to refactor all history and avoid the renaming commit? Otherwise, history will be lost on next migration:

git filter-branch -f --index-filter '
git ls-files --stage | \
sed "s:account_consolidation/:account_consolidation_oca/:" | \
GIT_INDEX_FILE=$GIT_INDEX_FILE.new \
git update-index --index-info && \
mv "$GIT_INDEX_FILE.new" "$GIT_INDEX_FILE"
' HEAD

@kaynnan
Copy link
Author

kaynnan commented Oct 4, 2023

There was some conflict when I went to squash and script, so to be more organized I opened a new pull request: [14.0] account_consolidation_oca: add new module

@kaynnan kaynnan deleted the 14.0-mig-account_consolidation branch November 28, 2023 14:52
@kaynnan kaynnan restored the 14.0-mig-account_consolidation branch November 28, 2023 14:52
@kaynnan kaynnan deleted the 14.0-mig-account_consolidation branch December 6, 2023 17:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.