ЕСОЗ - публічна документація
Merge Party and MPI
ERD
Migration open questions
- Fields which are mandatory for Employee and optional or not present for Persons
- tax_id (optional)
- no_tax_id (not present) - by default false
- email (optional) - >=3 emails: mpi (optional), doctor (required), employee (required)
- phones (optional) - >=3 phones: mpi (optional), doctor (required), employee (required)
- Fields which are mandatory for Persons and optional or not present for Employee
- birth_country (not present) - required, N/A
- birth_settlement (not present) - required, N/A
- secret (not present) - optional, by default N/A, collect via cabinet
- addresses (not present) - empty for doctors, fix na get for dictionaries or foreign keys, return empty objects
- authentication_methods (not present) - by default offline
- emergency_contact (not present) - empty object - {}
- patient_signed (not present) - false by default
- process_disclosure_data_consent (not present) - by default true, find evidence, add it to employee request for the future
- New field:
- preferred_way_communication - do not use
Data structures
PERSONS
Name | Type | M/O | Description and constraints |
---|---|---|---|
id | uuid | M | |
last_name | varchar | M | |
first_name | varchar | M | |
second_name | varchar | O | |
birth_date | date | M | |
birth_country | varchar | M | M for person/O for employee |
birth_settlement | varchar | M | M for person/O for employee |
gender | M | ||
O | M for employee | ||
tax_id | O | M for employee | |
no_tax_id | O | M for employee | |
death_date | O | ||
is_active | M | ||
documents | M | ||
addresses | M | M for person/O for employee | |
phones | O | M for person/O for employee | |
secret | O | M for person/O for employee | |
emergency_contact | M | ||
confidant_person | O | ||
patient_signed | M | ||
process_disclosure_data_consent | M | ||
authentication_methods | M | M for persons | |
preferred_way_communication | M |
DOCTOR_PROFILES
Name | Type | M/O | Description and constraints |
---|---|---|---|
id | uuid | M | |
person_id | uuid | O | |
educations | jsonb[] | M | |
qualifications | jsonb[] | O | |
specialities | jsonb[] | M | |
science_degree | jsonb | O | |
phones | jsonb[] | ?M | |
addresses | jsonb[] | ?M | |
start_date | date | M | |
working_experience | string | O |
EMPLOYEES
Name | Type | M/O | Description and constraints |
---|---|---|---|
id | uuid | M | |
person_id | uuid | O | |
position | varchar | M | |
status | varchar | M | |
employee_type | varchar | M | |
is_active | boolean | M | |
start_date | timestamp | M | |
end_date | timestamp | O | |
legal_entity_id | uuid | M | |
division_id | uuid | O | |
status_reason | varchar | O |
ЕСОЗ - публічна документація