fix: documented the api

This commit is contained in:
Jannat Patel
2024-08-19 12:03:32 +05:30
parent cdd46667f3
commit a3b8ed8f91
4 changed files with 11 additions and 6 deletions

View File

@@ -566,12 +566,17 @@ def get_categories(doctype, filters):
@frappe.whitelist()
def get_members(start=0, search=""):
""" Get members for the given search term and start index.
Args: start (int): Start index for the query.
search (str): Search term to filter the results.
Returns: List of members.
"""
filters = {"enabled": 1, "name": ["not in", ["Administrator", "Guest"]]}
if search:
filters["full_name"] = ["like", f"%{search}%"]
print(filters)
members = frappe.get_all(
"User",
filters=filters,