Dotclear

Changeset 1532:f6c9584b4677 for admin/js


Ignore:
Timestamp:
08/23/13 13:16:14 (12 years ago)
Author:
Nicolas <nikrou77@…>
Branch:
default
Message:

Fix issue #1535 : Allow categories to be ordered by drag and drop
Need to close isse #655 : duplicated

Location:
admin/js
Files:
1 added
1 edited

Legend:

Unmodified
Added
Removed
  • admin/js/_categories.js

    r1531 r1532  
    1 /* TODO: Some nice drag and drop on categories */ 
    21$(function() { 
     2     if ($.fn['nestedSortable']!==undefined) { 
     3          $('#categories ul li').css('cursor','move'); 
     4          $('#save-set-order').prop('disabled',true).addClass('disabled'); 
     5          $('#categories ul').nestedSortable({ 
     6               listType: 'ul', 
     7               items: 'li', 
     8               placeholder: 'placeholder', 
     9               update: function() { 
     10                    $('#categories_order').attr('value',JSON.stringify($('#categories ul').nestedSortable('toArray'))); 
     11                    $('#save-set-order').prop('disabled',false).removeClass('disabled'); 
     12               } 
     13          }); 
     14     } 
     15 
    316     $('.checkboxes-helpers').each(function() { 
    417          dotclear.checkboxesHelpers(this); 
Note: See TracChangeset for help on using the changeset viewer.

Sites map