app/models/item.rb in enju_biblio-0.1.0.pre58 vs app/models/item.rb in enju_biblio-0.1.0.pre59
- old
+ new
@@ -9,12 +9,12 @@
attr_accessible :call_number, :item_identifier, :circulation_status_id,
:checkout_type_id, :shelf_id, :include_supplements, :note, :url, :price,
:acquired_at, :bookstore_id, :missing_since, :budget_type_id, :lock_version,
:manifestation_id, :library_id, :required_role_id,
:binding_item_identifier, :binding_call_number, :binded_at
- scope :on_shelf, where('shelf_id != 1')
- scope :on_web, where(:shelf_id => 1)
- delegate :display_name, :to => :shelf, :prefix => true
+ scope :on_shelf, -> { where('shelf_id != 1') }
+ scope :on_web, -> { where(:shelf_id => 1) }
+ delegate :display_name, :to => :shelf, prefix: true
has_many :owns
has_many :agents, through: :owns
has_many :donates
has_many :donors, through: :donates, source: :agent
has_one :resource_import_result