mirror of
https://bitbucket.org/studiotem/jandl-taskmanager-app.git
synced 2026-10-21 14:29:34 +00:00
[auth] Added auth guard
This commit is contained in:
1 parent
ef6369714b
commit
1e86dbbbb3
5 files changed
+44
-21
No files matched your search
@@ -35,13 +35,12 @@ export default {
|
||||
splitDays() {
|
||||
const days = []
|
||||
const workingHours = {}
|
||||
const capacityPerDay = this.$store.getters['auth/user'].work_end - this.$store.getters['auth/user'].work_start
|
||||
|
||||
this.timelineData.tasks.forEach(task => {
|
||||
if (!workingHours[task.split])
|
||||
workingHours[task.split] = 0
|
||||
|
||||
if (task.nonWorking)
|
||||
if (task.nonWorking || task.subtask.is_finished)
|
||||
return
|
||||
|
||||
workingHours[task.split] += timelineUtils._getDifferenceInHours(task.end, task.start)
|
||||
@@ -52,7 +51,7 @@ export default {
|
||||
id: i + 1,
|
||||
fullname: `${this.filter.employee.name} ${this.filter.employee.surname}`,
|
||||
initials: this.filter.employee.name.charAt(0).toUpperCase() + this.filter.employee.surname.charAt(0).toUpperCase(),
|
||||
unscheduledTime: capacityPerDay - workingHours[i + 1],
|
||||
unscheduledTime: workingHours[i + 1],
|
||||
date: addDays(this.filter.start, i),
|
||||
isWeekend: timelineUtils.isWeekend(addDays(this.filter.start, i))
|
||||
})
|
||||
|
||||
Reference in new issue
Block a user