(request, uid)
return data
Details for a vote.

    Parameters:
    uid -- the id of the `Vote`.
Details for a vote.
Details for a vote .
def vote_details(request, uid):
    """
    Details for a vote.

    Parameters:
    uid -- the id of the `Vote`.
    """
    vote = Vote.objects.filter(id=uid).first()

    if not vote:
        return {}

    data = {
        'id': vote.id,
        'author_uid': vote.author.profile.uid,
        'author': vote.author.profile.name,
        'post_uid': vote.post.uid,
        'type': vote.get_type_display(),
        'type_id': vote.type,
        'date': util.datetime_to_iso(vote.date),
    }
    return data
def vote_details ( request , uid ) : vote = Vote . objects . filter ( id = uid ) . first ( ) if not vote : return { } data = { 'id' : vote . id , 'author_uid' : vote . author . profile . uid , 'author' : vote . author . profile . name , 'post_uid' : vote . post . uid , 'type' : vote . get_type_display ( ) , 'type_id' : vote . type , 'date' : util . datetime_to_iso ( vote . date ) , } return data