Data model
"AFFILIATION_STRATEGY_RULE" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"action": VARCHAR(255)
"cancelled_at": DATETIME
"company_id": VARCHAR(36)
"is_missing_siret": BOOLEAN
"name": TEXT
"siret": VARCHAR(14)
}
"OCCUPATIONAL_HEALTH_BILLED_ENTITY" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"emails_to_notify": ARRAY
"entity_name": VARCHAR(255)
"has_installment_plan_per_year": JSONB
"postal_city": VARCHAR(255)
"postal_code": VARCHAR(10)
"postal_country_code": VARCHAR(2)
"postal_street": VARCHAR(255)
"siren": VARCHAR(9)
"siret": VARCHAR(14)
"subscription_ref": UUID
}
"BILLING_AFFILIATION_OVERRIDE" {
shape: sql_table
"id": UUID {constraint: primary_key}
"affiliation_id": UUID
"billed_entity_id": UUID
"comment": TEXT
}
"DPAE_CSV_FILE" {
shape: sql_table
"id": UUID {constraint: primary_key}
"original_filename": VARCHAR(255)
"row_count": INTEGER
"uri": VARCHAR(2083)
}
"DPAE_EMPLOYEE" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"address": VARCHAR
"birth_date": DATE
"city": VARCHAR
"company_name": VARCHAR
"contract_start_date": DATE
"created_at_source": DATE
"dpae_csv_file_id": UUID
"first_name": VARCHAR
"gender": VARCHAR(255)
"last_name": VARCHAR
"married_name": VARCHAR
"siret": VARCHAR(14)
"user_id": VARCHAR
"zip_code": VARCHAR(5)
}
"OCCUPATIONAL_HEALTH_HEALTH_PROFESSIONAL" {
shape: sql_table
"id": UUID {constraint: primary_key}
"email": TEXT
"first_name": TEXT
"gender": VARCHAR(255)
"health_professional_info_documentation_link": TEXT
"health_professional_signature_link": TEXT
"last_name": TEXT
"offboarded_at": DATE
"role": TEXT
}
"OCCUPATIONAL_HEALTH_ACCOUNT_SETTING" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"hr_emails": ARRAY
"post_visit_google_drive_link": TEXT
"referring_health_professional_id": UUID
}
"OCCUPATIONAL_HEALTH_PROFILE" {
shape: sql_table
"id": UUID {constraint: primary_key}
"doctolib_patient_id": VARCHAR
"global_profile_id": UUID
"is_vip": BOOLEAN
"medical_secrecy_worker_record_id": UUID
"personal_email": VARCHAR
"phone_number": VARCHAR
}
"OCCUPATIONAL_HEALTH_ADMINISTRATIVE_PROFILE" {
shape: sql_table
"id": UUID {constraint: primary_key}
"health_data_sharing_consent": BOOLEAN
"health_data_sharing_consent_collected_at": DATETIME
"health_statuses": ARRAY
"medical_record_access_consent": BOOLEAN
"medical_record_access_consent_collected_at": DATETIME
"medical_record_sharing_consent": BOOLEAN
"medical_record_sharing_consent_collected_at": DATETIME
"notes": VARCHAR
"orient_prevention_of_work_consent": BOOLEAN
"orient_prevention_of_work_consent_collected_at": DATETIME
"profile_id": UUID
"risk_category": VARCHAR(255)
"transfer_dmst_to_spsti_consent": BOOLEAN
"transfer_dmst_to_spsti_consent_collected_at": DATETIME
"video_consultation_consent": BOOLEAN
"video_consultation_consent_collected_at": DATETIME
}
"OCCUPATIONAL_HEALTH_AFFILIATION_DECISION" {
shape: sql_table
"id": UUID {constraint: primary_key}
"core_employment_id": UUID
"decision": VARCHAR(255)
"employment_change_payload": JSONB
"manual_decision": VARCHAR(255)
"profile_id": UUID
"requested_siret": VARCHAR(14)
"rule_id": UUID
}
"OCCUPATIONAL_HEALTH_AFFILIATION_MOVEMENT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"affiliation_decision_id": UUID
"core_employment_id": UUID
"employment_change_payload": JSONB
"movement_type": VARCHAR(255)
"profile_id": UUID
}
"OCCUPATIONAL_HEALTH_DASHBOARD_ADMIN" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"scope": VARCHAR(255)
"user_id": VARCHAR
}
"OCCUPATIONAL_HEALTH_DISCREPANCY_NOTE" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"comment": VARCHAR
"noted_by_user_id": VARCHAR
"user_id": VARCHAR
}
"OCCUPATIONAL_HEALTH_INS_IDENTITY" {
shape: sql_table
"id": UUID {constraint: primary_key}
"birth_date": DATE
"birth_first_names": ARRAY
"birth_last_name": VARCHAR(255)
"birth_place_insee_code": VARCHAR(255)
"display_first_birth_first_name": VARCHAR(255)
"flagged_as_dubious": BOOLEAN
"given_first_name": TEXT
"given_last_name": TEXT
"identity_validation_method": VARCHAR(255)
"matricule_key": VARCHAR(2)
"matricule_oid": VARCHAR(255)
"matricule_value": VARCHAR(13)
"profile_id": UUID
"sex": VARCHAR(255)
"status": VARCHAR(255)
}
"OCCUPATIONAL_HEALTH_JOB" {
shape: sql_table
"id": UUID {constraint: primary_key}
"employer": VARCHAR(255)
"end_date": DATE
"is_past_job": BOOLEAN
"medical_secrecy_worker_job_id": UUID
"profile_id": UUID
"start_date": DATE
"title": VARCHAR(255)
}
"OCCUPATIONAL_HEALTH_MASS_AFFILIATION_LOG" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"affiliation_id": UUID
"extra_data": JSONB
"profile_id": UUID
"start_date": DATE
}
"OCCUPATIONAL_HEALTH_NEXT_VISIT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"archived_at": DATETIME
"created_by": VARCHAR
"profile_id": UUID
"reason": VARCHAR
"visit_deadline": DATE
"visit_type": VARCHAR(255)
}
"OCCUPATIONAL_HEALTH_POST_VISIT_DOCUMENT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"declined_at": DATETIME
"delivered_at": DATETIME
"document_type": VARCHAR(255)
"docusign_envelope_id": VARCHAR(255)
"filename": VARCHAR(512)
"gdrive_file_id": VARCHAR(255)
"gdrive_folder_id": VARCHAR(255)
"required_signature": BOOLEAN
"s3_uri": VARCHAR(1024)
"sent_at": DATETIME
"signed_at": DATETIME
"visit_id": UUID
"visit_model": VARCHAR(255)
"voided_at": DATETIME
}
"OCCUPATIONAL_HEALTH_PROFILE_EMPLOYMENT_DATA" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"professional_email": VARCHAR
"profile_id": UUID
}
"OCCUPATIONAL_HEALTH_SUBSCRIBER_DOCUMENT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"content_hash": VARCHAR(64)
"deleted_at": DATETIME
"document_type": VARCHAR(255)
"mime_type": VARCHAR(255)
"name": TEXT
"siret": VARCHAR(14)
"uploaded_at": DATETIME
"uri": VARCHAR(2083)
}
"OCCUPATIONAL_HEALTH_VISIT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"cancellation_reason": VARCHAR(255)
"health_professional_id": UUID
"managed_by_prevenir": BOOLEAN
"profile_id": UUID
"visit_date": DATE
"visit_end_datetime": DATETIME
"visit_setup": VARCHAR(255)
"visit_start_datetime": DATETIME
"visit_type": VARCHAR(255)
"work_stoppage_reason": VARCHAR(255)
}
"OCCUPATIONAL_HEALTH_VISIT_REQUEST" {
shape: sql_table
"id": UUID {constraint: primary_key}
"actor_id": INTEGER
"payload": JSONB
"request_type": VARCHAR(255)
"state": VARCHAR(255)
"state_reason": VARCHAR(255)
"state_reason_details": JSONB
"user_id": VARCHAR
"visit_id": UUID
"visit_type": VARCHAR(255)
}
"THESAURUS_MEAN" {
shape: sql_table
"id": UUID {constraint: primary_key}
"category": VARCHAR
"is_displayed": BOOLEAN
"key": VARCHAR
"label": VARCHAR
"presanse_label": VARCHAR
}
"OCCUPATIONAL_HEALTH_WORKSPACE_ACTION" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"actor_full_name": TEXT
"ended_at": DATETIME
"eta_date": DATE
"note": TEXT
"prevention_type": VARCHAR(255)
"profile_id": UUID
"siret": VARCHAR(14)
"started_at": DATETIME
"status": VARCHAR(255)
"thesaurus_mean_id": UUID
"title": TEXT
"type": VARCHAR(255)
}
"THESAURUS_OCCUPATIONAL_EXPOSURE" {
shape: sql_table
"id": UUID {constraint: primary_key}
"class_notation": VARCHAR
"dc_type": VARCHAR(255)
"label": VARCHAR
"line_number": INTEGER
"notation": VARCHAR
"parent_notation": VARCHAR
"risk_category": VARCHAR(255)
"status": VARCHAR(255)
"subclass_notation": VARCHAR
"version": VARCHAR
}
"TURING_OCCUPATIONAL_HEALTH_ON_DEMAND_VISIT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"additional_comments": TEXT
"are_individual_measures_reasonable_accommodation": BOOLEAN
"attestation_de_suivi_to_fill": BOOLEAN
"avis_aptitude_to_fill": BOOLEAN
"avis_inaptitude": BOOLEAN
"booking_email_sent_at": DATETIME
"cmb_doc_generated": BOOLEAN
"date_fixed": BOOLEAN
"date_planned": DATE
"doc_generated": BOOLEAN
"doctolib_visit_id": VARCHAR
"email_sent": BOOLEAN
"hour_booked": VARCHAR(10)
"hour_end": VARCHAR(10)
"hp_visit_owner_id": UUID
"hr_informed": BOOLEAN
"if_avis_comments": TEXT
"if_on_demand_visit_specify_motive": TEXT
"if_pre_return_visit_specify_request_initiator": TEXT
"if_return_visit_specify_motive": TEXT
"individual_measure_doc_generated": BOOLEAN
"individual_measures_comment": TEXT
"individual_measures_end_date": DATE
"individual_measures_start_date": DATE
"is_archived": BOOLEAN
"is_employee_submitting_the_request": VARCHAR(255)
"is_hr_informed": VARCHAR(255)
"next_visit_date": VARCHAR(255)
"notes": TEXT
"occupational_health_profile_id": UUID
"ops_comment": TEXT
"person_submitting_request": VARCHAR(255)
"post_visit_email_sent_at": DATETIME
"refer_to_doctor_comment": TEXT
"refer_to_doctor_name": TEXT
"reoriented_to_health_professional_comment": TEXT
"reoriented_to_health_professional_id": UUID
"return_to_work_date": DATE
"rps_doc_generated": BOOLEAN
"should_generate_individual_measures_doc": BOOLEAN
"should_refer_to_doctor": BOOLEAN
"sir_monitoring_date": DATE
"status": VARCHAR(255)
"submitted_at": DATETIME
"timestamp_planned": DATETIME
"tms_doc_generated": BOOLEAN
"updated_risk_category": VARCHAR(255)
"user_id": VARCHAR(255)
"utm_source": VARCHAR(255)
"visit_format": VARCHAR(255)
"visit_planned": BOOLEAN
"visit_setup": VARCHAR(255)
"visit_type": VARCHAR(255)
"work_stoppage_end_date": DATE
"work_stoppage_start_date": DATE
}
"TURING_OCCUPATIONAL_HEALTH_PREDICTABLE_VISIT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"admin_warning_no_visit": VARCHAR
"are_individual_measures_reasonable_accommodation": BOOLEAN
"attestation_de_suivi_to_fill": BOOLEAN
"avis_aptitude_to_fill": BOOLEAN
"booked": BOOLEAN
"cmb_doc_generated": BOOLEAN
"current_risk_category": VARCHAR(255)
"date_planned": DATE
"date_sent": DATE
"doc_generated": BOOLEAN
"doctolib_visit_id": VARCHAR
"hour_booked": VARCHAR(10)
"hour_end": VARCHAR(10)
"hp_visit_owner_id": UUID
"if_avis_comments": TEXT
"individual_measure_doc_generated": BOOLEAN
"individual_measures_comment": TEXT
"individual_measures_end_date": DATE
"individual_measures_start_date": DATE
"is_archived": BOOLEAN
"next_visit_date": VARCHAR(255)
"occupational_health_profile_id": UUID
"ops_comment": TEXT
"post_visit_email_sent_at": DATETIME
"refer_to_doctor_comment": TEXT
"refer_to_doctor_name": TEXT
"reoriented_to_health_professional_comment": TEXT
"reoriented_to_health_professional_id": UUID
"rps_doc_generated": BOOLEAN
"should_generate_individual_measures_doc": BOOLEAN
"should_refer_to_doctor": BOOLEAN
"sir_monitoring_date": DATE
"status": VARCHAR(255)
"timestamp_planned": DATETIME
"tms_doc_generated": BOOLEAN
"updated_risk_category": VARCHAR(255)
"user_id": VARCHAR(255)
"visit_setup": VARCHAR(255)
"visit_type": VARCHAR(255)
}
"TURING_OCCUPATIONAL_HEALTH_PROFILE_NEXT_VISIT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"occupational_health_profile_id": UUID
"visit_deadline": DATE
"visit_type": VARCHAR(255)
}
"TURING_OCCUPATIONAL_HEALTH_SUBSCRIBER_ESTABLISHMENT" {
shape: sql_table
"id": UUID {constraint: primary_key}
"account_id": UUID
"city": VARCHAR(255)
"name": VARCHAR(255)
"postal_code": VARCHAR(255)
"siret": VARCHAR(14)
}
"OCCUPATIONAL_HEALTH_BILLED_ENTITY"."id" -> "BILLING_AFFILIATION_OVERRIDE"."billed_entity_id": {
source-arrowhead.shape: cf-one-required
target-arrowhead.shape: cf-many
}
"DPAE_CSV_FILE"."id" -> "DPAE_EMPLOYEE"."dpae_csv_file_id": {
source-arrowhead.shape: cf-one-required
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_HEALTH_PROFESSIONAL"."id" -> "OCCUPATIONAL_HEALTH_ACCOUNT_SETTING"."referring_health_professional_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_ADMINISTRATIVE_PROFILE"."profile_id": {
source-arrowhead.shape: cf-one-required
target-arrowhead.shape: cf-many
}
"AFFILIATION_STRATEGY_RULE"."id" -> "OCCUPATIONAL_HEALTH_AFFILIATION_DECISION"."rule_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_AFFILIATION_DECISION"."profile_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_AFFILIATION_MOVEMENT"."profile_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_AFFILIATION_DECISION"."id" -> "OCCUPATIONAL_HEALTH_AFFILIATION_MOVEMENT"."affiliation_decision_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_INS_IDENTITY"."profile_id": {
source-arrowhead.shape: cf-one-required
target-arrowhead.shape: cf-one-required
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_JOB"."profile_id": {
source-arrowhead.shape: cf-one-required
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_MASS_AFFILIATION_LOG"."profile_id": {
source-arrowhead.shape: cf-one-required
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_NEXT_VISIT"."profile_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_PROFILE_EMPLOYMENT_DATA"."profile_id": {
source-arrowhead.shape: cf-one-required
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_VISIT"."profile_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_HEALTH_PROFESSIONAL"."id" -> "OCCUPATIONAL_HEALTH_VISIT"."health_professional_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"THESAURUS_MEAN"."id" -> "OCCUPATIONAL_HEALTH_WORKSPACE_ACTION"."thesaurus_mean_id": {
source-arrowhead.shape: cf-one-required
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_PROFILE"."id" -> "OCCUPATIONAL_HEALTH_WORKSPACE_ACTION"."profile_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_HEALTH_PROFESSIONAL"."id" -> "TURING_OCCUPATIONAL_HEALTH_ON_DEMAND_VISIT"."reoriented_to_health_professional_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_HEALTH_PROFESSIONAL"."id" -> "TURING_OCCUPATIONAL_HEALTH_ON_DEMAND_VISIT"."hp_visit_owner_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_HEALTH_PROFESSIONAL"."id" -> "TURING_OCCUPATIONAL_HEALTH_PREDICTABLE_VISIT"."reoriented_to_health_professional_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
"OCCUPATIONAL_HEALTH_HEALTH_PROFESSIONAL"."id" -> "TURING_OCCUPATIONAL_HEALTH_PREDICTABLE_VISIT"."hp_visit_owner_id": {
source-arrowhead.shape: cf-one
target-arrowhead.shape: cf-many
}
Hold "Alt" / "Option" to enable pan & zoom