1
0

Fix gantt chart (#79)

Fix moving tasks in Gantt

Start fixing gantt

Co-authored-by: kolaente <k@knt.li>
Reviewed-on: https://kolaente.dev/vikunja/frontend/pulls/79
This commit is contained in:
konrad
2020-04-04 16:26:35 +00:00
parent 27e2839f4c
commit 8480bf334f
3 changed files with 72 additions and 28 deletions

View File

@ -12,9 +12,9 @@ export default class TaskModel extends AbstractModel {
this.listID = Number(this.listID)
// Make date objects from timestamps
this.dueDate = new Date(this.dueDate)
this.startDate = new Date(this.startDate)
this.endDate = new Date(this.endDate)
this.dueDate = this.dueDate ? new Date(this.dueDate) : null
this.startDate = this.startDate ? new Date(this.startDate) : null
this.endDate = this.endDate ? new Date(this.endDate) : null
// Cancel all scheduled notifications for this task to be sure to only have available notifications
this.cancelScheduledNotifications()
@ -215,4 +215,5 @@ export default class TaskModel extends AbstractModel {
console.debug('Error scheduling notification', e)
})
}
}
}