* Finish task #43987.
This commit is contained in:
@@ -2433,7 +2433,7 @@ EOT;
|
||||
}
|
||||
}
|
||||
|
||||
$treeMenu[$module->parent] .= '<li class="' . implode(' ', $class) . '" data-id=' . $module->id . '>' . $li . '</li>';
|
||||
$treeMenu[$module->parent] .= '<li class=" can-sort ' . implode(' ', $class) . '" data-id=' . $module->id . '>' . $li . '</li>';
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -98,15 +98,16 @@ $sideWidth = common::checkNotCN() ? '270' : '238';
|
||||
if(!e.changed) return;
|
||||
|
||||
var orders = {};
|
||||
$('#modules').find('li.has-list').each(function()
|
||||
$('#modules').find('li.can-sort').each(function()
|
||||
{
|
||||
var $li = $(this);
|
||||
|
||||
var item = $li.data();
|
||||
orders['orders[' + item.id + ']'] = $li.attr('data-order') || item.order;
|
||||
'<?php echo $type;?>' == 'book' ? orders['sort[' + item.id + ']'] = $li.attr('data-order') || item.order : orders['orders[' + item.id + ']'] = $li.attr('data-order') || item.order;
|
||||
});
|
||||
|
||||
$.post('<?php echo $this->createLink('tree', 'updateOrder');?>', orders, function(data){}).error(function()
|
||||
var link = '<?php echo $type;?>' == 'book' ? createLink('doc', 'sortBookOrder') : createLink('tree', 'updateOrder');
|
||||
$.post(link, orders, function(data){}).error(function()
|
||||
{
|
||||
bootbox.alert(lang.timeout);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user