[F] Fix sorting
This commit is contained in:
@@ -185,8 +185,8 @@ export default class App extends Vue
|
|||||||
// Parse json and filter it
|
// Parse json and filter it
|
||||||
course.assignments = JsonUtils.filterAssignments(response.data);
|
course.assignments = JsonUtils.filterAssignments(response.data);
|
||||||
|
|
||||||
// Sort by date
|
// Sort by date (Latest is at 0)
|
||||||
course.assignments.sort((a, b) => a.date.getTime() - b.date.getTime());
|
course.assignments.sort((a, b) => b.date.getTime() - a.date.getTime());
|
||||||
|
|
||||||
// Filter assignments into terms
|
// Filter assignments into terms
|
||||||
let termAssignments: Assignment[][] = [[], [], [], []];
|
let termAssignments: Assignment[][] = [[], [], [], []];
|
||||||
|
|||||||
Reference in New Issue
Block a user