projects
/
cs356-p2-videostore.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
2905aed02fef93651d59c488b35c36bdb177bef1
[cs356-p2-videostore.git]
/
rentable.rb
1
class Rentable < ActiveRecord::Base
2
has_many :coitems
3
has_many :rentable_purchases
4
has_many :bonus_purchases
5
6
validates_presence_of :title
7
# don't validate newrelease, false is ok
8
9
def checkedout?
10
return Coitem.find_by_rentable_id(self.id) ? true : false
11
end
12
end