fix: certified participants query

This commit is contained in:
Jannat Patel
2024-04-24 11:27:50 +05:30
parent 3fcf037db2
commit 5b5d779f25

View File

@@ -334,10 +334,11 @@ def get_certified_participants():
LMSCertificate = DocType("LMS Certificate")
participants = (
frappe.qb.from_(LMSCertificate)
.select("DISTINCT member")
.select(LMSCertificate.member)
.distinct()
.where(LMSCertificate.published == 1)
.order_by("creation desc")
.run()
.orderby(LMSCertificate.creation, order=frappe.qb.desc)
.run(as_dict=1)
)
participant_details = []