Show parent response rate

This commit is contained in:
Nelson Jovel 2024-10-31 20:05:26 -07:00
parent fcf8f011c2
commit 8984023aa4
12 changed files with 98 additions and 48 deletions

View file

@ -0,0 +1,10 @@
class CreateParents < ActiveRecord::Migration[7.1]
def change
create_table :parents do |t|
t.string :response_id
t.integer :number_of_children
t.timestamps
end
end
end

View file

@ -0,0 +1,5 @@
class AddParentToSurveyItemResponse < ActiveRecord::Migration[7.1]
def change
add_reference :survey_item_responses, :parent, foreign_key: true
end
end