U
    UscÞ  ã                   @   sH  d dl mZmZ d dlmZ d dlmZ d dlmZ ddl	T d dl
mZ G dd	„ d	ejƒZG d
d„ dejƒZG dd„ dejƒZG dd„ dejƒZG dd„ dejƒZG dd„ dejƒZG dd„ dejƒZG dd„ dejƒZG dd„ dejƒZG dd„ dejƒZG dd„ dejƒZG dd„ dejƒZG d d!„ d!ejƒZG d"d#„ d#ejƒZd$S )%é    )ÚfieldÚfields)Úmodel)Úrequest)Úserializersé   )Ú*)Úsettingsc                   @   s   e Zd ZG dd„ dƒZdS )ÚUserRegisterSerializerc                   @   s:   e Zd ZeZddddddddd	d
dddddddddgZdS )zUserRegisterSerializer.MetaÚidÚ
first_nameÚ	last_nameÚusernameÚemail_varificationÚphone_varificationÚemailÚexp_otp_datetimeÚphone_numberÚcountry_codeÚotpÚ	device_idÚ	fcm_tokenÚcountryÚrolesÚdescriptionÚprofile_picÚsocial_login_typeÚuidN©Ú__name__Ú
__module__Ú__qualname__ÚUserr   r   © r#   r#   úZ/var/www/html/staging.mfahmagazine.net/magazine_api/magazine_web_admin/base/serializers.pyÚMeta   s   r%   N©r   r    r!   r%   r#   r#   r#   r$   r
      s   r
   c                   @   s*   e Zd Ze ¡ ZG dd„ dƒZdd„ ZdS )ÚRegisterSerializerc                   @   s:   e Zd ZeZddddddddd	d
dddddddddgZdS )zRegisterSerializer.Metar   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   Nr   r#   r#   r#   r$   r%      s   r%   c                 C   s   |j r|j jS d S ©N)r   r   ©ÚselfÚobjr#   r#   r$   Úget_country_code   s    z#RegisterSerializer.get_country_codeN)r   r    r!   r   ÚSerializerMethodFieldr   r%   r,   r#   r#   r#   r$   r'      s   r'   c                   @   s   e Zd ZG dd„ dƒZdS )ÚUserLoginSerializerc                   @   s   e Zd ZeZdZdS )zUserLoginSerializer.MetaÚ__all__Nr   r#   r#   r#   r$   r%   !   s   r%   Nr&   r#   r#   r#   r$   r.       s   r.   c                   @   s   e Zd ZG dd„ dƒZdS )ÚSocialLoginSerializerc                   @   s,   e Zd ZeZddddddddd	d
ddgZdS )zSocialLoginSerializer.Metar   r   r   r   r   r   r   r   r   r   r   r   Nr   r#   r#   r#   r$   r%   *   s   r%   Nr&   r#   r#   r#   r$   r0   '   s   r0   c                   @   s   e Zd ZG dd„ dƒZdS )ÚSocialRegisterSerializerc                   @   s.   e Zd ZeZddddddddd	d
dddgZdS )zSocialRegisterSerializer.Metar   r   r   r   r   r   r   r   r   r   r   r   r   Nr   r#   r#   r#   r$   r%   7   s   r%   Nr&   r#   r#   r#   r$   r1   5   s   r1   c                   @   s   e Zd ZG dd„ dƒZdS )ÚCountrySerializerc                   @   s   e Zd ZeZdZdS )zCountrySerializer.Metar/   N)r   r    r!   ÚCountryr   r   r#   r#   r#   r$   r%   >   s   r%   Nr&   r#   r#   r#   r$   r2   =   s   r2   c                   @   s   e Zd ZG dd„ dƒZdS )ÚSubscriptionSerializerc                   @   s   e Zd ZeZdZdS )zSubscriptionSerializer.Metar/   N©r   r    r!   ÚSubscriptionr   r   r#   r#   r#   r$   r%   D   s   r%   Nr&   r#   r#   r#   r$   r4   C   s   r4   c                   @   s   e Zd ZG dd„ dƒZdS )ÚSubsSerializerc                   @   s"   e Zd ZeZdddddddgZdS )	zSubsSerializer.Metar   Úsubscription_typeÚ
start_dateÚend_dateÚsubscription_statusÚ
created_onÚ
updated_onNr5   r#   r#   r#   r$   r%   J   s   r%   Nr&   r#   r#   r#   r$   r7   I   s   r7   c                   @   s   e Zd ZG dd„ dƒZdS )ÚMagazineProfileSerializerc                   @   s0   e Zd ZeZddddddddd	d
ddddgZdS )zMagazineProfileSerializer.Metar   r   r   r   r   r   r   r   r   Úotp_varificationr   r   r   r   Nr   r#   r#   r#   r$   r%   Q   s   r%   Nr&   r#   r#   r#   r$   r>   P   s   r>   c                   @   s   e Zd ZG dd„ dƒZdS )ÚGetMagazineProfileSerializerc                   @   s2   e Zd ZeZddddddddd	d
dddddgZdS )z!GetMagazineProfileSerializer.Metar   r   r   r   r   r   r   r   r   ÚaddressÚaddress_line_2ÚstateÚzipcodeÚcityÚcountry_nameNr   r#   r#   r#   r$   r%   V   s   r%   Nr&   r#   r#   r#   r$   r@   U   s   r@   c                   @   s   e Zd ZG dd„ dƒZdS )ÚUpdateProfileSerializerc                   @   s,   e Zd ZeZddddddddd	d
ddgZdS )zUpdateProfileSerializer.Metar   r   r   r   r   r   rA   rB   rC   rD   rE   rF   Nr   r#   r#   r#   r$   r%   \   s   r%   Nr&   r#   r#   r#   r$   rG   [   s   rG   c                   @   s*   e Zd Ze ¡ ZG dd„ dƒZdd„ ZdS )ÚShowUpdateProfileSerializerc                   @   s    e Zd ZeZddddddgZdS )z ShowUpdateProfileSerializer.Metar   r   r   r   r   ÚupdatepropicNr   r#   r#   r#   r$   r%   d   s   r%   c                 C   s   |j r|j S d S r(   )r   r)   r#   r#   r$   Úget_updatepropich   s    z,ShowUpdateProfileSerializer.get_updatepropicN)r   r    r!   r   r-   rI   r%   rJ   r#   r#   r#   r$   rH   b   s   rH   c                   @   s   e Zd ZG dd„ dƒZdS )ÚMasterCurrencySerializerc                   @   s    e Zd ZeZddddddgZdS )zMasterCurrencySerializer.Metar   r   ÚcurrencyÚcurrency_statusr<   r=   N)r   r    r!   ÚMasterCurrencyr   r   r#   r#   r#   r$   r%   p   s   r%   Nr&   r#   r#   r#   r$   rK   o   s   rK   c                   @   s   e Zd ZG dd„ dƒZdS )ÚContactsSerializerc                   @   s   e Zd ZeZdZdS )zContactsSerializer.Metar/   N)r   r    r!   Ú
ContactsUsr   r   r#   r#   r#   r$   r%   v   s   r%   Nr&   r#   r#   r#   r$   rO   u   s   rO   N)Zdataclassesr   r   Úpyexpatr   Úrequestsr   Úrest_frameworkr   ÚmodelsÚmagaziner	   ÚModelSerializerr
   r'   r.   r0   r1   r2   r4   r7   r>   r@   rG   rH   rK   rO   r#   r#   r#   r$   Ú<module>   s&   