(js) Only allow dragging of editable events

pull/101/head^2
Francis Lachapelle 2015-11-26 13:31:26 -05:00
parent 2e2d8b6963
commit 00b22a71db
1 changed files with 7 additions and 3 deletions

View File

@ -21,9 +21,13 @@
};
function link(scope, element, attrs, calendarDayCtrl) {
if (scope.block)
// Add dragging grips to existing event block
initGrips();
if (scope.block) {
if (scope.block.component.editable)
// Add dragging grips to existing event block
initGrips();
else
return;
}
// Start dragging on mousedown
element.on('mousedown', onDragDetect);