Skip to content

Commit

Permalink
fix: gde bugs (#346)
Browse files Browse the repository at this point in the history
* chore: Set local gde state to empty on sucsessfull add row.

* chore: Add equinor code to gde table.
  • Loading branch information
mheggelund authored Oct 17, 2024
1 parent 05089e8 commit cc3058a
Showing 1 changed file with 18 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,10 @@ export const GrossDepositionEnviromentGroup = ({
id: id,
requestBody: postRequestBody,
});
if (rowUpload.success) handleGdeDialog();
if (rowUpload.success) {
setGdeObject(defaultGdeData);
handleGdeDialog();
}
}
};

Expand Down Expand Up @@ -149,14 +152,24 @@ export const GrossDepositionEnviromentGroup = ({
/>
</Button>
</Table.Cell>
<Table.Cell>{row.grossDepEnv.identifier}</Table.Cell>
<Table.Cell>{row.depEnv.identifier}</Table.Cell>
<Table.Cell>{row.subenv.identifier}</Table.Cell>
<Table.Cell>
{row.grossDepEnv.equinorCode +
' ' +
row.grossDepEnv.identifier}
</Table.Cell>
<Table.Cell>
{row.grossDepEnv.equinorCode + ' ' + row.depEnv.identifier}
</Table.Cell>
<Table.Cell>
{row.grossDepEnv.equinorCode + ' ' + row.subenv.identifier}
</Table.Cell>
<Table.Cell>
{row.architecturalElements.length > 0 && (
<ul>
{row.architecturalElements.map((a) => (
<li key={a.geologicalStandardId}>{a.identifier}</li>
<li key={a.geologicalStandardId}>
{a.equinorCode + ' ' + a.identifier}
</li>
))}
</ul>
)}
Expand Down

0 comments on commit cc3058a

Please sign in to comment.