mirror of
https://github.com/projekteuler/projekteuler.git
synced 2026-01-26 18:18:51 +01:00
Prefill original title and content from projecteuler.net
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
class AddOriginalDataToProblems < ActiveRecord::Migration[6.0]
|
||||
def change
|
||||
add_column :problems, :pulled_at, :datetime
|
||||
add_column :problems, :original_title, :string
|
||||
add_column :problems, :original_content, :text
|
||||
end
|
||||
end
|
||||
15
db/schema.rb
15
db/schema.rb
@@ -2,20 +2,23 @@
|
||||
# of editing this file, please use the migrations feature of Active Record to
|
||||
# incrementally modify your database, and then regenerate this schema definition.
|
||||
#
|
||||
# Note that this schema.rb definition is the authoritative source for your
|
||||
# database schema. If you need to create the application database on another
|
||||
# system, you should be using db:schema:load, not running all the migrations
|
||||
# from scratch. The latter is a flawed and unsustainable approach (the more migrations
|
||||
# you'll amass, the slower it'll run and the greater likelihood for issues).
|
||||
# This file is the source Rails uses to define your schema when running `rails
|
||||
# db:schema:load`. When creating a new database, `rails db:schema:load` tends to
|
||||
# be faster and is potentially less error prone than running all of your
|
||||
# migrations from scratch. Old migrations may fail to apply correctly if those
|
||||
# migrations use external dependencies or application code.
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(version: 2019_08_28_084343) do
|
||||
ActiveRecord::Schema.define(version: 2020_05_01_095104) do
|
||||
|
||||
create_table "problems", force: :cascade do |t|
|
||||
t.datetime "created_at"
|
||||
t.datetime "updated_at"
|
||||
t.integer "translation_id"
|
||||
t.datetime "pulled_at"
|
||||
t.string "original_title"
|
||||
t.text "original_content"
|
||||
t.index ["translation_id"], name: "index_problems_on_translation_id"
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user