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

Survey Progress Field #1238

Merged
merged 31 commits into from
Mar 13, 2024
Merged

Survey Progress Field #1238

merged 31 commits into from
Mar 13, 2024

Conversation

mauberti-bc
Copy link
Collaborator

@mauberti-bc mauberti-bc commented Mar 11, 2024

Links to Jira Tickets

  • N/A. The intention is for users to be able to track the progress (ie. status) of their survey from planning -> in progress -> complete. This is independent of the publish workflow and indicates whether additional data is expected to be added to the Survey. The field is called "Progress" to keep it distinct from the Survey's publish status.

Description of Changes

  • Added a new field, "progress_id", to the Survey table and updated service/repo accordingly
  • Added "Progress" select component to the Survey form
  • Added the Survey progress label to the Survey lists table and the Survey page

Testing Notes

  • Should be able to add a Progress when creating/editing Surveys
  • Should see the Progress chip in the Survey page header
  • Should see the Progress chip in the Surveys list table

@mauberti-bc mauberti-bc added the Early Feedback Welcome PR is not finished, but early review feedback is welcomed label Mar 11, 2024
@codecov-commenter
Copy link

codecov-commenter commented Mar 11, 2024

Codecov Report

Attention: Patch coverage is 87.17949% with 5 lines in your changes are missing coverage. Please review.

Project coverage is 54.54%. Comparing base (ce20bbb) to head (fa8a260).

Files Patch % Lines
api/src/repositories/survey-repository.ts 25.00% 3 Missing ⚠️
app/src/features/surveys/edit/EditSurveyForm.tsx 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev    #1238      +/-   ##
==========================================
+ Coverage   54.51%   54.54%   +0.03%     
==========================================
  Files         598      599       +1     
  Lines       18356    18376      +20     
  Branches     2833     2837       +4     
==========================================
+ Hits        10007    10024      +17     
- Misses       7698     7701       +3     
  Partials      651      651              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mauberti-bc mauberti-bc added Ready For Review PR is ready for review and removed Early Feedback Welcome PR is not finished, but early review feedback is welcomed labels Mar 12, 2024
api/src/paths/codes.ts Outdated Show resolved Hide resolved
api/src/paths/project/{projectId}/survey/create.ts Outdated Show resolved Hide resolved
api/src/paths/project/{projectId}/survey/index.ts Outdated Show resolved Hide resolved
api/src/repositories/code-repository.ts Show resolved Hide resolved
api/src/repositories/code-repository.ts Outdated Show resolved Hide resolved
database/src/seeds/03_basic_project_survey_setup.ts Outdated Show resolved Hide resolved
al-rosenthal
al-rosenthal previously approved these changes Mar 12, 2024
Copy link
Contributor

@al-rosenthal al-rosenthal left a comment

Choose a reason for hiding this comment

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

ran this locally and everything worked as expected 🌈

@al-rosenthal al-rosenthal self-requested a review March 12, 2024 20:43
Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.4% Duplication on New Code

See analysis details on SonarCloud

Copy link
Contributor

@al-rosenthal al-rosenthal left a comment

Choose a reason for hiding this comment

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

🍻

Copy link
Contributor

@curtisupshall curtisupshall left a comment

Choose a reason for hiding this comment

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

LGTM

@mauberti-bc mauberti-bc merged commit e12d031 into dev Mar 13, 2024
17 checks passed
KjartanE pushed a commit that referenced this pull request Mar 13, 2024
* survey repository changes & frontend

* openApi spec

* more openapi spec changes

* migration fixes

* wip: fix migration where survey table does not have progress_id

* set survey status when creating or editing surveys

* cleanup

* include description in planning ui options

* planning chip on survey page

* add survey progress chip to survey list page

* adjust colors of progress chip

* add survey_progress to tests

* linter

* cleanup and fixes

* linter

* make progress required

* wip: validation not yet working on survey form for progress component

* include progress in yup schema

* create index for progress id in survey table

* linter

* fix incorrect name: progress -> progress_id

* cleanup

* address PR comments

* update seed

* update comments in codes repository

* update returns types in codes repository

---------

Co-authored-by: Al Rosenthal <[email protected]>
Co-authored-by: Nick Phura <[email protected]>
@NickPhura NickPhura deleted the survey-status branch April 17, 2024 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Ready For Review PR is ready for review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants