Sha256: 54e7fe3379dcad291622b4944f33bd2508c35aace89b39bc48a9de59b0e5ede1

Contents?: true

Size: 436 Bytes

Versions: 2

Compression:

Stored size: 436 Bytes

Contents

# The list of blocks on a page.
class @BlockList extends modularity.Module

  constructor: ->
    super

    # Make block list sortable.
    $('.block_list').sortable(stop: @sorting_finished)
    $('.block_list').disableSelection()


  # Returns the data of the blocks.
  get_data: ->
    for tr in @$('tr')
      new Block($(tr)).get_data()


  # Called when the sorting is done.
  sorting_finished: =>
    @trigger 'sorting_finished'

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
flms-0.9.0 app/assets/javascripts/flms/admin/pages/edit/block_list.coffee
flms-0.1.0 app/assets/javascripts/flms/admin/pages/edit/block_list.coffee