fix studio-ui onupdate chutier, element were not draggable anymore
This commit is contained in:
@@ -266,6 +266,8 @@
|
|||||||
function onLoadedChutier($studioChutier, data){
|
function onLoadedChutier($studioChutier, data){
|
||||||
$studioChutier.replaceWith(data.rendered);
|
$studioChutier.replaceWith(data.rendered);
|
||||||
initAjaxChutierLinks();
|
initAjaxChutierLinks();
|
||||||
|
// set chutier element draggable again
|
||||||
|
setChutierDraggable();
|
||||||
$('body').trigger({
|
$('body').trigger({
|
||||||
'type':'on-studio-chutier-updated'
|
'type':'on-studio-chutier-updated'
|
||||||
});
|
});
|
||||||
@@ -331,6 +333,10 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
// set chutier element draggable
|
// set chutier element draggable
|
||||||
|
setChutierDraggable();
|
||||||
|
|
||||||
|
};
|
||||||
|
function setChutierDraggable(){
|
||||||
$('.chutier_ui .item-list li>div').draggable({
|
$('.chutier_ui .item-list li>div').draggable({
|
||||||
containment:$('#studio-ui'),
|
containment:$('#studio-ui'),
|
||||||
scroll:false,
|
scroll:false,
|
||||||
@@ -357,8 +363,7 @@
|
|||||||
revertDuration:0,
|
revertDuration:0,
|
||||||
connectToSortable:$('.composition_ui .composer .composition .field--name-documents'),
|
connectToSortable:$('.composition_ui .composer .composition .field--name-documents'),
|
||||||
});
|
});
|
||||||
|
}
|
||||||
};
|
|
||||||
function onOrderChanged(e, ui){
|
function onOrderChanged(e, ui){
|
||||||
console.log('onOrderChanged : e', e);
|
console.log('onOrderChanged : e', e);
|
||||||
var cid = $(e.target).parents('.composition').attr('cid');
|
var cid = $(e.target).parents('.composition').attr('cid');
|
||||||
|
|||||||
Reference in New Issue
Block a user