Introduction
VaccinationProfile is a nomenclature that structures all the life conditions of an individual that can impact their vaccination recommendations.
Concepts
- Condition
- This refers to a life condition that can impact vaccination recommendations (for example, being pregnant or having a chronic disease). Each condition is of a specific type (for example, "pregnancy" is a boolean value condition, while "last history of COVID-19" is a date type value condition).
- ConditionGroup
- This is a group of conditions to be displayed together in the health profile form.
- Health Profile Form
- This is a form for entering an individual's life conditions. This form is structured as a tree, with each node of the tree being a group of conditions.
- Health Profile
- This is a set of condition values associated with a given patient. It takes the form of a set of key-value pairs where the key is a condition identifier and the value conforms to the expected type for the condition.
Libraries
The vaccination-profile library allows you to:
- Retrieve a nomenclature of health conditions that can influence vaccination recommendations;
- Display a health profile entry form;
- Encode and display a health profile.
PHP
Prerequisites
- The composer tool must be installed;
- PHP 7.4 or higher.
Usage
Initialization
You must first initialize the library. During the initialization of the library, the latest version of the nomenclature is downloaded.
$vaccination_profile = Syadem\VaccinationProfile\Container::init();
Note that this initialization operation is costly and should be performed only once. Therefore, it is advisable to keep the instance of the library in a global cache.
Displaying a Health Profile Condition
$nuva = Syadem\VaccinationProfile\Container::init();
echo $nuva->getConditions()->find("2427485e-907c-4241-83c8-939237010ca2")->getLabel()->getFr();
// => Personne immunodéprimée dans l'entourage
Installation
The vaccination-profile library is published on GitHub. Declare the repository in your composer.json, then install the library:
composer config repositories.syadem-vaccination-profile git https://github.com/Syadem/vaccination-profile-php.git
composer require syadem/vaccination-profile
Other Languages
If you wish to use the VaccinationProfile nomenclature with another programming language, please do not hesitate to contact us at the following address: contact@mesvaccins.net.
Detail of Concepts
Area
| Property | Type | Description |
|---|---|---|
| id | string |
|
| name | Name |
|
| code | string |
|
| category | Category |
|
| parent_ids | string [] |
Condition
| Property | Type | Description |
|---|---|---|
| id | string |
|
| code | string |
A readable code |
| type | ConditionType |
|
| label | TranslatedField |
|
| child_label | TranslatedField |
|
| female_label | TranslatedField |
|
| male_label | TranslatedField |
|
| professional_label | TranslatedField |
|
| help | TranslatedField |
Condition.type
- Type:
ConditionType - Valeurs autorisées:
booleandateintegerfloat
ConditionGroup
| Property | Type | Description |
|---|---|---|
| id | string |
|
| label | Name |
|
| parent_id | null |
|
| condition_ids | string [] |
TranslatedField
| Property | Type | Description |
|---|---|---|
| de | string |
|
| en | string |
|
| fr | string |
|
| nl | string |
|
| ru | string |
|
| ua | string |
|
| es | string |
|
| it | string |