Browse Source

fix config naming and update bike db fields

vagrant
loos 11 years ago
parent
commit
d77bf467eb
  1. 6
      config/database.yml
  2. 13
      db/migrate/20140312232550_add_fields_to_bike.rb
  3. 130
      db/schema.rb

6
config/database.yml

@ -1,6 +1,6 @@
development: development:
adapter: postgresql adapter: postgresql
database: db/rally_development database: db/bikedb_development
pool: 5 pool: 5
timeout: 5000 timeout: 5000
username: username:
@ -8,7 +8,7 @@ development:
test: test:
adapter: postgresql adapter: postgresql
database: db/rally_test database: db/bikedb_test
pool: 5 pool: 5
timeout: 5000 timeout: 5000
username: username:
@ -16,7 +16,7 @@ test:
production: production:
adapter: postgresql adapter: postgresql
database: db/rally_production database: db/bikedb_production
pool: 5 pool: 5
timeout: 5000 timeout: 5000
username: username:

13
db/migrate/20140312232550_add_fields_to_bike.rb

@ -0,0 +1,13 @@
class AddFieldsToBike < ActiveRecord::Migration
def change
add_column :bikes, :seat_tube_size, :float
add_column :bikes, :top_tube_size, :float
add_column :bikes, :log_number, :int
add_column :bikes, :purpose, :text
add_column :bikes, :mechanic, :text
remove_column :bikes, :repaired_by
remove_column :bikes, :sale
remove_column :bikes, :freecyclery
end
end

130
db/schema.rb

@ -11,36 +11,11 @@
# #
# It's strongly recommended that you check this file into your version control system. # It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 20140225171552) do ActiveRecord::Schema.define(version: 20140312232550) do
# These are extensions that must be enabled in order to support this database # These are extensions that must be enabled in order to support this database
enable_extension "plpgsql" enable_extension "plpgsql"
create_table "assignments", force: true do |t|
t.integer "attendee_id"
t.integer "task_id"
t.datetime "created_at"
t.datetime "updated_at"
end
add_index "assignments", ["attendee_id", "task_id"], name: "index_assignments_on_attendee_id_and_task_id", unique: true, using: :btree
add_index "assignments", ["attendee_id"], name: "index_assignments_on_attendee_id", using: :btree
add_index "assignments", ["task_id"], name: "index_assignments_on_task_id", using: :btree
create_table "attendees", force: true do |t|
t.string "email"
t.integer "movement_id"
t.datetime "created_at"
t.datetime "updated_at"
t.integer "event_id"
t.string "name"
t.text "notes"
t.boolean "point_person"
t.text "phone_number"
end
add_index "attendees", ["event_id"], name: "index_attendees_on_event_id", using: :btree
create_table "bikes", force: true do |t| create_table "bikes", force: true do |t|
t.string "entry_date" t.string "entry_date"
t.string "brand" t.string "brand"
@ -48,111 +23,18 @@ ActiveRecord::Schema.define(version: 20140225171552) do
t.string "bike_type" t.string "bike_type"
t.string "color" t.string "color"
t.string "frame_size" t.string "frame_size"
t.boolean "freecyclery"
t.boolean "sale"
t.string "serial_number" t.string "serial_number"
t.text "notes" t.text "notes"
t.text "tag_info" t.text "tag_info"
t.string "repaired_by"
t.string "completion_date" t.string "completion_date"
t.string "price" t.string "price"
t.datetime "created_at" t.datetime "created_at"
t.datetime "updated_at" t.datetime "updated_at"
end t.float "seat_tube_size"
t.float "top_tube_size"
create_table "event_types", force: true do |t| t.integer "log_number"
t.string "name" t.text "purpose"
end t.text "mechanic"
create_table "events", force: true do |t|
t.string "name"
t.text "notes"
t.string "address"
t.string "city"
t.string "zip"
t.datetime "created_at"
t.datetime "updated_at"
t.integer "movement_id"
t.float "latitude"
t.float "longitude"
t.string "date"
t.string "time"
t.string "location_details"
t.boolean "approved"
t.integer "host_id"
t.integer "event_type_id"
end
add_index "events", ["host_id"], name: "index_events_on_host_id", using: :btree
add_index "events", ["movement_id"], name: "index_events_on_movement_id", using: :btree
create_table "movements", force: true do |t|
t.string "name"
t.text "tagline"
t.datetime "created_at"
t.datetime "updated_at"
t.string "image_file_name"
t.string "image_content_type"
t.integer "image_file_size"
t.datetime "image_updated_at"
t.string "video"
t.integer "user_id"
t.text "call_to_action"
t.text "extended_description"
t.boolean "published", default: false
end
add_index "movements", ["user_id"], name: "index_movements_on_user_id", using: :btree
create_table "tasks", force: true do |t|
t.string "description"
t.datetime "created_at"
t.datetime "updated_at"
t.integer "event_id"
end
add_index "tasks", ["event_id"], name: "index_tasks_on_event_id", using: :btree
create_table "users", force: true do |t|
t.string "email", default: "", null: false
t.string "encrypted_password", default: ""
t.string "reset_password_token"
t.datetime "reset_password_sent_at"
t.datetime "remember_created_at"
t.integer "sign_in_count", default: 0, null: false
t.datetime "current_sign_in_at"
t.datetime "last_sign_in_at"
t.string "current_sign_in_ip"
t.string "last_sign_in_ip"
t.datetime "created_at"
t.datetime "updated_at"
t.string "provider"
t.string "uid"
t.string "name"
t.string "oauth_token"
t.datetime "oauth_expires_at"
t.string "invitation_token"
t.datetime "invitation_created_at"
t.datetime "invitation_sent_at"
t.datetime "invitation_accepted_at"
t.integer "invitation_limit"
t.integer "invited_by_id"
t.string "invited_by_type"
t.integer "movement_id"
end
add_index "users", ["email"], name: "index_users_on_email", unique: true, using: :btree
add_index "users", ["invitation_token"], name: "index_users_on_invitation_token", unique: true, using: :btree
add_index "users", ["invited_by_id"], name: "index_users_on_invited_by_id", using: :btree
add_index "users", ["reset_password_token"], name: "index_users_on_reset_password_token", unique: true, using: :btree
create_table "zipcodes", force: true do |t|
t.string "zip"
t.string "city"
t.string "state"
t.string "state_abbreviation"
t.float "latitude"
t.float "longitude"
end end
end end

Loading…
Cancel
Save