Add exercise feedback page for pair programming study
This commit is contained in:

committed by
Sebastian Serth

parent
79422225a8
commit
4b90a2a3c5
@ -0,0 +1,19 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class AddPairProgrammingExerciseFeedbacks < ActiveRecord::Migration[7.0]
|
||||
def change
|
||||
create_table :pair_programming_exercise_feedbacks do |t|
|
||||
t.references :exercise, null: false, index: true, foreign_key: true
|
||||
t.references :submission, null: false, index: true, foreign_key: true
|
||||
t.references :user, polymorphic: true, null: false, index: true
|
||||
t.references :programming_group, null: true, index: {name: 'pp_feedback_programming_group'}, foreign_key: true
|
||||
t.references :study_group, null: false, index: true, foreign_key: true
|
||||
t.integer :difficulty
|
||||
t.integer :user_estimated_worktime
|
||||
t.integer :reason_work_alone
|
||||
t.float :normalized_score
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
end
|
||||
end
|
26
db/schema.rb
26
db/schema.rb
@ -10,7 +10,7 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema[7.0].define(version: 2023_09_04_180123) do
|
||||
ActiveRecord::Schema[7.0].define(version: 2023_09_05_190519) do
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "pg_trgm"
|
||||
enable_extension "pgcrypto"
|
||||
@ -382,6 +382,26 @@ ActiveRecord::Schema[7.0].define(version: 2023_09_04_180123) do
|
||||
t.index ["study_group_id"], name: "index_lti_parameters_on_study_group_id"
|
||||
end
|
||||
|
||||
create_table "pair_programming_exercise_feedbacks", force: :cascade do |t|
|
||||
t.bigint "exercise_id", null: false
|
||||
t.bigint "submission_id", null: false
|
||||
t.string "user_type", null: false
|
||||
t.bigint "user_id", null: false
|
||||
t.bigint "programming_group_id"
|
||||
t.bigint "study_group_id", null: false
|
||||
t.integer "difficulty"
|
||||
t.integer "user_estimated_worktime"
|
||||
t.integer "reason_work_alone"
|
||||
t.float "normalized_score"
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
t.index ["exercise_id"], name: "index_pair_programming_exercise_feedbacks_on_exercise_id"
|
||||
t.index ["programming_group_id"], name: "pp_feedback_programming_group"
|
||||
t.index ["study_group_id"], name: "index_pair_programming_exercise_feedbacks_on_study_group_id"
|
||||
t.index ["submission_id"], name: "index_pair_programming_exercise_feedbacks_on_submission_id"
|
||||
t.index ["user_type", "user_id"], name: "index_pair_programming_exercise_feedbacks_on_user"
|
||||
end
|
||||
|
||||
create_table "programming_group_memberships", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
|
||||
t.bigint "programming_group_id", null: false
|
||||
t.string "user_type", null: false
|
||||
@ -643,6 +663,10 @@ ActiveRecord::Schema[7.0].define(version: 2023_09_04_180123) do
|
||||
add_foreign_key "lti_parameters", "exercises"
|
||||
add_foreign_key "lti_parameters", "external_users"
|
||||
add_foreign_key "lti_parameters", "study_groups"
|
||||
add_foreign_key "pair_programming_exercise_feedbacks", "exercises"
|
||||
add_foreign_key "pair_programming_exercise_feedbacks", "programming_groups"
|
||||
add_foreign_key "pair_programming_exercise_feedbacks", "study_groups"
|
||||
add_foreign_key "pair_programming_exercise_feedbacks", "submissions"
|
||||
add_foreign_key "programming_group_memberships", "programming_groups"
|
||||
add_foreign_key "programming_groups", "exercises"
|
||||
add_foreign_key "remote_evaluation_mappings", "study_groups"
|
||||
|
Reference in New Issue
Block a user