1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
|
{% /*
Copyright 2011-2013, Marten de Vries
This file is part of OpenTeacher.
OpenTeacher is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
OpenTeacher is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with OpenTeacher. If not, see <http://www.gnu.org/licenses/>.
*/ %}
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>{%= o.list.title || "" %}</title>
<style type='text/css'>
body {
font-family:Verdana, Helvetica, Arial, sans-serif;
margin:{%= o.margin %};
}
h1 {
font-size:x-large;
}
table {
border-collapse:collapse;
width:100%;
}
th {
text-align:left;
border-bottom:1px solid #000;
}
.number {
text-align:right;
color:#888;
padding-left:0;
}
.question, #question-header {
padding-left:1em;
}
.answer, #answer-header {
padding-left:2em;
padding-right:0;
}
{% if (o.coloredRows) { %}
.even {
background-color:#ddd;
}
{% } %}
th, td {
padding: 0.25em;
}
</style>
</head>
<body>
<h1>{%= o.list.title || "" %}</h1>
<table>
<thead>
<tr>
<th id='number-header'></th>
<th id='question-header'>{%= o.list.questionLanguage || "" %}</th>
<th id='answer-header'>{%= o.list.answerLanguage || "" %}</th>
</tr>
</thead>
<tbody>
{% for (var i = 0; i < (o.list.items || []).length; i += 1) { %}
{% if (i % 2) { %}
<tr class='even'>
{% } else { %}
<tr class='odd'>
{% } %}
<td class='number'>{%= i + 1 %}</td>
<td class='question'>{%= o.compose(o.list.items[i].questions || []) %}</td>
<td class='answer'>{%= o.compose(o.list.items[i].answers || []) %}</td>
</tr>
{% } %}
</tbody>
</table>
</body>
</html>
|