Skip to content
Snippets Groups Projects
Commit d9b61a53 authored by permcu's avatar permcu
Browse files

Fix backend documentation update

Did overwrite already set props with "".
parent c492cab2
No related branches found
No related tags found
2 merge requests!352Draft: Resolve "Add dialog with each lesson's students",!350Resolve "Add simple course book list"
Pipeline #169773 failed
...@@ -165,9 +165,13 @@ class DocumentationBatchCreateOrUpdateMutation(graphene.Mutation): ...@@ -165,9 +165,13 @@ class DocumentationBatchCreateOrUpdateMutation(graphene.Mutation):
if not info.context.user.has_perm("alsijil.edit_documentation_rule", obj): if not info.context.user.has_perm("alsijil.edit_documentation_rule", obj):
raise PermissionDenied() raise PermissionDenied()
obj.topic = doc.topic or "" if doc.topic:
obj.homework = doc.homework or "" obj.topic = doc.topic
obj.group_note = doc.group_note or "" if doc.homework:
obj.homework = doc.homework
if doc.group_note:
obj.group_note = doc.group_note
obj.save() obj.save()
return obj return obj
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment