|
@@ -4,7 +4,7 @@ import marshmallow
|
4
|
4
|
|
5
|
5
|
class ProfileSchema(marshmallow.Schema):
|
6
|
6
|
id = marshmallow.fields.Int(dump_only=True)
|
7
|
|
- name = marshmallow.fields.String()
|
|
7
|
+ slug = marshmallow.fields.String(attribute='name')
|
8
|
8
|
|
9
|
9
|
|
10
|
10
|
class UserSchema(marshmallow.Schema):
|
|
@@ -16,7 +16,11 @@ class UserSchema(marshmallow.Schema):
|
16
|
16
|
# TODO - G.M - 17-04-2018 - Restrict timezone values
|
17
|
17
|
timezone = marshmallow.fields.String()
|
18
|
18
|
# TODO - G.M - 17-04-2018 - check this, relative url allowed ?
|
19
|
|
- caldav_url = marshmallow.fields.Url(relative=True)
|
|
19
|
+ caldav_url = marshmallow.fields.Url(
|
|
20
|
+ relative=True,
|
|
21
|
+ attribute='calendar_url'
|
|
22
|
+ )
|
|
23
|
+ avatar_url = marshmallow.fields.Url()
|
20
|
24
|
profile = marshmallow.fields.Nested(
|
21
|
25
|
ProfileSchema,
|
22
|
26
|
many=False,
|