mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-07-26 00:29:40 +02:00
Add option to association
This commit is contained in:
parent
71939d6fb5
commit
129daa6a11
1 changed files with 1 additions and 1 deletions
|
@ -3,7 +3,7 @@ class Account < ApplicationRecord
|
||||||
|
|
||||||
belongs_to :family
|
belongs_to :family
|
||||||
|
|
||||||
delegated_type :accountable, types: %w[ Credit Depository Investment Loan OtherAsset OtherLiability Property Vehicle]
|
delegated_type :accountable, types: %w[ Credit Depository Investment Loan OtherAsset OtherLiability Property Vehicle], dependant: :destroy
|
||||||
|
|
||||||
scope :depository, -> { where(type: "Depository") }
|
scope :depository, -> { where(type: "Depository") }
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue