app/models/item.rb in enju_biblio-0.1.0.pre6 vs app/models/item.rb in enju_biblio-0.1.0.pre7
- old
+ new
@@ -1,10 +1,10 @@
# -*- encoding: utf-8 -*-
class Item < ActiveRecord::Base
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,
- :manifestation_id #,:exemplify_attributes
+ :manifestation_id, :library_id, :required_role_id #,:exemplify_attributes
scope :on_shelf, where('shelf_id != 1')
scope :on_web, where(:shelf_id => 1)
scope :accepted_between, lambda{|from, to| includes(:accept).where('items.created_at BETWEEN ? AND ?', Time.zone.parse(from).beginning_of_day, Time.zone.parse(to).end_of_day)}
has_one :exemplify, :dependent => :destroy
has_one :manifestation, :through => :exemplify