Created
April 8, 2016 13:11
-
-
Save zindel/2a9047c97dad8bd5310868e47a59f29e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/do( | |
$date_collected := today(), | |
$collected_by := null(), | |
$volume_amount := null(), | |
$volume_unit := null(), | |
$concentration_amount := null(), | |
$concentration_unit := null(), | |
$individual := top(todo?id()=$todo).individual, | |
with($sample_data, do( | |
$id := insert(sample := { | |
individual := $individual, | |
sample_type := $sample_type, | |
date_collected := $date_collected, | |
collected_by := $collected_by, | |
}), | |
for($_tube := $tube, with($_tube, insert(tube := { | |
sample := $id, | |
volume_amount := $volume_amount, | |
volume_unit := $volume_unit, | |
concentration_amount := $concentration_amount, | |
concentration_unit := $concentration_unit | |
}))), | |
insert(sample_todo_fulfillment := { | |
sample := $id, | |
todo := $todo | |
}) | |
)), | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment