$def with (user_info, course, submissions, tasks, tasks_data, grade, tag_filter_list) $# $# This file is part of INGInious. See the LICENSE and the COPYRIGHTS files for $# more information about the licensing of this file. $# $var title: $:course.get_name(user_manager.session_language()) $ registered = user_manager.course_is_user_registered(course) $ staff = user_manager.has_staff_rights_on_course(course) $# Left column content $def ColumnF(): $:template_helper.call('course_menu', course=course, template_helper=template_helper) $if registered or staff:

$:_("Current grade")

$int(grade)%

$:_("Last tried exercises")

$if submissions: $for submission in submissions: $submission['taskname'] $else: $:_("No submissions")
$if staff: $if not course.is_open_to_non_staff():
  $:_("Course administration")
$elif registered:
  $ myaggregation = user_manager.get_course_user_aggregation(course) $if course.use_classrooms(): $:_("Classroom : {}").format(myaggregation['description']) $elif len(myaggregation['groups']) > 0 and user_manager.session_username() in myaggregation['groups'][0]['students']: $:_("Team : {}").format(myaggregation['description']) $else: $:_("Teams management") $if course.allow_unregister():   $:_("Unregister from this course")
$elif not user_manager.session_logged_in(): $:include.signin_button() $elif course.is_registration_possible(user_info):

$:_("Enroll in the course")

  $:_("Enroll in the course")
$var Column: $:ColumnF() $def NavbarF(): $var Navbar: $:NavbarF() $# Start content

$:course.get_name(user_manager.session_language())

$if course.get_descriptor().get("description", ""):
$:course.get_description(user_manager.session_language())
$:_("List of exercises")
$if tag_filter_list:
$for taskid, task in tasks.items() $if tasks_data[taskid]["visible"]: $ succeeded=tasks_data[taskid]["succeeded"] $ completion=tasks_data[taskid]["grade"]
$task.get_name(user_manager.session_language()) $if not task.is_visible_by_students(): - $:_("task hidden to students") $if not task.get_accessible_time().is_open(): - $:_("deadline reached")
$if registered:
$(int(completion) if completion.is_integer() else completion)%
$:include.unregister_modal(course) $:include.register_modal(course)