from .serializers_base import ContactSerializerBase
from locations_api.serializers_base import LocationSerializerBase
from companies_api.serializers_base import CompanySerializerWithHeadquarters

class ContactSerializer(ContactSerializerBase): # serializers.ModelSerializer just tells django to convert sql to JSON
    home = LocationSerializerBase()
    company_set = CompanySerializerWithHeadquarters(many=True)

    class Meta(ContactSerializerBase.Meta):
        fields = ContactSerializerBase.Meta.fields + ('home', 'company_set')

967245f0f620eceff063aeafceb6df478fd64f1a
<mask token>

<mask token>


class ContactSerializer(ContactSerializerBase):
    <mask token>
    <mask token>


    class Meta(ContactSerializerBase.Meta):
        fields = ContactSerializerBase.Meta.fields + ('home', 'company_set')

<mask token>


class ContactSerializer(ContactSerializerBase):
    home = LocationSerializerBase()
    company_set = CompanySerializerWithHeadquarters(many=True)


    class Meta(ContactSerializerBase.Meta):
        fields = ContactSerializerBase.Meta.fields + ('home', 'company_set')

from .serializers_base import ContactSerializerBase
from locations_api.serializers_base import LocationSerializerBase
from companies_api.serializers_base import CompanySerializerWithHeadquarters


class ContactSerializer(ContactSerializerBase):
    home = LocationSerializerBase()
    company_set = CompanySerializerWithHeadquarters(many=True)


    class Meta(ContactSerializerBase.Meta):
        fields = ContactSerializerBase.Meta.fields + ('home', 'company_set')

from .serializers_base import ContactSerializerBase
from locations_api.serializers_base import LocationSerializerBase
from companies_api.serializers_base import CompanySerializerWithHeadquarters

class ContactSerializer(ContactSerializerBase): # serializers.ModelSerializer just tells django to convert sql to JSON
    home = LocationSerializerBase()
    company_set = CompanySerializerWithHeadquarters(many=True)

    class Meta(ContactSerializerBase.Meta):
        fields = ContactSerializerBase.Meta.fields + ('home', 'company_set')
