Add app/models/work_side_pairing.rb
This commit is contained in:
parent
faa132e468
commit
ab77307d50
1 changed files with 7 additions and 0 deletions
7
app/models/work_side_pairing.rb
Normal file
7
app/models/work_side_pairing.rb
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
class WorkSidePairing < ApplicationRecord
|
||||||
|
belongs_to :work
|
||||||
|
belongs_to :relationship,
|
||||||
|
class_name: "Relationship"
|
||||||
|
validates :relationship_id,
|
||||||
|
uniqueness: { scope: :work_id }
|
||||||
|
end
|
||||||
Loading…
Reference in a new issue