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

🐛 Fix validation script to require relapse-related fields when disease_status_at_followup is 'Progression NOS' #357

Open
hknahal opened this issue Aug 23, 2022 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@hknahal
Copy link
Contributor

hknahal commented Aug 23, 2022

Describe the bug

When "disease_status_at_followup" = "Progession NOS", the "relapse_type" and "relapse_interval" fields should be required. Instead, it reports an error 'relapse_type' cannot be provided if 'disease_status_at_followup' is not a state of progression, relapse, or recurrence. This is because the validation script only matches on "progression" at the end of the string:

 const stateOfProgression = (entry) => {return /(progression)$/.test(decodeURI(entry))}; 

This should be corrected so it matches on "progression" anywhere in the string submitted for "disease_status_at_followup".

Steps To Reproduce

Submit "disease_status_at_followup" = "Progression NOS"
Submit "relapse_type" = "distant recurrence/metastasis"
Submit "relapse_interval" = 54

Error message: ``'relapse_type' cannot be provided if 'disease_status_at_followup' is not a state of progression, relapse, or recurrence.`

@hknahal hknahal added the bug Something isn't working label Aug 23, 2022
@hknahal hknahal self-assigned this Aug 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant