o
    l½iG  ã                   @   sj   d dl mZ ddlmZmZ G dd„ dejƒZe e¡G dd„ dejƒƒZ	e e¡G dd	„ d	ejƒƒZ
d
S )é    )Úadminé   )ÚMotionEventÚ
MotionVotec                   @   s&   e Zd ZeZdZg d¢ZdZdgZdS )ÚMotionVoteInliner   )Úregistration_codeÚ	full_nameÚvoteÚvoted_atÚ
ip_addressTú	-voted_atN)	Ú__name__Ú
__module__Ú__qualname__r   ÚmodelÚextraÚreadonly_fieldsÚ
can_deleteÚordering© r   r   úC/var/www/html/smartRegister/backend/apps/motion_secondment/admin.pyr      s    
r   c                   @   s\   e Zd Zg d¢ZddgZddgZg d¢ZegZdd„ Z	d	e	_
d
d„ Zde_
dd„ Zde_
dS )ÚMotionEventAdmin)ÚnameÚslugÚ	is_activeÚis_archivedÚ	yes_countÚno_countÚtotal_votesÚ
created_atr   r   r   r   )r   r   r   r   r   Ú
updated_atc                 C   ó   |j S ©N)r   ©ÚselfÚobjr   r   r   r      ó   zMotionEventAdmin.yes_countÚYESc                 C   r!   r"   )r   r#   r   r   r   r      r&   zMotionEventAdmin.no_countÚNOc                 C   r!   r"   )r   r#   r   r   r   r      r&   zMotionEventAdmin.total_votesÚTotalN)r   r   r   Úlist_displayÚlist_filterÚsearch_fieldsr   r   Úinlinesr   Úshort_descriptionr   r   r   r   r   r   r      s    
r   c                   @   s2   e Zd Zg d¢ZddgZddgZddgZdgZd	S )
ÚMotionVoteAdmin)r   r   r	   Úeventr
   r   r0   r	   r   r   r
   r   r   N)r   r   r   r*   r+   r,   r   r   r   r   r   r   r/   "   s    
r/   N)Údjango.contribr   Úmodelsr   r   ÚTabularInliner   ÚregisterÚ
ModelAdminr   r/   r   r   r   r   Ú<module>   s    