dev_ec^2
parent
89782ffabd
commit
f35bc5f18d
@ -0,0 +1,3 @@
|
||||
class CompetitionModeSetting < ApplicationRecord
|
||||
belongs_to :course
|
||||
end
|
@ -0,0 +1,6 @@
|
||||
class AddNewColumnToCompetitions < ActiveRecord::Migration[5.2]
|
||||
def change
|
||||
add_column :competitions, :bonus, :integer, default: 0
|
||||
add_column :competitions, :mode, :integer, default: 0
|
||||
end
|
||||
end
|
@ -0,0 +1,11 @@
|
||||
class CreateCompetitionModeSettings < ActiveRecord::Migration[5.2]
|
||||
def change
|
||||
create_table :competition_mode_settings do |t|
|
||||
t.references :course
|
||||
t.datetime :start_time
|
||||
t.datetime :end_time
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
end
|
||||
end
|
@ -0,0 +1,5 @@
|
||||
require 'rails_helper'
|
||||
|
||||
RSpec.describe CompetitionModeSetting, type: :model do
|
||||
pending "add some examples to (or delete) #{__FILE__}"
|
||||
end
|
Loading…
Reference in new issue