def list_iterations_for_project(request, projectID):
    project = project_api.get_project(projectID)
    iterations = mdl_iteration.get_iterations_for_project(project)
    context = {
        'project': project,
        'iterations': iterations,
        'owns_project': project_api.user_owns_project(request.user, project),
    }
    return render(request, 'SideBarIters.html', context)
def list_iterations_for_project(request, projectID):
    project = project_api.get_project(projectID)
    iterations = mdl_iteration.get_iterations_for_project(project)
    context = {
        'project': project,
        'iterations': iterations,
        'owns_project': project_api.user_owns_project(request.user, project),
    }
    return render(request, 'SideBarIters.html', context)
def list_iterations_for_project_with_selection(request, projectID, iterationID):
    project = project_api.get_project(projectID)
    iterations = mdl_iteration.get_iterations_for_project(project)
    iteration = mdl_iteration.get_iteration(iterationID)
    context = {
        'project' : project,
        'iterations' : iterations,
        'iteration' : iteration,
        'owns_project' : project_api.user_owns_project(request.user,project),
    }
    if iteration == None:
        context['isIceBox'] = True
    return render(request, 'SideBarIters.html', context)
def list_iterations_for_project_with_selection(request, projectID,
                                               iterationID):
    project = project_api.get_project(projectID)
    iterations = mdl_iteration.get_iterations_for_project(project)
    iteration = mdl_iteration.get_iteration(iterationID)
    context = {
        'project': project,
        'iterations': iterations,
        'iteration': iteration,
        'owns_project': project_api.user_owns_project(request.user, project),
    }
    if iteration == None:
        context['isIceBox'] = True
    return render(request, 'SideBarIters.html', context)
Beispiel #5
0
def project(request, projectID):
    project = project_api.get_project(projectID)
    if project == None: return redirect('/req/projects')

    iterations = mdl_iteration.get_iterations_for_project(project)
    association = UserAssociation.objects.get(user=request.user, project=project)

    context = {'projects' : project_api.get_projects_for_user(request.user.id),
               'project' : project,
               'stories' : mdl_story.get_stories_for_project(project),
               'iterations' : iterations,
               'association' : association,
               'canOwnProject' : request.user.has_perm(PERMISSION_OWN_PROJECT),
               }
    return render(request, 'ProjectDetail.html', context)
Beispiel #6
0
def project(request, projectID):
    project = project_api.get_project(projectID)
    if project == None: return redirect('/req/projects')

    iterations = mdl_iteration.get_iterations_for_project(project)
    association = UserAssociation.objects.get(user=request.user, project=project)

    context = {'projects' : project_api.get_projects_for_user(request.user.id),
               'project' : project,
               'stories' : mdl_story.get_stories_for_project(project),
               'iterations' : iterations,
               'association' : association,
               'canOwnProject' : request.user.has_perm(PERMISSION_OWN_PROJECT),
               }
    return render(request, 'ProjectDetail.html', context)
def issues(request, projectID):
    # Loads the IssueList template, which contains a list of the issues the user is associated with, within a project
    p = project_api.get_project(projectID)
    if p is None:
        return redirect('/requirements/projects')

    iterations = mdl_iteration.get_iterations_for_project(p)
    association = UserAssociation.objects.get(user=request.user, project=p)

    context = {
        'projects': project_api.get_projects_for_user(request.user.id),
        'project': p,
        'stories': mdl_story.get_stories_for_project(p),
        'tasks': mdl_task.get_all_tasks(),
        'comments': mdl_story_comment.get_all_comments(),
        'attachments': mdl_story_attachment.get_all_attachments(),
        'issues': mdl_issue.get_all_issues(),
        'iterations': iterations,
        'association': association,
        'canOwnProject': request.user.has_perm(PERMISSION_OWN_PROJECT),
    }
    return render(request, 'IssueList.html', context)
def project(request, projectID):
    p = project_api.get_project(projectID)
    if p is None:
        return redirect('/requirements/projects')

    iterations = mdl_iteration.get_iterations_for_project(p)
    association = UserAssociation.objects.get(user=request.user, project=p)
    priorities = Story.PRIORITY_CHOICES

    context = {
        'projects': project_api.get_projects_for_user(request.user.id),
        'project': p,
        'stories': mdl_story.get_stories_for_project(p),
        'tasks': mdl_task.get_all_tasks(),
        'comments': mdl_story_comment.get_all_comments(),
        'priorities': priorities,
        'attachments': mdl_story_attachment.get_all_attachments(),
        'issues': mdl_issue.get_all_issues(),
        'iterations': iterations,
        'association': association,
        'canOwnProject': request.user.has_perm(PERMISSION_OWN_PROJECT),
    }
    return render(request, 'ProjectDetail.html', context)
def project(request, projectID):
    project = project_api.get_project(projectID)
    if project is None:
        return redirect('/req/projects')

    iterations = mdl_iteration.get_iterations_for_project(project)
    association = UserAssociation.objects.get(
        user=request.user,
        project=project)
    priorities = Story.PRIORITY_CHOICES

    context = {'projects': project_api.get_projects_for_user(request.user.id),
               'project': project,
               'stories': mdl_story.get_stories_for_project(project),
               'tasks': mdl_task.get_all_tasks(),
               'comments': mdl_story_comment.get_all_comments(),
               'priorities': priorities,
               'attachments': mdl_story_attachment.get_all_attachments(),
               'issues': mdl_issue.get_all_issues(),
               'iterations': iterations,
               'association': association,
               'canOwnProject': request.user.has_perm(PERMISSION_OWN_PROJECT),
               }
    return render(request, 'ProjectDetail.html', context)
def issues(request, projectID):
    # Loads the IssueList template, which contains a list of the issues the user is
    # associated with, within a project
    project = project_api.get_project(projectID)
    if project is None:
        return redirect('/req/projects')

    iterations = mdl_iteration.get_iterations_for_project(project)
    association = UserAssociation.objects.get(
        user=request.user,
        project=project)

    context = {'projects': project_api.get_projects_for_user(request.user.id),
               'project': project,
               'stories': mdl_story.get_stories_for_project(project),
               'tasks': mdl_task.get_all_tasks(),
               'comments': mdl_story_comment.get_all_comments(),
               'attachments': mdl_story_attachment.get_all_attachments(),
               'issues': mdl_issue.get_all_issues(),
               'iterations': iterations,
               'association': association,
               'canOwnProject': request.user.has_perm(PERMISSION_OWN_PROJECT),
    }
    return render(request, 'IssueList.html', context)