refactor: added slugs to course and topics to make nice urls

- the slug is autogenerated from the title
- the slug of a topic is unique among all the topics of that course
This commit is contained in:
Anand Chitipothu
2021-04-06 15:49:17 +05:30
parent 6620ecf0c8
commit 175bd19a51
11 changed files with 121 additions and 83 deletions

View File

@@ -7,6 +7,6 @@ def get_context(context):
def get_courses():
courses = frappe.get_all(
"LMS Course",
fields=['name', 'title', 'description']
fields=['name', 'slug', 'title', 'description']
)
return courses