Police-Data-Accessibility-Project / data-sources-app

An API and UI for using and maintaining the Data Sources database
MIT License
2 stars 5 forks source link

Create CRUD endpoints for `agencies` #417

Open maxachis opened 3 weeks ago

maxachis commented 3 weeks ago

Context

Requirements

Tests

Docs

Open questions

maxachis commented 3 weeks ago

@josh-chamberlain Here is the (as yet empty) table of permissions for agencies. Let me know what the permissions should look like, as well as whether any columns should be added or deleted.

column_name ADMIN STANDARD note
name READ READ concatenates submitted_name with - state_iso where state is present, purely to help select agencies on airtable submit data source form
submitted_name WRITE READ later will be the new name
homepage_url WRITE READ
jurisdiction_type WRITE READ
state_iso WRITE READ
municipality WRITE READ
county_fips WRITE READ
county_name READ READ inferred from FIPS
lat WRITE READ
lng WRITE READ
defunct_year WRITE READ
airtable_uid READ READ deprecated when we #32
count_data_sources READ READ generated by Airtable
agency_type WRITE READ
multi_agency WRITE READ
zip_code WRITE READ
data_sources READ READ generated by Airtable
no_web_presence WRITE READ
airtable_agency_last_modified READ READ generated by Airtable
data_sources_last_updated READ READ generated by Airtable
approved WRITE READ
rejection_reason WRITE READ
last_approval_editor WRITE READ
submitter_contact WRITE READ
agency_created READ READ generated by Airtable
county_airtable_uid READ READ generated by Airtable
id* READ READ needs to be added
josh-chamberlain commented 3 weeks ago

ok, updated @maxachis ! Love a blank form to fill in. To be clear, many of these can still be theoretically created by the submitter of a form for new agencies.

maxachis commented 3 weeks ago

ok, updated @maxachis ! Love a blank form to fill in. To be clear, many of these can still be theoretically created by the submitter of a form for new agencies.

From a design standpoint, we'd just need to connect the form submission process to the web app client with the requisite permissions to write to the table! So that should be quite doable.