-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html.template
executable file
·66 lines (57 loc) · 1.4 KB
/
index.html.template
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
<?php
# Define the settings
$settings = array (
'username' => 'the_username',
'password' => 'the_password',
'userCallback' => 'getUser', // Defined below
'collegesCallback' => 'getColleges', // Defined below
'dosListCallback' => 'getDosList', // Defined below
);
# Callback function to get details of a user
function getUser ($databaseConnection, $userId)
{
/*
Must return a datastructure like this; this example shows a member of Academic-related staff, with the type shown and appropriate booleans:
Array
(
[isUndergraduate] => 0
[isGraduate] => 0
[isStaff] => 1
[isStaffInternal] => 1
[staffType] => Academic-related staff
[course__JOIN__people__courses__reserved] =>
);
*/
}
# Callback function to get a list of Colleges
function getColleges ($databaseConnection)
{
/*
Must return a datastructure like this:
Array
(
[christs] => Christ's
[chu] => Churchill
...
[wolfson] => Wolfson
);
*/
}
# Function to get a list of Directors of Studies
function getDosList ($databaseConnection)
{
/*
Must return a datastructure like this:
Array
(
[abc123] => Dr Anton Callahan <abc123>
[sqpr1] => Dr Steve Rex <sqpr1>
...
[xyz1] => Dr Xavier Zachary <xyz1>
);
*/
}
# Load and run the example assessments class, which implements the reviewable assessments class
require_once ('vendor/autoload.php');
new exampleAssessments ($settings);
?>