From 07a3da4ed7ec672bba8f094e94f41f0d1973677c Mon Sep 17 00:00:00 2001 From: Hannes Kuchelmeister Date: Mon, 19 Oct 2020 16:58:43 +0200 Subject: [PATCH] add fill free space after adding task --- index.html | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index ca48e01..0d61bb3 100644 --- a/index.html +++ b/index.html @@ -215,8 +215,13 @@ } split_up = function(appointment){ this.parent.remove_child(this.id); + if(appointment.start != this.start) { + this.parent.add_child(new EmptySpaceAppointment(this.start, appointment.start)); + } this.parent.add_child(appointment); - // TODO: fill empty space + if(appointment.end != this.end) { + this.parent.add_child(new EmptySpaceAppointment(appointment.end, this.end)); + } this.parent.rebulid_html(); } }