Remove not null constraint from project_id in Activity table

This commit is contained in:
Urban Rotnik 2019-02-28 10:44:37 +01:00
parent 9ed3313f0f
commit ad8e5973fa
2 changed files with 9 additions and 2 deletions

View file

@ -0,0 +1,7 @@
# frozen_string_literal: true
class RemoveNullConstraintFromProjectInActivities < ActiveRecord::Migration[5.1]
def change
change_column_null :activities, :project_id, :integer, true
end
end

View file

@ -11,7 +11,7 @@
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 20190213064847) do
ActiveRecord::Schema.define(version: 20190227110801) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"
@ -25,7 +25,7 @@ ActiveRecord::Schema.define(version: 20190213064847) do
t.string "message"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.bigint "project_id", null: false
t.bigint "project_id"
t.bigint "experiment_id"
t.string "subject_type"
t.bigint "subject_id"