Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents

...

View file
nameUntitled Diagram.drawio

...

Processor

Once in N interval (where N - cron value of DLS_HEALTHCARE_SERVICE_LICENSES_SCHEDULE parameter), Processor app selects all records from PRM.healthcare_service_licenses table (table specs). Each entry should be processed with next logic:

Search healthcare service in PRM.licensed_healthcare_services table by healthcare_service_id:

...

If not found - insert new record. Set all fields in PRM.licensed_healthcare_services.

...

...

Processor

Once in N interval (where N - cron value of DLS_HEALTHCARE_SERVICE_LICENSES_SCHEDULE parameter), Processor app selects all records from PRM.healthcare_service_licenses table (table specs). Each entry should be processed with next logic:

  1. Search healthcare service in PRM.licensed_healthcare_services table by healthcare_service_id:

    • If not found - insert new record. Set all fields in PRM.licensed_healthcare_services.

    • if found - update PRM.licensed_healthcare_service.status.

  2. Log status history to PRM.licensed_healthcare_services_status_history table.

Deactivate Medical Program Provision

In case healthcare service with category = ‘PHARMACY’ becomes not verified in DLS (licensed_healthcare_service.status=inactive)

  1. If DISPENSE_DIVISION_HEALTHCARE_SERVICE_DLS_VERIFY chart parameter is on:

    • deactivate related to the division from healthcare service all active medical program provision entities:

      • set is_active = false

      • set deactivate_reason = AUTO_DIVISION_DLS_NOT_VERIFIED 

      • set updated_at, updated by 

  2. If DISPENSE_DIVISION_HEALTHCARE_SERVICE_DLS_VERIFY is off, then skip this event