TwoWeeksReady icon indicating copy to clipboard operation
TwoWeeksReady copied to clipboard

API: Hazard Information and Hazard Hunt - Create Update and Delete Admin Role Check

Open codingbandit opened this issue 5 years ago • 3 comments

Dependent on issue #19

Serves mobile application read-only lists of hazards as well as directives on what to do in case of the hazard(ie. earthquake). Serves (tbd) admin app to allow for maintenance of hazard information (crud).

Function names, signatures, object names, and number of functions are not set in stone:

GetHazardInformationList() returns HazardInformation[] GetHazardInformation(HazardInformationId) returns HazardInformation CreateHazardInformation(Name, Description, Directive, Photo, Icon) returns HazardInformation UpdateHazardInformation(HazardInformation) returns HazardInformation DeleteHazardInformation(HazardInformationId) returns bool

Once complete, please document the final API/Classes in the Wiki

codingbandit avatar Jan 16 '21 19:01 codingbandit

These functions have been created but we need to ensure that the Create, Update, and Delete endpoints are only accessible to admin users.

dpaquette avatar Sep 02 '21 02:09 dpaquette

Create, Update, and Delete endpoints need to have the admin check - check out the BaseKitsApi as an example

codingbandit avatar Mar 06 '22 17:03 codingbandit

These endpoints do have the admin check already.

dpaquette avatar Mar 07 '22 04:03 dpaquette