Skip to content

Commit

Permalink
changed how we check if contract comes from sub proposal
Browse files Browse the repository at this point in the history
  • Loading branch information
Prazn committed Aug 22, 2024
1 parent 9ad2e1d commit dbca2f9
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions sponsorship_compassion/models/contract_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,7 @@ def _should_skip_invoice_generation(self, invoicing_date, contract=None):

existing_invoices = self.env["account.move"].search_count(search_filter)

previous_contract = contract.parent_id
is_sub_proposal = (previous_contract is not None
and previous_contract.type == "S"
and previous_contract.sds_state == "sub")
is_sub_proposal = contract.parent_id.child_id

# If invoices come from sub proposal, ignore group suspension to also generate
# already paid invoices
Expand Down

0 comments on commit dbca2f9

Please sign in to comment.