Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents

Status

Page Properties


Specification

Status
colourGreen
titledone

Apiary
Status
colourGreen
titledone
JSON Schema request

Status
colourGrey
titleabsent

JSON Schema response
Status
colourRed
titlespecs


Purpose

This WS  is design to update flags "is_active" for Medical Program.

APIary 

Deactivate Medical program

...

Purpose validation: Check on active program medication. Only medical program without active program medication can't be deactivated. In case on existing active program medication error must be shown.

  1. Check exist `program medication` by $.id & `is_active`=false
    1. if invalid - return 409 error (message: "There are active participants on this program. Only medical programs without participants can be deactivated.")

Validate PK Program Medications

...

    1. if invalid  - return 409 error (message: "Medical program is not active and can't be deactivated again")

Deactivate Program Medications

Update medical program record by $.id  set values:


Destination

Source

is_active

FALSE

updated_at:timestamp
updated_byuser_id


Prepare & return response data structure

...