diff --git a/Gemfile b/Gemfile index 199428d..e2ad97c 100644 --- a/Gemfile +++ b/Gemfile @@ -28,7 +28,6 @@ gem 'bootsnap', '>= 1.1.0', require: false # gem 'rack-cors' group :production do - # Use postgresql as the database for Active Record gem 'pg' end diff --git a/README.md b/README.md index 7db80e4..7744413 100644 --- a/README.md +++ b/README.md @@ -1,24 +1,7 @@ # README -This README would normally document whatever steps are necessary to get the -application up and running. +This is a sample React + Rails Todo list app. To run this: -Things you may want to cover: +* rails db:migrate -* Ruby version - -* System dependencies - -* Configuration - -* Database creation - -* Database initialization - -* How to run the test suite - -* Services (job queues, cache servers, search engines, etc.) - -* Deployment instructions - -* ... +* heroku local -f Procfile.dev diff --git a/db/migrate/20181009104655_create_todos.rb b/db/migrate/20181009104655_create_todos.rb index bcbc859..7a3e0d1 100644 --- a/db/migrate/20181009104655_create_todos.rb +++ b/db/migrate/20181009104655_create_todos.rb @@ -2,7 +2,7 @@ class CreateTodos < ActiveRecord::Migration[5.2] def change create_table :todos do |t| t.string :title - t.boolean :done + t.boolean :done, default: false t.timestamps end diff --git a/db/seeds.rb b/db/seeds.rb index 4517e90..4aeeae3 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -1,10 +1,3 @@ -# This file should contain all the record creation needed to seed the database with its default values. -# The data can then be loaded with the rails db:seed command (or created alongside the database with db:setup). -# -# Examples: -# -# movies = Movie.create([{ name: 'Star Wars' }, { name: 'Lord of the Rings' }]) -# Character.create(name: 'Luke', movie: movies.first) -Todo.create(title: "Buy food: milk, bread, fruits", done: false) Todo.create(title: "Reserve tickets for the Imagine Dragons convert", done: false) +Todo.create(title: "Buy food: milk, bread, fruits", done: false)