Tapes are now Clips, also they have categories
This commit is contained in:
parent
86c489be72
commit
c8732b6332
41 changed files with 347 additions and 148 deletions
3
app/models/category.rb
Normal file
3
app/models/category.rb
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
class Category < ApplicationRecord
|
||||
has_many :clips
|
||||
end
|
||||
|
|
@ -1,4 +1,5 @@
|
|||
class Tape < ApplicationRecord
|
||||
class Clip < ApplicationRecord
|
||||
has_one_attached :video
|
||||
belongs_to :category
|
||||
validates :title, presence: true
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue