multiple schedule suppport kinda
This commit is contained in:
@@ -78,6 +78,7 @@ export class CourseCatalogScraper {
|
||||
number,
|
||||
status,
|
||||
isReserved,
|
||||
creditHours: this.getCreditHours(number),
|
||||
schedule: this.getSchedule(row),
|
||||
registerURL: this.getRegisterURL(row),
|
||||
url: this.getURL(row),
|
||||
@@ -112,6 +113,15 @@ export class CourseCatalogScraper {
|
||||
return [courseName, department, number];
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets how many credit hours the course is worth
|
||||
* @param number the course number, CS 314H
|
||||
* @return the number of credit hours the course is worth
|
||||
*/
|
||||
getCreditHours(number: string): number {
|
||||
return Number(number.split('')[0]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Scrape the Unique ID from the course catalog table row
|
||||
* @param row the row of the course catalog table
|
||||
|
||||
Reference in New Issue
Block a user