Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Change facility history API endpoint switch to a flag activated via group #881

Merged
merged 7 commits into from
Oct 25, 2019

Commits on Oct 24, 2019

  1. Create can_get_facility_history flag & group

    Add a data migration to add `can_get_facility_history` flag and group.
    Kelly Innes authored and jwalgran committed Oct 24, 2019
    Configuration menu
    Copy the full SHA
    c9ecea0 View commit details
    Browse the repository at this point in the history
  2. Update facility history code to use flag

    Update facility history endpoint tests to use the
    `can_get_facility_history` feature flag.
    
    Update facility history endpoint code to replace switch with flag.
    
    Replace endpoint decorator with custom flag_is_active check to
    circumvent a quirk with using waffle & DRF documented here:
    
    jazzband/django-waffle#221
    Kelly Innes authored and jwalgran committed Oct 24, 2019
    Configuration menu
    Copy the full SHA
    b6eb8a8 View commit details
    Browse the repository at this point in the history
  3. Add tests to check facility history endpoint auth

    Add tests to check the following history endpoint auth cases:
    
    - superuser receives 200
    - not-signed-in-user receives a 401
    - not-permitted-user receives a 403
    - permitted user receives 200
    Kelly Innes authored and jwalgran committed Oct 24, 2019
    Configuration menu
    Copy the full SHA
    254e584 View commit details
    Browse the repository at this point in the history
  4. Add migration to delete facility history switch

    Kelly Innes authored and jwalgran committed Oct 24, 2019
    Configuration menu
    Copy the full SHA
    e15e63d View commit details
    Browse the repository at this point in the history
  5. Display Group objects in django-admin

    Kelly Innes authored and jwalgran committed Oct 24, 2019
    Configuration menu
    Copy the full SHA
    37fdd09 View commit details
    Browse the repository at this point in the history
  6. Update CHANGELOG

    Kelly Innes authored and jwalgran committed Oct 24, 2019
    Configuration menu
    Copy the full SHA
    3d7dc6e View commit details
    Browse the repository at this point in the history
  7. Remove facility_history waffle switch from scripts/resetdb

    This switch was replaced with a flag that is tied to a user group.
    jwalgran committed Oct 24, 2019
    Configuration menu
    Copy the full SHA
    391f3fd View commit details
    Browse the repository at this point in the history