-
Notifications
You must be signed in to change notification settings - Fork 175
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_list/battery] Clean-up battery retrieval function #7167
Conversation
439aa19
to
4c6b64b
Compare
} | ||
|
||
if (Utility::columnsHasNull('test_subgroups', 'group_order')) { | ||
$query = "SELECT DISTINCT f.Test_name, |
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.
This should be converted to a group BY to avoid start next stage duplication issues
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.
does this still need to be resolved?
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.
yes but its unrelated to the survey_accounts bug if thats what you were thinking
@jesscall @CamilleBeau @pierre-p-s I need someone from CCNA to test this one, you guys have the more complex batteries and use all sorts of ordering. read the description carefully, theres a bunch of clean up here and testing should be rigorous |
@ridz1208 does this fix a specific issue? I am wondering if this PR indeed fixes the error you get when you try to 'Start Visit Stage' on a session that already has a survey created i.e. a test battery generated, blocking the rest of the instruments in the test battery from getting populated |
@zaliqarosli no this might fix instruments not displaying in the same order when you load instrument_list multiple times. the issue you are talking about was however fixed in a different PR |
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.
Tested and the ordering seemed to be working. Pass fail function worked as intended.
AND (s.SubprojectID=b.SubprojectID OR b.SubprojectID IS NULL) | ||
AND (s.Visit_label=b.Visit_label OR b.Visit_label IS NULL) |
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.
Why do you check for Null subproject IDs or visit labels?
Shouldnt the instruments in the test battery always have those information?
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.
// get the list of instruments | ||
$rows = $DB->pselect($query, $qparams); | ||
|
||
// return all the data selected | ||
return $rows; | ||
} // end getBatteryVerbose() |
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.
There s the same thing line 284 for the getBattery function
@ridz1208 can you rebase and integrate Pierre's feedback? Thanks! |
7acf8a7
to
ad121d0
Compare
@pierre-p-s please re-review/re-test @zaliqarosli if you can find some time to test (see description for more) |
Manual test and review worked. However we found an issue in the patch 2020-02-10_NewModulePermissions.sql in SQL/New_patches with @ridz1208. Should I make an issue? |
@pierre-p-s let's investigate that together for another 10 minutes before doing that. |
@zaliqarosli waiting on your testing |
testing on QPN data:
failed:
|
@zaliqarosli testing ITEM 4 involves making sure you can only toggle the VISIT to |
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.
passes testing
@driusan all urs |
Brief summary of changes
_assertBatterySelected
) but are also either completely unsued in these functions or not necessary at all.Testing instructions (if applicable)
@jesscall @sruthymathew123 @zaliqarosli each of you should test this on at least a handful of timepoints since you all use different functionalities affecting the instrument list module
make sure: