...
...
Table of Contents |
---|
Status
- Specification
Status colour Green title done - Apiary
Status colour Green title Done
Purpose
This procedure (Automatic schedule task) is designed to expire previously created Request for Medication request Request after ended time-life in NEW status.
Procedure logic for transition
- For info - status charts: Request_for_medication_requestMedication request Request Status Chart
Get list Request for Medication request
Code Block language sql SELECT * FROM requests_for_medication_request_requests RMR WHERE RMR.status == NEW AND RMR.expiryexpired_toat <= current_date()
- Update (Set values) Request for Medication request
- status = EXPIRED
- updated_by = user_id
- updated_at = timestamp