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

[Instrument] LINST Standard Date field Always Required, not working with conditional XIN rules #7650

Closed
christinerogers opened this issue Sep 29, 2021 · 2 comments · Fixed by #7925
Assignees
Labels
24.0.0-bugs Issues or bug fix PRs that were raised during the testing of release 24.0.0 Category: Bug PR or issue that aims to report or fix a bug

Comments

@christinerogers
Copy link
Contributor

christinerogers commented Sep 29, 2021

The LINST Standard Date field type seems to be required Always.
Unlike other fields that come with a _status field (e.g. textarea), this field can't be made conditional (not required) using XIN rules.
This is a bug, and there is probably an easy fix based on how textarea (or numeric etc) are implemented.

Example: I have a LINST questionnaire that asks:

  1. Was there a surgery done? field: surgery_done yes/no/not answered (Dropdown)
  2. What was the date of the surgery? surgery_date date plus not answered (StandardDate)

Question 2 should be required Only If Surgery was actually done -- i.e. surgery_done == yes
and a XIN rule is in place (* see below) to express this dependency.

However this field always gives an error (A date is required, or not answered) even when surgery_done == no.

Note: not answered is a valid option for this field (even when the surgery was done) so Standard Date is the most suitable date type.

(*) This Xin rule should, but does not, make the field conditional:
surgery_date{-}Required{-}surgery_done{@}=={@}yes

suggested fix : check against textarea implementation in the instrument class, which allows Xin rules to override this type of constraint

OR ELSE: Document clearly for users of the Instrument Builder / Linst that Standard Date fields can Never be conditional.

@christinerogers
Copy link
Contributor Author

might be resolved by #7266 - to be verified

@ridz1208 ridz1208 added the 24.0.0-bugs Issues or bug fix PRs that were raised during the testing of release 24.0.0 label Nov 16, 2021
@ridz1208 ridz1208 self-assigned this Nov 16, 2021
@ridz1208
Copy link
Collaborator

@christinerogers nice catch. Fixed in PR linked above

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
24.0.0-bugs Issues or bug fix PRs that were raised during the testing of release 24.0.0 Category: Bug PR or issue that aims to report or fix a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants