-
Notifications
You must be signed in to change notification settings - Fork 39
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
fixes edit profile - questionItems disable via readOnlyLinkIds #3218
Conversation
Revert fhircore PR#3069
Observer<T> | ||
// override fun onChanged(o: T?) { | ||
// data[0] = o | ||
// latch.countDown() | ||
// liveData.removeObserver(this) | ||
// } | ||
{ TODO("Not yet implemented") } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of commenting these lines, make the function parameter o
NON-NULLABLE by removing the question mark.
override fun onChanged(o: T) {
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
resolved
@ageryck @AbdulWahabMemon How is this PR different from this one by @DebbieArita #3070 |
@ellykits the other PR was evaluating to true when in edit mode irrespective of linkid's supplied hence rending full form in readonly mode |
@@ -130,13 +131,16 @@ constructor( | |||
readOnlyLinkIds: List<String>? = emptyList() | |||
): Questionnaire? = | |||
defaultRepository.loadResource<Questionnaire>(questionnaireConfig.id)?.apply { | |||
if (questionnaireConfig.type.isReadOnly() || questionnaireConfig.type.isEditMode()) { | |||
if (questionnaireConfig.type.isReadOnly()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ellykits , here its the main change I found to fix the underline issue,
the required/expected behavior is handle with line 141 below.
https://github.com/opensrp/fhircore/pull/3218/files#r1590661089 |
* Remove unanswered linkId from questionnaireResponse so that default initial values for the linkId get picked from Questionnaire * Apply patch changes from #3218
Revert fhircore PR#3069
IMPORTANT: Where possible all PRs must be linked to a Github issue
Fixes [link to issue]
Engineer Checklist
strings.xml
file./gradlew spotlessApply
and./gradlew spotlessCheck
to check my code follows the project's style guideCode Reviewer Checklist
strings.xml
file