views.py 文件源码

python
阅读 31 收藏 0 点赞 0 评论 0

项目:Distributed-Multi-User-Scrapy-System-with-a-Web-UI 作者: aaldaber 项目源码 文件源码
def pipelinelist(request, projectname):
    try:
        project = Project.objects.get(user=request.user, project_name=projectname)
    except Project.DoesNotExist:
        return HttpResponseNotFound('Nothing is here.')

    itemtracker = 0

    pipelines = Pipeline.objects.filter(project=project)
    pipelinedata = []
    for pipeline in pipelines:
        pipelinedata.append([])
        pipelinedata[itemtracker].append(pipeline.pipeline_name)
        pipelinedata[itemtracker].append(pipeline.pipeline_order)
        itemtracker += 1
    return render(request, 'pipelinelist.html', {'username': request.user.username, 'project': project.project_name, 'items': pipelinedata})
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号