Commit 5a99609
committed
fix(admin): return day column as text in getCampaignProgression
`postgres.js` returns PG `date` as a string, not a `Date`, which broke
the tRPC serializer (`value.toISOString is not a function`). Use
`to_char(submitted_at, 'YYYY-MM-DD')` to force a text column and drop the
now-unused `toIsoDay` helper.1 parent c6cda4f commit 5a99609
2 files changed
Lines changed: 13 additions & 18 deletions
Lines changed: 7 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
20 | 22 | | |
21 | 23 | | |
22 | 24 | | |
| |||
74 | 76 | | |
75 | 77 | | |
76 | 78 | | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
81 | 83 | | |
82 | 84 | | |
83 | 85 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
| 21 | + | |
32 | 22 | | |
33 | 23 | | |
34 | 24 | | |
| |||
44 | 34 | | |
45 | 35 | | |
46 | 36 | | |
47 | | - | |
| 37 | + | |
48 | 38 | | |
49 | 39 | | |
50 | 40 | | |
| |||
84 | 74 | | |
85 | 75 | | |
86 | 76 | | |
87 | | - | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
88 | 81 | | |
89 | 82 | | |
90 | 83 | | |
| |||
0 commit comments