From bf5cf86bcc5c60785a2f113af2fd0b0aa5617f63 Mon Sep 17 00:00:00 2001 From: Alex Kovalevych Date: Mon, 22 Jan 2018 18:30:48 +0200 Subject: [PATCH] [minor] create umbrella (#1756) Enjoy --- .formatter.exs | 7 +- .travis.yml | 8 +- apps/ehealth/.gitignore | 17 ++ apps/ehealth/README.md | 19 ++ apps/ehealth/config/config.exs | 251 +++++++++++++++++ {config => apps/ehealth/config}/dev.exs | 0 {config => apps/ehealth/config}/prod.exs | 0 {config => apps/ehealth/config}/test.exs | 0 apps/ehealth/coveralls.json | 17 ++ .../ehealth/lib/ehealth.ex | 2 - .../ehealth/lib}/ehealth/api/gandalf.ex | 0 .../lib}/ehealth/api/headers_processor.ex | 0 .../ehealth/api/helpers/microservice_base.ex | 0 .../ehealth/api/helpers/signed_content.ex | 0 {lib => apps/ehealth/lib}/ehealth/api/man.ex | 0 .../ehealth/lib}/ehealth/api/media_storage.ex | 0 .../ehealth/lib}/ehealth/api/mithril.ex | 0 {lib => apps/ehealth/lib}/ehealth/api/mpi.ex | 0 {lib => apps/ehealth/lib}/ehealth/api/ops.ex | 0 .../lib}/ehealth/api/otp_verification.ex | 0 .../lib}/ehealth/api/response_decoder.ex | 0 .../ehealth/lib}/ehealth/api/signature.ex | 0 .../ehealth/lib}/ehealth/api/uaddress.ex | 0 .../lib}/ehealth/bamboo/emails/sender.ex | 0 .../ehealth/lib}/ehealth/bamboo/mailer.ex | 0 .../lib}/ehealth/bamboo/mailgun_adapter.ex | 0 .../lib}/ehealth/bamboo/postmark_adapter.ex | 0 .../lib}/ehealth/bamboo/smtp_adapter.ex | 0 .../black_list_users/black_list_user.ex | 0 .../black_list_users/black_list_users.ex | 0 .../lib}/ehealth/black_list_users/search.ex | 0 .../lib}/ehealth/declaration_request/api.ex | 0 .../declaration_request/api/approve.ex | 0 .../ehealth/declaration_request/api/create.ex | 0 .../declaration_request/api/documents.ex | 0 .../declaration_request/api/helpers.ex | 0 .../declaration_request/api/resend_otp.ex | 0 .../ehealth/declaration_request/api/sign.ex | 0 .../api/validate_person.ex | 0 .../declaration_request/api/validations.ex | 0 .../ehealth/declaration_request/schema.ex | 0 .../declaration_request/sign_request.ex | 0 .../ehealth/lib}/ehealth/declarations/api.ex | 0 .../lib}/ehealth/declarations/person.ex | 0 .../ehealth/lib}/ehealth/declarations/view.ex | 0 .../lib}/ehealth/dictionaries/dictionaries.ex | 0 .../lib}/ehealth/dictionaries/dictionary.ex | 0 .../ehealth/dictionaries/dictionary_search.ex | 0 .../lib}/ehealth/divisions/division.ex | 0 .../lib}/ehealth/divisions/divisions.ex | 0 .../ehealth/lib}/ehealth/divisions/search.ex | 0 .../lib}/ehealth/divisions/uaddress.ex | 0 .../ehealth/lib}/ehealth/duplicate_persons.ex | 0 .../lib}/ehealth/duplicate_persons/cleanup.ex | 0 .../lib}/ehealth/duplicate_persons/signals.ex | 0 .../lib}/ehealth/ecto/comma_param_uuid.ex | 0 .../ehealth/lib}/ehealth/ecto/string_like.ex | 0 .../employee_requests/employee_request.ex | 0 .../employee_requests/employee_requests.ex | 0 .../ehealth/employee_requests/validator.ex | 0 .../lib}/ehealth/employees/employee.ex | 0 .../ehealth/employees/employee_creator.ex | 0 .../ehealth/employees/employee_updater.ex | 0 .../lib}/ehealth/employees/employees.ex | 0 .../ehealth/lib}/ehealth/employees/search.ex | 0 .../ehealth/employees/user_create_request.ex | 0 .../ehealth/employees/user_role_creator.ex | 0 .../ehealth/lib/ehealth}/endpoint.ex | 0 .../lib}/ehealth/event_manager/event.ex | 0 .../ehealth/event_manager/event_manager.ex | 0 .../lib}/ehealth/event_manager_repo.ex | 0 .../ehealth/lib}/ehealth/fraud_repo.ex | 0 .../global_parameters/global_parameter.ex | 0 .../global_parameters/global_parameters.ex | 0 .../lib}/ehealth/hash_chain/verification.ex | 0 .../ehealth/legal_entities/legal_entities.ex | 0 .../ehealth/legal_entities/legal_entity.ex | 0 .../legal_entities/legal_entity_request.ex | 0 .../legal_entities/legal_entity_updater.ex | 0 .../medical_service_provider.ex | 0 .../lib}/ehealth/legal_entities/registries.ex | 0 .../lib}/ehealth/legal_entities/registry.ex | 0 .../lib}/ehealth/legal_entities/search.ex | 0 .../lib}/ehealth/legal_entities/validator.ex | 0 .../ehealth/lib}/ehealth/logger_json.ex | 0 .../templates/credentials_recovery_request.ex | 0 .../declaration_request_printout_form.ex | 0 .../employee_created_notification.ex | 0 .../templates/employee_request_invitation.ex | 0 .../employee_request_update_invitation.ex | 0 .../hash_chain_verification_notification.ex | 0 .../medical_programs/medical_program.ex | 0 .../medical_programs/medical_programs.ex | 0 .../lib}/ehealth/medical_programs/search.ex | 0 .../lib}/ehealth/medication_dispenses/api.ex | 0 .../ehealth/medication_dispenses/search.ex | 0 .../search_by_medication_request.ex | 0 .../medication_request_requests/api.ex | 0 .../create_data_operation.ex | 0 .../human_readable_number_generator.ex | 0 .../medication_request_requests/operation.ex | 0 .../operation_helpers.ex | 0 .../preload_fk_operation.ex | 0 .../reject_operation.ex | 0 .../medication_request_requests/schema.ex | 0 .../sign_operation.ex | 0 .../validations.ex | 0 .../lib}/ehealth/medication_requests/api.ex | 0 .../ehealth/medication_requests/search.ex | 0 .../ehealth/medication_requests/sms_sender.ex | 0 .../lib}/ehealth/medications/drugs_search.ex | 0 .../lib}/ehealth/medications/innm/innm.ex | 0 .../lib}/ehealth/medications/innm/search.ex | 0 .../medications/innm_dosage/ingredient.ex | 0 .../medications/innm_dosage/innm_dosage.ex | 0 .../ehealth/medications/innm_dosage/search.ex | 0 .../medications/medication/ingredient.ex | 0 .../medications/medication/medication.ex | 0 .../ehealth/medications/medication/search.ex | 0 .../lib}/ehealth/medications/medications.ex | 0 .../ehealth/medications/program/program.ex | 0 .../ehealth/medications/program/search.ex | 0 .../lib}/ehealth/medications/validator.ex | 0 .../ehealth/lib}/ehealth/oauth/api.ex | 0 .../ehealth/lib}/ehealth/parties/document.ex | 0 .../ehealth/lib}/ehealth/parties/parties.ex | 0 .../ehealth/lib}/ehealth/parties/party.ex | 0 .../ehealth/lib}/ehealth/parties/phone.ex | 0 .../ehealth/lib}/ehealth/parties/search.ex | 0 .../lib}/ehealth/party_users/party_user.ex | 0 .../lib}/ehealth/party_users/party_users.ex | 0 .../lib}/ehealth/party_users/search.ex | 0 .../lib}/ehealth/plugs/client_context.ex | 0 .../ehealth/lib}/ehealth/plugs/headers.ex | 0 .../ehealth/lib}/ehealth/postgres_types.ex | 0 {lib => apps/ehealth/lib}/ehealth/prm_repo.ex | 0 {lib => apps/ehealth/lib}/ehealth/repo.ex | 0 .../ehealth/lib}/ehealth/scheduler.ex | 0 {lib => apps/ehealth/lib}/ehealth/search.ex | 0 .../ehealth/lib}/ehealth/users/api.ex | 0 .../users/credentials_recovery_request.ex | 0 .../lib}/ehealth/utils/address_merger.ex | 0 .../ehealth/lib}/ehealth/utils/connection.ex | 0 .../ehealth/lib}/ehealth/utils/helpers.ex | 0 .../lib}/ehealth/utils/map_deep_merge.ex | 0 .../ehealth/lib}/ehealth/utils/phone.ex | 0 .../lib}/ehealth/utils/types_converter.ex | 0 .../lib}/ehealth/validators/addresses.ex | 0 .../lib}/ehealth/validators/birth_date.ex | 0 .../lib}/ehealth/validators/json_objects.ex | 0 .../lib}/ehealth/validators/json_schema.ex | 0 .../ehealth/lib}/ehealth/validators/kveds.ex | 0 .../lib}/ehealth/validators/reference.ex | 0 .../lib}/ehealth/validators/schema_mapper.ex | 0 .../ehealth/lib}/ehealth/validators/tax_id.ex | 0 .../controllers/black_list_user_controller.ex | 0 .../web/controllers/client_controller.ex | 0 .../declaration_request_controller.ex | 0 .../controllers/declarations_controller.ex | 0 .../controllers/deduplication_controller.ex | 0 .../web/controllers/dictionary_controller.ex | 0 .../web/controllers/division_controller.ex | 0 .../employee_request_controller.ex | 0 .../web/controllers/employees_controller.ex | 0 .../web/controllers/fallback_controller.ex | 0 .../global_parameter_controller.ex | 0 .../web/controllers/hash_chain_controller.ex | 0 .../controllers/legal_entity_controller.ex | 0 .../controllers/medical_program_controller.ex | 0 .../controllers/medication/innm_controller.ex | 0 .../medication/innm_dosage_controller.ex | 0 .../medication/medication_controller.ex | 0 .../program_medication_controller.ex | 0 .../medication_dispense_controller.ex | 0 .../medication_request_controller.ex | 0 .../medication_request_request_controller.ex | 0 .../web/controllers/party_user_controller.ex | 0 .../web/controllers/person_controller.ex | 0 .../web/controllers/uaddresses_controller.ex | 0 .../web/controllers/user_controller.ex | 0 .../web/controllers/user_role_controller.ex | 0 .../ehealth/lib}/ehealth/web/proxy.ex | 0 .../ehealth/lib}/ehealth/web/router.ex | 0 .../ehealth/web/views/black_list_user_view.ex | 0 .../lib}/ehealth/web/views/changeset_view.ex | 0 .../web/views/declaration_request_view.ex | 0 .../lib}/ehealth/web/views/dictionary_view.ex | 0 .../lib}/ehealth/web/views/division_view.ex | 0 .../web/views/employee_request_view.ex | 0 .../lib}/ehealth/web/views/employee_view.ex | 0 .../web/views/global_parameter_view.ex | 0 .../lib}/ehealth/web/views/hash_chain.ex | 0 .../ehealth/web/views/legal_entity_view.ex | 0 .../ehealth/web/views/medical_program_view.ex | 0 .../web/views/medication/innm_dosage_view.ex | 0 .../ehealth/web/views/medication/innm_view.ex | 0 .../web/views/medication/medication_view.ex | 0 .../medication/program_medication_view.ex | 0 .../web/views/medication_dispense_view.ex | 0 .../views/medication_request_request_view.ex | 2 +- .../web/views/medication_request_view.ex | 0 .../lib}/ehealth/web/views/party_user_view.ex | 0 .../lib}/ehealth/web/views/party_view.ex | 0 .../lib}/ehealth/web/views/person_view.ex | 0 .../lib}/ehealth/web/views/user_role_view.ex | 0 .../lib}/ehealth/web/views/user_view.ex | 0 {lib => apps/ehealth/lib}/ehealth/web/web.ex | 0 {lib => apps/ehealth/lib}/tasks/tasks.ex | 2 +- apps/ehealth/mix.exs | 115 ++++++++ .../event_manager_repo/migrations/.gitkeep | 0 .../20171127145251_create_audit_log.exs | 0 .../20171127154946_create_events.exs | 0 .../20171208103336_change_event_id.exs | 0 .../20171208153626_add_events_primary_key.exs | 0 .../20171024084720_enable_postgis.exs | 0 .../20171024124214_create_legal_entities.exs | 0 .../20171024125331_create_divisions.exs | 0 .../20171024143002_create_employees.exs | 0 .../20171024151305_create_parties.exs | 0 .../20171024153405_create_party_users.exs | 0 .../20171024195147_create_audit_log.exs | 0 .../20171025134148_create_declarations.exs | 0 ...5135225_create_declaration_status_hstr.exs | 0 ...1025135518_create_declaration_requests.exs | 0 ...0171025142220_create_employee_requests.exs | 0 .../20171025144300_create_dictionaries.exs | 0 .../20171025145845_create_persons.exs | 0 ...20171031090345_create_black_list_users.exs | 0 .../20171106132511_create_mpi_audit_log.exs | 0 .../20171115162153_drop_parties_fields.exs | 0 .../20171116081857_drop_persons_fields.exs | 0 .../20171121142127_drop_parties_phones.exs | 0 .../20171211093621_add_parties_no_tax_id.exs | 0 .../prm_repo/fixtures/global_parameters.json | 0 .../priv}/prm_repo/migrations/.gitkeep | 0 ...0170413123306_create_entities_division.exs | 0 .../20170413123307_create_entities_msp.exs | 0 ...413123308_create_entities_legal_entity.exs | 0 .../20170413124601_entities_relations.exs | 0 ...832_add_unique_for_legal_entity_edrpou.exs | 0 .../20170417155741_create_parties_party.exs | 0 .../20170419075231_create_employees.exs | 0 .../20170419075232_create_employee_doctor.exs | 0 ...0110826_create_dictionaries_dictionary.exs | 0 ...170421104735_create_registries_ukr_med.exs | 0 ...7103609_rename_msp_license_to_licenses.exs | 0 ..._rename_divisions_address_to_addresses.exs | 0 ...70510164524_add_employee_status_reason.exs | 0 ..._legal_entity_created_by_mis_client_id.exs | 0 ...0511133900_change_employees_date_types.exs | 0 ...0170511154159_create_global_parameters.exs | 0 ...170522114501_create_parties_party_user.exs | 0 .../20170523113838_remove_dictionaries.exs | 0 .../20170524080809_rename_party_users.exs | 0 ...70525101522_rename_party_users_indexes.exs | 0 .../20170606171448_enable_postgis.exs | 0 .../20170606171954_add_location_to_prm.exs | 0 ...0170606203443_added_to_division_status.exs | 0 ...0607084728_added_to_division_is_active.exs | 0 .../20170615114013_create_audit_log_table.exs | 0 ...5155026_set_msp_accreditation_nullable.exs | 0 ...2140_remove_party_user_id_unique_index.exs | 0 ...35447_add_mis_verified_to_legal_entity.exs | 0 ...3635_add_nhs_verified_to_legal_entitiy.exs | 0 ...0122501_change_division_mountain_group.exs | 0 .../20170817084648_add_party_users_index.exs | 0 .../20170819084718_drop_employee_doctors.exs | 0 ...0822135340_add_mountain_group_not_null.exs | 0 ...823151548_add_type_to_ukr_med_registry.exs | 0 .../20170907104216_create_medications.exs | 0 .../20170907151543_create_innms.exs | 0 .../20170907151544_create_substances.exs | 0 ...70919072307_drop_party_user_duplicates.exs | 0 ...0920073508_add_unique_index_to_parties.exs | 0 ...110329_add_unique_index_to_party_users.exs | 0 .../20170922121046_create_medical_program.exs | 0 .../migrations/20170925124321_drop_innms.exs | 0 .../20170925124518_create_ingredients.exs | 0 ...e_substance_to_innm_update_ingredients.exs | 0 ...171004120857_create_program_medication.exs | 0 ...20171026104218_create_black_list_users.exs | 0 .../20171107222344_add_unique_indexes.exs | 0 ...0171206121408_add_no_tax_id_to_parties.exs | 0 ...03_add_optional_fields_to_legal_entity.exs | 0 .../ehealth/priv}/prm_repo/seeds.exs | 0 apps/ehealth/priv/repo/.DS_Store | Bin 0 -> 6148 bytes apps/ehealth/priv/repo/fixtures/.DS_Store | Bin 0 -> 6148 bytes .../priv}/repo/fixtures/dictionaries.json | 0 .../ehealth/priv}/repo/migrations/.gitkeep | 0 ...0170426122440_create_employee_requests.exs | 0 ...0504070542_add_employee_request_status.exs | 0 ...0516133632_create_declaration_requests.exs | 0 ...0110826_create_dictionaries_dictionary.exs | 0 ...040_add_columns_to_declaration_request.exs | 0 ...626120315_remove_documents_as_required.exs | 0 ...15104052_credentials_recovery_requests.exs | 0 ...45_add_employee_id_to_employee_request.exs | 0 ...5004_add_employee_dictionary_constants.exs | 0 ...declaration_id_to_declaration_requests.exs | 0 ...170828072457_change_kveds_dictionaries.exs | 0 ...344_create_medication_request_requests.exs | 0 .../20170918100201_add_new_division_types.exs | 0 ...x_to_medication_request_request_number.exs | 0 ...010125858_add_verification_code_to_mrr.exs | 0 ...14338_add_medication_request_id_to_mrr.exs | 0 ..._content_to_text_in_declaraion_request.exs | 0 ...rename_number_to_request_number_in_mrr.exs | 0 .../20171107214517_add_unique_indexes.exs | 0 {priv => apps/ehealth/priv}/repo/seeds.exs | 0 .../ehealth/release_notes}/.txt | 0 .../ehealth/release_notes}/0.5.1.txt | 0 .../ehealth/release_notes}/0.6.0.txt | 0 .../ehealth/release_notes}/6.37.0.txt | 0 .../ehealth/release_notes}/6.43.0.txt | 0 .../ehealth/release_notes}/7.0.0.txt | 0 .../ehealth/release_notes}/7.13.0.txt | 0 .../ehealth/release_notes}/7.14.0.txt | 0 .../ehealth/release_notes}/7.16.0.txt | 0 .../ehealth/release_notes}/7.2.0.txt | 0 .../ehealth/release_notes}/7.21.0.txt | 0 .../ehealth/release_notes}/7.23.0.txt | 0 .../ehealth/release_notes}/7.5.0.txt | 0 .../ehealth/release_notes}/7.7.0.txt | 0 .../ehealth/release_notes}/7.8.0.txt | 0 .../ehealth/specs}/database_schema/mpi.erd | 0 .../ehealth/specs}/database_schema/prm.erd | 0 .../ehealth/specs}/database_schema/prm.sql | 0 .../specs}/database_schema/reporting.erd | 0 .../specs}/declaration_request_process.md | 0 .../ehealth/specs}/json_schemas/README.md | 0 .../declaration_request_create_request.json | 0 .../declaration_request_list_response.json | 0 .../declaration_request_show_response.json | 0 .../division/division_create_request.json | 0 .../employee_doctor_create_request.json | 0 .../employee/employee_list_response.json | 0 .../employee_pharmacist_create_request.json | 0 .../employee/employee_show_response.json | 0 .../employee_request_create_request.json | 0 .../innm/innm_create_request.json | 0 .../json_schemas/innm/innm_list_response.json | 0 .../json_schemas/innm/innm_show_response.json | 0 .../innm_dosage_create_request.json | 0 .../innm_dosage_show_response.json | 0 .../legal_entity_create_request.json | 0 .../legal_entity_list_response.json | 0 .../medical_program_create_request.json | 0 .../medical_program_list_response.json | 0 .../medical_program_show_response.json | 0 .../medication/medication_create_request.json | 0 .../medication_dispense_create_request.json | 0 .../medication_dispense_list_response.json | 6 +- .../medication_dispense_show_response.json | 3 +- .../medication_request_list_response.json | 3 +- .../medication_request_qualify_request.json | 0 .../medication_request_qualify_response.json | 0 .../medication_request_show_response.json | 3 +- ...cation_request_request_create_request.json | 0 ...ication_request_request_list_response.json | 0 ...on_request_request_prequalify_request.json | 0 ...n_request_request_prequalify_response.json | 0 ...ication_request_request_show_response.json | 0 ...dication_request_request_sign_request.json | 0 .../party_user/party_user_list_response.json | 0 .../program_medication_create_request.json | 0 .../program_medication_show_response.json | 0 .../program_medication_update_request.json | 0 apps/ehealth/test/data/.DS_Store | Bin 0 -> 6148 bytes .../test}/data/declaration_request.json | 0 .../test/data/declaration_request/.DS_Store | Bin 0 -> 6148 bytes .../declaration_request/sign_request.json | 0 .../ehealth/test}/data/division.json | 0 .../test}/data/employee_doctor_request.json | 0 .../data/employee_pharmacist_request.json | 0 .../ehealth/test}/data/legal_entity.json | 0 .../medication_request_request.json | 0 .../test}/data/sign_declaration_request.json | 0 .../ehealth/test}/data/signed_content.json | 0 .../ehealth/test}/data/signed_content.txt | 0 ...gned_content_invalid_owner_birth_date.json | 0 ...igned_content_invalid_owner_birth_date.txt | 0 .../data/signed_content_invalid_tax_id.txt | 0 .../test}/data/signed_content_no_security.txt | 0 .../test}/data/signed_content_whitespace.txt | 0 .../approving_declaration_request_test.exs | 0 .../corrupt_chain_notification_test.exs | 0 .../creating_declaration_request_test.exs | 0 .../declaration_request/api/approve_test.exs | 0 .../declaration_request/api/create_test.exs | 0 .../declaration_request/api/reject_test.exs | 0 .../declaration_request/api/sign_test.exs | 0 .../deduplicating_persons_test.exs | 0 .../test}/integration/dictionaries_test.exs | 0 .../rejecting_declaration_request_test.exs | 0 .../ehealth/test}/support/conn_case.ex | 0 .../ehealth/test}/support/factories.ex | 0 .../ehealth/test}/support/fixtures.ex | 0 .../declaration_request_factory.ex | 0 .../il_factories/dictionary_factory.ex | 0 .../il_factories/employee_request_factory.ex | 0 .../test}/support/microservices_helper.ex | 0 .../ehealth/test}/support/mock_server.ex | 0 .../test}/support/octet_stream_parser.ex | 0 .../prm_factories/black_list_user_factory.ex | 0 .../support/prm_factories/division_factory.ex | 0 .../support/prm_factories/employee_factory.ex | 0 .../prm_factories/global_parameter_factory.ex | 0 .../prm_factories/legal_entity_factory.ex | 0 .../prm_factories/medical_program_factory.ex | 0 .../medical_service_provider_factory.ex | 0 .../prm_factories/medication_factory.ex | 0 .../support/prm_factories/party_factory.ex | 0 .../prm_factories/ukr_med_registries.ex | 0 .../ehealth/test}/support/simple_factory.ex | 0 {test => apps/ehealth/test}/test_helper.exs | 8 +- .../test}/unit/address_merger_test.exs | 0 .../api/helpers/microservice_base_test.exs | 0 .../test}/unit/api/media_storage_test.exs | 0 .../api/documents_test.exs | 0 .../declaration_request/api/helpers_test.exs | 0 .../api/validate_person_test.exs | 0 .../api/validations_test.exs | 0 .../unit/declaration_request/api_test.exs | 0 .../ehealth/test}/unit/declarations_test.exs | 0 .../test}/unit/digital_signature_test.exs | 0 .../test}/unit/divisions/divisions_test.exs | 0 .../unit/employee/employee_creator_test.exs | 0 .../unit/employee/user_role_creator_test.exs | 0 .../employee_requests_test.exs | 0 .../test}/unit/legal_entity/api_test.exs | 0 .../unit/legal_entity/validator_test.exs | 0 .../ehealth/test}/unit/legal_entity_test.exs | 0 .../test}/unit/medical_program/api_test.exs | 0 .../test}/unit/medication/api_test.exs | 0 .../medication_request_requests_test.exs | 0 .../ehealth/test}/unit/mithril_api_test.exs | 0 .../ehealth/test}/unit/oauth_test.exs | 0 .../test}/unit/postmark_adapter_test.exs | 0 .../ehealth/test}/unit/uaddresses_test.exs | 0 .../human_readable_number_generator_test.exs | 0 .../ehealth/test}/unit/utils/phone_test.exs | 0 .../ehealth/test}/unit/validator_test.exs | 0 .../unit/validators/json_objects_test.exs | 0 .../test}/unit/validators/tax_id_test.exs | 0 .../black_list_user_controller_test.exs | 0 .../controllers/client_controller_test.exs | 0 .../declaration_request_controller_test.exs | 0 .../declarations_controller_test.exs | 0 .../dictionary_controller_test.exs | 0 .../controllers/divisions_controller_test.exs | 0 .../employee_request_controller_test.exs | 0 .../controllers/employees_controller_test.exs | 0 .../global_parameter_controller_test.exs | 0 .../legal_entity_controller_test.exs | 0 .../medical_program_controller_test.exs | 0 .../medication/innm_controller_test.exs | 0 .../innm_dosage_controller_test.exs | 0 .../medication/medication_controller_test.exs | 0 .../program_medication_controller_test.exs | 0 .../medication_dispense_controller_test.exs | 0 .../medication_request_controller_test.exs | 0 ...cation_request_request_controller_test.exs | 0 .../party_user_controller_test.exs | 0 .../controllers/person_controller_test.exs | 0 .../uaddresses_controller_test.exs | 0 .../web/controllers/user_controller_test.exs | 0 .../controllers/user_role_controller_test.exs | 0 bin/ci/rel/build-container.sh | 10 + bin/ci/rel/fetch-project-environment.sh | 5 + bin/ci/rel/push-changes.sh | 49 ++++ bin/ci/release | 2 +- bin/ci/release.sh | 2 +- bin/hooks/pre-start.sh | 4 +- bin/mix_tests.sh | 14 +- config/.credo.exs | 4 +- config/config.exs | 264 +----------------- coveralls.json | 6 +- mix.exs | 110 +------- mix.lock | 18 +- 479 files changed, 551 insertions(+), 400 deletions(-) create mode 100644 apps/ehealth/.gitignore create mode 100644 apps/ehealth/README.md create mode 100644 apps/ehealth/config/config.exs rename {config => apps/ehealth/config}/dev.exs (100%) rename {config => apps/ehealth/config}/prod.exs (100%) rename {config => apps/ehealth/config}/test.exs (100%) create mode 100644 apps/ehealth/coveralls.json rename lib/ehealth/application.ex => apps/ehealth/lib/ehealth.ex (93%) rename {lib => apps/ehealth/lib}/ehealth/api/gandalf.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/headers_processor.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/helpers/microservice_base.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/helpers/signed_content.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/man.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/media_storage.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/mithril.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/mpi.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/ops.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/otp_verification.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/response_decoder.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/signature.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/api/uaddress.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/bamboo/emails/sender.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/bamboo/mailer.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/bamboo/mailgun_adapter.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/bamboo/postmark_adapter.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/bamboo/smtp_adapter.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/black_list_users/black_list_user.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/black_list_users/black_list_users.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/black_list_users/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api/approve.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api/create.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api/documents.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api/helpers.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api/resend_otp.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api/sign.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api/validate_person.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/api/validations.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/schema.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declaration_request/sign_request.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declarations/api.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declarations/person.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/declarations/view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/dictionaries/dictionaries.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/dictionaries/dictionary.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/dictionaries/dictionary_search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/divisions/division.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/divisions/divisions.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/divisions/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/divisions/uaddress.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/duplicate_persons.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/duplicate_persons/cleanup.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/duplicate_persons/signals.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/ecto/comma_param_uuid.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/ecto/string_like.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employee_requests/employee_request.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employee_requests/employee_requests.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employee_requests/validator.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employees/employee.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employees/employee_creator.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employees/employee_updater.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employees/employees.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employees/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employees/user_create_request.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/employees/user_role_creator.ex (100%) rename {lib/ehealth/web => apps/ehealth/lib/ehealth}/endpoint.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/event_manager/event.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/event_manager/event_manager.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/event_manager_repo.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/fraud_repo.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/global_parameters/global_parameter.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/global_parameters/global_parameters.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/hash_chain/verification.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/legal_entities.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/legal_entity.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/legal_entity_request.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/legal_entity_updater.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/medical_service_provider.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/registries.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/registry.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/legal_entities/validator.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/logger_json.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/man/templates/credentials_recovery_request.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/man/templates/declaration_request_printout_form.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/man/templates/employee_created_notification.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/man/templates/employee_request_invitation.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/man/templates/employee_request_update_invitation.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/man/templates/hash_chain_verification_notification.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medical_programs/medical_program.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medical_programs/medical_programs.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medical_programs/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_dispenses/api.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_dispenses/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_dispenses/search_by_medication_request.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/api.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/create_data_operation.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/human_readable_number_generator.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/operation.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/operation_helpers.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/preload_fk_operation.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/reject_operation.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/schema.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/sign_operation.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_request_requests/validations.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_requests/api.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_requests/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medication_requests/sms_sender.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/drugs_search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/innm/innm.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/innm/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/innm_dosage/ingredient.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/innm_dosage/innm_dosage.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/innm_dosage/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/medication/ingredient.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/medication/medication.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/medication/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/medications.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/program/program.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/program/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/medications/validator.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/oauth/api.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/parties/document.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/parties/parties.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/parties/party.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/parties/phone.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/parties/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/party_users/party_user.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/party_users/party_users.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/party_users/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/plugs/client_context.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/plugs/headers.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/postgres_types.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/prm_repo.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/repo.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/scheduler.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/search.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/users/api.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/users/credentials_recovery_request.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/utils/address_merger.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/utils/connection.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/utils/helpers.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/utils/map_deep_merge.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/utils/phone.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/utils/types_converter.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/validators/addresses.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/validators/birth_date.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/validators/json_objects.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/validators/json_schema.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/validators/kveds.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/validators/reference.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/validators/schema_mapper.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/validators/tax_id.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/black_list_user_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/client_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/declaration_request_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/declarations_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/deduplication_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/dictionary_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/division_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/employee_request_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/employees_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/fallback_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/global_parameter_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/hash_chain_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/legal_entity_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/medical_program_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/medication/innm_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/medication/innm_dosage_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/medication/medication_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/medication/program_medication_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/medication_dispense_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/medication_request_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/medication_request_request_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/party_user_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/person_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/uaddresses_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/user_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/controllers/user_role_controller.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/proxy.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/router.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/black_list_user_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/changeset_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/declaration_request_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/dictionary_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/division_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/employee_request_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/employee_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/global_parameter_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/hash_chain.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/legal_entity_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/medical_program_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/medication/innm_dosage_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/medication/innm_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/medication/medication_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/medication/program_medication_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/medication_dispense_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/medication_request_request_view.ex (98%) rename {lib => apps/ehealth/lib}/ehealth/web/views/medication_request_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/party_user_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/party_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/person_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/user_role_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/views/user_view.ex (100%) rename {lib => apps/ehealth/lib}/ehealth/web/web.ex (100%) rename {lib => apps/ehealth/lib}/tasks/tasks.ex (97%) create mode 100644 apps/ehealth/mix.exs rename {priv => apps/ehealth/priv}/event_manager_repo/migrations/.gitkeep (100%) rename {priv => apps/ehealth/priv}/event_manager_repo/migrations/20171127145251_create_audit_log.exs (100%) rename {priv => apps/ehealth/priv}/event_manager_repo/migrations/20171127154946_create_events.exs (100%) rename {priv => apps/ehealth/priv}/event_manager_repo/migrations/20171208103336_change_event_id.exs (100%) rename {priv => apps/ehealth/priv}/event_manager_repo/migrations/20171208153626_add_events_primary_key.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171024084720_enable_postgis.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171024124214_create_legal_entities.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171024125331_create_divisions.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171024143002_create_employees.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171024151305_create_parties.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171024153405_create_party_users.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171024195147_create_audit_log.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171025134148_create_declarations.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171025135225_create_declaration_status_hstr.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171025135518_create_declaration_requests.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171025142220_create_employee_requests.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171025144300_create_dictionaries.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171025145845_create_persons.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171031090345_create_black_list_users.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171106132511_create_mpi_audit_log.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171115162153_drop_parties_fields.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171116081857_drop_persons_fields.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171121142127_drop_parties_phones.exs (100%) rename {priv => apps/ehealth/priv}/fraud_repo/migrations/20171211093621_add_parties_no_tax_id.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/fixtures/global_parameters.json (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/.gitkeep (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170413123306_create_entities_division.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170413123307_create_entities_msp.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170413123308_create_entities_legal_entity.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170413124601_entities_relations.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170414155832_add_unique_for_legal_entity_edrpou.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170417155741_create_parties_party.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170419075231_create_employees.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170419075232_create_employee_doctor.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170420110826_create_dictionaries_dictionary.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170421104735_create_registries_ukr_med.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170427103609_rename_msp_license_to_licenses.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170427114030_rename_divisions_address_to_addresses.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170510164524_add_employee_status_reason.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170510164543_add_legal_entity_created_by_mis_client_id.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170511133900_change_employees_date_types.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170511154159_create_global_parameters.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170522114501_create_parties_party_user.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170523113838_remove_dictionaries.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170524080809_rename_party_users.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170525101522_rename_party_users_indexes.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170606171448_enable_postgis.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170606171954_add_location_to_prm.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170606203443_added_to_division_status.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170607084728_added_to_division_is_active.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170615114013_create_audit_log_table.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170615155026_set_msp_accreditation_nullable.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170623132140_remove_party_user_id_unique_index.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170704135447_add_mis_verified_to_legal_entity.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170704143635_add_nhs_verified_to_legal_entitiy.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170720122501_change_division_mountain_group.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170817084648_add_party_users_index.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170819084718_drop_employee_doctors.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170822135340_add_mountain_group_not_null.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170823151548_add_type_to_ukr_med_registry.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170907104216_create_medications.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170907151543_create_innms.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170907151544_create_substances.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170919072307_drop_party_user_duplicates.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170920073508_add_unique_index_to_parties.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170920110329_add_unique_index_to_party_users.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170922121046_create_medical_program.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170925124321_drop_innms.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170925124518_create_ingredients.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20170927101510_rename_substance_to_innm_update_ingredients.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20171004120857_create_program_medication.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20171026104218_create_black_list_users.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20171107222344_add_unique_indexes.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20171206121408_add_no_tax_id_to_parties.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/migrations/20180119121203_add_optional_fields_to_legal_entity.exs (100%) rename {priv => apps/ehealth/priv}/prm_repo/seeds.exs (100%) create mode 100644 apps/ehealth/priv/repo/.DS_Store create mode 100644 apps/ehealth/priv/repo/fixtures/.DS_Store rename {priv => apps/ehealth/priv}/repo/fixtures/dictionaries.json (100%) rename {priv => apps/ehealth/priv}/repo/migrations/.gitkeep (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170426122440_create_employee_requests.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170504070542_add_employee_request_status.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170516133632_create_declaration_requests.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170520110826_create_dictionaries_dictionary.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170613133040_add_columns_to_declaration_request.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170626120315_remove_documents_as_required.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170715104052_credentials_recovery_requests.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170801131945_add_employee_id_to_employee_request.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170821125004_add_employee_dictionary_constants.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170825120151_add_declaration_id_to_declaration_requests.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170828072457_change_kveds_dictionaries.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170911120344_create_medication_request_requests.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20170918100201_add_new_division_types.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20171009153604_add_unique_index_to_medication_request_request_number.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20171010125858_add_verification_code_to_mrr.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20171018214338_add_medication_request_id_to_mrr.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20171029174045_change_printout_content_to_text_in_declaraion_request.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20171101153320_rename_number_to_request_number_in_mrr.exs (100%) rename {priv => apps/ehealth/priv}/repo/migrations/20171107214517_add_unique_indexes.exs (100%) rename {priv => apps/ehealth/priv}/repo/seeds.exs (100%) rename {release_notes => apps/ehealth/release_notes}/.txt (100%) rename {release_notes => apps/ehealth/release_notes}/0.5.1.txt (100%) rename {release_notes => apps/ehealth/release_notes}/0.6.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/6.37.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/6.43.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.0.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.13.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.14.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.16.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.2.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.21.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.23.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.5.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.7.0.txt (100%) rename {release_notes => apps/ehealth/release_notes}/7.8.0.txt (100%) rename {specs => apps/ehealth/specs}/database_schema/mpi.erd (100%) rename {specs => apps/ehealth/specs}/database_schema/prm.erd (100%) rename {specs => apps/ehealth/specs}/database_schema/prm.sql (100%) rename {specs => apps/ehealth/specs}/database_schema/reporting.erd (100%) rename {specs => apps/ehealth/specs}/declaration_request_process.md (100%) rename {specs => apps/ehealth/specs}/json_schemas/README.md (100%) rename {specs => apps/ehealth/specs}/json_schemas/declaration_request/declaration_request_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/declaration_request/declaration_request_list_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/declaration_request/declaration_request_show_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/division/division_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/employee/employee_doctor_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/employee/employee_list_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/employee/employee_pharmacist_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/employee/employee_show_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/employee_request/employee_request_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/innm/innm_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/innm/innm_list_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/innm/innm_show_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/innm_dosage/innm_dosage_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/innm_dosage/innm_dosage_show_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/legal_entity/legal_entity_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/legal_entity/legal_entity_list_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medical_program/medical_program_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medical_program/medical_program_list_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medical_program/medical_program_show_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication/medication_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_dispense/medication_dispense_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_dispense/medication_dispense_list_response.json (99%) rename {specs => apps/ehealth/specs}/json_schemas/medication_dispense/medication_dispense_show_response.json (99%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request/medication_request_list_response.json (99%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request/medication_request_qualify_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request/medication_request_qualify_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request/medication_request_show_response.json (99%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request_request/medication_request_request_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request_request/medication_request_request_list_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request_request/medication_request_request_prequalify_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request_request/medication_request_request_prequalify_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request_request/medication_request_request_show_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/medication_request_request/medication_request_request_sign_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/party_user/party_user_list_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/program_medication/program_medication_create_request.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/program_medication/program_medication_show_response.json (100%) rename {specs => apps/ehealth/specs}/json_schemas/program_medication/program_medication_update_request.json (100%) create mode 100644 apps/ehealth/test/data/.DS_Store rename {test => apps/ehealth/test}/data/declaration_request.json (100%) create mode 100644 apps/ehealth/test/data/declaration_request/.DS_Store rename {test => apps/ehealth/test}/data/declaration_request/sign_request.json (100%) rename {test => apps/ehealth/test}/data/division.json (100%) rename {test => apps/ehealth/test}/data/employee_doctor_request.json (100%) rename {test => apps/ehealth/test}/data/employee_pharmacist_request.json (100%) rename {test => apps/ehealth/test}/data/legal_entity.json (100%) rename {test => apps/ehealth/test}/data/medication_request_request/medication_request_request.json (100%) rename {test => apps/ehealth/test}/data/sign_declaration_request.json (100%) rename {test => apps/ehealth/test}/data/signed_content.json (100%) rename {test => apps/ehealth/test}/data/signed_content.txt (100%) rename {test => apps/ehealth/test}/data/signed_content_invalid_owner_birth_date.json (100%) rename {test => apps/ehealth/test}/data/signed_content_invalid_owner_birth_date.txt (100%) rename {test => apps/ehealth/test}/data/signed_content_invalid_tax_id.txt (100%) rename {test => apps/ehealth/test}/data/signed_content_no_security.txt (100%) rename {test => apps/ehealth/test}/data/signed_content_whitespace.txt (100%) rename {test => apps/ehealth/test}/integration/approving_declaration_request_test.exs (100%) rename {test => apps/ehealth/test}/integration/corrupt_chain_notification_test.exs (100%) rename {test => apps/ehealth/test}/integration/creating_declaration_request_test.exs (100%) rename {test => apps/ehealth/test}/integration/declaration_request/api/approve_test.exs (100%) rename {test => apps/ehealth/test}/integration/declaration_request/api/create_test.exs (100%) rename {test => apps/ehealth/test}/integration/declaration_request/api/reject_test.exs (100%) rename {test => apps/ehealth/test}/integration/declaration_request/api/sign_test.exs (100%) rename {test => apps/ehealth/test}/integration/deduplicating_persons_test.exs (100%) rename {test => apps/ehealth/test}/integration/dictionaries_test.exs (100%) rename {test => apps/ehealth/test}/integration/rejecting_declaration_request_test.exs (100%) rename {test => apps/ehealth/test}/support/conn_case.ex (100%) rename {test => apps/ehealth/test}/support/factories.ex (100%) rename {test => apps/ehealth/test}/support/fixtures.ex (100%) rename {test => apps/ehealth/test}/support/il_factories/declaration_request_factory.ex (100%) rename {test => apps/ehealth/test}/support/il_factories/dictionary_factory.ex (100%) rename {test => apps/ehealth/test}/support/il_factories/employee_request_factory.ex (100%) rename {test => apps/ehealth/test}/support/microservices_helper.ex (100%) rename {test => apps/ehealth/test}/support/mock_server.ex (100%) rename {test => apps/ehealth/test}/support/octet_stream_parser.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/black_list_user_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/division_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/employee_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/global_parameter_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/legal_entity_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/medical_program_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/medical_service_provider_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/medication_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/party_factory.ex (100%) rename {test => apps/ehealth/test}/support/prm_factories/ukr_med_registries.ex (100%) rename {test => apps/ehealth/test}/support/simple_factory.ex (100%) rename {test => apps/ehealth/test}/test_helper.exs (66%) rename {test => apps/ehealth/test}/unit/address_merger_test.exs (100%) rename {test => apps/ehealth/test}/unit/api/helpers/microservice_base_test.exs (100%) rename {test => apps/ehealth/test}/unit/api/media_storage_test.exs (100%) rename {test => apps/ehealth/test}/unit/declaration_request/api/documents_test.exs (100%) rename {test => apps/ehealth/test}/unit/declaration_request/api/helpers_test.exs (100%) rename {test => apps/ehealth/test}/unit/declaration_request/api/validate_person_test.exs (100%) rename {test => apps/ehealth/test}/unit/declaration_request/api/validations_test.exs (100%) rename {test => apps/ehealth/test}/unit/declaration_request/api_test.exs (100%) rename {test => apps/ehealth/test}/unit/declarations_test.exs (100%) rename {test => apps/ehealth/test}/unit/digital_signature_test.exs (100%) rename {test => apps/ehealth/test}/unit/divisions/divisions_test.exs (100%) rename {test => apps/ehealth/test}/unit/employee/employee_creator_test.exs (100%) rename {test => apps/ehealth/test}/unit/employee/user_role_creator_test.exs (100%) rename {test => apps/ehealth/test}/unit/employee_requests/employee_requests_test.exs (100%) rename {test => apps/ehealth/test}/unit/legal_entity/api_test.exs (100%) rename {test => apps/ehealth/test}/unit/legal_entity/validator_test.exs (100%) rename {test => apps/ehealth/test}/unit/legal_entity_test.exs (100%) rename {test => apps/ehealth/test}/unit/medical_program/api_test.exs (100%) rename {test => apps/ehealth/test}/unit/medication/api_test.exs (100%) rename {test => apps/ehealth/test}/unit/medication_request_requests/medication_request_requests_test.exs (100%) rename {test => apps/ehealth/test}/unit/mithril_api_test.exs (100%) rename {test => apps/ehealth/test}/unit/oauth_test.exs (100%) rename {test => apps/ehealth/test}/unit/postmark_adapter_test.exs (100%) rename {test => apps/ehealth/test}/unit/uaddresses_test.exs (100%) rename {test => apps/ehealth/test}/unit/utils/human_readable_number_generator_test.exs (100%) rename {test => apps/ehealth/test}/unit/utils/phone_test.exs (100%) rename {test => apps/ehealth/test}/unit/validator_test.exs (100%) rename {test => apps/ehealth/test}/unit/validators/json_objects_test.exs (100%) rename {test => apps/ehealth/test}/unit/validators/tax_id_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/black_list_user_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/client_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/declaration_request_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/declarations_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/dictionary_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/divisions_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/employee_request_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/employees_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/global_parameter_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/legal_entity_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/medical_program_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/medication/innm_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/medication/innm_dosage_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/medication/medication_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/medication/program_medication_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/medication_dispense_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/medication_request_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/medication_request_request_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/party_user_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/person_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/uaddresses_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/user_controller_test.exs (100%) rename {test => apps/ehealth/test}/web/controllers/user_role_controller_test.exs (100%) create mode 100755 bin/ci/rel/build-container.sh create mode 100755 bin/ci/rel/fetch-project-environment.sh create mode 100755 bin/ci/rel/push-changes.sh diff --git a/.formatter.exs b/.formatter.exs index 50bad8c5c..d10d64aa7 100644 --- a/.formatter.exs +++ b/.formatter.exs @@ -1,8 +1,5 @@ +# Used by "mix format" [ - inputs: [ - "{config,lib,test,rel,priv}/**/*.{ex,exs}", - "mix.exs", - ".formatter.exs" - ], + inputs: ["mix.exs", "apps/*/mix.exs", "apps/*/{config,lib,test}/**/*.{ex,exs}"], line_length: 120 ] diff --git a/.travis.yml b/.travis.yml index 0271d3442..e9db318ee 100644 --- a/.travis.yml +++ b/.travis.yml @@ -40,7 +40,7 @@ before_install: - sudo ./bin/ci/init-db.sh before_script: # Extract project name and version from mix.exs - - source ./bin/ci/release/fetch-project-environment.sh + - source ./bin/ci/rel/fetch-project-environment.sh # Load information about new version - source ./bin/ci/release/fetch-source-version.sh # Load information about changelog @@ -55,14 +55,14 @@ script: # Run all tests except pending ones - ./bin/mix_tests.sh || travis_terminate 1 # Build Docker container - - ./bin/ci/release/build-container.sh || travis_terminate 1 + - ./bin/ci/rel/build-container.sh || travis_terminate 1 # Initialize DB for Docker container - - MIX_ENV=dev mix ecto.setup + - (cd apps/ehealth && MIX_ENV=dev mix ecto.setup) # Run Docker container - sudo ./bin/ci/release/start-container.sh - sudo ./bin/ci/release/check-container.sh || travis_terminate # Submit Docker container to Docker Hub and create GitHub Release by pushing tag with changelog - - ./bin/ci/release/push-changes.sh || travis_terminate 1 + - ./bin/ci/rel/push-changes.sh || travis_terminate 1 - echo "Decrypting deploy key..." - openssl aes-256-cbc -K $encrypted_c996ec964e08_key -iv $encrypted_c996ec964e08_iv -in eHealth-8110bd102a69.json.enc -out eHealth-8110bd102a69.json -d - sudo ./bin/deploy.sh || travis_terminate 1 diff --git a/apps/ehealth/.gitignore b/apps/ehealth/.gitignore new file mode 100644 index 000000000..e93c7dda7 --- /dev/null +++ b/apps/ehealth/.gitignore @@ -0,0 +1,17 @@ +# App artifacts +/_build +/db +/deps +/*.ez + +# Generated on crash by the VM +erl_crash.dump + +# Files matching config/*.secret.exs pattern contain sensitive +# data and you should not commit them into version control. +# +# Alternatively, you may comment the line below and commit the +# secrets files as long as you replace their contents by environment +# variables. +/config/*.secret.exs +/cover \ No newline at end of file diff --git a/apps/ehealth/README.md b/apps/ehealth/README.md new file mode 100644 index 000000000..892a6dd56 --- /dev/null +++ b/apps/ehealth/README.md @@ -0,0 +1,19 @@ +# EHealth + +To start your Phoenix app: + + * Install dependencies with `mix deps.get` + * Create and migrate your database with `mix ecto.create && mix ecto.migrate` + * Start Phoenix endpoint with `mix phoenix.server` + +Now you can visit [`localhost:4000`](http://localhost:4000) from your browser. + +Ready to run in production? Please [check our deployment guides](http://www.phoenixframework.org/docs/deployment). + +## Learn more + + * Official website: http://www.phoenixframework.org/ + * Guides: http://phoenixframework.org/docs/overview + * Docs: https://hexdocs.pm/phoenix + * Mailing list: http://groups.google.com/group/phoenix-talk + * Source: https://github.com/phoenixframework/phoenix diff --git a/apps/ehealth/config/config.exs b/apps/ehealth/config/config.exs new file mode 100644 index 000000000..01c2b5b8f --- /dev/null +++ b/apps/ehealth/config/config.exs @@ -0,0 +1,251 @@ +use Mix.Config + +# General application configuration +config :ehealth, + env: Mix.env(), + namespace: EHealth, + ecto_repos: [EHealth.Repo, EHealth.PRMRepo, EHealth.FraudRepo, EHealth.EventManagerRepo], + run_declaration_request_terminator: true, + system_user: {:system, "EHEALTH_SYSTEM_USER", "4261eacf-8008-4e62-899f-de1e2f7065f0"} + +# Configures the endpoint +config :ehealth, EHealth.Web.Endpoint, + url: [host: "localhost"], + secret_key_base: "AcugHtFljaEFhBY1d6opAasbdFYsvV8oydwW98qS0oZOv+N/a5TE5G7DPfTZcXm9", + render_errors: [view: EView.Views.PhoenixError, accepts: ~w(json)] + +# Configures Digital Signature API +config :ehealth, EHealth.API.Signature, + enabled: {:system, :boolean, "DIGITAL_SIGNATURE_ENABLED", true}, + endpoint: {:system, "DIGITAL_SIGNATURE_ENDPOINT"}, + hackney_options: [ + connect_timeout: {:system, :integer, "DIGITAL_SIGNATURE_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "DIGITAL_SIGNATURE_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "DIGITAL_SIGNATURE_REQUEST_TIMEOUT", 30_000} + ] + +# Configures MediaStorage API +config :ehealth, EHealth.API.MediaStorage, + endpoint: {:system, "MEDIA_STORAGE_ENDPOINT"}, + legal_entity_bucket: {:system, "MEDIA_STORAGE_LEGAL_ENTITY_BUCKET"}, + declaration_request_bucket: {:system, "MEDIA_STORAGE_DECLARATION_REQUEST_BUCKET"}, + declaration_bucket: {:system, "MEDIA_STORAGE_DECLARATION_BUCKET"}, + medication_request_request_bucket: {:system, "MEDIA_STORAGE_MEDICATION_REQUEST_REQUEST_BUCKET"}, + enabled?: {:system, :boolean, "MEDIA_STORAGE_ENABLED", false}, + hackney_options: [ + connect_timeout: {:system, :integer, "MEDIA_STORAGE_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "MEDIA_STORAGE_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "MEDIA_STORAGE_REQUEST_TIMEOUT", 30_000} + ] + +# Configures PRM API +config :ehealth, EHealth.API.PRM, + endpoint: {:system, "PRM_ENDPOINT", "http://api-svc.prm/api"}, + hackney_options: [ + connect_timeout: {:system, :integer, "PRM_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "PRM_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "PRM_REQUEST_TIMEOUT", 30_000} + ] + +# Configures Legal Entities token permission +config :ehealth, EHealth.Plugs.ClientContext, + tokens_types_personal: {:system, :list, "TOKENS_TYPES_PERSONAL", ["MSP", "PHARMACY"]}, + tokens_types_mis: {:system, :list, "TOKENS_TYPES_MIS", ["MIS"]}, + tokens_types_admin: {:system, :list, "TOKENS_TYPES_ADMIN", ["NHS ADMIN"]} + +# Configures OAuth API +config :ehealth, EHealth.API.Mithril, + endpoint: {:system, "OAUTH_ENDPOINT"}, + hackney_options: [ + connect_timeout: {:system, :integer, "OAUTH_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "OAUTH_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "OAUTH_REQUEST_TIMEOUT", 30_000} + ] + +# Configures Man API +config :ehealth, EHealth.API.Man, + endpoint: {:system, "MAN_ENDPOINT"}, + hackney_options: [ + connect_timeout: {:system, :integer, "MAN_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "MAN_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "MAN_REQUEST_TIMEOUT", 30_000} + ] + +# Configures UAddress API +config :ehealth, EHealth.API.UAddress, + endpoint: {:system, "UADDRESS_ENDPOINT"}, + hackney_options: [ + connect_timeout: {:system, :integer, "UADDRESS_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "UADDRESS_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "UADDRESS_REQUEST_TIMEOUT", 30_000} + ] + +# Configures OTP Verification API +config :ehealth, EHealth.API.OTPVerification, + endpoint: {:system, "OTP_VERIFICATION_ENDPOINT"}, + hackney_options: [ + connect_timeout: {:system, :integer, "OTP_VERIFICATION_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "OTP_VERIFICATION_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "OTP_VERIFICATION_REQUEST_TIMEOUT", 30_000} + ] + +# Configures MPI API +config :ehealth, EHealth.API.MPI, + endpoint: {:system, "MPI_ENDPOINT"}, + hackney_options: [ + connect_timeout: {:system, :integer, "MPI_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "MPI_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "MPI_REQUEST_TIMEOUT", 30_000} + ] + +# Configures OPS API +config :ehealth, EHealth.API.OPS, + endpoint: {:system, "OPS_ENDPOINT"}, + hackney_options: [ + connect_timeout: {:system, :integer, "OPS_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "OPS_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "OPS_REQUEST_TIMEOUT", 30_000} + ] + +# Configures Gandalf API +config :ehealth, EHealth.API.Gandalf, + endpoint: {:system, "GNDF_ENDPOINT"}, + client_id: {:system, "GNDF_CLIENT_ID"}, + client_secret: {:system, "GNDF_CLIENT_SECRET"}, + application_id: {:system, "GNDF_APPLICATION_ID"}, + table_id: {:system, "GNDF_TABLE_ID"}, + hackney_options: [ + connect_timeout: {:system, :integer, "GNDF_REQUEST_TIMEOUT", 30_000}, + recv_timeout: {:system, :integer, "GNDF_REQUEST_TIMEOUT", 30_000}, + timeout: {:system, :integer, "GNDF_REQUEST_TIMEOUT", 30_000} + ] + +# configure emails +config :ehealth, :emails, + employee_request_invitation: %{ + from: {:system, "BAMBOO_EMPLOYEE_REQUEST_INVITATION_FROM", ""}, + subject: {:system, "BAMBOO_EMPLOYEE_REQUEST_INVITATION_SUBJECT", ""} + }, + employee_request_update_invitation: %{ + from: {:system, "BAMBOO_EMPLOYEE_REQUEST_UPDATE_INVITATION_FROM", ""}, + subject: {:system, "BAMBOO_EMPLOYEE_REQUEST_UPDATE_INVITATION_SUBJECT", ""} + }, + hash_chain_verification_notification: %{ + from: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_FROM", ""}, + to: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_TO", ""}, + subject: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_SUBJECT", ""} + }, + employee_created_notification: %{ + from: {:system, "BAMBOO_EMPLOYEE_CREATED_NOTIFICATION_FROM", ""}, + subject: {:system, "BAMBOO_EMPLOYEE_CREATED_NOTIFICATION_SUBJECT", ""} + }, + credentials_recovery_request: %{ + from: {:system, "BAMBOO_CREDENTIALS_RECOVERY_REQUEST_INVITATION_FROM", ""}, + subject: {:system, "BAMBOO_CREDENTIALS_RECOVERY_REQUEST_INVITATION_SUBJECT", ""} + } + +config :ehealth, EHealth.Man.Templates.EmployeeRequestInvitation, + id: {:system, "EMPLOYEE_REQUEST_INVITATION_TEMPLATE_ID"}, + format: {:system, "EMPLOYEE_REQUEST_INVITATION_TEMPLATE_FORMAT", "text/html"}, + locale: {:system, "EMPLOYEE_REQUEST_INVITATION_TEMPLATE_LOCALE", "uk_UA"} + +# Configures employee request update invitation template +config :ehealth, EHealth.Man.Templates.EmployeeRequestUpdateInvitation, + id: {:system, "EMPLOYEE_REQUEST_UPDATE_INVITATION_TEMPLATE_ID"}, + format: {:system, "EMPLOYEE_REQUEST_UPDATE_INVITATION_TEMPLATE_FORMAT", "text/html"}, + locale: {:system, "EMPLOYEE_REQUEST_UPDATE_INVITATION_TEMPLATE_LOCALE", "uk_UA"} + +config :ehealth, EHealth.Man.Templates.HashChainVerificationNotification, + id: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_ID", ""}, + format: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_FORMAT", ""}, + locale: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_LOCALE", ""} + +# employee created notification +# Configures employee created notification template +config :ehealth, EHealth.Man.Templates.EmployeeCreatedNotification, + id: {:system, "EMPLOYEE_CREATED_NOTIFICATION_TEMPLATE_ID"}, + format: {:system, "EMPLOYEE_CREATED_NOTIFICATION_TEMPLATE_FORMAT", "text/html"}, + locale: {:system, "EMPLOYEE_CREATED_NOTIFICATION_TEMPLATE_LOCALE", "uk_UA"} + +config :ehealth, EHealth.Man.Templates.DeclarationRequestPrintoutForm, + id: {:system, "DECLARATION_REQUEST_PRINTOUT_FORM_TEMPLATE_ID"}, + format: {:system, "DECLARATION_REQUEST_PRINTOUT_FORM_TEMPLATE_FORMAT", "text/html"}, + locale: {:system, "DECLARATION_REQUEST_PRINTOUT_FORM_TEMPLATE_LOCALE", "uk_UA"} + +# Template and setting for credentials recovery requests +config :ehealth, :credentials_recovery_request_ttl, {:system, :integer, "CREDENTIALS_RECOVERY_REQUEST_TTL", 1_500} + +config :ehealth, EHealth.Man.Templates.CredentialsRecoveryRequest, + id: {:system, "CREDENTIALS_RECOVERY_REQUEST_INVITATION_TEMPLATE_ID"}, + format: {:system, "CREDENTIALS_RECOVERY_REQUEST_INVITATION_TEMPLATE_FORMAT", "text/html"}, + locale: {:system, "CREDENTIALS_RECOVERY_REQUEST_INVITATION_TEMPLATE_LOCALE", "uk_UA"} + +config :ehealth, :legal_entity_employee_types, + msp: {:system, "LEGAL_ENTITY_MSP_EMPLOYEE_TYPES", ["OWNER", "HR", "DOCTOR", "ADMIN"]}, + pharmacy: {:system, "LEGAL_ENTITY_PHARMACY_EMPLOYEE_TYPES", ["PHARMACY_OWNER", "PHARMACIST", "HR"]} + +config :ehealth, :legal_entity_division_types, + msp: {:system, "LEGAL_ENTITY_MSP_DIVISION_TYPES", ["CLINIC", "AMBULANT_CLINIC", "FAP"]}, + pharmacy: {:system, "LEGAL_ENTITY_PHARMACIST_DIVISION_TYPES", ["DRUGSTORE", "DRUGSTORE_POINT"]} + +config :ehealth, :medication_request_request, + expire_in_minutes: {:system, "MEDICATION_REQUEST_REQUEST_EXPIRATION", 30}, + otp_code_length: {:system, "MEDICATION_REQUEST_REQUEST_OTP_CODE_LENGTH", 4} + +config :ehealth, :medication_request, + sign_template_sms: + {:system, "TEMPLATE_SMS_FOR_SIGN_MEDICATION_REQUEST", + "Ваш рецепт: . Код підтвердження: "}, + reject_template_sms: + {:system, "TEMPLATE_SMS_FOR_REJECT_MEDICATION_REQUEST", "Відкликано рецепт: від "} + +config :ehealth, EHealth.Bamboo.Emails.Sender, mailer: {:system, :module, "BAMBOO_MAILER"} + +# Configures bamboo +config :ehealth, EHealth.Bamboo.PostmarkMailer, + adapter: EHealth.Bamboo.PostmarkAdapter, + api_key: {:system, "POSTMARK_API_KEY", ""} + +config :ehealth, EHealth.Bamboo.MailgunMailer, + adapter: EHealth.Bamboo.MailgunAdapter, + api_key: {:system, "MAILGUN_API_KEY", ""}, + domain: {:system, "MAILGUN_DOMAIN", ""} + +config :ehealth, EHealth.Bamboo.SMTPMailer, + adapter: EHealth.Bamboo.SMTPAdapter, + server: {:system, "BAMBOO_SMTP_SERVER", ""}, + hostname: {:system, "BAMBOO_SMTP_HOSTNAME", ""}, + port: {:system, "BAMBOO_SMTP_PORT", ""}, + username: {:system, "BAMBOO_SMTP_USERNAME", ""}, + password: {:system, "BAMBOO_SMTP_PASSWORD", ""}, + tls: :if_available, + allowed_tls_versions: [:tlsv1, :"tlsv1.1", :"tlsv1.2"], + ssl: true, + retries: 1 + +# Configures address merger +config :ehealth, EHealth.Utils.AddressMerger, no_suffix_areas: {:system, "NO_SUFFIX_AREAS", ["М.КИЇВ", "М.СЕВАСТОПОЛЬ"]} + +# Configures genral validator +config :ehealth, EHealth.LegalEntities.Validator, owner_positions: {:system, :list, "OWNER_POSITIONS", [""]} + +# Configures birth date validator +config :ehealth, EHealth.Validators.BirthDate, + min_age: {:system, "MIN_AGE", 0}, + max_age: {:system, "MAX_AGE", 150} + +# Configures Elixir's Logger +config :logger, :console, + format: "$message\n", + handle_otp_reports: true, + level: :info + +config :ehealth, EHealth.Scheduler, + declaration_request_autotermination: {:system, :string, "DECLARATION_REQUEST_AUTOTERMINATION_SCHEDULE", "* 0-4 * * *"}, + employee_request_autotermination: {:system, :string, "EMPLOYEE_REQUEST_AUTOTERMINATION_SCHEDULE", "0-4 * * *"} + +config :cipher, + keyphrase: System.get_env("CIPHER_KEYPHRASE") || "8()VN#U#_CU#X)*BFG(Cadsvn$&", + ivphrase: System.get_env("CIPHER_IVPHRASE") || "B((%(^(%V(CWBY(**(by(*YCBDYB#(Y(C#" + +import_config "#{Mix.env()}.exs" diff --git a/config/dev.exs b/apps/ehealth/config/dev.exs similarity index 100% rename from config/dev.exs rename to apps/ehealth/config/dev.exs diff --git a/config/prod.exs b/apps/ehealth/config/prod.exs similarity index 100% rename from config/prod.exs rename to apps/ehealth/config/prod.exs diff --git a/config/test.exs b/apps/ehealth/config/test.exs similarity index 100% rename from config/test.exs rename to apps/ehealth/config/test.exs diff --git a/apps/ehealth/coveralls.json b/apps/ehealth/coveralls.json new file mode 100644 index 000000000..8b1607db4 --- /dev/null +++ b/apps/ehealth/coveralls.json @@ -0,0 +1,17 @@ +{ + "skip_files": [ + "specs/*", + "test/*", + "lib/tasks" + ], + "custom_stop_words": [ + "field", + "has_one", + "has_many", + "embeds_one", + "embeds_many", + "schema", + "send" + ], + "treat_no_relevant_lines_as_covered": true +} diff --git a/lib/ehealth/application.ex b/apps/ehealth/lib/ehealth.ex similarity index 93% rename from lib/ehealth/application.ex rename to apps/ehealth/lib/ehealth.ex index 1e32b3056..e511ee0df 100644 --- a/lib/ehealth/application.ex +++ b/apps/ehealth/lib/ehealth.ex @@ -26,8 +26,6 @@ defmodule EHealth do # Start the endpoint when the application starts supervisor(EHealth.Web.Endpoint, []), worker(EHealth.Scheduler, []) - # Starts a worker by calling: EHealth.Worker.start_link(arg1, arg2, arg3) - # worker(EHealth.Worker, [arg1, arg2, arg3]), ] # See http://elixir-lang.org/docs/stable/elixir/Supervisor.html diff --git a/lib/ehealth/api/gandalf.ex b/apps/ehealth/lib/ehealth/api/gandalf.ex similarity index 100% rename from lib/ehealth/api/gandalf.ex rename to apps/ehealth/lib/ehealth/api/gandalf.ex diff --git a/lib/ehealth/api/headers_processor.ex b/apps/ehealth/lib/ehealth/api/headers_processor.ex similarity index 100% rename from lib/ehealth/api/headers_processor.ex rename to apps/ehealth/lib/ehealth/api/headers_processor.ex diff --git a/lib/ehealth/api/helpers/microservice_base.ex b/apps/ehealth/lib/ehealth/api/helpers/microservice_base.ex similarity index 100% rename from lib/ehealth/api/helpers/microservice_base.ex rename to apps/ehealth/lib/ehealth/api/helpers/microservice_base.ex diff --git a/lib/ehealth/api/helpers/signed_content.ex b/apps/ehealth/lib/ehealth/api/helpers/signed_content.ex similarity index 100% rename from lib/ehealth/api/helpers/signed_content.ex rename to apps/ehealth/lib/ehealth/api/helpers/signed_content.ex diff --git a/lib/ehealth/api/man.ex b/apps/ehealth/lib/ehealth/api/man.ex similarity index 100% rename from lib/ehealth/api/man.ex rename to apps/ehealth/lib/ehealth/api/man.ex diff --git a/lib/ehealth/api/media_storage.ex b/apps/ehealth/lib/ehealth/api/media_storage.ex similarity index 100% rename from lib/ehealth/api/media_storage.ex rename to apps/ehealth/lib/ehealth/api/media_storage.ex diff --git a/lib/ehealth/api/mithril.ex b/apps/ehealth/lib/ehealth/api/mithril.ex similarity index 100% rename from lib/ehealth/api/mithril.ex rename to apps/ehealth/lib/ehealth/api/mithril.ex diff --git a/lib/ehealth/api/mpi.ex b/apps/ehealth/lib/ehealth/api/mpi.ex similarity index 100% rename from lib/ehealth/api/mpi.ex rename to apps/ehealth/lib/ehealth/api/mpi.ex diff --git a/lib/ehealth/api/ops.ex b/apps/ehealth/lib/ehealth/api/ops.ex similarity index 100% rename from lib/ehealth/api/ops.ex rename to apps/ehealth/lib/ehealth/api/ops.ex diff --git a/lib/ehealth/api/otp_verification.ex b/apps/ehealth/lib/ehealth/api/otp_verification.ex similarity index 100% rename from lib/ehealth/api/otp_verification.ex rename to apps/ehealth/lib/ehealth/api/otp_verification.ex diff --git a/lib/ehealth/api/response_decoder.ex b/apps/ehealth/lib/ehealth/api/response_decoder.ex similarity index 100% rename from lib/ehealth/api/response_decoder.ex rename to apps/ehealth/lib/ehealth/api/response_decoder.ex diff --git a/lib/ehealth/api/signature.ex b/apps/ehealth/lib/ehealth/api/signature.ex similarity index 100% rename from lib/ehealth/api/signature.ex rename to apps/ehealth/lib/ehealth/api/signature.ex diff --git a/lib/ehealth/api/uaddress.ex b/apps/ehealth/lib/ehealth/api/uaddress.ex similarity index 100% rename from lib/ehealth/api/uaddress.ex rename to apps/ehealth/lib/ehealth/api/uaddress.ex diff --git a/lib/ehealth/bamboo/emails/sender.ex b/apps/ehealth/lib/ehealth/bamboo/emails/sender.ex similarity index 100% rename from lib/ehealth/bamboo/emails/sender.ex rename to apps/ehealth/lib/ehealth/bamboo/emails/sender.ex diff --git a/lib/ehealth/bamboo/mailer.ex b/apps/ehealth/lib/ehealth/bamboo/mailer.ex similarity index 100% rename from lib/ehealth/bamboo/mailer.ex rename to apps/ehealth/lib/ehealth/bamboo/mailer.ex diff --git a/lib/ehealth/bamboo/mailgun_adapter.ex b/apps/ehealth/lib/ehealth/bamboo/mailgun_adapter.ex similarity index 100% rename from lib/ehealth/bamboo/mailgun_adapter.ex rename to apps/ehealth/lib/ehealth/bamboo/mailgun_adapter.ex diff --git a/lib/ehealth/bamboo/postmark_adapter.ex b/apps/ehealth/lib/ehealth/bamboo/postmark_adapter.ex similarity index 100% rename from lib/ehealth/bamboo/postmark_adapter.ex rename to apps/ehealth/lib/ehealth/bamboo/postmark_adapter.ex diff --git a/lib/ehealth/bamboo/smtp_adapter.ex b/apps/ehealth/lib/ehealth/bamboo/smtp_adapter.ex similarity index 100% rename from lib/ehealth/bamboo/smtp_adapter.ex rename to apps/ehealth/lib/ehealth/bamboo/smtp_adapter.ex diff --git a/lib/ehealth/black_list_users/black_list_user.ex b/apps/ehealth/lib/ehealth/black_list_users/black_list_user.ex similarity index 100% rename from lib/ehealth/black_list_users/black_list_user.ex rename to apps/ehealth/lib/ehealth/black_list_users/black_list_user.ex diff --git a/lib/ehealth/black_list_users/black_list_users.ex b/apps/ehealth/lib/ehealth/black_list_users/black_list_users.ex similarity index 100% rename from lib/ehealth/black_list_users/black_list_users.ex rename to apps/ehealth/lib/ehealth/black_list_users/black_list_users.ex diff --git a/lib/ehealth/black_list_users/search.ex b/apps/ehealth/lib/ehealth/black_list_users/search.ex similarity index 100% rename from lib/ehealth/black_list_users/search.ex rename to apps/ehealth/lib/ehealth/black_list_users/search.ex diff --git a/lib/ehealth/declaration_request/api.ex b/apps/ehealth/lib/ehealth/declaration_request/api.ex similarity index 100% rename from lib/ehealth/declaration_request/api.ex rename to apps/ehealth/lib/ehealth/declaration_request/api.ex diff --git a/lib/ehealth/declaration_request/api/approve.ex b/apps/ehealth/lib/ehealth/declaration_request/api/approve.ex similarity index 100% rename from lib/ehealth/declaration_request/api/approve.ex rename to apps/ehealth/lib/ehealth/declaration_request/api/approve.ex diff --git a/lib/ehealth/declaration_request/api/create.ex b/apps/ehealth/lib/ehealth/declaration_request/api/create.ex similarity index 100% rename from lib/ehealth/declaration_request/api/create.ex rename to apps/ehealth/lib/ehealth/declaration_request/api/create.ex diff --git a/lib/ehealth/declaration_request/api/documents.ex b/apps/ehealth/lib/ehealth/declaration_request/api/documents.ex similarity index 100% rename from lib/ehealth/declaration_request/api/documents.ex rename to apps/ehealth/lib/ehealth/declaration_request/api/documents.ex diff --git a/lib/ehealth/declaration_request/api/helpers.ex b/apps/ehealth/lib/ehealth/declaration_request/api/helpers.ex similarity index 100% rename from lib/ehealth/declaration_request/api/helpers.ex rename to apps/ehealth/lib/ehealth/declaration_request/api/helpers.ex diff --git a/lib/ehealth/declaration_request/api/resend_otp.ex b/apps/ehealth/lib/ehealth/declaration_request/api/resend_otp.ex similarity index 100% rename from lib/ehealth/declaration_request/api/resend_otp.ex rename to apps/ehealth/lib/ehealth/declaration_request/api/resend_otp.ex diff --git a/lib/ehealth/declaration_request/api/sign.ex b/apps/ehealth/lib/ehealth/declaration_request/api/sign.ex similarity index 100% rename from lib/ehealth/declaration_request/api/sign.ex rename to apps/ehealth/lib/ehealth/declaration_request/api/sign.ex diff --git a/lib/ehealth/declaration_request/api/validate_person.ex b/apps/ehealth/lib/ehealth/declaration_request/api/validate_person.ex similarity index 100% rename from lib/ehealth/declaration_request/api/validate_person.ex rename to apps/ehealth/lib/ehealth/declaration_request/api/validate_person.ex diff --git a/lib/ehealth/declaration_request/api/validations.ex b/apps/ehealth/lib/ehealth/declaration_request/api/validations.ex similarity index 100% rename from lib/ehealth/declaration_request/api/validations.ex rename to apps/ehealth/lib/ehealth/declaration_request/api/validations.ex diff --git a/lib/ehealth/declaration_request/schema.ex b/apps/ehealth/lib/ehealth/declaration_request/schema.ex similarity index 100% rename from lib/ehealth/declaration_request/schema.ex rename to apps/ehealth/lib/ehealth/declaration_request/schema.ex diff --git a/lib/ehealth/declaration_request/sign_request.ex b/apps/ehealth/lib/ehealth/declaration_request/sign_request.ex similarity index 100% rename from lib/ehealth/declaration_request/sign_request.ex rename to apps/ehealth/lib/ehealth/declaration_request/sign_request.ex diff --git a/lib/ehealth/declarations/api.ex b/apps/ehealth/lib/ehealth/declarations/api.ex similarity index 100% rename from lib/ehealth/declarations/api.ex rename to apps/ehealth/lib/ehealth/declarations/api.ex diff --git a/lib/ehealth/declarations/person.ex b/apps/ehealth/lib/ehealth/declarations/person.ex similarity index 100% rename from lib/ehealth/declarations/person.ex rename to apps/ehealth/lib/ehealth/declarations/person.ex diff --git a/lib/ehealth/declarations/view.ex b/apps/ehealth/lib/ehealth/declarations/view.ex similarity index 100% rename from lib/ehealth/declarations/view.ex rename to apps/ehealth/lib/ehealth/declarations/view.ex diff --git a/lib/ehealth/dictionaries/dictionaries.ex b/apps/ehealth/lib/ehealth/dictionaries/dictionaries.ex similarity index 100% rename from lib/ehealth/dictionaries/dictionaries.ex rename to apps/ehealth/lib/ehealth/dictionaries/dictionaries.ex diff --git a/lib/ehealth/dictionaries/dictionary.ex b/apps/ehealth/lib/ehealth/dictionaries/dictionary.ex similarity index 100% rename from lib/ehealth/dictionaries/dictionary.ex rename to apps/ehealth/lib/ehealth/dictionaries/dictionary.ex diff --git a/lib/ehealth/dictionaries/dictionary_search.ex b/apps/ehealth/lib/ehealth/dictionaries/dictionary_search.ex similarity index 100% rename from lib/ehealth/dictionaries/dictionary_search.ex rename to apps/ehealth/lib/ehealth/dictionaries/dictionary_search.ex diff --git a/lib/ehealth/divisions/division.ex b/apps/ehealth/lib/ehealth/divisions/division.ex similarity index 100% rename from lib/ehealth/divisions/division.ex rename to apps/ehealth/lib/ehealth/divisions/division.ex diff --git a/lib/ehealth/divisions/divisions.ex b/apps/ehealth/lib/ehealth/divisions/divisions.ex similarity index 100% rename from lib/ehealth/divisions/divisions.ex rename to apps/ehealth/lib/ehealth/divisions/divisions.ex diff --git a/lib/ehealth/divisions/search.ex b/apps/ehealth/lib/ehealth/divisions/search.ex similarity index 100% rename from lib/ehealth/divisions/search.ex rename to apps/ehealth/lib/ehealth/divisions/search.ex diff --git a/lib/ehealth/divisions/uaddress.ex b/apps/ehealth/lib/ehealth/divisions/uaddress.ex similarity index 100% rename from lib/ehealth/divisions/uaddress.ex rename to apps/ehealth/lib/ehealth/divisions/uaddress.ex diff --git a/lib/ehealth/duplicate_persons.ex b/apps/ehealth/lib/ehealth/duplicate_persons.ex similarity index 100% rename from lib/ehealth/duplicate_persons.ex rename to apps/ehealth/lib/ehealth/duplicate_persons.ex diff --git a/lib/ehealth/duplicate_persons/cleanup.ex b/apps/ehealth/lib/ehealth/duplicate_persons/cleanup.ex similarity index 100% rename from lib/ehealth/duplicate_persons/cleanup.ex rename to apps/ehealth/lib/ehealth/duplicate_persons/cleanup.ex diff --git a/lib/ehealth/duplicate_persons/signals.ex b/apps/ehealth/lib/ehealth/duplicate_persons/signals.ex similarity index 100% rename from lib/ehealth/duplicate_persons/signals.ex rename to apps/ehealth/lib/ehealth/duplicate_persons/signals.ex diff --git a/lib/ehealth/ecto/comma_param_uuid.ex b/apps/ehealth/lib/ehealth/ecto/comma_param_uuid.ex similarity index 100% rename from lib/ehealth/ecto/comma_param_uuid.ex rename to apps/ehealth/lib/ehealth/ecto/comma_param_uuid.ex diff --git a/lib/ehealth/ecto/string_like.ex b/apps/ehealth/lib/ehealth/ecto/string_like.ex similarity index 100% rename from lib/ehealth/ecto/string_like.ex rename to apps/ehealth/lib/ehealth/ecto/string_like.ex diff --git a/lib/ehealth/employee_requests/employee_request.ex b/apps/ehealth/lib/ehealth/employee_requests/employee_request.ex similarity index 100% rename from lib/ehealth/employee_requests/employee_request.ex rename to apps/ehealth/lib/ehealth/employee_requests/employee_request.ex diff --git a/lib/ehealth/employee_requests/employee_requests.ex b/apps/ehealth/lib/ehealth/employee_requests/employee_requests.ex similarity index 100% rename from lib/ehealth/employee_requests/employee_requests.ex rename to apps/ehealth/lib/ehealth/employee_requests/employee_requests.ex diff --git a/lib/ehealth/employee_requests/validator.ex b/apps/ehealth/lib/ehealth/employee_requests/validator.ex similarity index 100% rename from lib/ehealth/employee_requests/validator.ex rename to apps/ehealth/lib/ehealth/employee_requests/validator.ex diff --git a/lib/ehealth/employees/employee.ex b/apps/ehealth/lib/ehealth/employees/employee.ex similarity index 100% rename from lib/ehealth/employees/employee.ex rename to apps/ehealth/lib/ehealth/employees/employee.ex diff --git a/lib/ehealth/employees/employee_creator.ex b/apps/ehealth/lib/ehealth/employees/employee_creator.ex similarity index 100% rename from lib/ehealth/employees/employee_creator.ex rename to apps/ehealth/lib/ehealth/employees/employee_creator.ex diff --git a/lib/ehealth/employees/employee_updater.ex b/apps/ehealth/lib/ehealth/employees/employee_updater.ex similarity index 100% rename from lib/ehealth/employees/employee_updater.ex rename to apps/ehealth/lib/ehealth/employees/employee_updater.ex diff --git a/lib/ehealth/employees/employees.ex b/apps/ehealth/lib/ehealth/employees/employees.ex similarity index 100% rename from lib/ehealth/employees/employees.ex rename to apps/ehealth/lib/ehealth/employees/employees.ex diff --git a/lib/ehealth/employees/search.ex b/apps/ehealth/lib/ehealth/employees/search.ex similarity index 100% rename from lib/ehealth/employees/search.ex rename to apps/ehealth/lib/ehealth/employees/search.ex diff --git a/lib/ehealth/employees/user_create_request.ex b/apps/ehealth/lib/ehealth/employees/user_create_request.ex similarity index 100% rename from lib/ehealth/employees/user_create_request.ex rename to apps/ehealth/lib/ehealth/employees/user_create_request.ex diff --git a/lib/ehealth/employees/user_role_creator.ex b/apps/ehealth/lib/ehealth/employees/user_role_creator.ex similarity index 100% rename from lib/ehealth/employees/user_role_creator.ex rename to apps/ehealth/lib/ehealth/employees/user_role_creator.ex diff --git a/lib/ehealth/web/endpoint.ex b/apps/ehealth/lib/ehealth/endpoint.ex similarity index 100% rename from lib/ehealth/web/endpoint.ex rename to apps/ehealth/lib/ehealth/endpoint.ex diff --git a/lib/ehealth/event_manager/event.ex b/apps/ehealth/lib/ehealth/event_manager/event.ex similarity index 100% rename from lib/ehealth/event_manager/event.ex rename to apps/ehealth/lib/ehealth/event_manager/event.ex diff --git a/lib/ehealth/event_manager/event_manager.ex b/apps/ehealth/lib/ehealth/event_manager/event_manager.ex similarity index 100% rename from lib/ehealth/event_manager/event_manager.ex rename to apps/ehealth/lib/ehealth/event_manager/event_manager.ex diff --git a/lib/ehealth/event_manager_repo.ex b/apps/ehealth/lib/ehealth/event_manager_repo.ex similarity index 100% rename from lib/ehealth/event_manager_repo.ex rename to apps/ehealth/lib/ehealth/event_manager_repo.ex diff --git a/lib/ehealth/fraud_repo.ex b/apps/ehealth/lib/ehealth/fraud_repo.ex similarity index 100% rename from lib/ehealth/fraud_repo.ex rename to apps/ehealth/lib/ehealth/fraud_repo.ex diff --git a/lib/ehealth/global_parameters/global_parameter.ex b/apps/ehealth/lib/ehealth/global_parameters/global_parameter.ex similarity index 100% rename from lib/ehealth/global_parameters/global_parameter.ex rename to apps/ehealth/lib/ehealth/global_parameters/global_parameter.ex diff --git a/lib/ehealth/global_parameters/global_parameters.ex b/apps/ehealth/lib/ehealth/global_parameters/global_parameters.ex similarity index 100% rename from lib/ehealth/global_parameters/global_parameters.ex rename to apps/ehealth/lib/ehealth/global_parameters/global_parameters.ex diff --git a/lib/ehealth/hash_chain/verification.ex b/apps/ehealth/lib/ehealth/hash_chain/verification.ex similarity index 100% rename from lib/ehealth/hash_chain/verification.ex rename to apps/ehealth/lib/ehealth/hash_chain/verification.ex diff --git a/lib/ehealth/legal_entities/legal_entities.ex b/apps/ehealth/lib/ehealth/legal_entities/legal_entities.ex similarity index 100% rename from lib/ehealth/legal_entities/legal_entities.ex rename to apps/ehealth/lib/ehealth/legal_entities/legal_entities.ex diff --git a/lib/ehealth/legal_entities/legal_entity.ex b/apps/ehealth/lib/ehealth/legal_entities/legal_entity.ex similarity index 100% rename from lib/ehealth/legal_entities/legal_entity.ex rename to apps/ehealth/lib/ehealth/legal_entities/legal_entity.ex diff --git a/lib/ehealth/legal_entities/legal_entity_request.ex b/apps/ehealth/lib/ehealth/legal_entities/legal_entity_request.ex similarity index 100% rename from lib/ehealth/legal_entities/legal_entity_request.ex rename to apps/ehealth/lib/ehealth/legal_entities/legal_entity_request.ex diff --git a/lib/ehealth/legal_entities/legal_entity_updater.ex b/apps/ehealth/lib/ehealth/legal_entities/legal_entity_updater.ex similarity index 100% rename from lib/ehealth/legal_entities/legal_entity_updater.ex rename to apps/ehealth/lib/ehealth/legal_entities/legal_entity_updater.ex diff --git a/lib/ehealth/legal_entities/medical_service_provider.ex b/apps/ehealth/lib/ehealth/legal_entities/medical_service_provider.ex similarity index 100% rename from lib/ehealth/legal_entities/medical_service_provider.ex rename to apps/ehealth/lib/ehealth/legal_entities/medical_service_provider.ex diff --git a/lib/ehealth/legal_entities/registries.ex b/apps/ehealth/lib/ehealth/legal_entities/registries.ex similarity index 100% rename from lib/ehealth/legal_entities/registries.ex rename to apps/ehealth/lib/ehealth/legal_entities/registries.ex diff --git a/lib/ehealth/legal_entities/registry.ex b/apps/ehealth/lib/ehealth/legal_entities/registry.ex similarity index 100% rename from lib/ehealth/legal_entities/registry.ex rename to apps/ehealth/lib/ehealth/legal_entities/registry.ex diff --git a/lib/ehealth/legal_entities/search.ex b/apps/ehealth/lib/ehealth/legal_entities/search.ex similarity index 100% rename from lib/ehealth/legal_entities/search.ex rename to apps/ehealth/lib/ehealth/legal_entities/search.ex diff --git a/lib/ehealth/legal_entities/validator.ex b/apps/ehealth/lib/ehealth/legal_entities/validator.ex similarity index 100% rename from lib/ehealth/legal_entities/validator.ex rename to apps/ehealth/lib/ehealth/legal_entities/validator.ex diff --git a/lib/ehealth/logger_json.ex b/apps/ehealth/lib/ehealth/logger_json.ex similarity index 100% rename from lib/ehealth/logger_json.ex rename to apps/ehealth/lib/ehealth/logger_json.ex diff --git a/lib/ehealth/man/templates/credentials_recovery_request.ex b/apps/ehealth/lib/ehealth/man/templates/credentials_recovery_request.ex similarity index 100% rename from lib/ehealth/man/templates/credentials_recovery_request.ex rename to apps/ehealth/lib/ehealth/man/templates/credentials_recovery_request.ex diff --git a/lib/ehealth/man/templates/declaration_request_printout_form.ex b/apps/ehealth/lib/ehealth/man/templates/declaration_request_printout_form.ex similarity index 100% rename from lib/ehealth/man/templates/declaration_request_printout_form.ex rename to apps/ehealth/lib/ehealth/man/templates/declaration_request_printout_form.ex diff --git a/lib/ehealth/man/templates/employee_created_notification.ex b/apps/ehealth/lib/ehealth/man/templates/employee_created_notification.ex similarity index 100% rename from lib/ehealth/man/templates/employee_created_notification.ex rename to apps/ehealth/lib/ehealth/man/templates/employee_created_notification.ex diff --git a/lib/ehealth/man/templates/employee_request_invitation.ex b/apps/ehealth/lib/ehealth/man/templates/employee_request_invitation.ex similarity index 100% rename from lib/ehealth/man/templates/employee_request_invitation.ex rename to apps/ehealth/lib/ehealth/man/templates/employee_request_invitation.ex diff --git a/lib/ehealth/man/templates/employee_request_update_invitation.ex b/apps/ehealth/lib/ehealth/man/templates/employee_request_update_invitation.ex similarity index 100% rename from lib/ehealth/man/templates/employee_request_update_invitation.ex rename to apps/ehealth/lib/ehealth/man/templates/employee_request_update_invitation.ex diff --git a/lib/ehealth/man/templates/hash_chain_verification_notification.ex b/apps/ehealth/lib/ehealth/man/templates/hash_chain_verification_notification.ex similarity index 100% rename from lib/ehealth/man/templates/hash_chain_verification_notification.ex rename to apps/ehealth/lib/ehealth/man/templates/hash_chain_verification_notification.ex diff --git a/lib/ehealth/medical_programs/medical_program.ex b/apps/ehealth/lib/ehealth/medical_programs/medical_program.ex similarity index 100% rename from lib/ehealth/medical_programs/medical_program.ex rename to apps/ehealth/lib/ehealth/medical_programs/medical_program.ex diff --git a/lib/ehealth/medical_programs/medical_programs.ex b/apps/ehealth/lib/ehealth/medical_programs/medical_programs.ex similarity index 100% rename from lib/ehealth/medical_programs/medical_programs.ex rename to apps/ehealth/lib/ehealth/medical_programs/medical_programs.ex diff --git a/lib/ehealth/medical_programs/search.ex b/apps/ehealth/lib/ehealth/medical_programs/search.ex similarity index 100% rename from lib/ehealth/medical_programs/search.ex rename to apps/ehealth/lib/ehealth/medical_programs/search.ex diff --git a/lib/ehealth/medication_dispenses/api.ex b/apps/ehealth/lib/ehealth/medication_dispenses/api.ex similarity index 100% rename from lib/ehealth/medication_dispenses/api.ex rename to apps/ehealth/lib/ehealth/medication_dispenses/api.ex diff --git a/lib/ehealth/medication_dispenses/search.ex b/apps/ehealth/lib/ehealth/medication_dispenses/search.ex similarity index 100% rename from lib/ehealth/medication_dispenses/search.ex rename to apps/ehealth/lib/ehealth/medication_dispenses/search.ex diff --git a/lib/ehealth/medication_dispenses/search_by_medication_request.ex b/apps/ehealth/lib/ehealth/medication_dispenses/search_by_medication_request.ex similarity index 100% rename from lib/ehealth/medication_dispenses/search_by_medication_request.ex rename to apps/ehealth/lib/ehealth/medication_dispenses/search_by_medication_request.ex diff --git a/lib/ehealth/medication_request_requests/api.ex b/apps/ehealth/lib/ehealth/medication_request_requests/api.ex similarity index 100% rename from lib/ehealth/medication_request_requests/api.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/api.ex diff --git a/lib/ehealth/medication_request_requests/create_data_operation.ex b/apps/ehealth/lib/ehealth/medication_request_requests/create_data_operation.ex similarity index 100% rename from lib/ehealth/medication_request_requests/create_data_operation.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/create_data_operation.ex diff --git a/lib/ehealth/medication_request_requests/human_readable_number_generator.ex b/apps/ehealth/lib/ehealth/medication_request_requests/human_readable_number_generator.ex similarity index 100% rename from lib/ehealth/medication_request_requests/human_readable_number_generator.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/human_readable_number_generator.ex diff --git a/lib/ehealth/medication_request_requests/operation.ex b/apps/ehealth/lib/ehealth/medication_request_requests/operation.ex similarity index 100% rename from lib/ehealth/medication_request_requests/operation.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/operation.ex diff --git a/lib/ehealth/medication_request_requests/operation_helpers.ex b/apps/ehealth/lib/ehealth/medication_request_requests/operation_helpers.ex similarity index 100% rename from lib/ehealth/medication_request_requests/operation_helpers.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/operation_helpers.ex diff --git a/lib/ehealth/medication_request_requests/preload_fk_operation.ex b/apps/ehealth/lib/ehealth/medication_request_requests/preload_fk_operation.ex similarity index 100% rename from lib/ehealth/medication_request_requests/preload_fk_operation.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/preload_fk_operation.ex diff --git a/lib/ehealth/medication_request_requests/reject_operation.ex b/apps/ehealth/lib/ehealth/medication_request_requests/reject_operation.ex similarity index 100% rename from lib/ehealth/medication_request_requests/reject_operation.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/reject_operation.ex diff --git a/lib/ehealth/medication_request_requests/schema.ex b/apps/ehealth/lib/ehealth/medication_request_requests/schema.ex similarity index 100% rename from lib/ehealth/medication_request_requests/schema.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/schema.ex diff --git a/lib/ehealth/medication_request_requests/sign_operation.ex b/apps/ehealth/lib/ehealth/medication_request_requests/sign_operation.ex similarity index 100% rename from lib/ehealth/medication_request_requests/sign_operation.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/sign_operation.ex diff --git a/lib/ehealth/medication_request_requests/validations.ex b/apps/ehealth/lib/ehealth/medication_request_requests/validations.ex similarity index 100% rename from lib/ehealth/medication_request_requests/validations.ex rename to apps/ehealth/lib/ehealth/medication_request_requests/validations.ex diff --git a/lib/ehealth/medication_requests/api.ex b/apps/ehealth/lib/ehealth/medication_requests/api.ex similarity index 100% rename from lib/ehealth/medication_requests/api.ex rename to apps/ehealth/lib/ehealth/medication_requests/api.ex diff --git a/lib/ehealth/medication_requests/search.ex b/apps/ehealth/lib/ehealth/medication_requests/search.ex similarity index 100% rename from lib/ehealth/medication_requests/search.ex rename to apps/ehealth/lib/ehealth/medication_requests/search.ex diff --git a/lib/ehealth/medication_requests/sms_sender.ex b/apps/ehealth/lib/ehealth/medication_requests/sms_sender.ex similarity index 100% rename from lib/ehealth/medication_requests/sms_sender.ex rename to apps/ehealth/lib/ehealth/medication_requests/sms_sender.ex diff --git a/lib/ehealth/medications/drugs_search.ex b/apps/ehealth/lib/ehealth/medications/drugs_search.ex similarity index 100% rename from lib/ehealth/medications/drugs_search.ex rename to apps/ehealth/lib/ehealth/medications/drugs_search.ex diff --git a/lib/ehealth/medications/innm/innm.ex b/apps/ehealth/lib/ehealth/medications/innm/innm.ex similarity index 100% rename from lib/ehealth/medications/innm/innm.ex rename to apps/ehealth/lib/ehealth/medications/innm/innm.ex diff --git a/lib/ehealth/medications/innm/search.ex b/apps/ehealth/lib/ehealth/medications/innm/search.ex similarity index 100% rename from lib/ehealth/medications/innm/search.ex rename to apps/ehealth/lib/ehealth/medications/innm/search.ex diff --git a/lib/ehealth/medications/innm_dosage/ingredient.ex b/apps/ehealth/lib/ehealth/medications/innm_dosage/ingredient.ex similarity index 100% rename from lib/ehealth/medications/innm_dosage/ingredient.ex rename to apps/ehealth/lib/ehealth/medications/innm_dosage/ingredient.ex diff --git a/lib/ehealth/medications/innm_dosage/innm_dosage.ex b/apps/ehealth/lib/ehealth/medications/innm_dosage/innm_dosage.ex similarity index 100% rename from lib/ehealth/medications/innm_dosage/innm_dosage.ex rename to apps/ehealth/lib/ehealth/medications/innm_dosage/innm_dosage.ex diff --git a/lib/ehealth/medications/innm_dosage/search.ex b/apps/ehealth/lib/ehealth/medications/innm_dosage/search.ex similarity index 100% rename from lib/ehealth/medications/innm_dosage/search.ex rename to apps/ehealth/lib/ehealth/medications/innm_dosage/search.ex diff --git a/lib/ehealth/medications/medication/ingredient.ex b/apps/ehealth/lib/ehealth/medications/medication/ingredient.ex similarity index 100% rename from lib/ehealth/medications/medication/ingredient.ex rename to apps/ehealth/lib/ehealth/medications/medication/ingredient.ex diff --git a/lib/ehealth/medications/medication/medication.ex b/apps/ehealth/lib/ehealth/medications/medication/medication.ex similarity index 100% rename from lib/ehealth/medications/medication/medication.ex rename to apps/ehealth/lib/ehealth/medications/medication/medication.ex diff --git a/lib/ehealth/medications/medication/search.ex b/apps/ehealth/lib/ehealth/medications/medication/search.ex similarity index 100% rename from lib/ehealth/medications/medication/search.ex rename to apps/ehealth/lib/ehealth/medications/medication/search.ex diff --git a/lib/ehealth/medications/medications.ex b/apps/ehealth/lib/ehealth/medications/medications.ex similarity index 100% rename from lib/ehealth/medications/medications.ex rename to apps/ehealth/lib/ehealth/medications/medications.ex diff --git a/lib/ehealth/medications/program/program.ex b/apps/ehealth/lib/ehealth/medications/program/program.ex similarity index 100% rename from lib/ehealth/medications/program/program.ex rename to apps/ehealth/lib/ehealth/medications/program/program.ex diff --git a/lib/ehealth/medications/program/search.ex b/apps/ehealth/lib/ehealth/medications/program/search.ex similarity index 100% rename from lib/ehealth/medications/program/search.ex rename to apps/ehealth/lib/ehealth/medications/program/search.ex diff --git a/lib/ehealth/medications/validator.ex b/apps/ehealth/lib/ehealth/medications/validator.ex similarity index 100% rename from lib/ehealth/medications/validator.ex rename to apps/ehealth/lib/ehealth/medications/validator.ex diff --git a/lib/ehealth/oauth/api.ex b/apps/ehealth/lib/ehealth/oauth/api.ex similarity index 100% rename from lib/ehealth/oauth/api.ex rename to apps/ehealth/lib/ehealth/oauth/api.ex diff --git a/lib/ehealth/parties/document.ex b/apps/ehealth/lib/ehealth/parties/document.ex similarity index 100% rename from lib/ehealth/parties/document.ex rename to apps/ehealth/lib/ehealth/parties/document.ex diff --git a/lib/ehealth/parties/parties.ex b/apps/ehealth/lib/ehealth/parties/parties.ex similarity index 100% rename from lib/ehealth/parties/parties.ex rename to apps/ehealth/lib/ehealth/parties/parties.ex diff --git a/lib/ehealth/parties/party.ex b/apps/ehealth/lib/ehealth/parties/party.ex similarity index 100% rename from lib/ehealth/parties/party.ex rename to apps/ehealth/lib/ehealth/parties/party.ex diff --git a/lib/ehealth/parties/phone.ex b/apps/ehealth/lib/ehealth/parties/phone.ex similarity index 100% rename from lib/ehealth/parties/phone.ex rename to apps/ehealth/lib/ehealth/parties/phone.ex diff --git a/lib/ehealth/parties/search.ex b/apps/ehealth/lib/ehealth/parties/search.ex similarity index 100% rename from lib/ehealth/parties/search.ex rename to apps/ehealth/lib/ehealth/parties/search.ex diff --git a/lib/ehealth/party_users/party_user.ex b/apps/ehealth/lib/ehealth/party_users/party_user.ex similarity index 100% rename from lib/ehealth/party_users/party_user.ex rename to apps/ehealth/lib/ehealth/party_users/party_user.ex diff --git a/lib/ehealth/party_users/party_users.ex b/apps/ehealth/lib/ehealth/party_users/party_users.ex similarity index 100% rename from lib/ehealth/party_users/party_users.ex rename to apps/ehealth/lib/ehealth/party_users/party_users.ex diff --git a/lib/ehealth/party_users/search.ex b/apps/ehealth/lib/ehealth/party_users/search.ex similarity index 100% rename from lib/ehealth/party_users/search.ex rename to apps/ehealth/lib/ehealth/party_users/search.ex diff --git a/lib/ehealth/plugs/client_context.ex b/apps/ehealth/lib/ehealth/plugs/client_context.ex similarity index 100% rename from lib/ehealth/plugs/client_context.ex rename to apps/ehealth/lib/ehealth/plugs/client_context.ex diff --git a/lib/ehealth/plugs/headers.ex b/apps/ehealth/lib/ehealth/plugs/headers.ex similarity index 100% rename from lib/ehealth/plugs/headers.ex rename to apps/ehealth/lib/ehealth/plugs/headers.ex diff --git a/lib/ehealth/postgres_types.ex b/apps/ehealth/lib/ehealth/postgres_types.ex similarity index 100% rename from lib/ehealth/postgres_types.ex rename to apps/ehealth/lib/ehealth/postgres_types.ex diff --git a/lib/ehealth/prm_repo.ex b/apps/ehealth/lib/ehealth/prm_repo.ex similarity index 100% rename from lib/ehealth/prm_repo.ex rename to apps/ehealth/lib/ehealth/prm_repo.ex diff --git a/lib/ehealth/repo.ex b/apps/ehealth/lib/ehealth/repo.ex similarity index 100% rename from lib/ehealth/repo.ex rename to apps/ehealth/lib/ehealth/repo.ex diff --git a/lib/ehealth/scheduler.ex b/apps/ehealth/lib/ehealth/scheduler.ex similarity index 100% rename from lib/ehealth/scheduler.ex rename to apps/ehealth/lib/ehealth/scheduler.ex diff --git a/lib/ehealth/search.ex b/apps/ehealth/lib/ehealth/search.ex similarity index 100% rename from lib/ehealth/search.ex rename to apps/ehealth/lib/ehealth/search.ex diff --git a/lib/ehealth/users/api.ex b/apps/ehealth/lib/ehealth/users/api.ex similarity index 100% rename from lib/ehealth/users/api.ex rename to apps/ehealth/lib/ehealth/users/api.ex diff --git a/lib/ehealth/users/credentials_recovery_request.ex b/apps/ehealth/lib/ehealth/users/credentials_recovery_request.ex similarity index 100% rename from lib/ehealth/users/credentials_recovery_request.ex rename to apps/ehealth/lib/ehealth/users/credentials_recovery_request.ex diff --git a/lib/ehealth/utils/address_merger.ex b/apps/ehealth/lib/ehealth/utils/address_merger.ex similarity index 100% rename from lib/ehealth/utils/address_merger.ex rename to apps/ehealth/lib/ehealth/utils/address_merger.ex diff --git a/lib/ehealth/utils/connection.ex b/apps/ehealth/lib/ehealth/utils/connection.ex similarity index 100% rename from lib/ehealth/utils/connection.ex rename to apps/ehealth/lib/ehealth/utils/connection.ex diff --git a/lib/ehealth/utils/helpers.ex b/apps/ehealth/lib/ehealth/utils/helpers.ex similarity index 100% rename from lib/ehealth/utils/helpers.ex rename to apps/ehealth/lib/ehealth/utils/helpers.ex diff --git a/lib/ehealth/utils/map_deep_merge.ex b/apps/ehealth/lib/ehealth/utils/map_deep_merge.ex similarity index 100% rename from lib/ehealth/utils/map_deep_merge.ex rename to apps/ehealth/lib/ehealth/utils/map_deep_merge.ex diff --git a/lib/ehealth/utils/phone.ex b/apps/ehealth/lib/ehealth/utils/phone.ex similarity index 100% rename from lib/ehealth/utils/phone.ex rename to apps/ehealth/lib/ehealth/utils/phone.ex diff --git a/lib/ehealth/utils/types_converter.ex b/apps/ehealth/lib/ehealth/utils/types_converter.ex similarity index 100% rename from lib/ehealth/utils/types_converter.ex rename to apps/ehealth/lib/ehealth/utils/types_converter.ex diff --git a/lib/ehealth/validators/addresses.ex b/apps/ehealth/lib/ehealth/validators/addresses.ex similarity index 100% rename from lib/ehealth/validators/addresses.ex rename to apps/ehealth/lib/ehealth/validators/addresses.ex diff --git a/lib/ehealth/validators/birth_date.ex b/apps/ehealth/lib/ehealth/validators/birth_date.ex similarity index 100% rename from lib/ehealth/validators/birth_date.ex rename to apps/ehealth/lib/ehealth/validators/birth_date.ex diff --git a/lib/ehealth/validators/json_objects.ex b/apps/ehealth/lib/ehealth/validators/json_objects.ex similarity index 100% rename from lib/ehealth/validators/json_objects.ex rename to apps/ehealth/lib/ehealth/validators/json_objects.ex diff --git a/lib/ehealth/validators/json_schema.ex b/apps/ehealth/lib/ehealth/validators/json_schema.ex similarity index 100% rename from lib/ehealth/validators/json_schema.ex rename to apps/ehealth/lib/ehealth/validators/json_schema.ex diff --git a/lib/ehealth/validators/kveds.ex b/apps/ehealth/lib/ehealth/validators/kveds.ex similarity index 100% rename from lib/ehealth/validators/kveds.ex rename to apps/ehealth/lib/ehealth/validators/kveds.ex diff --git a/lib/ehealth/validators/reference.ex b/apps/ehealth/lib/ehealth/validators/reference.ex similarity index 100% rename from lib/ehealth/validators/reference.ex rename to apps/ehealth/lib/ehealth/validators/reference.ex diff --git a/lib/ehealth/validators/schema_mapper.ex b/apps/ehealth/lib/ehealth/validators/schema_mapper.ex similarity index 100% rename from lib/ehealth/validators/schema_mapper.ex rename to apps/ehealth/lib/ehealth/validators/schema_mapper.ex diff --git a/lib/ehealth/validators/tax_id.ex b/apps/ehealth/lib/ehealth/validators/tax_id.ex similarity index 100% rename from lib/ehealth/validators/tax_id.ex rename to apps/ehealth/lib/ehealth/validators/tax_id.ex diff --git a/lib/ehealth/web/controllers/black_list_user_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/black_list_user_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/black_list_user_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/black_list_user_controller.ex diff --git a/lib/ehealth/web/controllers/client_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/client_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/client_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/client_controller.ex diff --git a/lib/ehealth/web/controllers/declaration_request_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/declaration_request_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/declaration_request_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/declaration_request_controller.ex diff --git a/lib/ehealth/web/controllers/declarations_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/declarations_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/declarations_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/declarations_controller.ex diff --git a/lib/ehealth/web/controllers/deduplication_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/deduplication_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/deduplication_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/deduplication_controller.ex diff --git a/lib/ehealth/web/controllers/dictionary_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/dictionary_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/dictionary_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/dictionary_controller.ex diff --git a/lib/ehealth/web/controllers/division_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/division_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/division_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/division_controller.ex diff --git a/lib/ehealth/web/controllers/employee_request_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/employee_request_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/employee_request_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/employee_request_controller.ex diff --git a/lib/ehealth/web/controllers/employees_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/employees_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/employees_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/employees_controller.ex diff --git a/lib/ehealth/web/controllers/fallback_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/fallback_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/fallback_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/fallback_controller.ex diff --git a/lib/ehealth/web/controllers/global_parameter_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/global_parameter_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/global_parameter_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/global_parameter_controller.ex diff --git a/lib/ehealth/web/controllers/hash_chain_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/hash_chain_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/hash_chain_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/hash_chain_controller.ex diff --git a/lib/ehealth/web/controllers/legal_entity_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/legal_entity_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/legal_entity_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/legal_entity_controller.ex diff --git a/lib/ehealth/web/controllers/medical_program_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/medical_program_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/medical_program_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/medical_program_controller.ex diff --git a/lib/ehealth/web/controllers/medication/innm_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/medication/innm_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/medication/innm_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/medication/innm_controller.ex diff --git a/lib/ehealth/web/controllers/medication/innm_dosage_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/medication/innm_dosage_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/medication/innm_dosage_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/medication/innm_dosage_controller.ex diff --git a/lib/ehealth/web/controllers/medication/medication_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/medication/medication_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/medication/medication_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/medication/medication_controller.ex diff --git a/lib/ehealth/web/controllers/medication/program_medication_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/medication/program_medication_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/medication/program_medication_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/medication/program_medication_controller.ex diff --git a/lib/ehealth/web/controllers/medication_dispense_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/medication_dispense_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/medication_dispense_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/medication_dispense_controller.ex diff --git a/lib/ehealth/web/controllers/medication_request_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/medication_request_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/medication_request_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/medication_request_controller.ex diff --git a/lib/ehealth/web/controllers/medication_request_request_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/medication_request_request_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/medication_request_request_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/medication_request_request_controller.ex diff --git a/lib/ehealth/web/controllers/party_user_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/party_user_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/party_user_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/party_user_controller.ex diff --git a/lib/ehealth/web/controllers/person_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/person_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/person_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/person_controller.ex diff --git a/lib/ehealth/web/controllers/uaddresses_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/uaddresses_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/uaddresses_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/uaddresses_controller.ex diff --git a/lib/ehealth/web/controllers/user_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/user_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/user_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/user_controller.ex diff --git a/lib/ehealth/web/controllers/user_role_controller.ex b/apps/ehealth/lib/ehealth/web/controllers/user_role_controller.ex similarity index 100% rename from lib/ehealth/web/controllers/user_role_controller.ex rename to apps/ehealth/lib/ehealth/web/controllers/user_role_controller.ex diff --git a/lib/ehealth/web/proxy.ex b/apps/ehealth/lib/ehealth/web/proxy.ex similarity index 100% rename from lib/ehealth/web/proxy.ex rename to apps/ehealth/lib/ehealth/web/proxy.ex diff --git a/lib/ehealth/web/router.ex b/apps/ehealth/lib/ehealth/web/router.ex similarity index 100% rename from lib/ehealth/web/router.ex rename to apps/ehealth/lib/ehealth/web/router.ex diff --git a/lib/ehealth/web/views/black_list_user_view.ex b/apps/ehealth/lib/ehealth/web/views/black_list_user_view.ex similarity index 100% rename from lib/ehealth/web/views/black_list_user_view.ex rename to apps/ehealth/lib/ehealth/web/views/black_list_user_view.ex diff --git a/lib/ehealth/web/views/changeset_view.ex b/apps/ehealth/lib/ehealth/web/views/changeset_view.ex similarity index 100% rename from lib/ehealth/web/views/changeset_view.ex rename to apps/ehealth/lib/ehealth/web/views/changeset_view.ex diff --git a/lib/ehealth/web/views/declaration_request_view.ex b/apps/ehealth/lib/ehealth/web/views/declaration_request_view.ex similarity index 100% rename from lib/ehealth/web/views/declaration_request_view.ex rename to apps/ehealth/lib/ehealth/web/views/declaration_request_view.ex diff --git a/lib/ehealth/web/views/dictionary_view.ex b/apps/ehealth/lib/ehealth/web/views/dictionary_view.ex similarity index 100% rename from lib/ehealth/web/views/dictionary_view.ex rename to apps/ehealth/lib/ehealth/web/views/dictionary_view.ex diff --git a/lib/ehealth/web/views/division_view.ex b/apps/ehealth/lib/ehealth/web/views/division_view.ex similarity index 100% rename from lib/ehealth/web/views/division_view.ex rename to apps/ehealth/lib/ehealth/web/views/division_view.ex diff --git a/lib/ehealth/web/views/employee_request_view.ex b/apps/ehealth/lib/ehealth/web/views/employee_request_view.ex similarity index 100% rename from lib/ehealth/web/views/employee_request_view.ex rename to apps/ehealth/lib/ehealth/web/views/employee_request_view.ex diff --git a/lib/ehealth/web/views/employee_view.ex b/apps/ehealth/lib/ehealth/web/views/employee_view.ex similarity index 100% rename from lib/ehealth/web/views/employee_view.ex rename to apps/ehealth/lib/ehealth/web/views/employee_view.ex diff --git a/lib/ehealth/web/views/global_parameter_view.ex b/apps/ehealth/lib/ehealth/web/views/global_parameter_view.ex similarity index 100% rename from lib/ehealth/web/views/global_parameter_view.ex rename to apps/ehealth/lib/ehealth/web/views/global_parameter_view.ex diff --git a/lib/ehealth/web/views/hash_chain.ex b/apps/ehealth/lib/ehealth/web/views/hash_chain.ex similarity index 100% rename from lib/ehealth/web/views/hash_chain.ex rename to apps/ehealth/lib/ehealth/web/views/hash_chain.ex diff --git a/lib/ehealth/web/views/legal_entity_view.ex b/apps/ehealth/lib/ehealth/web/views/legal_entity_view.ex similarity index 100% rename from lib/ehealth/web/views/legal_entity_view.ex rename to apps/ehealth/lib/ehealth/web/views/legal_entity_view.ex diff --git a/lib/ehealth/web/views/medical_program_view.ex b/apps/ehealth/lib/ehealth/web/views/medical_program_view.ex similarity index 100% rename from lib/ehealth/web/views/medical_program_view.ex rename to apps/ehealth/lib/ehealth/web/views/medical_program_view.ex diff --git a/lib/ehealth/web/views/medication/innm_dosage_view.ex b/apps/ehealth/lib/ehealth/web/views/medication/innm_dosage_view.ex similarity index 100% rename from lib/ehealth/web/views/medication/innm_dosage_view.ex rename to apps/ehealth/lib/ehealth/web/views/medication/innm_dosage_view.ex diff --git a/lib/ehealth/web/views/medication/innm_view.ex b/apps/ehealth/lib/ehealth/web/views/medication/innm_view.ex similarity index 100% rename from lib/ehealth/web/views/medication/innm_view.ex rename to apps/ehealth/lib/ehealth/web/views/medication/innm_view.ex diff --git a/lib/ehealth/web/views/medication/medication_view.ex b/apps/ehealth/lib/ehealth/web/views/medication/medication_view.ex similarity index 100% rename from lib/ehealth/web/views/medication/medication_view.ex rename to apps/ehealth/lib/ehealth/web/views/medication/medication_view.ex diff --git a/lib/ehealth/web/views/medication/program_medication_view.ex b/apps/ehealth/lib/ehealth/web/views/medication/program_medication_view.ex similarity index 100% rename from lib/ehealth/web/views/medication/program_medication_view.ex rename to apps/ehealth/lib/ehealth/web/views/medication/program_medication_view.ex diff --git a/lib/ehealth/web/views/medication_dispense_view.ex b/apps/ehealth/lib/ehealth/web/views/medication_dispense_view.ex similarity index 100% rename from lib/ehealth/web/views/medication_dispense_view.ex rename to apps/ehealth/lib/ehealth/web/views/medication_dispense_view.ex diff --git a/lib/ehealth/web/views/medication_request_request_view.ex b/apps/ehealth/lib/ehealth/web/views/medication_request_request_view.ex similarity index 98% rename from lib/ehealth/web/views/medication_request_request_view.ex rename to apps/ehealth/lib/ehealth/web/views/medication_request_request_view.ex index f8f3b0206..d8d421ff5 100644 --- a/lib/ehealth/web/views/medication_request_request_view.ex +++ b/apps/ehealth/lib/ehealth/web/views/medication_request_request_view.ex @@ -98,7 +98,7 @@ defmodule EHealth.Web.MedicationRequestRequestView do PersonView |> render("show.json", %{"person" => person}) |> Map.put("age", age) - |> Map.drop(["birth_date", "addresses"]) + |> Map.delete("bitrh_date") end defp get_age(birth_date, current_date) do diff --git a/lib/ehealth/web/views/medication_request_view.ex b/apps/ehealth/lib/ehealth/web/views/medication_request_view.ex similarity index 100% rename from lib/ehealth/web/views/medication_request_view.ex rename to apps/ehealth/lib/ehealth/web/views/medication_request_view.ex diff --git a/lib/ehealth/web/views/party_user_view.ex b/apps/ehealth/lib/ehealth/web/views/party_user_view.ex similarity index 100% rename from lib/ehealth/web/views/party_user_view.ex rename to apps/ehealth/lib/ehealth/web/views/party_user_view.ex diff --git a/lib/ehealth/web/views/party_view.ex b/apps/ehealth/lib/ehealth/web/views/party_view.ex similarity index 100% rename from lib/ehealth/web/views/party_view.ex rename to apps/ehealth/lib/ehealth/web/views/party_view.ex diff --git a/lib/ehealth/web/views/person_view.ex b/apps/ehealth/lib/ehealth/web/views/person_view.ex similarity index 100% rename from lib/ehealth/web/views/person_view.ex rename to apps/ehealth/lib/ehealth/web/views/person_view.ex diff --git a/lib/ehealth/web/views/user_role_view.ex b/apps/ehealth/lib/ehealth/web/views/user_role_view.ex similarity index 100% rename from lib/ehealth/web/views/user_role_view.ex rename to apps/ehealth/lib/ehealth/web/views/user_role_view.ex diff --git a/lib/ehealth/web/views/user_view.ex b/apps/ehealth/lib/ehealth/web/views/user_view.ex similarity index 100% rename from lib/ehealth/web/views/user_view.ex rename to apps/ehealth/lib/ehealth/web/views/user_view.ex diff --git a/lib/ehealth/web/web.ex b/apps/ehealth/lib/ehealth/web/web.ex similarity index 100% rename from lib/ehealth/web/web.ex rename to apps/ehealth/lib/ehealth/web/web.ex diff --git a/lib/tasks/tasks.ex b/apps/ehealth/lib/tasks/tasks.ex similarity index 97% rename from lib/tasks/tasks.ex rename to apps/ehealth/lib/tasks/tasks.ex index 2a369f3c5..bf4479130 100644 --- a/lib/tasks/tasks.ex +++ b/apps/ehealth/lib/tasks/tasks.ex @@ -1,4 +1,4 @@ -defmodule :ehealth_tasks do +defmodule EHealth.ReleaseTasks do @moduledoc """ Nice way to apply migrations inside a released application. diff --git a/apps/ehealth/mix.exs b/apps/ehealth/mix.exs new file mode 100644 index 000000000..b70bd2b8f --- /dev/null +++ b/apps/ehealth/mix.exs @@ -0,0 +1,115 @@ +defmodule EHealth.Mixfile do + @moduledoc false + + use Mix.Project + + @version "7.23.3" + + def project do + [ + app: :ehealth, + description: "Integration Layer for projects that related to Ukrainian Health Services government institution.", + package: package(), + version: @version, + elixir: "~> 1.5", + build_path: "../../_build", + config_path: "../../config/config.exs", + deps_path: "../../deps", + lockfile: "../../mix.lock", + elixirc_paths: elixirc_paths(Mix.env()), + compilers: [:phoenix] ++ Mix.compilers(), + build_embedded: Mix.env() == :prod, + start_permanent: Mix.env() == :prod, + aliases: aliases(), + deps: deps(), + preferred_cli_env: [coveralls: :test], + test_coverage: [tool: ExCoveralls], + docs: [source_ref: "v#\{@version\}", main: "readme", extras: ["README.md"]] + ] + end + + # Configuration for the OTP application. + # + # Type `mix help compile.app` for more information. + def application do + [ + mod: {EHealth, []}, + extra_applications: [:logger] + ] + end + + # Specifies which paths to compile per environment. + defp elixirc_paths(:test), do: ["lib", "web", "test/support"] + defp elixirc_paths(_), do: ["lib", "web"] + + # Specifies your project dependencies. + # + # Type `mix help deps` for examples and options. + defp deps do + [ + {:confex, "~> 3.2"}, + {:timex, ">= 3.1.15"}, + {:poison, "~> 3.1"}, + {:plug, "~> 1.4"}, + {:cowboy, "~> 1.1"}, + {:httpoison, "~> 0.12"}, + # fix for https://github.com/edgurgel/httpoison/issues/264 + {:hackney, "== 1.8.0", override: true}, + {:postgrex, ">= 0.0.0"}, + {:ecto, "~> 2.1"}, + {:scrivener_ecto, "~> 1.2"}, + {:ecto_trail, "~> 0.2.3"}, + {:phoenix, "~> 1.3.0"}, + {:phoenix_ecto, "~> 3.2"}, + {:eview, "~> 0.12.2"}, + {:jvalid, "~> 0.6.0"}, + {:bamboo, "~> 0.8"}, + {:bamboo_postmark, "~> 0.2.0"}, + {:bamboo_smtp, "~> 1.4.0"}, + {:geo, "~> 1.4"}, + {:quantum, ">= 2.1.0"}, + {:plug_logger_json, "~> 0.5"}, + {:cipher, "~> 1.3"}, + {:ex_doc, ">= 0.15.0", only: [:dev, :test]}, + {:ex_machina, "~> 2.0", only: [:dev, :test]} + ] + end + + # Settings for publishing in Hex package manager: + defp package do + [ + contributors: ["edenlabllc"], + maintainers: ["edenlabllc"], + licenses: ["LISENSE.md"], + links: %{github: "https://github.com/edenlabllc/ehealth.api"}, + files: ~w(lib LICENSE.md mix.exs README.md) + ] + end + + # Aliases are shortcuts or tasks specific to the current project. + # For example, to create, migrate and run the seeds file at once: + # + # $ mix ecto.setup + # + # See the documentation for `Mix` for more info on aliases. + defp aliases do + [ + "ecto.setup": [ + "ecto.create", + "ecto.create --repo EHealth.FraudRepo", + "ecto.create --repo EHealth.PRMRepo", + "ecto.create --repo EHealth.EventManagerRepo", + "ecto.migrate", + "run priv/repo/seeds.exs" + ], + "ecto.reset": ["ecto.drop", "ecto.setup"], + test: [ + "ecto.create --quiet", + "ecto.create --quiet --repo EHealth.PRMRepo", + "ecto.create --quiet --repo EHealth.EventManagerRepo", + "ecto.migrate", + "test" + ] + ] + end +end diff --git a/priv/event_manager_repo/migrations/.gitkeep b/apps/ehealth/priv/event_manager_repo/migrations/.gitkeep similarity index 100% rename from priv/event_manager_repo/migrations/.gitkeep rename to apps/ehealth/priv/event_manager_repo/migrations/.gitkeep diff --git a/priv/event_manager_repo/migrations/20171127145251_create_audit_log.exs b/apps/ehealth/priv/event_manager_repo/migrations/20171127145251_create_audit_log.exs similarity index 100% rename from priv/event_manager_repo/migrations/20171127145251_create_audit_log.exs rename to apps/ehealth/priv/event_manager_repo/migrations/20171127145251_create_audit_log.exs diff --git a/priv/event_manager_repo/migrations/20171127154946_create_events.exs b/apps/ehealth/priv/event_manager_repo/migrations/20171127154946_create_events.exs similarity index 100% rename from priv/event_manager_repo/migrations/20171127154946_create_events.exs rename to apps/ehealth/priv/event_manager_repo/migrations/20171127154946_create_events.exs diff --git a/priv/event_manager_repo/migrations/20171208103336_change_event_id.exs b/apps/ehealth/priv/event_manager_repo/migrations/20171208103336_change_event_id.exs similarity index 100% rename from priv/event_manager_repo/migrations/20171208103336_change_event_id.exs rename to apps/ehealth/priv/event_manager_repo/migrations/20171208103336_change_event_id.exs diff --git a/priv/event_manager_repo/migrations/20171208153626_add_events_primary_key.exs b/apps/ehealth/priv/event_manager_repo/migrations/20171208153626_add_events_primary_key.exs similarity index 100% rename from priv/event_manager_repo/migrations/20171208153626_add_events_primary_key.exs rename to apps/ehealth/priv/event_manager_repo/migrations/20171208153626_add_events_primary_key.exs diff --git a/priv/fraud_repo/migrations/20171024084720_enable_postgis.exs b/apps/ehealth/priv/fraud_repo/migrations/20171024084720_enable_postgis.exs similarity index 100% rename from priv/fraud_repo/migrations/20171024084720_enable_postgis.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171024084720_enable_postgis.exs diff --git a/priv/fraud_repo/migrations/20171024124214_create_legal_entities.exs b/apps/ehealth/priv/fraud_repo/migrations/20171024124214_create_legal_entities.exs similarity index 100% rename from priv/fraud_repo/migrations/20171024124214_create_legal_entities.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171024124214_create_legal_entities.exs diff --git a/priv/fraud_repo/migrations/20171024125331_create_divisions.exs b/apps/ehealth/priv/fraud_repo/migrations/20171024125331_create_divisions.exs similarity index 100% rename from priv/fraud_repo/migrations/20171024125331_create_divisions.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171024125331_create_divisions.exs diff --git a/priv/fraud_repo/migrations/20171024143002_create_employees.exs b/apps/ehealth/priv/fraud_repo/migrations/20171024143002_create_employees.exs similarity index 100% rename from priv/fraud_repo/migrations/20171024143002_create_employees.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171024143002_create_employees.exs diff --git a/priv/fraud_repo/migrations/20171024151305_create_parties.exs b/apps/ehealth/priv/fraud_repo/migrations/20171024151305_create_parties.exs similarity index 100% rename from priv/fraud_repo/migrations/20171024151305_create_parties.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171024151305_create_parties.exs diff --git a/priv/fraud_repo/migrations/20171024153405_create_party_users.exs b/apps/ehealth/priv/fraud_repo/migrations/20171024153405_create_party_users.exs similarity index 100% rename from priv/fraud_repo/migrations/20171024153405_create_party_users.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171024153405_create_party_users.exs diff --git a/priv/fraud_repo/migrations/20171024195147_create_audit_log.exs b/apps/ehealth/priv/fraud_repo/migrations/20171024195147_create_audit_log.exs similarity index 100% rename from priv/fraud_repo/migrations/20171024195147_create_audit_log.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171024195147_create_audit_log.exs diff --git a/priv/fraud_repo/migrations/20171025134148_create_declarations.exs b/apps/ehealth/priv/fraud_repo/migrations/20171025134148_create_declarations.exs similarity index 100% rename from priv/fraud_repo/migrations/20171025134148_create_declarations.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171025134148_create_declarations.exs diff --git a/priv/fraud_repo/migrations/20171025135225_create_declaration_status_hstr.exs b/apps/ehealth/priv/fraud_repo/migrations/20171025135225_create_declaration_status_hstr.exs similarity index 100% rename from priv/fraud_repo/migrations/20171025135225_create_declaration_status_hstr.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171025135225_create_declaration_status_hstr.exs diff --git a/priv/fraud_repo/migrations/20171025135518_create_declaration_requests.exs b/apps/ehealth/priv/fraud_repo/migrations/20171025135518_create_declaration_requests.exs similarity index 100% rename from priv/fraud_repo/migrations/20171025135518_create_declaration_requests.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171025135518_create_declaration_requests.exs diff --git a/priv/fraud_repo/migrations/20171025142220_create_employee_requests.exs b/apps/ehealth/priv/fraud_repo/migrations/20171025142220_create_employee_requests.exs similarity index 100% rename from priv/fraud_repo/migrations/20171025142220_create_employee_requests.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171025142220_create_employee_requests.exs diff --git a/priv/fraud_repo/migrations/20171025144300_create_dictionaries.exs b/apps/ehealth/priv/fraud_repo/migrations/20171025144300_create_dictionaries.exs similarity index 100% rename from priv/fraud_repo/migrations/20171025144300_create_dictionaries.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171025144300_create_dictionaries.exs diff --git a/priv/fraud_repo/migrations/20171025145845_create_persons.exs b/apps/ehealth/priv/fraud_repo/migrations/20171025145845_create_persons.exs similarity index 100% rename from priv/fraud_repo/migrations/20171025145845_create_persons.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171025145845_create_persons.exs diff --git a/priv/fraud_repo/migrations/20171031090345_create_black_list_users.exs b/apps/ehealth/priv/fraud_repo/migrations/20171031090345_create_black_list_users.exs similarity index 100% rename from priv/fraud_repo/migrations/20171031090345_create_black_list_users.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171031090345_create_black_list_users.exs diff --git a/priv/fraud_repo/migrations/20171106132511_create_mpi_audit_log.exs b/apps/ehealth/priv/fraud_repo/migrations/20171106132511_create_mpi_audit_log.exs similarity index 100% rename from priv/fraud_repo/migrations/20171106132511_create_mpi_audit_log.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171106132511_create_mpi_audit_log.exs diff --git a/priv/fraud_repo/migrations/20171115162153_drop_parties_fields.exs b/apps/ehealth/priv/fraud_repo/migrations/20171115162153_drop_parties_fields.exs similarity index 100% rename from priv/fraud_repo/migrations/20171115162153_drop_parties_fields.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171115162153_drop_parties_fields.exs diff --git a/priv/fraud_repo/migrations/20171116081857_drop_persons_fields.exs b/apps/ehealth/priv/fraud_repo/migrations/20171116081857_drop_persons_fields.exs similarity index 100% rename from priv/fraud_repo/migrations/20171116081857_drop_persons_fields.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171116081857_drop_persons_fields.exs diff --git a/priv/fraud_repo/migrations/20171121142127_drop_parties_phones.exs b/apps/ehealth/priv/fraud_repo/migrations/20171121142127_drop_parties_phones.exs similarity index 100% rename from priv/fraud_repo/migrations/20171121142127_drop_parties_phones.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171121142127_drop_parties_phones.exs diff --git a/priv/fraud_repo/migrations/20171211093621_add_parties_no_tax_id.exs b/apps/ehealth/priv/fraud_repo/migrations/20171211093621_add_parties_no_tax_id.exs similarity index 100% rename from priv/fraud_repo/migrations/20171211093621_add_parties_no_tax_id.exs rename to apps/ehealth/priv/fraud_repo/migrations/20171211093621_add_parties_no_tax_id.exs diff --git a/priv/prm_repo/fixtures/global_parameters.json b/apps/ehealth/priv/prm_repo/fixtures/global_parameters.json similarity index 100% rename from priv/prm_repo/fixtures/global_parameters.json rename to apps/ehealth/priv/prm_repo/fixtures/global_parameters.json diff --git a/priv/prm_repo/migrations/.gitkeep b/apps/ehealth/priv/prm_repo/migrations/.gitkeep similarity index 100% rename from priv/prm_repo/migrations/.gitkeep rename to apps/ehealth/priv/prm_repo/migrations/.gitkeep diff --git a/priv/prm_repo/migrations/20170413123306_create_entities_division.exs b/apps/ehealth/priv/prm_repo/migrations/20170413123306_create_entities_division.exs similarity index 100% rename from priv/prm_repo/migrations/20170413123306_create_entities_division.exs rename to apps/ehealth/priv/prm_repo/migrations/20170413123306_create_entities_division.exs diff --git a/priv/prm_repo/migrations/20170413123307_create_entities_msp.exs b/apps/ehealth/priv/prm_repo/migrations/20170413123307_create_entities_msp.exs similarity index 100% rename from priv/prm_repo/migrations/20170413123307_create_entities_msp.exs rename to apps/ehealth/priv/prm_repo/migrations/20170413123307_create_entities_msp.exs diff --git a/priv/prm_repo/migrations/20170413123308_create_entities_legal_entity.exs b/apps/ehealth/priv/prm_repo/migrations/20170413123308_create_entities_legal_entity.exs similarity index 100% rename from priv/prm_repo/migrations/20170413123308_create_entities_legal_entity.exs rename to apps/ehealth/priv/prm_repo/migrations/20170413123308_create_entities_legal_entity.exs diff --git a/priv/prm_repo/migrations/20170413124601_entities_relations.exs b/apps/ehealth/priv/prm_repo/migrations/20170413124601_entities_relations.exs similarity index 100% rename from priv/prm_repo/migrations/20170413124601_entities_relations.exs rename to apps/ehealth/priv/prm_repo/migrations/20170413124601_entities_relations.exs diff --git a/priv/prm_repo/migrations/20170414155832_add_unique_for_legal_entity_edrpou.exs b/apps/ehealth/priv/prm_repo/migrations/20170414155832_add_unique_for_legal_entity_edrpou.exs similarity index 100% rename from priv/prm_repo/migrations/20170414155832_add_unique_for_legal_entity_edrpou.exs rename to apps/ehealth/priv/prm_repo/migrations/20170414155832_add_unique_for_legal_entity_edrpou.exs diff --git a/priv/prm_repo/migrations/20170417155741_create_parties_party.exs b/apps/ehealth/priv/prm_repo/migrations/20170417155741_create_parties_party.exs similarity index 100% rename from priv/prm_repo/migrations/20170417155741_create_parties_party.exs rename to apps/ehealth/priv/prm_repo/migrations/20170417155741_create_parties_party.exs diff --git a/priv/prm_repo/migrations/20170419075231_create_employees.exs b/apps/ehealth/priv/prm_repo/migrations/20170419075231_create_employees.exs similarity index 100% rename from priv/prm_repo/migrations/20170419075231_create_employees.exs rename to apps/ehealth/priv/prm_repo/migrations/20170419075231_create_employees.exs diff --git a/priv/prm_repo/migrations/20170419075232_create_employee_doctor.exs b/apps/ehealth/priv/prm_repo/migrations/20170419075232_create_employee_doctor.exs similarity index 100% rename from priv/prm_repo/migrations/20170419075232_create_employee_doctor.exs rename to apps/ehealth/priv/prm_repo/migrations/20170419075232_create_employee_doctor.exs diff --git a/priv/prm_repo/migrations/20170420110826_create_dictionaries_dictionary.exs b/apps/ehealth/priv/prm_repo/migrations/20170420110826_create_dictionaries_dictionary.exs similarity index 100% rename from priv/prm_repo/migrations/20170420110826_create_dictionaries_dictionary.exs rename to apps/ehealth/priv/prm_repo/migrations/20170420110826_create_dictionaries_dictionary.exs diff --git a/priv/prm_repo/migrations/20170421104735_create_registries_ukr_med.exs b/apps/ehealth/priv/prm_repo/migrations/20170421104735_create_registries_ukr_med.exs similarity index 100% rename from priv/prm_repo/migrations/20170421104735_create_registries_ukr_med.exs rename to apps/ehealth/priv/prm_repo/migrations/20170421104735_create_registries_ukr_med.exs diff --git a/priv/prm_repo/migrations/20170427103609_rename_msp_license_to_licenses.exs b/apps/ehealth/priv/prm_repo/migrations/20170427103609_rename_msp_license_to_licenses.exs similarity index 100% rename from priv/prm_repo/migrations/20170427103609_rename_msp_license_to_licenses.exs rename to apps/ehealth/priv/prm_repo/migrations/20170427103609_rename_msp_license_to_licenses.exs diff --git a/priv/prm_repo/migrations/20170427114030_rename_divisions_address_to_addresses.exs b/apps/ehealth/priv/prm_repo/migrations/20170427114030_rename_divisions_address_to_addresses.exs similarity index 100% rename from priv/prm_repo/migrations/20170427114030_rename_divisions_address_to_addresses.exs rename to apps/ehealth/priv/prm_repo/migrations/20170427114030_rename_divisions_address_to_addresses.exs diff --git a/priv/prm_repo/migrations/20170510164524_add_employee_status_reason.exs b/apps/ehealth/priv/prm_repo/migrations/20170510164524_add_employee_status_reason.exs similarity index 100% rename from priv/prm_repo/migrations/20170510164524_add_employee_status_reason.exs rename to apps/ehealth/priv/prm_repo/migrations/20170510164524_add_employee_status_reason.exs diff --git a/priv/prm_repo/migrations/20170510164543_add_legal_entity_created_by_mis_client_id.exs b/apps/ehealth/priv/prm_repo/migrations/20170510164543_add_legal_entity_created_by_mis_client_id.exs similarity index 100% rename from priv/prm_repo/migrations/20170510164543_add_legal_entity_created_by_mis_client_id.exs rename to apps/ehealth/priv/prm_repo/migrations/20170510164543_add_legal_entity_created_by_mis_client_id.exs diff --git a/priv/prm_repo/migrations/20170511133900_change_employees_date_types.exs b/apps/ehealth/priv/prm_repo/migrations/20170511133900_change_employees_date_types.exs similarity index 100% rename from priv/prm_repo/migrations/20170511133900_change_employees_date_types.exs rename to apps/ehealth/priv/prm_repo/migrations/20170511133900_change_employees_date_types.exs diff --git a/priv/prm_repo/migrations/20170511154159_create_global_parameters.exs b/apps/ehealth/priv/prm_repo/migrations/20170511154159_create_global_parameters.exs similarity index 100% rename from priv/prm_repo/migrations/20170511154159_create_global_parameters.exs rename to apps/ehealth/priv/prm_repo/migrations/20170511154159_create_global_parameters.exs diff --git a/priv/prm_repo/migrations/20170522114501_create_parties_party_user.exs b/apps/ehealth/priv/prm_repo/migrations/20170522114501_create_parties_party_user.exs similarity index 100% rename from priv/prm_repo/migrations/20170522114501_create_parties_party_user.exs rename to apps/ehealth/priv/prm_repo/migrations/20170522114501_create_parties_party_user.exs diff --git a/priv/prm_repo/migrations/20170523113838_remove_dictionaries.exs b/apps/ehealth/priv/prm_repo/migrations/20170523113838_remove_dictionaries.exs similarity index 100% rename from priv/prm_repo/migrations/20170523113838_remove_dictionaries.exs rename to apps/ehealth/priv/prm_repo/migrations/20170523113838_remove_dictionaries.exs diff --git a/priv/prm_repo/migrations/20170524080809_rename_party_users.exs b/apps/ehealth/priv/prm_repo/migrations/20170524080809_rename_party_users.exs similarity index 100% rename from priv/prm_repo/migrations/20170524080809_rename_party_users.exs rename to apps/ehealth/priv/prm_repo/migrations/20170524080809_rename_party_users.exs diff --git a/priv/prm_repo/migrations/20170525101522_rename_party_users_indexes.exs b/apps/ehealth/priv/prm_repo/migrations/20170525101522_rename_party_users_indexes.exs similarity index 100% rename from priv/prm_repo/migrations/20170525101522_rename_party_users_indexes.exs rename to apps/ehealth/priv/prm_repo/migrations/20170525101522_rename_party_users_indexes.exs diff --git a/priv/prm_repo/migrations/20170606171448_enable_postgis.exs b/apps/ehealth/priv/prm_repo/migrations/20170606171448_enable_postgis.exs similarity index 100% rename from priv/prm_repo/migrations/20170606171448_enable_postgis.exs rename to apps/ehealth/priv/prm_repo/migrations/20170606171448_enable_postgis.exs diff --git a/priv/prm_repo/migrations/20170606171954_add_location_to_prm.exs b/apps/ehealth/priv/prm_repo/migrations/20170606171954_add_location_to_prm.exs similarity index 100% rename from priv/prm_repo/migrations/20170606171954_add_location_to_prm.exs rename to apps/ehealth/priv/prm_repo/migrations/20170606171954_add_location_to_prm.exs diff --git a/priv/prm_repo/migrations/20170606203443_added_to_division_status.exs b/apps/ehealth/priv/prm_repo/migrations/20170606203443_added_to_division_status.exs similarity index 100% rename from priv/prm_repo/migrations/20170606203443_added_to_division_status.exs rename to apps/ehealth/priv/prm_repo/migrations/20170606203443_added_to_division_status.exs diff --git a/priv/prm_repo/migrations/20170607084728_added_to_division_is_active.exs b/apps/ehealth/priv/prm_repo/migrations/20170607084728_added_to_division_is_active.exs similarity index 100% rename from priv/prm_repo/migrations/20170607084728_added_to_division_is_active.exs rename to apps/ehealth/priv/prm_repo/migrations/20170607084728_added_to_division_is_active.exs diff --git a/priv/prm_repo/migrations/20170615114013_create_audit_log_table.exs b/apps/ehealth/priv/prm_repo/migrations/20170615114013_create_audit_log_table.exs similarity index 100% rename from priv/prm_repo/migrations/20170615114013_create_audit_log_table.exs rename to apps/ehealth/priv/prm_repo/migrations/20170615114013_create_audit_log_table.exs diff --git a/priv/prm_repo/migrations/20170615155026_set_msp_accreditation_nullable.exs b/apps/ehealth/priv/prm_repo/migrations/20170615155026_set_msp_accreditation_nullable.exs similarity index 100% rename from priv/prm_repo/migrations/20170615155026_set_msp_accreditation_nullable.exs rename to apps/ehealth/priv/prm_repo/migrations/20170615155026_set_msp_accreditation_nullable.exs diff --git a/priv/prm_repo/migrations/20170623132140_remove_party_user_id_unique_index.exs b/apps/ehealth/priv/prm_repo/migrations/20170623132140_remove_party_user_id_unique_index.exs similarity index 100% rename from priv/prm_repo/migrations/20170623132140_remove_party_user_id_unique_index.exs rename to apps/ehealth/priv/prm_repo/migrations/20170623132140_remove_party_user_id_unique_index.exs diff --git a/priv/prm_repo/migrations/20170704135447_add_mis_verified_to_legal_entity.exs b/apps/ehealth/priv/prm_repo/migrations/20170704135447_add_mis_verified_to_legal_entity.exs similarity index 100% rename from priv/prm_repo/migrations/20170704135447_add_mis_verified_to_legal_entity.exs rename to apps/ehealth/priv/prm_repo/migrations/20170704135447_add_mis_verified_to_legal_entity.exs diff --git a/priv/prm_repo/migrations/20170704143635_add_nhs_verified_to_legal_entitiy.exs b/apps/ehealth/priv/prm_repo/migrations/20170704143635_add_nhs_verified_to_legal_entitiy.exs similarity index 100% rename from priv/prm_repo/migrations/20170704143635_add_nhs_verified_to_legal_entitiy.exs rename to apps/ehealth/priv/prm_repo/migrations/20170704143635_add_nhs_verified_to_legal_entitiy.exs diff --git a/priv/prm_repo/migrations/20170720122501_change_division_mountain_group.exs b/apps/ehealth/priv/prm_repo/migrations/20170720122501_change_division_mountain_group.exs similarity index 100% rename from priv/prm_repo/migrations/20170720122501_change_division_mountain_group.exs rename to apps/ehealth/priv/prm_repo/migrations/20170720122501_change_division_mountain_group.exs diff --git a/priv/prm_repo/migrations/20170817084648_add_party_users_index.exs b/apps/ehealth/priv/prm_repo/migrations/20170817084648_add_party_users_index.exs similarity index 100% rename from priv/prm_repo/migrations/20170817084648_add_party_users_index.exs rename to apps/ehealth/priv/prm_repo/migrations/20170817084648_add_party_users_index.exs diff --git a/priv/prm_repo/migrations/20170819084718_drop_employee_doctors.exs b/apps/ehealth/priv/prm_repo/migrations/20170819084718_drop_employee_doctors.exs similarity index 100% rename from priv/prm_repo/migrations/20170819084718_drop_employee_doctors.exs rename to apps/ehealth/priv/prm_repo/migrations/20170819084718_drop_employee_doctors.exs diff --git a/priv/prm_repo/migrations/20170822135340_add_mountain_group_not_null.exs b/apps/ehealth/priv/prm_repo/migrations/20170822135340_add_mountain_group_not_null.exs similarity index 100% rename from priv/prm_repo/migrations/20170822135340_add_mountain_group_not_null.exs rename to apps/ehealth/priv/prm_repo/migrations/20170822135340_add_mountain_group_not_null.exs diff --git a/priv/prm_repo/migrations/20170823151548_add_type_to_ukr_med_registry.exs b/apps/ehealth/priv/prm_repo/migrations/20170823151548_add_type_to_ukr_med_registry.exs similarity index 100% rename from priv/prm_repo/migrations/20170823151548_add_type_to_ukr_med_registry.exs rename to apps/ehealth/priv/prm_repo/migrations/20170823151548_add_type_to_ukr_med_registry.exs diff --git a/priv/prm_repo/migrations/20170907104216_create_medications.exs b/apps/ehealth/priv/prm_repo/migrations/20170907104216_create_medications.exs similarity index 100% rename from priv/prm_repo/migrations/20170907104216_create_medications.exs rename to apps/ehealth/priv/prm_repo/migrations/20170907104216_create_medications.exs diff --git a/priv/prm_repo/migrations/20170907151543_create_innms.exs b/apps/ehealth/priv/prm_repo/migrations/20170907151543_create_innms.exs similarity index 100% rename from priv/prm_repo/migrations/20170907151543_create_innms.exs rename to apps/ehealth/priv/prm_repo/migrations/20170907151543_create_innms.exs diff --git a/priv/prm_repo/migrations/20170907151544_create_substances.exs b/apps/ehealth/priv/prm_repo/migrations/20170907151544_create_substances.exs similarity index 100% rename from priv/prm_repo/migrations/20170907151544_create_substances.exs rename to apps/ehealth/priv/prm_repo/migrations/20170907151544_create_substances.exs diff --git a/priv/prm_repo/migrations/20170919072307_drop_party_user_duplicates.exs b/apps/ehealth/priv/prm_repo/migrations/20170919072307_drop_party_user_duplicates.exs similarity index 100% rename from priv/prm_repo/migrations/20170919072307_drop_party_user_duplicates.exs rename to apps/ehealth/priv/prm_repo/migrations/20170919072307_drop_party_user_duplicates.exs diff --git a/priv/prm_repo/migrations/20170920073508_add_unique_index_to_parties.exs b/apps/ehealth/priv/prm_repo/migrations/20170920073508_add_unique_index_to_parties.exs similarity index 100% rename from priv/prm_repo/migrations/20170920073508_add_unique_index_to_parties.exs rename to apps/ehealth/priv/prm_repo/migrations/20170920073508_add_unique_index_to_parties.exs diff --git a/priv/prm_repo/migrations/20170920110329_add_unique_index_to_party_users.exs b/apps/ehealth/priv/prm_repo/migrations/20170920110329_add_unique_index_to_party_users.exs similarity index 100% rename from priv/prm_repo/migrations/20170920110329_add_unique_index_to_party_users.exs rename to apps/ehealth/priv/prm_repo/migrations/20170920110329_add_unique_index_to_party_users.exs diff --git a/priv/prm_repo/migrations/20170922121046_create_medical_program.exs b/apps/ehealth/priv/prm_repo/migrations/20170922121046_create_medical_program.exs similarity index 100% rename from priv/prm_repo/migrations/20170922121046_create_medical_program.exs rename to apps/ehealth/priv/prm_repo/migrations/20170922121046_create_medical_program.exs diff --git a/priv/prm_repo/migrations/20170925124321_drop_innms.exs b/apps/ehealth/priv/prm_repo/migrations/20170925124321_drop_innms.exs similarity index 100% rename from priv/prm_repo/migrations/20170925124321_drop_innms.exs rename to apps/ehealth/priv/prm_repo/migrations/20170925124321_drop_innms.exs diff --git a/priv/prm_repo/migrations/20170925124518_create_ingredients.exs b/apps/ehealth/priv/prm_repo/migrations/20170925124518_create_ingredients.exs similarity index 100% rename from priv/prm_repo/migrations/20170925124518_create_ingredients.exs rename to apps/ehealth/priv/prm_repo/migrations/20170925124518_create_ingredients.exs diff --git a/priv/prm_repo/migrations/20170927101510_rename_substance_to_innm_update_ingredients.exs b/apps/ehealth/priv/prm_repo/migrations/20170927101510_rename_substance_to_innm_update_ingredients.exs similarity index 100% rename from priv/prm_repo/migrations/20170927101510_rename_substance_to_innm_update_ingredients.exs rename to apps/ehealth/priv/prm_repo/migrations/20170927101510_rename_substance_to_innm_update_ingredients.exs diff --git a/priv/prm_repo/migrations/20171004120857_create_program_medication.exs b/apps/ehealth/priv/prm_repo/migrations/20171004120857_create_program_medication.exs similarity index 100% rename from priv/prm_repo/migrations/20171004120857_create_program_medication.exs rename to apps/ehealth/priv/prm_repo/migrations/20171004120857_create_program_medication.exs diff --git a/priv/prm_repo/migrations/20171026104218_create_black_list_users.exs b/apps/ehealth/priv/prm_repo/migrations/20171026104218_create_black_list_users.exs similarity index 100% rename from priv/prm_repo/migrations/20171026104218_create_black_list_users.exs rename to apps/ehealth/priv/prm_repo/migrations/20171026104218_create_black_list_users.exs diff --git a/priv/prm_repo/migrations/20171107222344_add_unique_indexes.exs b/apps/ehealth/priv/prm_repo/migrations/20171107222344_add_unique_indexes.exs similarity index 100% rename from priv/prm_repo/migrations/20171107222344_add_unique_indexes.exs rename to apps/ehealth/priv/prm_repo/migrations/20171107222344_add_unique_indexes.exs diff --git a/priv/prm_repo/migrations/20171206121408_add_no_tax_id_to_parties.exs b/apps/ehealth/priv/prm_repo/migrations/20171206121408_add_no_tax_id_to_parties.exs similarity index 100% rename from priv/prm_repo/migrations/20171206121408_add_no_tax_id_to_parties.exs rename to apps/ehealth/priv/prm_repo/migrations/20171206121408_add_no_tax_id_to_parties.exs diff --git a/priv/prm_repo/migrations/20180119121203_add_optional_fields_to_legal_entity.exs b/apps/ehealth/priv/prm_repo/migrations/20180119121203_add_optional_fields_to_legal_entity.exs similarity index 100% rename from priv/prm_repo/migrations/20180119121203_add_optional_fields_to_legal_entity.exs rename to apps/ehealth/priv/prm_repo/migrations/20180119121203_add_optional_fields_to_legal_entity.exs diff --git a/priv/prm_repo/seeds.exs b/apps/ehealth/priv/prm_repo/seeds.exs similarity index 100% rename from priv/prm_repo/seeds.exs rename to apps/ehealth/priv/prm_repo/seeds.exs diff --git a/apps/ehealth/priv/repo/.DS_Store b/apps/ehealth/priv/repo/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..9df5499d835542e66e049d8e315392b731274c39 GIT binary patch literal 6148 zcmeHK%}T>S5T0$TCWzRBqQ_jk_0Vb$UW8EV!J81#gG!r_Y6CSXO={H`$y4YX`3k;{ zGrQZ;61{j3DKjwp&Cbs*`z7oT0EpJuZva#Qz(6G|nb>?I6elf6NqY!|9AgY4=t1mF z;$b119siL5`gR7~LI97Dz})xq29bxc4{taK;-p^x6s2-yWp&LkO~c$UZ=8NKaS}Hf z$1QhsC3}J2^R#^)MT42`dKW=&(y4A8M`7XyVQ(~-etj8)el%%CT^}i4AtXVY z-V%hCMq6X95F;o;l_IKAp`RE+m80L%dA7z}p(+OE990L zU^1tR1(U|70yb~kVi4* f(owvNDh2%(8Hl#VTp@Z;_#z-_;D#CaQwF{O?J836 literal 0 HcmV?d00001 diff --git a/apps/ehealth/priv/repo/fixtures/.DS_Store b/apps/ehealth/priv/repo/fixtures/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..5008ddfcf53c02e82d7eee2e57c38e5672ef89f6 GIT binary patch literal 6148 zcmeH~Jr2S!425mzP>H1@V-^m;4Wg<&0T*E43hX&L&p$$qDprKhvt+--jT7}7np#A3 zem<@ulZcFPQ@L2!n>{z**++&mCkOWA81W14cNZlEfg7;MkzE(HCqgga^y>{tEnwC%0;vJ&^%eQ zLs35+`xjp>T01uheh4eYqV`|NUg|<9-wTU#$tmayCmN3VYO2D z0X_hFZQ(!QBlr>S%-CM4YC+R9b1iJ>K&cV~Oxl2FFAFglMr*rDYF!U*EYSLF@nb#)X6%WG4 zNq%Ce4ufzQtxu=D?d{FD*XzwTsC{@-1e}tIex;^bB|gJOfL>fZLja)g^cq{|KG|&%kmqK>I_C zN|-ooESjwY8~S~u@irj|+H{v7j2$Kp8;dxC!fYy{O=a$i!E8GEV;7e=Y%JPzU}k2l z<7Q^=hQiG3=#Nb}u*9NoJp-PBn+&YjZbaw*{@?HaH60}l2BY@@plRu<|xKkI*Qj(ji5g!12J*fSVRws{}C`W_{KBvUm5rXVApF| literal 0 HcmV?d00001 diff --git a/test/data/declaration_request.json b/apps/ehealth/test/data/declaration_request.json similarity index 100% rename from test/data/declaration_request.json rename to apps/ehealth/test/data/declaration_request.json diff --git a/apps/ehealth/test/data/declaration_request/.DS_Store b/apps/ehealth/test/data/declaration_request/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..5008ddfcf53c02e82d7eee2e57c38e5672ef89f6 GIT binary patch literal 6148 zcmeH~Jr2S!425mzP>H1@V-^m;4Wg<&0T*E43hX&L&p$$qDprKhvt+--jT7}7np#A3 zem<@ulZcFPQ@L2!n>{z**++&mCkOWA81W14cNZlEfg7;MkzE(HCqgga^y>{tEnwC%0;vJ&^%eQ zLs35+`xjp>T0 /dev/null +fi; + +if [[ "${TRAVIS_PULL_REQUEST}" == "false" ]]; then + # Commit incremented version and release_notes + git add apps/ehealth/mix.exs docs apps/ehealth/release_notes; + git commit -m "Increment version [ci skip]"; + + echo "Current branch: ${TRAVIS_BRANCH}" + echo "Trunk branch: ${TRUNK_BRANCH}" + echo "Build requires maintenance?: ${BUILD_REQUIRES_MAINTENANCE}" + echo "Maintenance branch: ${MAINTENANCE_BRANCH}" + + if [[ "${TRAVIS_BRANCH}" == "${TRUNK_BRANCH}" && "${BUILD_REQUIRES_MAINTENANCE}" == "0" || "${TRAVIS_BRANCH}" == "${MAINTENANCE_BRANCH}" ]]; then + ${DIR}/../release/push-container.sh -a $DOCKER_HUB_ACCOUNT -t $TRAVIS_BRANCH -l; + + if [[ "${GITHUB_TOKEN}" != "" ]]; then + echo "Done. Pushing changes back to origin repo."; + git push upstream HEAD:$TRAVIS_BRANCH &> /dev/null; + git push upstream HEAD:$TRAVIS_BRANCH --tags &> /dev/null; + else + echo "Done. Pushing changes back to upstream repo."; + git push origin HEAD:$TRAVIS_BRANCH; + git push origin HEAD:$TRAVIS_BRANCH --tags; + fi; + else + echo "[I] This build is not in a trunk or maintenance branch, new version will not be created" + fi; +else + echo "[I] This build is a pull request, new version will not be created" +fi; diff --git a/bin/ci/release b/bin/ci/release index 85faaae8d..65582d280 160000 --- a/bin/ci/release +++ b/bin/ci/release @@ -1 +1 @@ -Subproject commit 85faaae8d481004caa9bdff91a5d8c5d00b9c3cb +Subproject commit 65582d28046101754ac592678cd6997d8e1cd418 diff --git a/bin/ci/release.sh b/bin/ci/release.sh index 6fe7fa000..752c1bb78 100755 --- a/bin/ci/release.sh +++ b/bin/ci/release.sh @@ -13,7 +13,7 @@ # Find mix.exs inside project tree. # This allows to call bash scripts within any folder inside project. -PROJECT_DIR=$(git rev-parse --show-toplevel) +PROJECT_DIR="$(git rev-parse --show-toplevel)" if [ ! -f "${PROJECT_DIR}/mix.exs" ]; then echo "[E] Can't find '${PROJECT_DIR}/mix.exs'." echo " Check that you run this script inside git repo or init a new one in project root." diff --git a/bin/hooks/pre-start.sh b/bin/hooks/pre-start.sh index ab3f5d006..e6af1cb04 100755 --- a/bin/hooks/pre-start.sh +++ b/bin/hooks/pre-start.sh @@ -4,10 +4,10 @@ APP_NAME="ehealth" if [ "${DB_MIGRATE}" == "true" ]; then echo "[WARNING] Migrating database!" - ./bin/$APP_NAME command "${APP_NAME}_tasks" migrate + ./bin/$APP_NAME command Elixir.EHealth.ReleaseTasks migrate fi; if [ "${DB_SEED}" == "true" ]; then echo "[WARNING] Seeding database!" - ./bin/$APP_NAME command "${APP_NAME}_tasks" seed + ./bin/$APP_NAME command Elixir.EHealth.ReleaseTasks seed fi; diff --git a/bin/mix_tests.sh b/bin/mix_tests.sh index 389f7a55e..e02d11acd 100755 --- a/bin/mix_tests.sh +++ b/bin/mix_tests.sh @@ -2,11 +2,11 @@ cd $TRAVIS_BUILD_DIR # Run all tests except pending ones echo "- mix test --exclude pending --trace " - mix test --exclude pending --trace + mix test --exclude pending --trace if [ "$?" -eq 0 ]; then echo "mix test successfully completed" - else + else echo "mix test Finished with errors ,exited with 1" mix_test=1 ; fi; @@ -14,20 +14,20 @@ cd $TRAVIS_BUILD_DIR # Submit code coverage report to Coveralls # Add --pro if you using private repo. - echo "- mix coveralls.travis --exclude pending ;" - mix coveralls.travis --exclude pending + echo "- mix coveralls.travis --exclude pending --umbrella;" + mix coveralls.travis --exclude pending --umbrella if [ "$?" -eq 0 ]; then echo "mix coveralls.travis successfully completed" - else + else echo "mix coveralls.travis finished with errors , exited with 1" mix_test=1; fi; - # Run static code analysis + # Run static code analysis echo "- mix credo --strict ; " - mix credo --strict + mix credo --strict if [ "$?" -eq 0 ]; then echo "mix credo successfully completed" diff --git a/config/.credo.exs b/config/.credo.exs index 0b3952081..5399d4483 100644 --- a/config/.credo.exs +++ b/config/.credo.exs @@ -4,8 +4,8 @@ color: true, name: "default", files: %{ - included: ["lib/"], - excluded: ["lib/tasks/tasks.ex"] + included: ["apps/*/lib/*"], + excluded: ["apps/*/lib/tasks/tasks.ex"] }, checks: [ {Credo.Check.Design.TagTODO, exit_status: 0}, diff --git a/config/config.exs b/config/config.exs index 01c2b5b8f..74b5053c0 100644 --- a/config/config.exs +++ b/config/config.exs @@ -1,251 +1,17 @@ +# This file is responsible for configuring your application +# and its dependencies with the aid of the Mix.Config module. use Mix.Config -# General application configuration -config :ehealth, - env: Mix.env(), - namespace: EHealth, - ecto_repos: [EHealth.Repo, EHealth.PRMRepo, EHealth.FraudRepo, EHealth.EventManagerRepo], - run_declaration_request_terminator: true, - system_user: {:system, "EHEALTH_SYSTEM_USER", "4261eacf-8008-4e62-899f-de1e2f7065f0"} - -# Configures the endpoint -config :ehealth, EHealth.Web.Endpoint, - url: [host: "localhost"], - secret_key_base: "AcugHtFljaEFhBY1d6opAasbdFYsvV8oydwW98qS0oZOv+N/a5TE5G7DPfTZcXm9", - render_errors: [view: EView.Views.PhoenixError, accepts: ~w(json)] - -# Configures Digital Signature API -config :ehealth, EHealth.API.Signature, - enabled: {:system, :boolean, "DIGITAL_SIGNATURE_ENABLED", true}, - endpoint: {:system, "DIGITAL_SIGNATURE_ENDPOINT"}, - hackney_options: [ - connect_timeout: {:system, :integer, "DIGITAL_SIGNATURE_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "DIGITAL_SIGNATURE_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "DIGITAL_SIGNATURE_REQUEST_TIMEOUT", 30_000} - ] - -# Configures MediaStorage API -config :ehealth, EHealth.API.MediaStorage, - endpoint: {:system, "MEDIA_STORAGE_ENDPOINT"}, - legal_entity_bucket: {:system, "MEDIA_STORAGE_LEGAL_ENTITY_BUCKET"}, - declaration_request_bucket: {:system, "MEDIA_STORAGE_DECLARATION_REQUEST_BUCKET"}, - declaration_bucket: {:system, "MEDIA_STORAGE_DECLARATION_BUCKET"}, - medication_request_request_bucket: {:system, "MEDIA_STORAGE_MEDICATION_REQUEST_REQUEST_BUCKET"}, - enabled?: {:system, :boolean, "MEDIA_STORAGE_ENABLED", false}, - hackney_options: [ - connect_timeout: {:system, :integer, "MEDIA_STORAGE_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "MEDIA_STORAGE_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "MEDIA_STORAGE_REQUEST_TIMEOUT", 30_000} - ] - -# Configures PRM API -config :ehealth, EHealth.API.PRM, - endpoint: {:system, "PRM_ENDPOINT", "http://api-svc.prm/api"}, - hackney_options: [ - connect_timeout: {:system, :integer, "PRM_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "PRM_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "PRM_REQUEST_TIMEOUT", 30_000} - ] - -# Configures Legal Entities token permission -config :ehealth, EHealth.Plugs.ClientContext, - tokens_types_personal: {:system, :list, "TOKENS_TYPES_PERSONAL", ["MSP", "PHARMACY"]}, - tokens_types_mis: {:system, :list, "TOKENS_TYPES_MIS", ["MIS"]}, - tokens_types_admin: {:system, :list, "TOKENS_TYPES_ADMIN", ["NHS ADMIN"]} - -# Configures OAuth API -config :ehealth, EHealth.API.Mithril, - endpoint: {:system, "OAUTH_ENDPOINT"}, - hackney_options: [ - connect_timeout: {:system, :integer, "OAUTH_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "OAUTH_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "OAUTH_REQUEST_TIMEOUT", 30_000} - ] - -# Configures Man API -config :ehealth, EHealth.API.Man, - endpoint: {:system, "MAN_ENDPOINT"}, - hackney_options: [ - connect_timeout: {:system, :integer, "MAN_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "MAN_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "MAN_REQUEST_TIMEOUT", 30_000} - ] - -# Configures UAddress API -config :ehealth, EHealth.API.UAddress, - endpoint: {:system, "UADDRESS_ENDPOINT"}, - hackney_options: [ - connect_timeout: {:system, :integer, "UADDRESS_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "UADDRESS_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "UADDRESS_REQUEST_TIMEOUT", 30_000} - ] - -# Configures OTP Verification API -config :ehealth, EHealth.API.OTPVerification, - endpoint: {:system, "OTP_VERIFICATION_ENDPOINT"}, - hackney_options: [ - connect_timeout: {:system, :integer, "OTP_VERIFICATION_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "OTP_VERIFICATION_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "OTP_VERIFICATION_REQUEST_TIMEOUT", 30_000} - ] - -# Configures MPI API -config :ehealth, EHealth.API.MPI, - endpoint: {:system, "MPI_ENDPOINT"}, - hackney_options: [ - connect_timeout: {:system, :integer, "MPI_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "MPI_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "MPI_REQUEST_TIMEOUT", 30_000} - ] - -# Configures OPS API -config :ehealth, EHealth.API.OPS, - endpoint: {:system, "OPS_ENDPOINT"}, - hackney_options: [ - connect_timeout: {:system, :integer, "OPS_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "OPS_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "OPS_REQUEST_TIMEOUT", 30_000} - ] - -# Configures Gandalf API -config :ehealth, EHealth.API.Gandalf, - endpoint: {:system, "GNDF_ENDPOINT"}, - client_id: {:system, "GNDF_CLIENT_ID"}, - client_secret: {:system, "GNDF_CLIENT_SECRET"}, - application_id: {:system, "GNDF_APPLICATION_ID"}, - table_id: {:system, "GNDF_TABLE_ID"}, - hackney_options: [ - connect_timeout: {:system, :integer, "GNDF_REQUEST_TIMEOUT", 30_000}, - recv_timeout: {:system, :integer, "GNDF_REQUEST_TIMEOUT", 30_000}, - timeout: {:system, :integer, "GNDF_REQUEST_TIMEOUT", 30_000} - ] - -# configure emails -config :ehealth, :emails, - employee_request_invitation: %{ - from: {:system, "BAMBOO_EMPLOYEE_REQUEST_INVITATION_FROM", ""}, - subject: {:system, "BAMBOO_EMPLOYEE_REQUEST_INVITATION_SUBJECT", ""} - }, - employee_request_update_invitation: %{ - from: {:system, "BAMBOO_EMPLOYEE_REQUEST_UPDATE_INVITATION_FROM", ""}, - subject: {:system, "BAMBOO_EMPLOYEE_REQUEST_UPDATE_INVITATION_SUBJECT", ""} - }, - hash_chain_verification_notification: %{ - from: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_FROM", ""}, - to: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_TO", ""}, - subject: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_SUBJECT", ""} - }, - employee_created_notification: %{ - from: {:system, "BAMBOO_EMPLOYEE_CREATED_NOTIFICATION_FROM", ""}, - subject: {:system, "BAMBOO_EMPLOYEE_CREATED_NOTIFICATION_SUBJECT", ""} - }, - credentials_recovery_request: %{ - from: {:system, "BAMBOO_CREDENTIALS_RECOVERY_REQUEST_INVITATION_FROM", ""}, - subject: {:system, "BAMBOO_CREDENTIALS_RECOVERY_REQUEST_INVITATION_SUBJECT", ""} - } - -config :ehealth, EHealth.Man.Templates.EmployeeRequestInvitation, - id: {:system, "EMPLOYEE_REQUEST_INVITATION_TEMPLATE_ID"}, - format: {:system, "EMPLOYEE_REQUEST_INVITATION_TEMPLATE_FORMAT", "text/html"}, - locale: {:system, "EMPLOYEE_REQUEST_INVITATION_TEMPLATE_LOCALE", "uk_UA"} - -# Configures employee request update invitation template -config :ehealth, EHealth.Man.Templates.EmployeeRequestUpdateInvitation, - id: {:system, "EMPLOYEE_REQUEST_UPDATE_INVITATION_TEMPLATE_ID"}, - format: {:system, "EMPLOYEE_REQUEST_UPDATE_INVITATION_TEMPLATE_FORMAT", "text/html"}, - locale: {:system, "EMPLOYEE_REQUEST_UPDATE_INVITATION_TEMPLATE_LOCALE", "uk_UA"} - -config :ehealth, EHealth.Man.Templates.HashChainVerificationNotification, - id: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_ID", ""}, - format: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_FORMAT", ""}, - locale: {:system, "CHAIN_VERIFICATION_FAILED_NOTIFICATION_LOCALE", ""} - -# employee created notification -# Configures employee created notification template -config :ehealth, EHealth.Man.Templates.EmployeeCreatedNotification, - id: {:system, "EMPLOYEE_CREATED_NOTIFICATION_TEMPLATE_ID"}, - format: {:system, "EMPLOYEE_CREATED_NOTIFICATION_TEMPLATE_FORMAT", "text/html"}, - locale: {:system, "EMPLOYEE_CREATED_NOTIFICATION_TEMPLATE_LOCALE", "uk_UA"} - -config :ehealth, EHealth.Man.Templates.DeclarationRequestPrintoutForm, - id: {:system, "DECLARATION_REQUEST_PRINTOUT_FORM_TEMPLATE_ID"}, - format: {:system, "DECLARATION_REQUEST_PRINTOUT_FORM_TEMPLATE_FORMAT", "text/html"}, - locale: {:system, "DECLARATION_REQUEST_PRINTOUT_FORM_TEMPLATE_LOCALE", "uk_UA"} - -# Template and setting for credentials recovery requests -config :ehealth, :credentials_recovery_request_ttl, {:system, :integer, "CREDENTIALS_RECOVERY_REQUEST_TTL", 1_500} - -config :ehealth, EHealth.Man.Templates.CredentialsRecoveryRequest, - id: {:system, "CREDENTIALS_RECOVERY_REQUEST_INVITATION_TEMPLATE_ID"}, - format: {:system, "CREDENTIALS_RECOVERY_REQUEST_INVITATION_TEMPLATE_FORMAT", "text/html"}, - locale: {:system, "CREDENTIALS_RECOVERY_REQUEST_INVITATION_TEMPLATE_LOCALE", "uk_UA"} - -config :ehealth, :legal_entity_employee_types, - msp: {:system, "LEGAL_ENTITY_MSP_EMPLOYEE_TYPES", ["OWNER", "HR", "DOCTOR", "ADMIN"]}, - pharmacy: {:system, "LEGAL_ENTITY_PHARMACY_EMPLOYEE_TYPES", ["PHARMACY_OWNER", "PHARMACIST", "HR"]} - -config :ehealth, :legal_entity_division_types, - msp: {:system, "LEGAL_ENTITY_MSP_DIVISION_TYPES", ["CLINIC", "AMBULANT_CLINIC", "FAP"]}, - pharmacy: {:system, "LEGAL_ENTITY_PHARMACIST_DIVISION_TYPES", ["DRUGSTORE", "DRUGSTORE_POINT"]} - -config :ehealth, :medication_request_request, - expire_in_minutes: {:system, "MEDICATION_REQUEST_REQUEST_EXPIRATION", 30}, - otp_code_length: {:system, "MEDICATION_REQUEST_REQUEST_OTP_CODE_LENGTH", 4} - -config :ehealth, :medication_request, - sign_template_sms: - {:system, "TEMPLATE_SMS_FOR_SIGN_MEDICATION_REQUEST", - "Ваш рецепт: . Код підтвердження: "}, - reject_template_sms: - {:system, "TEMPLATE_SMS_FOR_REJECT_MEDICATION_REQUEST", "Відкликано рецепт: від "} - -config :ehealth, EHealth.Bamboo.Emails.Sender, mailer: {:system, :module, "BAMBOO_MAILER"} - -# Configures bamboo -config :ehealth, EHealth.Bamboo.PostmarkMailer, - adapter: EHealth.Bamboo.PostmarkAdapter, - api_key: {:system, "POSTMARK_API_KEY", ""} - -config :ehealth, EHealth.Bamboo.MailgunMailer, - adapter: EHealth.Bamboo.MailgunAdapter, - api_key: {:system, "MAILGUN_API_KEY", ""}, - domain: {:system, "MAILGUN_DOMAIN", ""} - -config :ehealth, EHealth.Bamboo.SMTPMailer, - adapter: EHealth.Bamboo.SMTPAdapter, - server: {:system, "BAMBOO_SMTP_SERVER", ""}, - hostname: {:system, "BAMBOO_SMTP_HOSTNAME", ""}, - port: {:system, "BAMBOO_SMTP_PORT", ""}, - username: {:system, "BAMBOO_SMTP_USERNAME", ""}, - password: {:system, "BAMBOO_SMTP_PASSWORD", ""}, - tls: :if_available, - allowed_tls_versions: [:tlsv1, :"tlsv1.1", :"tlsv1.2"], - ssl: true, - retries: 1 - -# Configures address merger -config :ehealth, EHealth.Utils.AddressMerger, no_suffix_areas: {:system, "NO_SUFFIX_AREAS", ["М.КИЇВ", "М.СЕВАСТОПОЛЬ"]} - -# Configures genral validator -config :ehealth, EHealth.LegalEntities.Validator, owner_positions: {:system, :list, "OWNER_POSITIONS", [""]} - -# Configures birth date validator -config :ehealth, EHealth.Validators.BirthDate, - min_age: {:system, "MIN_AGE", 0}, - max_age: {:system, "MAX_AGE", 150} - -# Configures Elixir's Logger -config :logger, :console, - format: "$message\n", - handle_otp_reports: true, - level: :info - -config :ehealth, EHealth.Scheduler, - declaration_request_autotermination: {:system, :string, "DECLARATION_REQUEST_AUTOTERMINATION_SCHEDULE", "* 0-4 * * *"}, - employee_request_autotermination: {:system, :string, "EMPLOYEE_REQUEST_AUTOTERMINATION_SCHEDULE", "0-4 * * *"} - -config :cipher, - keyphrase: System.get_env("CIPHER_KEYPHRASE") || "8()VN#U#_CU#X)*BFG(Cadsvn$&", - ivphrase: System.get_env("CIPHER_IVPHRASE") || "B((%(^(%V(CWBY(**(by(*YCBDYB#(Y(C#" - -import_config "#{Mix.env()}.exs" +# By default, the umbrella project as well as each child +# application will require this configuration file, ensuring +# they all use the same configuration. While one could +# configure all applications here, we prefer to delegate +# back to each application for organization purposes. +import_config "../apps/*/config/config.exs" + +# Sample configuration (overrides the imported configuration above): +# +# config :logger, :console, +# level: :info, +# format: "$date $time [$level] $metadata$message\n", +# metadata: [:user_id] diff --git a/coveralls.json b/coveralls.json index abae7db95..955bf8719 100644 --- a/coveralls.json +++ b/coveralls.json @@ -1,9 +1,5 @@ { - "skip_files": [ - "specs/*", - "test/*", - "/lib/ehealth/tasks.ex" - ], + "skip_files": [], "custom_stop_words": [ "field", "has_one", diff --git a/mix.exs b/mix.exs index 3284c2e2d..6fc0cfafc 100644 --- a/mix.exs +++ b/mix.exs @@ -1,119 +1,27 @@ -defmodule EHealth.Mixfile do - use Mix.Project +defmodule Ehealth.MixProject do + @moduledoc false - @version "7.23.3" + use Mix.Project def project do [ - app: :ehealth, - description: "Integration Layer for projects that related to Ukrainian Health Services government institution.", - package: package(), - version: @version, - elixir: "~> 1.5", - elixirc_paths: elixirc_paths(Mix.env()), - compilers: [:phoenix] ++ Mix.compilers(), - build_embedded: Mix.env() == :prod, + apps_path: "apps", start_permanent: Mix.env() == :prod, - aliases: aliases(), deps: deps(), - test_coverage: [tool: ExCoveralls], - preferred_cli_env: [coveralls: :test], - docs: [source_ref: "v#\{@version\}", main: "readme", extras: ["README.md"]] + test_coverage: [tool: ExCoveralls] ] end - # Configuration for the OTP application - # - # Type "mix help compile.app" for more information - def application do - [extra_applications: [:logger, :runtime_tools], mod: {EHealth, []}] - end - - # Specifies which paths to compile per environment. - defp elixirc_paths(:test), do: ["lib", "test/support"] - defp elixirc_paths(_), do: ["lib"] - - # Dependencies can be Hex packages: - # - # {:mydep, "~> 0.3.0"} - # - # Or git/path repositories: - # - # {:mydep, git: "https://github.com/elixir-lang/mydep.git", tag: "0.1.0"} - # - # To depend on another app inside the umbrella: - # - # {:myapp, in_umbrella: true} + # Dependencies listed here are available only for this + # project and cannot be accessed from applications inside + # the apps folder. # - # Type "mix help deps" for more examples and options + # Run "mix help deps" for examples and options. defp deps do [ {:distillery, "~> 1.5", runtime: false}, - {:confex, "~> 3.2"}, - {:timex, ">= 3.1.15"}, - {:poison, "~> 3.1"}, - {:plug, "~> 1.4"}, - {:cowboy, "~> 1.1"}, - {:httpoison, "~> 0.12"}, - # fix for https://github.com/edgurgel/httpoison/issues/264 - {:hackney, "== 1.8.0", override: true}, - {:postgrex, ">= 0.0.0"}, - {:ecto, "~> 2.1"}, - {:scrivener_ecto, "~> 1.2"}, - {:ecto_trail, "~> 0.2.3"}, - {:phoenix, "~> 1.3.0"}, - {:phoenix_ecto, "~> 3.2"}, - {:eview, "~> 0.12.2"}, - {:jvalid, "~> 0.6.0"}, - {:bamboo, "~> 0.8"}, - {:bamboo_postmark, "~> 0.2.0"}, - {:bamboo_smtp, "~> 1.4.0"}, - {:geo, "~> 1.4"}, - {:quantum, ">= 2.1.0"}, - {:plug_logger_json, "~> 0.5"}, - {:cipher, "~> 1.3"}, - {:ex_doc, ">= 0.15.0", only: [:dev, :test]}, {:excoveralls, ">= 0.5.0", only: [:dev, :test]}, - {:ex_machina, "~> 2.0", only: [:dev, :test]}, {:credo, ">= 0.5.1", only: [:dev, :test]} ] end - - # Settings for publishing in Hex package manager: - defp package do - [ - contributors: ["edenlabllc"], - maintainers: ["edenlabllc"], - licenses: ["LISENSE.md"], - links: %{github: "https://github.com/edenlabllc/ehealth.api"}, - files: ~w(lib LICENSE.md mix.exs README.md) - ] - end - - # Aliases are shortcuts or tasks specific to the current project. - # For example, to create, migrate and run the seeds file at once: - # - # $ mix ecto.setup - # - # See the documentation for `Mix` for more info on aliases. - defp aliases do - [ - "ecto.setup": [ - "ecto.create", - "ecto.create --repo EHealth.FraudRepo", - "ecto.create --repo EHealth.PRMRepo", - "ecto.create --repo EHealth.EventManagerRepo", - "ecto.migrate", - "run priv/repo/seeds.exs" - ], - "ecto.reset": ["ecto.drop", "ecto.setup"], - test: [ - "ecto.create --quiet", - "ecto.create --quiet --repo EHealth.PRMRepo", - "ecto.create --quiet --repo EHealth.EventManagerRepo", - "ecto.migrate", - "test" - ] - ] - end end diff --git a/mix.lock b/mix.lock index 0c9d60e17..4080af050 100644 --- a/mix.lock +++ b/mix.lock @@ -1,10 +1,10 @@ %{ "bamboo": {:hex, :bamboo, "0.8.0", "573889a3efcb906bb9d25a1c4caa4ca22f479235e1b8cc3260d8b88dabeb4b14", [:mix], [{:hackney, "~> 1.6", [hex: :hackney, repo: "hexpm", optional: false]}, {:plug, "~> 1.0", [hex: :plug, repo: "hexpm", optional: false]}, {:poison, ">= 1.5.0", [hex: :poison, repo: "hexpm", optional: false]}], "hexpm"}, "bamboo_postmark": {:hex, :bamboo_postmark, "0.2.0", "9c51d09b4e619559d5a98054a603ed6f1157f5ba59847b9748ecbb49896e16fc", [:mix], [{:bamboo, "~> 0.5", [hex: :bamboo, repo: "hexpm", optional: false]}, {:hackney, "~> 1.6", [hex: :hackney, repo: "hexpm", optional: false]}, {:plug, "~> 1.0", [hex: :plug, repo: "hexpm", optional: false]}, {:poison, ">= 1.5.0", [hex: :poison, repo: "hexpm", optional: false]}], "hexpm"}, - "bamboo_smtp": {:hex, :bamboo_smtp, "1.4.0", "a01d91406f3a46b3452c84d345d50f75d6facca5e06337358287a97da0426240", [], [{:bamboo, "~> 0.8.0", [hex: :bamboo, repo: "hexpm", optional: false]}, {:gen_smtp, "~> 0.12.0", [hex: :gen_smtp, repo: "hexpm", optional: false]}], "hexpm"}, + "bamboo_smtp": {:hex, :bamboo_smtp, "1.4.0", "a01d91406f3a46b3452c84d345d50f75d6facca5e06337358287a97da0426240", [:mix], [{:bamboo, "~> 0.8.0", [hex: :bamboo, repo: "hexpm", optional: false]}, {:gen_smtp, "~> 0.12.0", [hex: :gen_smtp, repo: "hexpm", optional: false]}], "hexpm"}, "bunt": {:hex, :bunt, "0.2.0", "951c6e801e8b1d2cbe58ebbd3e616a869061ddadcc4863d0a2182541acae9a38", [:mix], [], "hexpm"}, "certifi": {:hex, :certifi, "1.1.0", "c9b71a547016c2528a590ccfc28de786c7edb74aafa17446b84f54e04efc00ee", [:rebar3], [], "hexpm"}, - "cipher": {:hex, :cipher, "1.3.3", "ed0ea13e8d0ede4f7e70ec9c220aceadbd654af612813c9040c48fd452fc054e", [:mix], [{:plug, ">= 1.1.0", [hex: :plug, repo: "hexpm", optional: false]}, {:poison, "~> 2.0 or ~> 3.0", [hex: :poison, repo: "hexpm", optional: false]}], "hexpm"}, + "cipher": {:hex, :cipher, "1.3.4", "10d3bf7ec1410a2c45136672b3389e53e9810c80e70a0773192bd75f43c1d129", [:mix], [{:plug, ">= 1.1.0", [hex: :plug, repo: "hexpm", optional: false]}, {:poison, "~> 2.0 or ~> 3.0", [hex: :poison, repo: "hexpm", optional: false]}], "hexpm"}, "combine": {:hex, :combine, "0.10.0", "eff8224eeb56498a2af13011d142c5e7997a80c8f5b97c499f84c841032e429f", [:mix], [], "hexpm"}, "confex": {:hex, :confex, "3.3.1", "8febaf751bf293a16a1ed2cbd258459cdcc7ca53cfa61d3f83d49dd276a992b4", [:mix], [], "hexpm"}, "connection": {:hex, :connection, "1.0.4", "a1cae72211f0eef17705aaededacac3eb30e6625b04a6117c1b2db6ace7d5976", [:mix], [], "hexpm"}, @@ -12,21 +12,21 @@ "cowlib": {:hex, :cowlib, "1.0.2", "9d769a1d062c9c3ac753096f868ca121e2730b9a377de23dec0f7e08b1df84ee", [:make], [], "hexpm"}, "credo": {:hex, :credo, "0.8.10", "261862bb7363247762e1063713bb85df2bbd84af8d8610d1272cd9c1943bba63", [:mix], [{:bunt, "~> 0.2.0", [hex: :bunt, repo: "hexpm", optional: false]}], "hexpm"}, "crontab": {:hex, :crontab, "1.1.2", "4784a50987b4a19af07a908f98e8a308b00f9c93efc5a7892155dc10cd8fc7d9", [:mix], [{:ecto, "~> 1.0 or ~> 2.0 or ~> 2.1", [hex: :ecto, repo: "hexpm", optional: true]}], "hexpm"}, - "db_connection": {:hex, :db_connection, "1.1.2", "2865c2a4bae0714e2213a0ce60a1b12d76a6efba0c51fbda59c9ab8d1accc7a8", [:mix], [{:connection, "~> 1.0.2", [hex: :connection, repo: "hexpm", optional: false]}, {:poolboy, "~> 1.5", [hex: :poolboy, repo: "hexpm", optional: true]}, {:sbroker, "~> 1.0", [hex: :sbroker, repo: "hexpm", optional: true]}], "hexpm"}, + "db_connection": {:hex, :db_connection, "1.1.3", "89b30ca1ef0a3b469b1c779579590688561d586694a3ce8792985d4d7e575a61", [:mix], [{:connection, "~> 1.0.2", [hex: :connection, repo: "hexpm", optional: false]}, {:poolboy, "~> 1.5", [hex: :poolboy, repo: "hexpm", optional: true]}, {:sbroker, "~> 1.0", [hex: :sbroker, repo: "hexpm", optional: true]}], "hexpm"}, "decimal": {:hex, :decimal, "1.4.1", "ad9e501edf7322f122f7fc151cce7c2a0c9ada96f2b0155b8a09a795c2029770", [:mix], [], "hexpm"}, "distillery": {:hex, :distillery, "1.5.2", "eec18b2d37b55b0bcb670cf2bcf64228ed38ce8b046bb30a9b636a6f5a4c0080", [:mix], [], "hexpm"}, "earmark": {:hex, :earmark, "1.2.4", "99b637c62a4d65a20a9fb674b8cffb8baa771c04605a80c911c4418c69b75439", [:mix], [], "hexpm"}, - "ecto": {:hex, :ecto, "2.2.7", "2074106ff4a5cd9cb2b54b12ca087c4b659ddb3f6b50be4562883c1d763fb031", [:mix], [{:db_connection, "~> 1.1", [hex: :db_connection, repo: "hexpm", optional: true]}, {:decimal, "~> 1.2", [hex: :decimal, repo: "hexpm", optional: false]}, {:mariaex, "~> 0.8.0", [hex: :mariaex, repo: "hexpm", optional: true]}, {:poison, "~> 2.2 or ~> 3.0", [hex: :poison, repo: "hexpm", optional: true]}, {:poolboy, "~> 1.5", [hex: :poolboy, repo: "hexpm", optional: false]}, {:postgrex, "~> 0.13.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:sbroker, "~> 1.0", [hex: :sbroker, repo: "hexpm", optional: true]}], "hexpm"}, + "ecto": {:hex, :ecto, "2.2.8", "a4463c0928b970f2cee722cd29aaac154e866a15882c5737e0038bbfcf03ec2c", [:mix], [{:db_connection, "~> 1.1", [hex: :db_connection, repo: "hexpm", optional: true]}, {:decimal, "~> 1.2", [hex: :decimal, repo: "hexpm", optional: false]}, {:mariaex, "~> 0.8.0", [hex: :mariaex, repo: "hexpm", optional: true]}, {:poison, "~> 2.2 or ~> 3.0", [hex: :poison, repo: "hexpm", optional: true]}, {:poolboy, "~> 1.5", [hex: :poolboy, repo: "hexpm", optional: false]}, {:postgrex, "~> 0.13.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:sbroker, "~> 1.0", [hex: :sbroker, repo: "hexpm", optional: true]}], "hexpm"}, "ecto_trail": {:hex, :ecto_trail, "0.2.3", "cdb031b5fab16cb08b1ac37cf4ff43103f0d686547ff825742f969fbd0ffa958", [:mix], [{:ecto, "~> 2.1", [hex: :ecto, repo: "hexpm", optional: false]}, {:postgrex, "~> 0.13.2", [hex: :postgrex, repo: "hexpm", optional: true]}], "hexpm"}, "eview": {:hex, :eview, "0.12.4", "539c3f5dc3a0c33b784585bd34eb60fb4a18dc28be4dfd57cd90665cf30275cb", [:mix], [{:credit_card, "~> 1.0", [hex: :credit_card, repo: "hexpm", optional: true]}, {:ecto, "~> 2.1", [hex: :ecto, repo: "hexpm", optional: true]}, {:nex_json_schema, "~> 0.7.0", [hex: :nex_json_schema, repo: "hexpm", optional: true]}, {:plug, "~> 1.3", [hex: :plug, repo: "hexpm", optional: false]}, {:poison, "~> 3.1", [hex: :poison, repo: "hexpm", optional: false]}], "hexpm"}, "ex_doc": {:hex, :ex_doc, "0.18.1", "37c69d2ef62f24928c1f4fdc7c724ea04aecfdf500c4329185f8e3649c915baf", [:mix], [{:earmark, "~> 1.1", [hex: :earmark, repo: "hexpm", optional: false]}], "hexpm"}, "ex_machina": {:hex, :ex_machina, "2.1.0", "4874dc9c78e7cf2d429f24dc3c4005674d4e4da6a08be961ffccc08fb528e28b", [:mix], [{:ecto, "~> 2.1", [hex: :ecto, repo: "hexpm", optional: true]}], "hexpm"}, "excoveralls": {:hex, :excoveralls, "0.8.0", "99d2691d3edf8612f128be3f9869c4d44b91c67cec92186ce49470ae7a7404cf", [:mix], [{:exjsx, ">= 3.0.0", [hex: :exjsx, repo: "hexpm", optional: false]}, {:hackney, ">= 0.12.0", [hex: :hackney, repo: "hexpm", optional: false]}], "hexpm"}, "exjsx": {:hex, :exjsx, "4.0.0", "60548841e0212df401e38e63c0078ec57b33e7ea49b032c796ccad8cde794b5c", [:mix], [{:jsx, "~> 2.8.0", [hex: :jsx, repo: "hexpm", optional: false]}], "hexpm"}, - "gen_smtp": {:hex, :gen_smtp, "0.12.0", "97d44903f5ca18ca85cb39aee7d9c77e98d79804bbdef56078adcf905cb2ef00", [], [], "hexpm"}, + "gen_smtp": {:hex, :gen_smtp, "0.12.0", "97d44903f5ca18ca85cb39aee7d9c77e98d79804bbdef56078adcf905cb2ef00", [:rebar3], [], "hexpm"}, "gen_stage": {:hex, :gen_stage, "0.12.2", "e0e347cbb1ceb5f4e68a526aec4d64b54ad721f0a8b30aa9d28e0ad749419cbb", [:mix], [], "hexpm"}, "geo": {:hex, :geo, "1.5.0", "14301aae05bc9124f36b3726e028830477d2ee6b397b7a00b98eca3da06de193", [:mix], [{:ecto, "~> 2.1", [hex: :ecto, repo: "hexpm", optional: true]}, {:poison, "~> 1.5 or ~> 2.0 or ~> 3.0", [hex: :poison, repo: "hexpm", optional: true]}, {:postgrex, "~> 0.13", [hex: :postgrex, repo: "hexpm", optional: true]}], "hexpm"}, - "gettext": {:hex, :gettext, "0.13.1", "5e0daf4e7636d771c4c71ad5f3f53ba09a9ae5c250e1ab9c42ba9edccc476263", [:mix], [], "hexpm"}, + "gettext": {:hex, :gettext, "0.14.0", "1a019a2e51d5ad3d126efe166dcdf6563768e5d06c32a99ad2281a1fa94b4c72", [:mix], [], "hexpm"}, "hackney": {:hex, :hackney, "1.8.0", "8388a22f4e7eb04d171f2cf0285b217410f266d6c13a4c397a6c22ab823a486c", [:rebar3], [{:certifi, "1.1.0", [hex: :certifi, repo: "hexpm", optional: false]}, {:idna, "4.0.0", [hex: :idna, repo: "hexpm", optional: false]}, {:metrics, "1.0.1", [hex: :metrics, repo: "hexpm", optional: false]}, {:mimerl, "1.0.2", [hex: :mimerl, repo: "hexpm", optional: false]}, {:ssl_verify_fun, "1.1.1", [hex: :ssl_verify_fun, repo: "hexpm", optional: false]}], "hexpm"}, "httpoison": {:hex, :httpoison, "0.13.0", "bfaf44d9f133a6599886720f3937a7699466d23bb0cd7a88b6ba011f53c6f562", [:mix], [{:hackney, "~> 1.8", [hex: :hackney, repo: "hexpm", optional: false]}], "hexpm"}, "idna": {:hex, :idna, "4.0.0", "10aaa9f79d0b12cf0def53038547855b91144f1bfcc0ec73494f38bb7b9c4961", [:rebar3], [], "hexpm"}, @@ -44,11 +44,11 @@ "poison": {:hex, :poison, "3.1.0", "d9eb636610e096f86f25d9a46f35a9facac35609a7591b3be3326e99a0484665", [:mix], [], "hexpm"}, "poolboy": {:hex, :poolboy, "1.5.1", "6b46163901cfd0a1b43d692657ed9d7e599853b3b21b95ae5ae0a777cf9b6ca8", [:rebar], [], "hexpm"}, "postgrex": {:hex, :postgrex, "0.13.3", "c277cfb2a9c5034d445a722494c13359e361d344ef6f25d604c2353185682bfc", [:mix], [{:connection, "~> 1.0", [hex: :connection, repo: "hexpm", optional: false]}, {:db_connection, "~> 1.1", [hex: :db_connection, repo: "hexpm", optional: false]}, {:decimal, "~> 1.0", [hex: :decimal, repo: "hexpm", optional: false]}], "hexpm"}, - "quantum": {:hex, :quantum, "2.2.0", "26a483932d591d32d868041a27850e34bb58a2fb82f6a79822696d6cd7ddbb8d", [:mix], [{:calendar, "~> 0.17", [hex: :calendar, repo: "hexpm", optional: true]}, {:crontab, "~> 1.1", [hex: :crontab, repo: "hexpm", optional: false]}, {:gen_stage, "~> 0.12.2", [hex: :gen_stage, repo: "hexpm", optional: false]}, {:timex, "~> 3.1.13", [hex: :timex, repo: "hexpm", optional: true]}], "hexpm"}, + "quantum": {:hex, :quantum, "2.2.1", "a8f2ef38b68121833651617ed0c01b348582542dee11730d553acdc57a7d0f7c", [:mix], [{:calendar, "~> 0.17", [hex: :calendar, repo: "hexpm", optional: true]}, {:crontab, "~> 1.1", [hex: :crontab, repo: "hexpm", optional: false]}, {:gen_stage, "~> 0.12.2", [hex: :gen_stage, repo: "hexpm", optional: false]}, {:timex, "~> 3.1.13", [hex: :timex, repo: "hexpm", optional: true]}], "hexpm"}, "ranch": {:hex, :ranch, "1.3.2", "e4965a144dc9fbe70e5c077c65e73c57165416a901bd02ea899cfd95aa890986", [:rebar3], [], "hexpm"}, - "scrivener": {:hex, :scrivener, "2.4.0", "c9431804b13ac6a5c4b01eb32188c1ff926898a2d684244d021706841f022e66", [:mix], [], "hexpm"}, + "scrivener": {:hex, :scrivener, "2.5.0", "e1f78c62b6806d91cc9c4778deef1ea4e80aa9fadfce2c16831afe0468cc8a2c", [:mix], [], "hexpm"}, "scrivener_ecto": {:hex, :scrivener_ecto, "1.3.0", "69698428e22810ac8a47abc12d1df5b2f5d8f6b36dc5d5bfe6dd93fde857c576", [:mix], [{:ecto, "~> 2.0", [hex: :ecto, repo: "hexpm", optional: false]}, {:postgrex, "~> 0.11.0 or ~> 0.12.0 or ~> 0.13.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:scrivener, "~> 2.4", [hex: :scrivener, repo: "hexpm", optional: false]}], "hexpm"}, "ssl_verify_fun": {:hex, :ssl_verify_fun, "1.1.1", "28a4d65b7f59893bc2c7de786dec1e1555bd742d336043fe644ae956c3497fbe", [:make, :rebar], [], "hexpm"}, "timex": {:hex, :timex, "3.1.24", "d198ae9783ac807721cca0c5535384ebdf99da4976be8cefb9665a9262a1e9e3", [:mix], [{:combine, "~> 0.7", [hex: :combine, repo: "hexpm", optional: false]}, {:gettext, "~> 0.10", [hex: :gettext, repo: "hexpm", optional: false]}, {:tzdata, "~> 0.1.8 or ~> 0.5", [hex: :tzdata, repo: "hexpm", optional: false]}], "hexpm"}, - "tzdata": {:hex, :tzdata, "0.5.14", "56f05ea3dd87db946966ab3c7168c0b35025c7ee0e9b4fc130a04631f5611eb1", [:mix], [{:hackney, "~> 1.0", [hex: :hackney, repo: "hexpm", optional: false]}], "hexpm"}, + "tzdata": {:hex, :tzdata, "0.5.16", "13424d3afc76c68ff607f2df966c0ab4f3258859bbe3c979c9ed1606135e7352", [:mix], [{:hackney, "~> 1.0", [hex: :hackney, repo: "hexpm", optional: false]}], "hexpm"}, }