Skip to content

[FEAT-API]: Create structure / endpoint to connect reaches to savepoints #558

@martyheynbah

Description

@martyheynbah

In the Savepoint step of the Storm Selection Tab (In the Data Ingest component), the user will be selecting a savepoint for each reach. Initially this will be done on the frontend in the client store, but once they have matched a savepoint with each reach and they move onto the Hazard Data step, and the savepoint - reach connection will need to be saved to the DB.

To do this we need to create an endpoint for this action. Doing this will include:

  • altering the savepoint and reach table to add a relationship / key to link the tables together
    • this will be a 1-1 relationship that is null initially when the reach is created
  • add a query to link reaches to savepoints by project.
    • Should take in multiple reaches and savepoints in whatever format you decide is best and link them to each other. Or do a single reach to savepoint and loop over a list of reach/savepoint connections on the frontend making the single call each time. See which is more efficient / easiest lift
  • create handler / endpoint to test this. Create payload as well. Will need to think about how to format data being passed to it

Metadata

Metadata

Assignees

Labels

3SPEffort Estimation: 1-2 Days

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions