Commit 1829df16 by chrisndodge

Merge pull request #45 from edx/muhhshoaib/PHX-24-proctored-exam-status-screens

PHX-24
parents b6bcbaa6 cd0897ed
# pylint: disable=too-many-branches
# pylint: disable=too-many-statements
"""
In-Proc API (aka Library) for the edx_proctoring subsystem. This is not to be confused with a HTTP REST
......@@ -495,7 +496,6 @@ def get_student_view(user_id, course_id, content_id,
if user_role != 'student':
return None
has_finished_exam = False
student_view_template = None
exam_id = None
......@@ -552,10 +552,20 @@ def get_student_view(user_id, course_id, content_id,
})
else:
student_view_template = 'proctoring/seq_timed_exam_entrance.html'
elif has_finished_exam:
student_view_template = 'proctoring/seq_timed_exam_completed.html'
elif has_time_expired:
student_view_template = 'proctoring/seq_timed_exam_expired.html'
elif attempt['status'] == ProctoredExamStudentAttemptStatus.submitted:
student_view_template = 'proctoring/seq_proctored_exam_submitted.html'
elif attempt['status'] == ProctoredExamStudentAttemptStatus.verified:
student_view_template = 'proctoring/seq_proctored_exam_verified.html'
elif attempt['status'] == ProctoredExamStudentAttemptStatus.rejected:
student_view_template = 'proctoring/seq_proctored_exam_rejected.html'
elif attempt['status'] == ProctoredExamStudentAttemptStatus.completed:
if is_proctored:
student_view_template = 'proctoring/seq_proctored_exam_completed.html'
else:
student_view_template = 'proctoring/seq_timed_exam_completed.html'
if student_view_template:
template = loader.get_template(student_view_template)
django_context = Context(context)
......
{% load i18n %}
<div class="sequence proctored-exam completed" data-exam-id="{{exam_id}}">
<h3>
{% blocktrans %}
This is the end of your proctored exam
{% endblocktrans %}
</h3>
<p>
{% blocktrans %}
Make sure your responses and work are ready to be submitted. Once they are, you may end the exam below.
Your worked will then be graded and your proctored session will be reviewed separately.
{% endblocktrans %}
</p>
<button type="button" name="submit-proctored-exam" >
{% blocktrans %}
I'm ready! Submit my answers and end my proctored exam
{% endblocktrans %}
</button>
</div>
<div class="footer-sequence border-b-0 padding-b-0">
<span> {% trans "What happens next ?" %} </span>
<p>
{% blocktrans %}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.
Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim.
{% endblocktrans %}
</p>
</div>
......@@ -38,7 +38,7 @@
rules for online proctoring.
{% endblocktrans %}
</p>
<p class="proctored-exam-option">
<p class="proctored-exam-instruction">
{% blocktrans %}
Don't want to take this exam with online proctoring? <a href="#">Take this exam as an open exam instead.</a>
{% endblocktrans %}
......
{% load i18n %}
<div class="failure sequence proctored-exam" data-exam-id="{{exam_id}}">
<h3>
{% blocktrans %}
Your proctoring session was reviewed and did not pass requirements
{% endblocktrans %}
</h3>
<h4>
{% blocktrans %}
Your Proctoring Session review: <b class="failure"> Failed </b>
{% endblocktrans %}
</h4>
<p>
{% blocktrans %}
Your session was reviewed by one of our proctors and some activities noted violate the
<a href="#">requirements and guidelines</a> needed for a successful review,
{% endblocktrans %}
</p>
<hr>
<p>
{% blocktrans %}
Please see <a href="{{progress_page_url}}">your progress in this course </a>
for your general course credit worthiness.
{% endblocktrans %}
</p>
</div>
<div class="footer-sequence border-b-0 padding-b-0">
<span> {% trans "Can I contest this review?" %} </span>
<p class="proctored-exam-option">
{% blocktrans %}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
Aenean massa.
{% endblocktrans %}
</p>
<a href="#" class="contest-review">Contest this review</a>
<hr class="clearfix">
<span> {% trans "Is there anything I can do to make up/replace this session?" %} </span>
<p class="proctored-exam-option">
{% blocktrans %}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
Aenean massa.
{% endblocktrans %}
</p>
<hr class="clearfix">
<span> {% trans "See Also" %} </span>
<p>
{% blocktrans %}
<a class="footer-link" href="#">
Frequently asked questions about proctoring and earning college credit.
</a>
{% endblocktrans %}
</p>
</div>
{% load i18n %}
<div class="sequence proctored-exam completed" data-exam-id="{{exam_id}}">
<h3>
{% blocktrans %}
You have submitted this proctored exam for review
{% endblocktrans %}
</h3>
<h4>
{% blocktrans %}
Your Proctoring Session review: <b> Pending </b>
{% endblocktrans %}
</h4>
<p>
{% blocktrans %}
In general sessions are reviewed in 24-48 hours of submission. If you have questions about
the status of this review after that timeframe, <a href="#">contact edX support</a>
{% endblocktrans %}
</p>
<hr>
<p>
{% blocktrans %}
Please see <a href="{{progress_page_url}}">your progress in this course </a>
for your general course credit worthiness.
{% endblocktrans %}
</p>
</div>
<div class="footer-sequence border-b-0 padding-b-0">
<span> {% trans "See Also" %} </span>
<p>
{% blocktrans %}
<a class="footer-link" href="#">
Frequently asked questions about proctoring and earning college credit.
</a>
{% endblocktrans %}
</p>
</div>
{% load i18n %}
<div class="success sequence proctored-exam passed" data-exam-id="{{exam_id}}">
<h3>
{% blocktrans %}
Your proctoring session was reviewed and passed all requirements
{% endblocktrans %}
</h3>
<h4>
{% blocktrans %}
Your Proctoring Session review: <b class="success"> Passed </b>
{% endblocktrans %}
</h4>
<p>
{% blocktrans %}
This satisfies the requirement that you complete this exam in a proctored format and contributes
to your credit earning work for this course.
{% endblocktrans %}
</p>
<hr>
<p>
{% blocktrans %}
Please see <a href="{{progress_page_url}}">your progress in this course </a>
for your general course credit worthiness.
{% endblocktrans %}
</p>
</div>
<div class="footer-sequence border-b-0 padding-b-0">
<span> {% trans "See Also" %} </span>
<p>
{% blocktrans %}
<a class="footer-link" href="#">
Frequently asked questions about proctoring and earning college credit.
</a>
{% endblocktrans %}
</p>
</div>
{% load i18n %}
<div class="sequence timed-exam completed">
<div class="gated-sequence">
{% trans "You have finished your exam!" %}
</div>
<div class="sequence timed-exam completed" data-exam-id="{{exam_id}}">
<h3>
{% blocktrans %}
This is the end of your timed exam
{% endblocktrans %}
</h3>
<p>
{% blocktrans %}
Make sure your responses and work are ready to be submitted. Once they are, you may end the exam below
and your worked will then be graded.
{% endblocktrans %}
</p>
<button type="button" name="submit-timed-exam" >
{% blocktrans %}
I'm ready! Submit my answers and end my timed exam
{% endblocktrans %}
</button>
</div>
<div class="footer-sequence border-b-0 padding-b-0">
<span> {% trans "What happens next ?" %} </span>
<p>
{% blocktrans %}
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.
Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim.
{% endblocktrans %}
</p>
</div>
{% include 'proctoring/seq_timed_exam_footer.html' %}
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