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

[16.0][MIG][sale_stock_picking_invoicing] #1857

Merged

Conversation

rvalyi
Copy link
Member

@rvalyi rvalyi commented Dec 2, 2024

cc @mbcosta @renatonlima

EDIT: I put it in draft as I'm not too sure yet what should should be done for analytical fields around 65fa883#diff-d8a5810924c9e2509dedcd08b9b6aea083a8543de434b845310fbe7f0c501b58R163
Suggestions are welcome.

@rvalyi rvalyi force-pushed the 16.0-mig-sale_stock_picking_invoicing branch from edbd32f to 65fa883 Compare December 2, 2024 20:22
@rvalyi rvalyi marked this pull request as draft December 3, 2024 19:33
@mbcosta mbcosta force-pushed the 16.0-mig-sale_stock_picking_invoicing branch 3 times, most recently from 7755701 to 5aaafe2 Compare January 15, 2025 12:01
@mbcosta
Copy link
Contributor

mbcosta commented Jan 15, 2025

@rvalyi @renatonlima about the changes:

        analytic_account_id = self.order_id.analytic_account_id.id
        if self.analytic_distribution and not self.display_type:
            res['analytic_distribution'] = self.analytic_distribution
        if analytic_account_id and not self.display_type:
            analytic_account_id = str(analytic_account_id)
            if 'analytic_distribution' in res:
                res['analytic_distribution'][analytic_account_id] = res['analytic_distribution'].get(analytic_account_id, 0) + 100
            else:
                res['analytic_distribution'] = {analytic_account_id: 100}

This value and the sale_line_ids are the only two fields informed when the ''Invoice Type" are out_refund ( Should be informed other fields? Is there another "Invoice Type" that should not copy Sale fields? I let a TODO there https://github.com/akretion/account-invoicing/blob/16.0-mig-sale_stock_picking_invoicing/sale_stock_picking_invoicing/wizards/stock_invoice_onshipping.py#L169 )

Test the copy of field:

image

image

image

Analytic Lines seems to be change as Mixin in the module https://github.com/OCA/OCB/tree/16.0/addons/analytic

I did the changes in new commits to make easy to see the diff, but can be just a amend in one MIG commit, let me know if will be better only one commit.

With this changes I think the PR can be move from status Draft to Ready to Review

@rvalyi rvalyi force-pushed the 16.0-mig-sale_stock_picking_invoicing branch from 5aaafe2 to 86195f1 Compare February 6, 2025 19:12
@rvalyi
Copy link
Member Author

rvalyi commented Feb 6, 2025

@mbcosta thank you for the fixes. As it was a pretty simple commit I squashed your Analytic lines fix 6d9450c into the previous migration to 16.0 commit. I believe it is now ready indeed...

@mbcosta
Copy link
Contributor

mbcosta commented Feb 7, 2025

Thank you @rvalyi @renatonlima for review

@rvalyi
Copy link
Member Author

rvalyi commented Feb 9, 2025

/ocabot merge nobump

@OCA-git-bot
Copy link
Contributor

Hey, thanks for contributing! Proceeding to merge this for you.
Prepared branch 16.0-ocabot-merge-pr-1857-by-rvalyi-bump-nobump, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit 9088b1d into OCA:16.0 Feb 9, 2025
6 of 7 checks passed
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at 8c2e58c. Thanks a lot for contributing to OCA. ❤️

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.

4 participants