1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-08-04 21:15:19 +02:00

Domain model sketch

This commit is contained in:
Zach Gollwitzer 2025-02-25 09:27:59 -05:00
parent 02bfa9f251
commit b2d8da8857
2 changed files with 53 additions and 0 deletions

View file

@ -0,0 +1,25 @@
class AddRules < ActiveRecord::Migration[7.2]
def change
create_table :rules, id: :uuid do |t|
t.references :family, null: false, foreign_key: true, type: :uuid
t.date :effective_date, null: false
t.boolean :active, null: false, default: true
t.timestamps
end
create_table :rule_triggers do |t|
t.references :rule, null: false, foreign_key: true, type: :uuid
t.string :trigger_type, null: false
t.timestamps
end
create_table :rule_actions do |t|
t.references :rule, null: false, foreign_key: true, type: :uuid
t.string :action_type, null: false
t.timestamps
end
end
end