Closed huip-ims closed 2 years ago
I will give it a test, but can you use
|date|id=datetest|
@danielruss @boyd-mj Daniel - I'm not sure NCI want a participant to recall a specific date for each of their COVID infections. Currently, they are just asking for month and year which are easier to remember, but I'll check with Julie while you do your test.
@huip-ims Checking the code, it appears the functionality existed at one time. I am looking into how it is supposed to work and if I can get it working.
@huip-ims
Try this:
[A1] Please answer the following:
Name: |__|id=name required|
Id: |__|id=test_id required|
[END] Thank you
This should only be used for questions that have MULTIPLE required responses. Otherwise, use our friend [Q1!]
@danielruss @naiyume @boyd-mj Daniel - Using the test code you provided, if any 1 of the 2 boxes is filled in, it requires you to fill in the null text box. However, if both text boxes are left missing, it allows the question to move forward, which we don't want. And, if I also use [A1!], this prevents moving forward when both text boxes are missing. Do you see any issues in using [A1!] in conjunction with your test code?
@huip-ims Please try again.
@naiyume I have worked the "required" attribute into the validation. Please take a look at the code, see if you understand what I am doing. Future me, who never seems to understand my code, thanks you now.
@danielruss @naiyume @boyd-mj Daniel - It's working now. Both text boxes must be filled in before proceeding. Thanks!
@danielruss @guinevere83 Hi Daniel - we're noticing that the code below no longer works. We have a question in the biospecimen module with 2 text boxes that are both required. We coded it based on the example in your May 4th comment above, and it worked at the time. However, during today's test, it's allowing you to proceed if you provide 1 or no responses, and if responses are provided, it's storing the responses incorrectly (see {"SRVBLU_COV3_MONTH_V1R0_1%20required":"8","SRVBLU_COV3_YEAR_V1R0_1%20required":"2022"}} in screenshot below)
Has something changed in the renderer since May that may be causing this to no longer work?
[SRVBLU_COV3_V1R0!,displayif=greaterThanOrEqual(SRVBLU_COV2_V1R0,#loop)] When was the <b>{##}</b> time that you had COVID-19? If you are not sure, please make your best guess.
Month |__|__|id=SRVBLU_COV3_MONTH_V1R0 required min=1 max=12|
Year |__|__|__|__|id=SRVBLU_COV3_YEAR_V1R0 required min=2020 max=#currentYear|
@danielruss @boyd-mj Hi Daniel - In the Biospecimen Survey, we have a required question with 2 text boxes. Is there a way to make both text boxes required within the same question? Currently, Quest is allowing the question to move forward if any 1 of the 2 boxes is answered. See example below.
[SRVBLU_COV3_V1R0!,displayif=greaterThanOrEqual(SRVBLU_COV2_V1R0,#loop)] When was the {##} time that you had COVID-19? If you are not sure, please make your best guess.
Month |||id=SRVBLU_COV3_MONTH_V1R0 min=1 max=12| Year |||||id=SRVBLU_COV3_YEAR_V1R0 min=2020 max=#currentYear|