-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathteachers.html
135 lines (130 loc) · 6.99 KB
/
teachers.html
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
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>TTAssist</title>
<link rel="icon" type="image/x-icon" href="images/TTAssistLogo.png"/>
<link rel="stylesheet" href="CSS/Style.css">
<link rel="apple-touch-icon" sizes="57x57" href="images/Icon-57.png">
<link rel="apple-touch-icon" sizes="60x60" href="images/Icon-60.png">
<link rel="apple-touch-icon" sizes="72x72" href="images/Icon-72.png">
<link rel="apple-touch-icon" sizes="76x76" href="images/Icon-76.png">
<link rel="apple-touch-icon" sizes="114x114" href="images/Icon-114.png">
<link rel="apple-touch-icon" sizes="120x120" href="images/Icon-120.png">
<link rel="apple-touch-icon" sizes="144x144" href="images/Icon-144.png">
<link rel="apple-touch-icon" sizes="152x152" href="images/Icon-152.png">
<link rel="apple-touch-icon" sizes="180x180" href="images/Icon-180.png">
<script src="JS/libraries/p5.min.js"></script>
<script src="JS/Script.js"></script>
<script src="JS/subjects.js"></script>
<script src="JS/teachers.js"></script>
<script src="JS/teachersOnly.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="TTAssist is a timetabling assistive tool." />
</head>
<body id="top" onload="teachersStart()">
<nav class="nav" id="nav">
<ul>
<li>
<a href='timetable.html'>Timetable</a>
</li>
<li>
<a href='subjects.html'>Subjects</a>
</li>
<li id="navActive">
<a href='teachers.html'>Teachers</a>
</li>
<li>
<a href='classes.html'>Classes</a>
</li>
<li>
<a href='analysis.html'>Analysis</a>
</li>
</ul>
</nav>
<div class="teachersPage mainPage">
<label for="template">Download Template File : </label>
<button type="button" id="template" name="template" value="template">Template</button>
<br>
<br>
<p>You can either complete the form below for each teacher, or download and fill in the template file using the button above. This will allow you to input the data offline, and in bulk, eg by copying from an export from your School Management Software.</p>
<br>
<br>
<br>
<form>
<label for="subFile">Upload Subjects File (required for both file check and/or manual input). Don't forget to press the "Add Subjects" button once you have selected your file. : </label>
<input type="file" id="subFile" name="uploadSub" accept=".csv">
<button type="button" id="checkItSub" name="uploadSub" value="uploadSub">Add Subjects</button>
<br>
<br>
<label for="teacherFile">Upload previous Teacher File : </label>
<input type="file" id="teacherFile" name="uploadTeacher" accept=".csv">
<button type="button" id="checkIt" name="uploadTeacher" value="uploadTeacher">Check it</button>
<p class="hide invalidFile" id="invalidFile">Sorry this is an invalid file type, please upload a valid csv file from this software.</p>
<p class="hide invalidHeaders" id="invalidHeaders">Sorry, this doesn't seem to the the right file, please ensure you are using a file based upon the templates provided.</p>
<p class="hide invalidContents" id="invalidContents">Sorry, it seems that one or more of your data rows is incomplete. Please either try to upload another file, or check the values below against expected outcomes, correct and save file again.</p>
<p class="hide invalidRow" id="invalidRow">Sorry, it seems that one or more of your data rows has produced an error. Please check the error messages below the user input for more information, try to upload another file, or check the values below against expected outcomes, correct and save file again.</p>
<p class="hide noSubjects" id="noSubjects">Sorry, it seems you haven't uploaded a valid Subjects file. Please upload a valid Subjects csv file from this software in the area above, click the "Add Subjects" button, then try again.</p>
<br>
<br>
<br>
<label for="defaultPeriods">What is the default number of periods taught by teachers per timetable? (eg what number of lessons are taught by most teachers - must be a whole number greater than 0) :</label>
<input type="number" id="defaultPeriods" name="defaultPeriods">
<br>
<br>
<p>Would you prefer to input teacher subjects by :</p>
<button type="button" id="subCode" name="subjectStyle" value="0" class="subStyleBtn active">Subject Code</button>
<button type="button" id="subName" name="subjectStyle" value="1" class="subStyleBtn">Subject Name</button>
<br>
<br>
<label for="setDefaults">Set Defaults : </label>
<button type="button" id="setDefaults" name="setDefaults" value="setDefaults">Set Defaults</button>
<p class="hide noPeriods" id="noPeriods">Sorry, it seems you haven't set a value for the default number of periods taught. This should be a whole number greater than 0, recommended to be the number of periods taught by the majority of your staff. Please amend your value above and try again.</p>
<br>
<br>
<br>
<label for="teacherName">Teacher Name :</label>
<input type="text" id="teacherName" name="teacherName">
<br>
<br>
<label for="teacherCode">Teacher Code :</label>
<input type="text" id="teacherCode" name="teacherCode">
<br>
<br>
<label for="teacherPeriods">Periods taught (must be a whole number greater than 0):</label>
<input type="number" id="teacherPeriods" name="teacherPeriods">
<br>
<br>
<label for="primarySub">Main Subject :</label>
<select name="primarySub" id="primarySub">
<option value=""></option>
</select>
<br>
<br>
<label for="secondarySub">Secondary Subject :</label>
<select name="secondarySub" id="secondarySub" >
<option value=""></option>
</select>
<br>
<br>
<button type="button" id="addTeacher" name="addTeacher" value="addTeacher">Add teacher</button>
<br>
<p class="hide shortInput" id="shortInput">Sorry, you don't appear to have completed all required fields above correctly. All fields are required with the exception of the Secondary Subject. Contact Periods should be a whole number higher than 0. If you are inputting from file, please also check your Subject Codes match those in your Subjects file. Please complete all the input boxes.</p>
<p class="hide notAlphaNum" id="notAlphaNum">Sorry, the Teacher Code can only be Letters or Numbers. Please amend your Teacher Code above.</p>
<p class="hide alreadyAdded" id="alreadyAdded">Sorry, the Teacher Code you have added is already in the list. Please amend your Teacher Code above.</p>
<br>
<br>
<p>Check your Teachers: (don't forget to scroll down to save your template)</p>
<br>
<table id="teacherList" ></table>
<button type="button" id="delTeacher" name="delTeacher" value="delTeacher">Delete Row</button>
<br>
<br>
<label for="save">If this is correct : </label>
<button type="button" id="save" name="save" value="Save">Save</button>
<br>
<p>If this is not correct, please click a row to select, and then click delete to delete the faulty row.</p>
</form>
</div>
</body>
</html>