Skip to content

Conversation

Joe-Heffer-Shef
Copy link
Collaborator

@Joe-Heffer-Shef Joe-Heffer-Shef commented Sep 15, 2025

Resolves

Changes

  • Removed target audience option from "configure survey" page
    • Added target audience option to "create survey page"
  • Added new demographics data JSON files for each profession in data/survey_config/
    • The default one is NMAHPs because that's the most general category
    • Added settings.DEMOGRAPHY_TEMPLATES for the 3 demography config files
    • Update the Django system check to ensure all these new config files are present as expected
    • Added new options for midwife and nursing professions, etc.
  • Improved the data integrity of the Survey.survey_body_path field (created migration)
    • Add a Profession enum (nurses, NMAHPs, midwives) using the Django choices class.
  • Improved Survey model
    • Rename Survey.merge_sections() to Survey.update() which is now the main way to update the survey config.
    • Clarified the Survey properties that define the paths of the config files (e.g. Survey.demography_config_default)
    • Added Survey.reset() method to revert to out-of-the-box questions for all sections

Screenshots

image image image

@Joe-Heffer-Shef Joe-Heffer-Shef linked an issue Sep 15, 2025 that may be closed by this pull request
@Joe-Heffer-Shef Joe-Heffer-Shef self-assigned this Sep 15, 2025
@Joe-Heffer-Shef Joe-Heffer-Shef marked this pull request as draft September 15, 2025 14:39
@Joe-Heffer-Shef Joe-Heffer-Shef marked this pull request as ready for review September 17, 2025 09:28
Copy link

github-actions bot commented Sep 17, 2025

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 15.13% 287 / 1896
🔵 Statements 15.13% 287 / 1896
🔵 Functions 42.85% 30 / 70
🔵 Branches 81% 81 / 100
File Coverage
File Stmts Branches Functions Lines Uncovered Lines
Changed Files
ui_components/src/SurveyConfigConsentDemographyApp.svelte 0% 100% 100% 0% 6-61
Generated in workflow #237 for commit 6b61fab by the Vitest Coverage Report Action

Copy link
Contributor

@twinkarma twinkarma left a comment

Choose a reason for hiding this comment

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

This looks good! 🚀

"Hospital Midwife",
"Specialist Midwife",
"Senior Midwife",
"Lead/Manager Midwife",
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Are these options okay? It wasn't clear from the communications with Trixie etc

@Joe-Heffer-Shef Joe-Heffer-Shef merged commit 355d58f into dev Sep 17, 2025
4 checks passed
@Joe-Heffer-Shef Joe-Heffer-Shef deleted the feat/separate-demographics branch September 17, 2025 11:56
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.

3 separate sets of demographics questions
2 participants