diff options
author | Louise Crow <louise.crow@gmail.com> | 2013-10-24 14:35:25 +0100 |
---|---|---|
committer | Louise Crow <louise.crow@gmail.com> | 2013-12-04 09:32:42 +0000 |
commit | 9a5c01d781129aeb1ab2b18771ac131ecdfb56c1 (patch) | |
tree | 78a4c2f3d0bf2037935d6f38b4866959ef13e7ec /app/models/info_request_batch.rb | |
parent | 857128b465cf345756bbeabbccdc673921090210 (diff) |
Add InfoRequestBatch model.
Re-annotate models. Index InfoRequestBatches by user - we'll display the
batches for a user when they view their own requests.
Diffstat (limited to 'app/models/info_request_batch.rb')
-rw-r--r-- | app/models/info_request_batch.rb | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/app/models/info_request_batch.rb b/app/models/info_request_batch.rb new file mode 100644 index 000000000..af6956095 --- /dev/null +++ b/app/models/info_request_batch.rb @@ -0,0 +1,20 @@ +# == Schema Information +# Schema version: 20131024114346 +# +# Table name: info_request_batches +# +# id :integer not null, primary key +# title :text not null +# user_id :integer not null +# created_at :datetime +# updated_at :datetime +# + +class InfoRequestBatch < ActiveRecord::Base + has_many :info_requests + belongs_to :user + + validates_presence_of :user + validates_presence_of :title + +end |