mirror of
https://github.com/Hestia-Homes/assessment-model.git
synced 2026-07-12 13:28:55 +00:00
feat(db): add inputs column to tasks
Mirrors sub_task.inputs (JSON as text): the task's request inputs. For a modelling run (ADR-0008, feature/bulk-trigger-modelling) the task row itself carries the run's config — portfolio id, scenario ids, filters — with sub_tasks holding the per-property execution work. Column-only change so it can be applied to the database ahead of the feature merging. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
27254e7622
commit
fe521aa8d5
4 changed files with 11807 additions and 0 deletions
1
src/app/db/migrations/0262_wandering_nocturne.sql
Normal file
1
src/app/db/migrations/0262_wandering_nocturne.sql
Normal file
|
|
@ -0,0 +1 @@
|
|||
ALTER TABLE "tasks" ADD COLUMN "inputs" text;
|
||||
11794
src/app/db/migrations/meta/0262_snapshot.json
Normal file
11794
src/app/db/migrations/meta/0262_snapshot.json
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -1828,6 +1828,13 @@
|
|||
"when": 1783352788862,
|
||||
"tag": "0261_fixed_excalibur",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 262,
|
||||
"version": "7",
|
||||
"when": 1783420235209,
|
||||
"tag": "0262_wandering_nocturne",
|
||||
"breakpoints": true
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -18,6 +18,11 @@ export const tasks = pgTable("tasks", {
|
|||
|
||||
sourceId: text("source_id"), // identifier for the source (e.g., portfolio_id value)
|
||||
|
||||
// The task's request inputs, mirroring sub_task.inputs (JSON as text; could
|
||||
// later change to JSONB). For a modelling run this is the run's config —
|
||||
// portfolio id, scenario ids, filters (ADR-0008).
|
||||
inputs: text("inputs"),
|
||||
|
||||
updatedAt: timestamp("updated_at", { precision: 6, withTimezone: true })
|
||||
.defaultNow()
|
||||
.$onUpdate(() => new Date())
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue