Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for year-long modules to module planner #2913

Open
wants to merge 28 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 24 commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
22ca05d
Add support for year-long modules to module planner
jeffsieu Oct 17, 2020
1029b35
Fix module planner dragging
jeffsieu Oct 17, 2020
725a1e9
Fix dragging planner modules to bin
jeffsieu Oct 17, 2020
3cb6eb0
Add test cases for isYearLong and isYearLongModule
jeffsieu Oct 18, 2020
958a8aa
Merge branch 'master' into planner-year-long-support
jeffsieu Oct 18, 2020
e517ba1
Merge branch 'master' into planner-year-long-support
jeffsieu Oct 19, 2020
a486808
Merge branch 'master' into planner-year-long-support
jeffsieu Oct 19, 2020
adf1ab5
Remove extraneous code
jeffsieu Oct 20, 2020
2692430
Merge branch 'planner-year-long-support' of https://github.com/jeffsi…
jeffsieu Oct 22, 2020
527b8e7
Merge branch 'master' into planner-year-long-support
jeffsieu Oct 22, 2020
8a13d84
Include ModuleCondensed.yearLong in scraper
jeffsieu Oct 23, 2020
f10cd31
Merge branch 'planner-year-long-support' of https://github.com/jeffsi…
jeffsieu Oct 24, 2020
d59b7cf
Merge branch 'master' into planner-year-long-support
jeffsieu Oct 24, 2020
cec521f
Merge branch 'master' into planner-year-long-support
jeffsieu Oct 30, 2020
814f828
Merge branch 'master' into planner-year-long-support
jeffsieu Nov 8, 2020
70bc84c
Merge branch 'master' into planner-year-long-support
jeffsieu Nov 10, 2020
4ce415e
Merge branch 'master' into planner-year-long-support
jeffsieu Dec 30, 2020
88284f2
Add PlannerModuleSemester, ModuleType
jeffsieu Jan 1, 2021
5e7574e
Update scrapers/nus-v2/src/tasks/CollateModules.ts
jeffsieu Jan 1, 2021
a356999
Add workaround comment in PlannerYear
jeffsieu Jan 1, 2021
7215841
Merge branch 'planner-year-long-support' of https://github.com/jeffsi…
jeffsieu Jan 1, 2021
96f1567
Module planner: Fix multiple module code entry
jeffsieu Jan 6, 2021
dd3c64b
Merge branch 'master' into planner-year-long-support
jeffsieu Jan 7, 2021
03edd12
Merge branch 'master' into planner-year-long-support
jeffsieu Jan 8, 2021
483e0e8
Merge branch 'master' into planner-year-long-support
jeffsieu Jan 17, 2021
f79e34e
Change isSemester to type guard
jeffsieu Jan 17, 2021
3996493
Fix lint issues
jeffsieu Jan 17, 2021
4e02420
Merge branch 'planner-year-long-support' of https://github.com/jeffsi…
jeffsieu Jan 17, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions scrapers/nus-v2/src/tasks/CollateModules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,10 +118,12 @@ const getModuleCondensed = ({
moduleCode,
title,
semesterData,
attributes,
}: ModuleWithoutTree): ModuleCondensed => ({
moduleCode,
title,
semesters: semesterData.map((semester) => semester.semester),
yearLong: Boolean(attributes.year),
});

// Avoid using _.pick here because it is not type safe
Expand Down
1 change: 1 addition & 0 deletions scrapers/nus-v2/src/types/modules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ export type ModuleCondensed = Readonly<{
moduleCode: ModuleCode;
title: ModuleTitle;
semesters: number[];
yearLong: boolean;
}>;

// This format is returned from the module information endpoint
Expand Down
Loading