Sha256: 6eaf69e8d1b3554f87cb005ff6187cf7079bcfbf9436953685bbded37ad0b077

Contents?: true

Size: 448 Bytes

Versions: 51

Compression:

Stored size: 448 Bytes

Contents

class ItemSweeper < ActionController::Caching::Sweeper
  include ExpireEditableFragment
  observe Item

  def after_save(record)
    expire_editable_fragment(record)
    expire_editable_fragment(record.manifestation)
    record.patrons.each do |patron|
      expire_editable_fragment(patron)
    end
    record.donors.each do |donor|
      expire_editable_fragment(donor)
    end
  end

  def after_destroy(record)
    after_save(record)
  end
end

Version data entries

51 entries across 51 versions & 1 rubygems

Version Path
enju_biblio-0.1.0.pre42 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre41 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre40 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre39 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre38 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre37 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre36 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre35 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre34 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre33 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre32 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre31 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre30 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre29 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre28 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre27 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre26 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre25 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre24 app/models/item_sweeper.rb
enju_biblio-0.1.0.pre23 app/models/item_sweeper.rb