Commit b922e609 authored by Sébastiaan Versteeg's avatar Sébastiaan Versteeg

Fix fieldnames, fullcalendar expects camelCase

parent c058990b
......@@ -10,7 +10,7 @@ class CalenderJSSerializer(serializers.ModelSerializer):
fields = (
'start', 'end', 'all_day', 'is_birthday',
'url', 'title', 'description',
'background_color', 'text_color', 'target_blank'
'backgroundColor', 'textColor', 'blank'
)
start = serializers.SerializerMethodField('_start')
......@@ -20,9 +20,9 @@ class CalenderJSSerializer(serializers.ModelSerializer):
url = serializers.SerializerMethodField('_url')
title = serializers.SerializerMethodField('_title')
description = serializers.SerializerMethodField('_description')
background_color = serializers.SerializerMethodField('_background_color')
text_color = serializers.SerializerMethodField('_text_color')
target_blank = serializers.SerializerMethodField('_target_blank')
backgroundColor = serializers.SerializerMethodField('_background_color')
textColor = serializers.SerializerMethodField('_text_color')
blank = serializers.SerializerMethodField('_target_blank')
def _start(self, instance):
return timezone.localtime(instance.start)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment