Skip to content

Commit

Permalink
fix: specify parenttype for purchase taxes
Browse files Browse the repository at this point in the history
  • Loading branch information
ljain112 committed Jun 19, 2024
1 parent 224ddc8 commit 287813a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -434,6 +434,7 @@ def get_query(self, additional_fields=None, is_return=False):
.where(self.PI.docstatus == 1)
.where(IfNull(self.PI.reconciliation_status, "") != "Not Applicable")
.where(self.PI.is_opening == "NO")
.where(self.PI_TAX.parenttype == "Purchase Invoice")
.groupby(self.PI.name)
.select(
*fields,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -526,6 +526,7 @@ def get_tax_case_statement(account, alias):
IfNull(pi.ineligibility_reason, "") == "ITC restricted due to PoS rules"
)
.where(pi.name.isin(ineligible_transactions))
.where(taxes.parenttype == "Purchase Invoice")
.groupby(pi[group_by])
.run(as_dict=True)
)
Expand Down

0 comments on commit 287813a

Please sign in to comment.