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

Christmas gift can be generated even without being active #1985

Open
wants to merge 1 commit into
base: 14.0
Choose a base branch
from

Conversation

davidwul
Copy link
Contributor

Christmas gift being a fund does not need to wait for being activate before generating invoices.
This change is already on the nordic prod

Copy link

sonarcloud bot commented Oct 21, 2024

@@ -43,10 +43,11 @@ def _generate_invoices(self, invoicer, contract_id=None):
super(
ContractGroup, self.with_context(open_invoices_sponsorship_only=True)
)._generate_invoices(invoicer, contract_id)
# We can generate christmas even if the contract isn't active as it is a fund.
self.mapped("contract_ids")._generate_gifts(invoicer, CHRISTMAS_GIFT)
Copy link
Member

Choose a reason for hiding this comment

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

This would also generate gifts for terminated contracts, do we want to avoid it? I would propose to keep a filter but maybe only keep waiting and active contracts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants