From acdd076ce7344b78dcb389d044cc4b11110f5458 Mon Sep 17 00:00:00 2001 From: Hadi Nategh Date: Tue, 17 Dec 2013 08:25:51 +0000 Subject: [PATCH] Fix to get the correct calendar droppable element for height calculation --- calendar/js/app.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/calendar/js/app.js b/calendar/js/app.js index 7dc2bdf356..f563e1e2fd 100644 --- a/calendar/js/app.js +++ b/calendar/js/app.js @@ -147,8 +147,9 @@ app.classes.calendar = AppJS.extend( var dataResize = resizeHelper.split("|"); var time = dataResize[1].split(":"); var dropDate = dataResize[0]+"T"+time[0]+time[1]; + var calOwner = this.getAttribute('id').substring(this.getAttribute('id').lastIndexOf("_O")+2,this.getAttribute('id').lastIndexOf("_C")); - var drop = jQuery("div[id^='drop_"+dropDate+"']"); + var drop = jQuery("div[id^='drop_"+dropDate+"_O"+calOwner+"']"); var newDuration = Math.round(this.clientHeight/drop[0].clientHeight)* parseInt(dataResize[2]) * 60; that.dropEvent(this.getAttribute('id'),dropDate,newDuration); },