From 790a1b316dbc80fc41705ad0a2abb5fb34a1a463 Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Sun, 19 Sep 2021 19:32:33 +0000 Subject: [PATCH] --- ayanova/src/views/home-schedule.vue | 30 ++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/ayanova/src/views/home-schedule.vue b/ayanova/src/views/home-schedule.vue index 309026e1..4ae8a48f 100644 --- a/ayanova/src/views/home-schedule.vue +++ b/ayanova/src/views/home-schedule.vue @@ -360,11 +360,10 @@ export default { }; }, methods: { - startDrag({ event, timed }) { + startDrag({ event }) { // console.log("startDrag", event); - //TODO: IF event is not editable then just return here to prevent the drag - //if (event && timed) { - if (event) { + + if (event && event.editable) { //My work around to disambiguate dragging and clicking clearTimeout(this.dragTimeout); this.dragged = false; @@ -379,19 +378,20 @@ export default { }, extendBottom(event) { // console.log("extendBottom", event); - //TODO: if event is not editable then just return here to prevent extend - //My work around to disambiguate extending and clicking - clearTimeout(this.dragTimeout); - this.dragged = false; - this.dragTimeout = setTimeout(() => { - this.dragged = true; - }, 100); // Minimal delay to be regarded as extend instead of click + if (event.editable) { + //My work around to disambiguate extending and clicking + clearTimeout(this.dragTimeout); + this.dragged = false; + this.dragTimeout = setTimeout(() => { + this.dragged = true; + }, 100); // Minimal delay to be regarded as extend instead of click - //this.dragEvent = event; - this.extendEvent = event; - this.createStart = event.start; - this.extendOriginal = event.end; + //this.dragEvent = event; + this.extendEvent = event; + this.createStart = event.start; + this.extendOriginal = event.end; + } }, async endDragExtend() { //On drag then dragEvent and dragTime are set