Skip to content
Snippets Groups Projects
Commit 342d9220 authored by stvn's avatar stvn
Browse files

feat: Implement to_internal_value helper for discussion API

parent def644b9
No related branches found
Tags release-2021-04-08-07.47
No related merge requests found
......@@ -64,7 +64,14 @@ class DiscussionsConfigurationView(APIView):
"""
Transform the *incoming* primitive data into a native value.
"""
raise NotImplementedError
payload = {
'context_key': data.get('course_key', ''),
'enabled': data.get('enabled', False),
'lti_configuration': data.get('lti_configuration', {}),
'plugin_configuration': data.get('plugin_configuration', {}),
'provider_type': data.get('provider_type', ''),
}
return payload
def to_representation(self, instance) -> dict:
"""
......
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