(request, episode)
return render(
        request,
        "episode-history.html",
        {
            "episode": episode,
            "podcast": podcast,
            "history": history,
            "actions": EPISODE_ACTION_TYPES,
            "clients": clients,
        },
    )
shows the history of the episode
shows the history of the episode
shows the history of the episode
def history(request, episode):
    """shows the history of the episode"""

    user = request.user
    podcast = episode.podcast

    history = (
        EpisodeHistoryEntry.objects.filter(user=user, episode=episode)
        .order_by("-timestamp")
        .prefetch_related(
            "episode",
            "episode__slugs",
            "episode__podcast",
            "episode__podcast__slugs",
            "client",
        )
    )

    clients = user.client_set.all()

    return render(
        request,
        "episode-history.html",
        {
            "episode": episode,
            "podcast": podcast,
            "history": history,
            "actions": EPISODE_ACTION_TYPES,
            "clients": clients,
        },
    )
def history ( request , episode ) : user = request . user podcast = episode . podcast history = ( EpisodeHistoryEntry . objects . filter ( user = user , episode = episode ) . order_by ( "-timestamp" ) . prefetch_related ( "episode" , "episode__slugs" , "episode__podcast" , "episode__podcast__slugs" , "client" , ) ) clients = user . client_set . all ( ) return render ( request , "episode-history.html" , { "episode" : episode , "podcast" : podcast , "history" : history , "actions" : EPISODE_ACTION_TYPES , "clients" : clients , } , )