Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1755 - added ssp boolean to stt model #2211

Closed
wants to merge 27 commits into from
Closed

Conversation

n0remac
Copy link

@n0remac n0remac commented Oct 26, 2022

Summary of Changes

Provide a brief summary of changes
Pull request closes #1755

I have included code to allow the SSP to be modified in the DAC for ease of access in testing.

Demo on Raft:

dev_ssp_file_type_1.mov
dev_ssp_file_type_2.mov

Older local demo:

Added SSP radio buttons to frontend when SSP is added for STT. Passes value to backend through DRF on submit.

Screen.Recording.2022-10-28.at.3.32.50.PM.mov

How to Test

As a Non OFA Admin belonging to an STT with SSP set to yes go to the datafiles page and the File Type section will be visible.

As an OFA Admin the File Type section will become visible when an STT with SSP set to yes is selected.

Deliverables

More details on how deliverables herein are assessed included here.

Deliverable 1: Accepted Features

Checklist of ACs:

  • STT Data Analyst can select the type of data report being uploaded
  • Radio button section not visible to users of STTs without SSP indicator
  • Radio select defaults to TANF
  • Heading 1 is modified to read "Data Files" instead of "TANF Data Files"
  • Heading 2 prints radio selection between [STT Name] and [Fiscal Year]
  • Testing Checklist has been run and all tests pass
  • README is updated, if necessary

Deliverable 2: Tested Code

  • Are all areas of code introduced in this PR meaningfully tested?
    • If this PR introduces backend code changes, are they meaningfully tested?
    • If this PR introduces frontend code changes, are they meaningfully tested?
  • Are code coverage minimums met?
    • Frontend coverage: 94.46% (see CodeCov Report comment in PR)
    • Backend coverage: 93.49% (see CodeCov Report comment in PR)

Deliverable 3: Properly Styled Code

  • Are backend code style checks passing on CircleCI?
  • Are frontend code style checks passing on CircleCI?
  • Are code maintainability principles being followed?

Deliverable 4: Accessible

  • Does this PR complete the epic?
  • Are links included to any other gov-approved PRs associated with epic?
  • Does PR include documentation for Raft's a11y review?
  • Did automated and manual testing with iamjolly and ttran-hub using Accessibility Insights reveal any errors introduced in this PR?

Deliverable 5: Deployed

  • Was the code successfully deployed via automated CircleCI process to development on Cloud.gov?

Deliverable 6: Documented

  • Does this PR provide background for why coding decisions were made?
  • If this PR introduces backend code, is that code easy to understand and sufficiently documented, both inline and overall?
  • If this PR introduces frontend code, is that code easy to understand and sufficiently documented, both inline and overall?
  • If this PR introduces dependencies, are their licenses documented?
  • Can reviewer explain and take ownership of these elements presented in this code review?

Deliverable 7: Secure

  • Does the OWASP Scan pass on CircleCI?
  • Do manual code review and manual testing detect any new security issues?
  • If new issues detected, is investigation and/or remediation plan documented?

Deliverable 8: User Research

Research product(s) clearly articulate(s):

  • the purpose of the research
  • methods used to conduct the research
  • who participated in the research
  • what was tested and how
  • impact of research on TDP
  • (if applicable) final design mockups produced for TDP development

@n0remac n0remac self-assigned this Oct 26, 2022
@andrew-jameson andrew-jameson changed the title added ssp boolean to stt model 1755 - added ssp boolean to stt model Oct 28, 2022
@codecov
Copy link

codecov bot commented Oct 28, 2022

Codecov Report

Merging #2211 (cd2ecce) into develop (53253fb) will decrease coverage by 0.06%.
The diff coverage is 80.00%.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##           develop    #2211      +/-   ##
===========================================
- Coverage    93.86%   93.80%   -0.07%     
===========================================
  Files           88       88              
  Lines         2396     2405       +9     
  Branches       318      320       +2     
===========================================
+ Hits          2249     2256       +7     
- Misses         110      112       +2     
  Partials        37       37              
Flag Coverage Δ
dev-backend 93.93% <100.00%> (+0.01%) ⬆️
dev-frontend 93.49% <50.00%> (-0.25%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
tdrs-backend/tdpservice/data_files/views.py 97.22% <ø> (ø)
tdrs-frontend/src/actions/reports.js 100.00% <ø> (ø)
tdrs-frontend/src/components/Routes/Routes.js 100.00% <ø> (ø)
...ntend/src/components/UploadReport/UploadReport.jsx 82.14% <ø> (ø)
tdrs-frontend/src/components/Reports/Reports.jsx 85.33% <50.00%> (-2.00%) ⬇️
tdrs-backend/tdpservice/data_files/serializers.py 100.00% <100.00%> (ø)
tdrs-backend/tdpservice/stts/models.py 100.00% <100.00%> (ø)
tdrs-backend/tdpservice/stts/serializers.py 92.30% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 53253fb...cd2ecce. Read the comment docs.

@n0remac n0remac added the Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI label Oct 28, 2022
@n0remac
Copy link
Author

n0remac commented Oct 28, 2022

@reitermb For A11y I am interested to know if anything needs to happen when an OFA Admin selects and STT with SSP access.

@n0remac n0remac added Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI and removed Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI labels Oct 31, 2022
@reitermb reitermb added the Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI label Nov 1, 2022
@n0remac n0remac added Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI and removed Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI labels Nov 1, 2022
@reitermb reitermb added Deploy with CircleCI-a11y Deploy to https://tdp-frontend-a11y.app.cloud.gov through CircleCI and removed Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI labels Nov 2, 2022
Copy link

@reitermb reitermb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good from an a11y standpoint. Radio buttons behave as radio buttons should, i.e:

  • Label is read for the group
  • Navigation/selection within the group happens via arrow keys rather than tabbing

No curveballs here so it should be good to go based on conversation with @ttran-hub yesterday.

Video showing behavior:
https://user-images.githubusercontent.com/28515874/199581520-a2f2349e-19a9-4e27-bc7e-28c5530a503c.mp4

Just one question re: ticket scope, I noticed that we're not changing the heading2 ( search
result) heading based off the TANF / SSP selection. Was there a decision to make that follow-on work? (This is AC #5 in the ticket)

cc @ADPennington

@ADPennington
Copy link
Collaborator

Looks good from an a11y standpoint. Radio buttons behave as radio buttons should, i.e:

  • Label is read for the group
  • Navigation/selection within the group happens via arrow keys rather than tabbing

No curveballs here so it should be good to go based on conversation with @ttran-hub yesterday.

Video showing behavior: https://user-images.githubusercontent.com/28515874/199581520-a2f2349e-19a9-4e27-bc7e-28c5530a503c.mp4

Just one question re: ticket scope, I noticed that we're not changing the heading2 ( search result) heading based off the TANF / SSP selection. Was there a decision to make that follow-on work? (This is AC #5 in the ticket)

cc @ADPennington

@n0remac Miles is referring to this AC: Heading 2 prints radio selection between [STT Name] and [Fiscal Year] . It would look like the below screenshot. Pending implementation, we will not need another a11y review because @reitermb @ttran-hub confirm that it should get read-out as part of the heading.
1755p1

@n0remac n0remac added Deploy with CircleCI-sandbox and removed Deploy with CircleCI-a11y Deploy to https://tdp-frontend-a11y.app.cloud.gov through CircleCI labels Nov 3, 2022
@ADPennington ADPennington added Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI Deploy with CircleCI-sandbox and removed Deploy with CircleCI-sandbox Deploy with CircleCI-raft Deploy to https://tdp-frontend-raft.app.cloud.gov through CircleCI labels Nov 3, 2022
Copy link

@jtimpe jtimpe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks really good. Migrations works locally, the TANF vs SSP-MOE radio button works great for submitting files. Just a couple notes.

  1. There's an IntegrityError thrown inside the sftp_task because the data_file.filename() currently returns null for SSP submissions. However, I think this will be fixed by As a user, I need the filename for SSP section to be correctly assigned after uploading the file #2154.

image

  1. The radio button works great for uploading data files, but I'm not sure it's used to GET the search results again. I don't know if it qualifies as scope creep on the ticket, but I'm not sure the search functionality is consistent anymore. @ADPennington @andrew-jameson

image

  1. Lastly, Fix/992 notify data file search selection changes #2209 changes how the frontend form works and I think it'd be useful to either update the implementation of the radio button when it merges or create a follow-on ticket to do so.

@andrew-jameson
Copy link
Collaborator

andrew-jameson commented Nov 4, 2022

Please see #2236 for latest

@n0remac n0remac deleted the feat/1755-ssp-data-types branch November 14, 2022 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

As an STT data analyst, I need to tell TDP which data report I am uploading
6 participants