Sha256: 7c5933482e028c355a86a1f96537da2cc16877763b8f99443e5e69141aded8c5

Contents?: true

Size: 594 Bytes

Versions: 25

Compression:

Stored size: 594 Bytes

Contents

$(document).ready ->

  $('.gallery_photos.sortable').sortable
    items: ".gallery_photo"
    containment: "parent"
    start: (e, info) ->
      info.item.siblings(".selected").not(".ui-sortable-placeholder").appendTo info.item

    stop: (e, info) ->
      info.item.after info.item.find("li")

    update: ->
      $.ajax
        type: "PUT"
        # url: ROOT_URL + "gallery_photos/sort"
        url: (location.protocol + '//' + location.host + location.pathname).replace(/(\/$|\/edit)/, '') + "/gallery_photos/sort"
        data: $(this).sortable("serialize")
        dataType: "script"

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
biola_wcms_components-0.25.4 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.25.3 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.25.2 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.25.1 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.25.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.24.3 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.24.2 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.24.1 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.24.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.23.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.22.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.21.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.20.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.19.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.18.1 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.18.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.17.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.16.0 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.15.3 app/assets/javascripts/components/forms/gallery_photo.js.coffee
biola_wcms_components-0.15.2 app/assets/javascripts/components/forms/gallery_photo.js.coffee