forked from jaredcraddock/schedulebuilder
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtechManual.txt
More file actions
62 lines (50 loc) · 2.9 KB
/
techManual.txt
File metadata and controls
62 lines (50 loc) · 2.9 KB
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
Technical Support Manual
---------------------------
Table of Contents:
I. Table of Contents.
II. Overview
III. Classes and Functions
IV. Events
--------------------------------------
II. Overview :
Website: cuschedulebuilder.azurewebsites.net
The CU schedule builder scrapes https://apps.concord.edu/schedules/seatstaken.php every 5 minutes in order to update course data. The project consist of a front-end by means of HTML,CSS, jQuery, and DataTables. The back end consist of a MySQL database, A web-scraper built in python, and a PHP server processing script.
The process of events are as follows:
The webscraper constantly scrapes Concord's website every 5 minutes and updates the MySQL database.
The AJAX address in the front end tables.js file is set to the server side PHP script that queries the database.
The PHP script queries the database and returns the information via JSON format to the front end.
The front end receives this information and inserts it into a table that supports dynamic multi-column searching that does not require page refreshes
The courses offered table continues to be constantly updated every 5 minutes.
---------------------------------------
III. Classes and Functions
Classes
A. Course
Functions
A. wipeWeekTable()
B. prettifyTime(time)
---------------------------------------
IV. Events
A. $(document).ready(function () {})
i. Defines the variables for the DataTables, courseTable and scheduleTable, and sets the initiale settings for the tables
a. Once courseTable completes its initialization, a function populates the dropdown select boxes for specified columns whose
column header contains the selectSearch in its ID.
b. courseTable creates text input search boxes for column headers that contain textSearch in its ID.
B. courseTable.on('click', '#addButton', function() {} )
i. Adds a click event to the add button in the table and when the button is clicked, the row is removed from the course table and
added to the scheduleTable and tells the courseTable to redraw itself.
a. Calls the wipeWeekTable function.
C. scheduleTable.on('click', '#removeButton', function() {} )
i. Adds a click event to the remove button in the table. When clicked, the row is removed from the scheduleTable and added to
the courseTable.
a. Calls the wipeWeekTable function.
D. $("#weekTableButton").click(function() {} )
i. Generates the week at a glance table based on the courses listed in scheduleTable.
---------------------------------------
V. Functions
A. wipeWeekTable()
i. If the week at a glance table container is displayed on the screen,
a. Fade the container to minumum opacity
b. Remove the contents of the container in which the week at a glance table is contained.
B. prettyifyTime(time)
i. Converts an integer or a string of an integer within the range 100 to 2400 into a 12-hour clock format string and returns
the formatted string.