# This file is autogenerated. Instead of editing this file, please use the # migrations feature of ActiveRecord to incrementally modify your database, and # then regenerate this schema definition. ActiveRecord::Schema.define(:version => 4) do create_table "accounts", :force => true do |t| t.column "forenames", :string t.column "surname", :string t.column "email", :string t.column "username", :string t.column "encrypted_password", :string t.column "salt", :string t.column "login_key", :string t.column "login_key_expires_at", :datetime t.column "activated", :boolean, :default => false t.column "admin", :boolean, :default => false t.column "currency_id", :integer, :default => 8 t.column "created_on", :datetime t.column "disabled", :boolean, :default => false t.column "updated_at", :datetime end add_index "accounts", ["username", "email", "login_key", "activated", "currency_id"], :name => "accounts_index", :unique => true create_table "assets", :force => true do |t| t.column "account_id", :integer t.column "name", :string t.column "base_starting_balance", :integer t.column "feed_url", :string end add_index "assets", ["account_id", "name", "feed_url"], :name => "assets_index", :unique => true create_table "balances", :force => true do |t| t.column "asset_id", :integer t.column "incoming_id", :integer t.column "outgoing_id", :integer t.column "transaction_date", :date t.column "base_amount", :integer end add_index "balances", ["asset_id", "incoming_id", "outgoing_id", "transaction_date"], :name => "balances_index" create_table "categories", :force => true do |t| t.column "account_id", :integer t.column "flow_id", :integer t.column "name", :string end add_index "categories", ["account_id", "flow_id"], :name => "categories_index" create_table "currencies", :force => true do |t| t.column "name", :string t.column "symbol", :string end create_table "flows", :force => true do |t| t.column "name", :string end add_index "flows", ["name"], :name => "flows_index", :unique => true create_table "incomings", :force => true do |t| t.column "asset_id", :integer t.column "category_id", :integer t.column "transaction_date", :date t.column "created_on", :datetime t.column "base_amount", :integer end add_index "incomings", ["asset_id", "category_id", "transaction_date", "created_on"], :name => "incomings_index" create_table "outgoings", :force => true do |t| t.column "asset_id", :integer t.column "category_id", :integer t.column "transaction_date", :date t.column "created_on", :datetime t.column "base_amount", :integer end add_index "outgoings", ["asset_id", "category_id", "transaction_date", "created_on"], :name => "outgoings_index" create_table "sessions", :force => true do |t| t.column "session_id", :string t.column "data", :text t.column "updated_at", :datetime end add_index "sessions", ["session_id"], :name => "index_sessions_on_session_id" add_index "sessions", ["updated_at"], :name => "index_sessions_on_updated_at" end