Skip to content
Snippets Groups Projects
Commit 111b47ba authored by Julian's avatar Julian
Browse files

Simplify sorting method

parent 164e5596
No related branches found
No related tags found
1 merge request!2Resolve "Frontend for Models"
......@@ -285,9 +285,8 @@ export default {
return this.items
?.sort(
(a,b) =>
60 * 60 * (parseInt(a.timeStart.slice(0, 2)) - parseInt(b.timeStart.slice(0, 2)))
+ 60 * (parseInt(a.timeStart.slice(3, 5)) - parseInt(b.timeStart.slice(3, 5)))
+ parseInt(a.timeStart.slice(6, 8)) - parseInt(b.timeStart.slice(6, 8))
parseInt(a.timeStart.replace(":", ""))
- parseInt(b.timeStart.replace(":", ""))
) || [];
},
columns() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment