mirror of
https://github.com/Icinga/icingaweb2-module-businessprocess.git
synced 2026-02-04 01:09:25 -05:00
tiles: Also show proper d&d cursors and lock drag during progress
This commit is contained in:
parent
dc69522ae5
commit
00fcce8192
2 changed files with 21 additions and 5 deletions
|
|
@ -479,6 +479,19 @@ td > a > .badges {
|
|||
}
|
||||
}
|
||||
|
||||
.tiles.sortable:not([data-sortable-disabled="true"]) {
|
||||
> div {
|
||||
cursor: grab;
|
||||
|
||||
&.sortable-chosen {
|
||||
cursor: grabbing;
|
||||
}
|
||||
}
|
||||
|
||||
&.progress > div {
|
||||
cursor: wait;
|
||||
}
|
||||
}
|
||||
|
||||
.tiles > div.parent::before {
|
||||
content: '&';
|
||||
|
|
|
|||
|
|
@ -106,11 +106,8 @@
|
|||
var evt = event.originalEvent;
|
||||
if (evt.oldIndex !== evt.newIndex) {
|
||||
var $source = $(evt.from);
|
||||
var actionUrl = [
|
||||
$source.data('actionUrl'),
|
||||
'action=move',
|
||||
'movenode=' + $(evt.item).data('nodeName')
|
||||
].join('&');
|
||||
$source.addClass('progress')
|
||||
.data('sortable').option('disabled', true);
|
||||
|
||||
var data = {
|
||||
csrfToken: $source.data('csrfToken'),
|
||||
|
|
@ -120,6 +117,12 @@
|
|||
to: evt.newIndex
|
||||
};
|
||||
|
||||
var actionUrl = [
|
||||
$source.data('actionUrl'),
|
||||
'action=move',
|
||||
'movenode=' + $(evt.item).data('nodeName')
|
||||
].join('&');
|
||||
|
||||
var $container = $source.closest('.container');
|
||||
var req = icinga.loader.loadUrl(actionUrl, $container, data, 'POST');
|
||||
req.complete(function (req, textStatus) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue