mirror of
https://github.com/rzmk/learnhouse.git
synced 2025-12-19 04:19:25 +00:00
feat: init activity starting from course
This commit is contained in:
parent
a21ccb3626
commit
cf7285b6f9
8 changed files with 247 additions and 70 deletions
|
|
@ -206,7 +206,7 @@ async def update_coursechapters_meta(request: Request,course_id: str, coursechap
|
|||
"$set": {"chapters": coursechapters_metadata.chapterOrder}})
|
||||
|
||||
# update lectures in coursechapters
|
||||
# TODO : performance/optimization improvement
|
||||
# TODO : performance/optimization improvement, this does not work anyway.
|
||||
for coursechapter in coursechapters_metadata.chapters.__dict__.items():
|
||||
coursechapters.update_one({"coursechapter_id": coursechapter}, {
|
||||
"$set": {"lectures": coursechapters_metadata.chapters[coursechapter]["lectureIds"]}}) # type: ignore
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue