mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-07-19 05:09:38 +02:00
Remove account type column
This commit is contained in:
parent
ecb3f2726f
commit
e7d7c70b2f
3 changed files with 8 additions and 7 deletions
5
db/migrate/20240203030754_remove_type_from_accounts.rb
Normal file
5
db/migrate/20240203030754_remove_type_from_accounts.rb
Normal file
|
@ -0,0 +1,5 @@
|
|||
class RemoveTypeFromAccounts < ActiveRecord::Migration[7.2]
|
||||
def change
|
||||
remove_column :accounts, :type
|
||||
end
|
||||
end
|
4
db/schema.rb
generated
4
db/schema.rb
generated
|
@ -10,7 +10,7 @@
|
|||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema[7.2].define(version: 2024_02_02_230325) do
|
||||
ActiveRecord::Schema[7.2].define(version: 2024_02_03_030754) do
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "pgcrypto"
|
||||
enable_extension "plpgsql"
|
||||
|
@ -56,7 +56,6 @@ ActiveRecord::Schema[7.2].define(version: 2024_02_02_230325) do
|
|||
end
|
||||
|
||||
create_table "accounts", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
|
||||
t.string "type"
|
||||
t.string "subtype"
|
||||
t.uuid "family_id", null: false
|
||||
t.string "name"
|
||||
|
@ -68,7 +67,6 @@ ActiveRecord::Schema[7.2].define(version: 2024_02_02_230325) do
|
|||
t.uuid "accountable_id"
|
||||
t.index ["accountable_type"], name: "index_accounts_on_accountable_type"
|
||||
t.index ["family_id"], name: "index_accounts_on_family_id"
|
||||
t.index ["type"], name: "index_accounts_on_type"
|
||||
end
|
||||
|
||||
create_table "families", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
|
||||
|
|
6
test/fixtures/accounts.yml
vendored
6
test/fixtures/accounts.yml
vendored
|
@ -1,13 +1,11 @@
|
|||
# Read about fixtures at https://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html
|
||||
|
||||
one:
|
||||
type:
|
||||
family: one
|
||||
name: MyString
|
||||
balance:
|
||||
balance:
|
||||
|
||||
two:
|
||||
type:
|
||||
family: two
|
||||
name: MyString
|
||||
balance:
|
||||
balance:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue