Ejemplo n.º 1
0
def detail(request, repo, org, cid, eid):
    entity = Entity.get(repo, org, cid, eid)
    if not entity:
        raise Http404
    return render_to_response('ui/entities/detail.html', {
        'repo': repo,
        'org': org,
        'cid': cid,
        'eid': eid,
        'object': entity,
    },
                              context_instance=RequestContext(request,
                                                              processors=[]))
Ejemplo n.º 2
0
def detail( request, repo, org, cid, eid ):
    entity = Entity.get(repo, org, cid, eid)
    if not entity:
        raise Http404
    return render_to_response(
        'ui/entities/detail.html',
        {
            'repo': repo,
            'org': org,
            'cid': cid,
            'eid': eid,
            'object': entity,
        },
        context_instance=RequestContext(request, processors=[])
    )
Ejemplo n.º 3
0
def files(request, repo, org, cid, eid):
    """Lists all the files in an entity.
    """
    entity = Entity.get(repo, org, cid, eid)
    if not entity:
        raise Http404
    paginator = Paginator(entity.files(), settings.RESULTS_PER_PAGE)
    page = paginator.page(request.GET.get('page', 1))
    return render_to_response('ui/entities/files.html', {
        'repo': repo,
        'org': org,
        'cid': cid,
        'eid': eid,
        'object': entity,
        'paginator': paginator,
        'page': page,
    },
                              context_instance=RequestContext(request,
                                                              processors=[]))
Ejemplo n.º 4
0
def files( request, repo, org, cid, eid ):
    """Lists all the files in an entity.
    """
    entity = Entity.get(repo, org, cid, eid)
    if not entity:
        raise Http404
    paginator = Paginator(entity.files(), settings.RESULTS_PER_PAGE)
    page = paginator.page(request.GET.get('page', 1))
    return render_to_response(
        'ui/entities/files.html',
        {
            'repo': repo,
            'org': org,
            'cid': cid,
            'eid': eid,
            'object': entity,
            'paginator': paginator,
            'page': page,
        },
        context_instance=RequestContext(request, processors=[])
    )