Sha256: c2c2d41ee34c03bea011acc6a5fb18e1dd15399784bc35478269c756b90458cd

Contents?: true

Size: 779 Bytes

Versions: 3

Compression:

Stored size: 779 Bytes

Contents

//= require uploader/locales/en
//= require uploader/tmpl.min
//= require uploader/load-image.min
//= require uploader/jquery.iframe-transport
//= require uploader/jquery.fileupload
//= require uploader/jquery.fileupload-ui

$(document).off('init.sort').on('init.sort', '.uploader-files', function() {
    var $t = $(this);
    $t.sortable({
        update: function(event, ui) {
            var sort = [];
            $t.children().each(function() {
                sort.push($(this).data('id'));
            });
            $.ajax({
                type: 'POST',
                url: $t.data('sortPath'),
                data: {sort: sort.join('|')}
            })
        }
    })
});

$('.uploader-dnd-area input[type=file]').trigger("init.uploader");

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
glebtv-rails-uploader-0.1.3 app/assets/javascripts/uploader/rails_admin.js
glebtv-rails-uploader-0.1.2 app/assets/javascripts/uploader/rails_admin.js
glebtv-rails-uploader-0.1.1 app/assets/javascripts/uploader/rails_admin.js