{% import "components/user.html" as user with context %} {% import "components/ui/v1.html" as ui_v1 %} {% extends "layout/basic.html" %} {% block content %}
{% call ui_v1.page_header(cpdoc.title, _('查看课程包说明和全部版本。')) %}
{% if cpdoc.hidden %}{{ ui_v1.badge(_('已隐藏'), 'warning') }}{% endif %} {{ _('返回课程包') }} {% if canManage %}{{ _('创建版本') }}{% endif %}
{% endcall %}

{{ _('Description') }}

{{ cpdoc.content|default('')|markdown|safe }}

{{ _('版本') }}

{% if not versions.length %} {{ ui_v1.empty_state(_('暂无版本')) }} {% else %}
    {% for vpdoc in versions %}
  1. {{ vpdoc.title }} {% if vpdoc.hidden %}{{ ui_v1.badge(_('已隐藏'), 'warning') }}{% endif %}

    {{ vpdoc.summary.chapterCount }} {{ _('章') }} {{ vpdoc.summary.lessonCount }} {{ _('节') }} {{ vpdoc.summary.problemCount }} {{ _('题目') }} {% if vpdoc.updateAt %}{{ _('Last Update At') }}: {{ datetimeSpan(vpdoc.updateAt)|safe }}{% endif %}
    {{ ui_v1.badge(vpdoc.version, 'neutral') }} {% if canManage %}
    {% endif %}
  2. {% endfor %}
{% endif %}
{% endblock %}