Closed dbarrell closed 6 years ago
Hi Dan,
I think you should have access to the QC flag in the artifact entity.
Just be carefull in your code the variable you called artifact
is a dictionary that contains the Artifact
.
I would probably do something like that (code is not tested)
step_actions = step.actions
for next_action in step_actions.next_actions:
if next_action['artifact'].qc_flag == 'PASSED':
next_action['action'] = 'complete'
else:
# probably requeue ?
step.actions.put()
Checkout the next action and qc_flag doc
Thanks, that was just what was needed.
Hi, I'd like to 'Mark protocol as complete' for each sample ONLY IF 'Samples that passed Aggregate_QC...' is true:
I can manually mark as complete using something like:
However, I'd like the code to emulate the check that is performed when hitting 'Apply' in the screenshot. Is it just a matter of checking the QC flag for each sample or is there functionality in pyclarity-lims to do this in one easy step as one would do in the web interface?
Thanks
Dan