feat: new-sign-up-form, request invite widget, request invite tests, get_sketches with owner

This commit is contained in:
pateljannat
2021-05-03 12:33:31 +05:30
parent cd1d2067ad
commit 565787eeb6
11 changed files with 124 additions and 38 deletions

View File

@@ -4,13 +4,11 @@ from community.lms.models import Sketch
def get_context(context):
context.no_cache = 1
context.username = frappe.form_dict["username"]
print(frappe.form_dict["username"])
context.member = get_member(context.username)
print(context.member)
if not context.member:
context.template = "www/404.html"
else:
context.sketches = list(filter(lambda x: x.owner == context.member.email, Sketch.get_recent_sketches()))
context.sketches = Sketch.get_recent_sketches(context.member.email)
def get_member(username):
try: