Table of Contents |
---|
...
Find program_devices related to the program, that:
are active
have validity period (start_date and end_date) within current date
in case not found - return reject_reason = “No appropriate participants found for this medical program“
For found program_devices check there at least one appropriate Device Definition, that:
is active
has packaging_unit that matches to quantity.code of the Device Request
in case of error - return reject_reason = “Not found any active Device Definition with the same units of measure as pointed in the quantity of the Device Request”
has at least one classification type that is the same code as in the Device Request
in case of error - return reject_reason = “Not found any active device definition with classification type that match with code from device request”
has a remainder of the division ($.device_request.quantity.value/device_definition.packaging_count) that is equal to 0
in case of error - return reject_reason = “The quantity in the Device Request must be divisible to packaging_count of at least one related Device Definition”
...