Skip to content

Commit 6daa597

Browse files
samsharafrozenhelium
authored andcommitted
fix(dref): include num_assisted in final report export
1 parent 1e8e5e6 commit 6daa597

File tree

5 files changed

+29
-13
lines changed

5 files changed

+29
-13
lines changed

.changeset/witty-spies-play.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"go-web-app": patch
3+
---
4+
5+
Show number of people assisted in DREF Final Report export

app/src/views/DrefFinalReportExport/i18n.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
"glideNumberLabel": "Glide Number",
1818
"peopleAffectedLabel": "People Affected",
1919
"peopleTargetedLabel": "People Targeted",
20+
"peopleAssistedLabel": "People Assisted",
2021
"peopleSuffix": " people",
2122
"operationStartDateLabel": "Operation Start Date",
2223
"operationTimeframeLabel": "Total Operating Timeframe",

app/src/views/DrefFinalReportExport/index.tsx

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -321,9 +321,9 @@ export function Component() {
321321
value={drefResponse?.disaster_category_display}
322322
valueClassName={_cs(
323323
isDefined(drefResponse)
324-
&& isDefined(drefResponse.disaster_category)
325-
&& isDefined(drefResponse.disaster_category)
326-
&& colorMap[drefResponse.disaster_category],
324+
&& isDefined(drefResponse.disaster_category)
325+
&& isDefined(drefResponse.disaster_category)
326+
&& colorMap[drefResponse.disaster_category],
327327
)}
328328
strongValue
329329
/>
@@ -348,13 +348,21 @@ export function Component() {
348348
strongValue
349349
/>
350350
<TextOutput
351-
className={styles.peopleTargeted}
351+
className={styles.metaItem}
352352
label={strings.peopleTargetedLabel}
353353
value={drefResponse?.total_targeted_population}
354354
suffix={strings.peopleSuffix}
355355
valueType="number"
356356
strongValue
357357
/>
358+
<TextOutput
359+
className={styles.metaItem}
360+
label={strings.peopleAssistedLabel}
361+
value={drefResponse?.num_assisted}
362+
suffix={strings.peopleSuffix}
363+
valueType="number"
364+
strongValue
365+
/>
358366
<TextOutput
359367
className={styles.metaItem}
360368
label={strings.eventOnsetLabel}

app/src/views/DrefFinalReportExport/styles.module.css

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,6 @@
5858
}
5959
}
6060

61-
.people-targeted {
62-
display: flex;
63-
flex-direction: column;
64-
background-color: var(--pdf-element-bg);
65-
padding: var(--go-ui-spacing-sm);
66-
grid-column: span 2;
67-
break-inside: avoid;
68-
}
69-
7061
.targeted-areas {
7162
background-color: var(--pdf-element-bg);
7263
padding: var(--go-ui-spacing-sm);
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"parent": "000015-1739181128201.json",
3+
"actions": [
4+
{
5+
"action": "add",
6+
"key": "peopleAssistedLabel",
7+
"namespace": "drefFinalReportExport",
8+
"value": "People Assisted"
9+
}
10+
]
11+
}

0 commit comments

Comments
 (0)