Overview
Service request auto-expiration process starts periodically based on the value of configuration parameter SERVICE_REQUEST_AUTOEXPIRATION_SCHEDULE. It cancels all service requests in status Active that have an expiration date less than the current time.
Process
- Update
- status = recalled
- status_reason = autoexpired
- status history
for all service requests where:
- status =
active
- expiration_date < current_time + SERVICE_REQUEST_EXPIRATION_DAYS
- program_processing_status= NULL or new
- there is no encounter or diagnostic report in ME where incoming_referral/based_on reference service_request