Commit 6cdfe66d authored by Bruno Martin's avatar Bruno Martin
Browse files

course and lesson templates loading properly, without backend errors

parent 0a2bb3fe
{% load i18n %}
<!-- HEADER -->
<header class="main-header">
<!-- PAGE-HEADER -->
<div class="page-header container">
<!-- ROW -->
<div class="row">
<div class="col-sm-8 col-md-9 col-xs-12">
<h1><i class="fa fa-angle-double-right"></i> {{course.name}}</h1>
{% include "_course-details-inline.html" with course=course %}
</div>
<div class="col-sm-4 col-md-3 col-xs-12 textright">
{% if user_is_enrolled and not course.has_started %}
<div class="has-tooltip js-login-required uppercase"
href="#"
data-toggle="tooltip"
data-placement="bottom"
data-original-title="{% blocktrans with start_date=course.start_date|date:"d/m/Y" %} This course starts on {{ start_date }} and you are already subscribed{% endblocktrans %}."
title="{% blocktrans with start_date=course.start_date|date:"d/m/Y" %} This course starts on {{ start_date }} and you are already subscribed{% endblocktrans %}.">
<button class="btn btn-lg btn-block btn-default" ng-disabled="true">Ir para o Curso</button>
</div>
{% else %} {# user is not enrolled #}
{% if course.has_started %}
<a href="{% url 'courses_legacy:enroll_course' course.slug %}" class="btn btn-lg btn-info col-xs-12 js-login-required uppercase">Ir para o Curso</a>
{% else %}
<a href="{% url 'courses_legacy:enroll_course' course.slug %}" class="btn btn-lg btn-info col-xs-12 js-login-required uppercase">Inscreva-se</a>
{% endif %}
{% endif %}
</div>
</div>
<!-- END ROW -->
</div>
<!-- END PAGE-HEADER -->
</header>
<!-- END HEADER -->
{% load i18n %}
<script type="text/ng-template" id="courseCompleteModal.html" xmlns="http://www.w3.org/1999/html">
<div class="modal-header">
<button type="button" class="close" ng-click="cancel()" aria-hidden="true">&times;</button>
<h4 class="modal-title" id="myModalLabel">
{% trans "Course Complete" %}</h4>
</div>
<div class="modal-body">
{% verbatim %}
<div class="row">
<div class="col-md-6">
<h2>Parabéns por chegar ao fim do curso {{ cs.name }}!</h2>
<p ng-show="cs.can_emmit_receipt && cs.user.is_profile_filled">
Você concluiu {{ cs.percent_progress }}% do curso.
<span ng-show="cs.can_emmit_receipt">
Clique abaixo para acessar seu comprovante. Ele pode ser visualizado por qualquer pessoa
através do link de acesso.
</span >
<dd ng-show="cs.can_emmit_receipt && cs.user.is_profile_filled">
<a href="/certificate/{{ receipt.link_hash }}" class="btn btn-success">Ver comprovante</a>
</dd>
</p>
<p ng-show="!cs.user.is_profile_filled && cs.can_emmit_receipt">
Para validar seu comprovante, você precisa preencher seu perfil.
<a href="/profile/edit?next=/certificate/{{ receipt.link_hash }}">
{% endverbatim %}
{% trans 'Clique aqui para editá-lo' %}
{% verbatim %}
</a>.
</p>
<p ng-hide="cs.can_emmit_receipt">
<span>Infelizmente, seu comprovante não pode ser emitido:</span>
</p>
<p ng-hide="cs.course_finished">
Para concluir o curso, você precisa finalizar {{ cs.min_percent_to_complete }}% das atividades e
você concluiu {{ cs.percent_progress }}%
</p>
<p ng-hide="cs.course_finished">
Finalize as atividades restantes para que seu comprovante possa ser emitido!
</p>
</div>
<!--<div class="col-md-6">-->
<!--<span class="text-danger"><i class="glyphicon glyphicon-exclamation-sign"></i> Importante</span>-->
<!--<p>-->
<!--O <strong>comprovante</strong> é a prova de que você concluiu a carga mínima necessária do curso, designada pelos instrutores. Porém, ele <strong>não</strong> possui a validade de um <strong>certificado</strong>.-->
<!--</p>-->
<!--<p ng-show="cs.certificate.processes.length">-->
<!--Processo de certificação em andamento, para verificar o status do processo, clique-->
<!--{% endverbatim %}-->
<!--<a href="user_courses/#my-certificates">aqui</a>-->
<!--{% verbatim %}-->
<!--</p>-->
<!--<p ng-show="cs.can_emmit_receipt && !cs.certificate.processes.length">-->
<!--Para obter um certificado, é necessário ser aprovado na avaliação do curso. Peça a emissão-->
<!--do certificado clicando abaixo.-->
<!--</p>-->
<!--<p ng-show="cs.can_emmit_receipt && !cs.user.is_profile_filled" class="alert alert-danger">-->
<!--Você precisa preencher seu perfil antes de entrar em um processo de certificação-->
<!--</p>-->
<!--&lt;!&ndash; TODO trocar o link pra emissão de certificado &ndash;&gt;-->
<!--<div ng-show="cs.can_emmit_receipt && cs.user.is_profile_filled" class="text-right">-->
<!--<a ng-hide="cs.certificate.processes.length"-->
<!--ng-click="createCertificationProcess()" class="btn btn-success">-->
<!--{% endverbatim %}-->
<!--Pedir certificado-->
<!--{% verbatim %}-->
<!--</a>-->
<!--</div>-->
<!--</div>-->
</div>
{% endverbatim %}
</div>
<div class="modal-footer">
<button type="button" class="btn btn-danger" ng-click="cancel()">{% trans "Close" %}</button>
</div>
</script>
......@@ -7,8 +7,6 @@
{% block js %}
{{ block.super }}
{% compress js %}
<script type="text/javascript" src="{% static 'tinymce-dist/tinymce.js' %}"></script>
<!-- Markdown -->
<script type="text/javascript" src="{% static 'js/vendor/pagedown/Markdown.Converter.js' %}"></script>
<script type="text/javascript" src="{% static 'js/vendor/pagedown/Markdown.Editor.js' %}"></script>
......@@ -16,6 +14,12 @@
<script type="text/javascript" src="{% static 'js/markdown/app.js' %}"></script>
<script type="text/javascript" src="{% static 'js/markdown/filters.js' %}"></script>
<script src="https://unpkg.com/tinymce@4.5.10/tinymce.min.js"></script>
<script src="https://unpkg.com/ng-file-upload@12.0.4/dist/ng-file-upload.min.js"></script>
<script src="https://unpkg.com/angular-ui-tinymce@0.0.19/dist/tinymce.min.js"></script>
<script type="text/javascript" src="{% static 'angular-scroll/angular-scroll.js' %}"></script>
{% compress js %}
<!-- Lesson -->
<script type="text/javascript" src="{% static 'js/activities/app.js' %}"></script>
<script type="text/javascript" src="{% static 'js/activities/controllers.js' %}"></script>
......@@ -29,14 +33,6 @@
<script type="text/javascript" src="{% static 'js/directives/codemirror.js' %}"></script>
<script type="text/javascript" src="{% static 'js/directives/layout.js' %}"></script>
<!-- Forum (Timtec version) -->
<script type="text/javascript" src="{% static 'js/forum/app.js' %}"></script>
<script type="text/javascript" src="{% static 'js/forum/controllers.js' %}"></script>
<script type="text/javascript" src="{% static 'js/forum/directives.js' %}"></script>
<script type="text/javascript" src="{% static 'js/forum/filters.js' %}"></script>
<script type="text/javascript" src="{% static 'js/forum/services.js' %}"></script>
<script type="text/javascript" src="{% static 'js/factories/timtec-models.js' %}"></script>
<!-- Notes -->
<script type="text/javascript" src="{% static 'js/notes/app.js' %}"></script>
<script type="text/javascript" src="{% static 'js/notes/controllers.js' %}"></script>
......@@ -48,10 +44,8 @@
<script type="text/javascript" src="{% static 'js/discussion-controllers.js' %}"></script>
<script type="text/javascript" src="{% static 'js/discussion-services.js' %}"></script>
<script type="text/javascript" src="{% static 'js/discussion-directives.js' %}"></script>
<script type="text/javascript" src="{% static 'angular-ui-tinymce/src/tinymce.js' %}"></script>
<script type="text/javascript" src="{% static 'js/ui.tinymce.paralapraca.config.js' %}"></script>
<script type="text/javascript" src="{% static 'ng-file-upload/ng-file-upload.js' %}"></script>
<script type="text/javascript" src="{% static 'angular-scroll/angular-scroll.js' %}"></script>
<script src="{% static 'js/ui.tinymce.paralapraca.config.js' %}"></script>
{% endcompress %}
<script type="text/javascript">
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment