-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
F/#68 apify contact emails #91
Conversation
bundle.data['contact_emails'] = contact_list | ||
return bundle | ||
|
||
def determine_format(self, request): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's not do this. Read about serializers http://django-tastypie.readthedocs.org/en/latest/serialization.html and put it in the base class.
…rmat is now assured by the serializer in BaseResource
@bogdans83 , review again, please? :) |
lgtm, but you haven't tested out the method :P leave at least a TODO |
I'll postpone the merging until I write some tests. Although I'm not fond of it, I have to do it. |
|
||
class BaseResource(ModelResource): | ||
class Meta: | ||
pass | ||
serializer = Serializer(formats=['json']) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
The API provides a new entry in the Subject resource: contact_emails, which is a list of emails.