Attempt to resurrect qomet code - need some rewrite
[qomet.git] / views / evaluation.pug
CommitLineData
e99c53fb
BA
1extends withQuestions
2
3block append stylesheets
43828378 4 link(rel="stylesheet" href="/stylesheets/statements.css")
e99c53fb
BA
5 link(rel="stylesheet" href="/stylesheets/assessment.css")
6 noscript
7 meta(http-equiv="Refresh" content="0; URL=/enablejs")
8
9block rightMenu
10 a#rightButton.btn-floating.btn-large.grey(href=assessment.name + "/monitor")
11 i.material-icons video_label
12
13block content
14 .container#assessment
15 .row
16 #warning.modal
f03a2ad9 17 .modal-content {{ warnMsg }}
e99c53fb
BA
18 .modal-footer
19 .center-align
f03a2ad9 20 a.modal-action.modal-close.waves-effect.waves-light.btn-flat(href="#!") Ok
e99c53fb 21 .row
8a2b3260 22 .col.s12.m10.offset-m1
e99c53fb 23 h4= assessment.name
cc7c0f5e 24 #stage0(v-show="stage==0")
e99c53fb
BA
25 .card
26 .input-field.inline.on-left
27 label(for="number") Number
28 input#number(type="text" v-model="student.number" @keyup.enter="getStudent()")
29 button.waves-effect.waves-light.btn(@click="getStudent()") Send
cc7c0f5e 30 #stage1(v-show="stage==1")
e99c53fb
BA
31 .card
32 if assessment.mode != "open"
e99c53fb
BA
33 .input-field.inline
34 label(for="name") Name
35 input#name(type="text" v-model="student.name" disabled)
cc7c0f5e 36 p.center-align
e99c53fb
BA
37 if assessment.mode != "open"
38 button.waves-effect.waves-light.btn.on-left(@click="cancelStudent") Cancel
39 button.waves-effect.waves-light.btn(@click="startAssessment") Start!
71d1ca9c 40 #stage0_1_4(v-show="[0,1,4].includes(stage)")
e99c53fb
BA
41 .card
42 .introduction(v-html="assessment.introduction")
8d386418 43 #stage2_4(v-if="[2,4].includes(stage)")
e99c53fb 44 if assessment.time > 0
3b8117c5 45 .card(v-show="stage==2")
71d1ca9c 46 .timer.center {{ countdown }}
e99c53fb 47 .card
1131a8e7 48 button.sendAnswer.waves-effect.waves-light.btn(v-show="stage==2" @click="sendAnswer") Send
8a51dbf7 49 statements(:questions="assessment.questions" :answers="answers")
3b8117c5 50 if assessment.display == "all"
1131a8e7 51 button.sendAnswer.waves-effect.waves-light.btn(v-show="stage==2" @click="sendAnswer") Send
cc7c0f5e 52 #stage3(v-show="stage==3")
e99c53fb
BA
53 .card
54 .finish Exam completed ☺ ...don't close the window!
e99c53fb
BA
55
56block append javascripts
57 script.
58 let assessment = !{JSON.stringify(assessment)};
435371c7 59 const monitoring = false;
71d1ca9c
BA
60 script(src="//cdnjs.cloudflare.com/ajax/libs/socket.io/2.0.4/socket.io.js")
61 script(src="/javascripts/utils/libsRefresh.js")
435371c7 62 script(src="/javascripts/components/statements.js")
e99c53fb 63 script(src="/javascripts/assessment.js")