Files
edx-platform/lms/templates/vert_module.html
Dillon Dumesnil 7f6a2518cb AA-44: Adding due dates into courseware
Due dates will only display for graded subsections.
If the assignment has already been completed, there will be a pill
to indicate that. If the assignment is past due, there will be a
pill. If it is upcoming, there are no pills
2020-06-24 08:26:52 -07:00

46 lines
1.2 KiB
HTML

<%page expression_filter="h"/>
<%namespace name='static' file='/static_content.html'/>
<%!
from django.utils.translation import gettext as _
from openedx.core.djangolib.markup import HTML
%>
%if unit_title and show_title:
<h2 class="hd hd-2 unit-title">${unit_title}</h2>
% endif
% if due:
<%
data_string = _("{subsection_format} due {{date}}").format(subsection_format=subsection_format)
%>
<div class="vert-due-date">
<div class="localized-datetime" data-datetime="${due}" data-string="${data_string}" data-timezone="${user_timezone}"></div>
% if completed:
<div class="pill completed">${_('Completed')}</div>
% elif past_due:
<div class="pill past-due">${_('Past Due')}</div>
%endif
</div>
% endif
% if show_bookmark_button:
<%include file='bookmark_button.html' args="bookmark_id=bookmark_id, is_bookmarked=bookmarked"/>
% endif
<div class="vert-mod">
% for idx, item in enumerate(items):
% if item['content']:
<div class="vert vert-${idx}" data-id="${item['id']}">
${HTML(item['content'])}
</div>
%endif
% endfor
</div>
<%static:require_module_async module_name="js/dateutil_factory" class_name="DateUtilFactory">
DateUtilFactory.transform('.localized-datetime');
</%static:require_module_async>