$def with (course,task,submissions) $# Copyright (c) 2014-2015 Université Catholique de Louvain. $# $# This file is part of INGInious. $# $# INGInious is free software: you can redistribute it and/or modify $# it under the terms of the GNU Affero General Public License as published $# by the Free Software Foundation, either version 3 of the License, or $# (at your option) any later version. $# $# INGInious is distributed in the hope that it will be useful, $# but WITHOUT ANY WARRANTY; without even the implied warranty of $# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the $# GNU Affero General Public License for more details. $# $# You should have received a copy of the GNU Affero General Public $# License along with INGInious. If not, see . $var title: $:task.get_name() - $:task.get_course().get_name() $# Left column content $def ColumnF():

Informations

$if task.get_authors():
Author(s) $",".join(task.get_authors())
Deadline $task.get_deadline()
Status $if len(submissions) == 0: Not yet attempted $else: $ succeeded=False $ waiting=False $for submission in submissions: $if submission["status"] == "done" and submission["result"] == "success": $ succeeded=True $break $elif submission["status"] == "waiting": $ waiting=True $break $if succeeded: Succeeded $elif waiting: Waiting for verification $else: Wrong answer
Grade $user_manager.get_task_grade(task)%
Grading weight $task.get_grading_weight()
Attempts ${len(submissions)}
$if user_manager.has_staff_rights_on_course(course):

Administration

$if not course.is_open_to_non_staff(): $if not task.is_visible_by_students():
  View submissions $if user_manager.has_admin_rights_on_course(course):   Edit task   Debug informations
$else:

Submitting as

$if task.is_group_task():   Group $else:   $user_manager.session_realname()
  Classroom : $user_manager.get_course_user_classroom(course)["description"]

Submissions

$var Column: $:ColumnF() $def NavbarF(): $var Navbar: $:NavbarF() $# Start content

$task.get_name()

$:task.get_context()
$if user_manager.has_admin_rights_on_course(course):
$for key, problem in enumerate(task.get_problems()):
$if len(task.get_problems()) != 1 or problem.get_name() != "":

$if len(task.get_problems()) != 1: Question ${key+1}: $problem.get_name()

$:problem.get_header() $:problem.show_input(template_helper.get_common_renderer())
$if user_manager.task_can_user_submit(task): $elif not task.get_accessible_time().is_open(): $elif task.is_group_task(): Please register in a group $else: