Merge pull request #31218 from deepeshgarg007/distinct_gstin

fix(India): GSTIN filter in GSTR-1 report
This commit is contained in:
Deepesh Garg
2022-06-06 08:57:55 +05:30
committed by GitHub

View File

@@ -1155,8 +1155,11 @@ def get_company_gstins(company):
.inner_join(links)
.on(address.name == links.parent)
.select(address.gstin)
.distinct()
.where(links.link_doctype == "Company")
.where(links.link_name == company)
.where(address.gstin.isnotnull())
.where(address.gstin != "")
.run(as_dict=1)
)