Specification
Apiary
Purpose
This service is made to count an amount of declaration doctor has already made. The amount will increase or decrease with each declaration signed or terminated on prm and recalculated every night with real amount of doctor's declarations on ops.
Sign declaration request
- get employee_id payload
- add +1 to employee's properties
- properties:{declaration_amount:n+1}
Terminate declaration
- get employee_id payload
- add -1 to employee's properties
- properties:{declaration_amount:n-1}
Count declarations for employees
Ones a day start the process. Calculate amount of declarations and update properties on prm.employees for each doctor