Merge remote-tracking branch 'origin/master' into error-info
# Conflicts: # app/controllers/concerns/submission_scoring.rb # app/views/application/_navigation.html.slim # config/locales/de.yml # config/locales/en.yml # db/schema.rb
This commit is contained in:
18
db/migrate/20170830083601_add_cause_to_testruns.rb
Normal file
18
db/migrate/20170830083601_add_cause_to_testruns.rb
Normal file
@ -0,0 +1,18 @@
|
||||
class AddCauseToTestruns < ActiveRecord::Migration
|
||||
def up
|
||||
add_column :testruns, :cause, :string
|
||||
Testrun.reset_column_information
|
||||
Testrun.all.each{ |testrun|
|
||||
if(testrun.submission.nil?)
|
||||
say_with_time "#{testrun.id} has no submission" do end
|
||||
else
|
||||
testrun.cause = testrun.submission.cause
|
||||
testrun.save
|
||||
end
|
||||
}
|
||||
end
|
||||
|
||||
def down
|
||||
remove_column :testruns, :cause
|
||||
end
|
||||
end
|
11
db/migrate/20170906124500_create_subscriptions.rb
Normal file
11
db/migrate/20170906124500_create_subscriptions.rb
Normal file
@ -0,0 +1,11 @@
|
||||
class CreateSubscriptions < ActiveRecord::Migration
|
||||
def change
|
||||
create_table :subscriptions do |t|
|
||||
t.belongs_to :user, polymorphic: true
|
||||
t.references :request_for_comment
|
||||
t.string :type
|
||||
|
||||
t.timestamps null: false
|
||||
end
|
||||
end
|
||||
end
|
5
db/migrate/20170913054203_rename_subscription_type.rb
Normal file
5
db/migrate/20170913054203_rename_subscription_type.rb
Normal file
@ -0,0 +1,5 @@
|
||||
class RenameSubscriptionType < ActiveRecord::Migration
|
||||
def change
|
||||
rename_column :subscriptions, :type, :subscription_type
|
||||
end
|
||||
end
|
5
db/migrate/20170920145852_add_deleted_to_subscription.rb
Normal file
5
db/migrate/20170920145852_add_deleted_to_subscription.rb
Normal file
@ -0,0 +1,5 @@
|
||||
class AddDeletedToSubscription < ActiveRecord::Migration
|
||||
def change
|
||||
add_column :subscriptions, :deleted, :boolean
|
||||
end
|
||||
end
|
13
db/schema.rb
13
db/schema.rb
@ -11,7 +11,7 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(version: 20170719133351) do
|
||||
ActiveRecord::Schema.define(version: 20170920145852) do
|
||||
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "plpgsql"
|
||||
@ -321,6 +321,16 @@ ActiveRecord::Schema.define(version: 20170719133351) do
|
||||
add_index "submissions", ["exercise_id"], name: "index_submissions_on_exercise_id", using: :btree
|
||||
add_index "submissions", ["user_id"], name: "index_submissions_on_user_id", using: :btree
|
||||
|
||||
create_table "subscriptions", force: :cascade do |t|
|
||||
t.integer "user_id"
|
||||
t.string "user_type"
|
||||
t.integer "request_for_comment_id"
|
||||
t.string "subscription_type"
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
t.boolean "deleted"
|
||||
end
|
||||
|
||||
create_table "tags", force: :cascade do |t|
|
||||
t.string "name", null: false
|
||||
t.datetime "created_at"
|
||||
@ -334,6 +344,7 @@ ActiveRecord::Schema.define(version: 20170719133351) do
|
||||
t.integer "submission_id"
|
||||
t.datetime "created_at"
|
||||
t.datetime "updated_at"
|
||||
t.string "cause"
|
||||
end
|
||||
|
||||
create_table "user_exercise_feedbacks", force: :cascade do |t|
|
||||
|
Reference in New Issue
Block a user