renalware-core 2.0.153 → 2.0.159
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/renalware/components/configuration.js +20 -0
- data/app/assets/javascripts/renalware/components/{dialogs.js.erb → dialogs.js} +2 -5
- data/app/assets/javascripts/renalware/components/{feed_only_inputs.js.erb → feed_only_inputs.js} +4 -4
- data/app/assets/javascripts/renalware/components/navigation.js +0 -7
- data/app/assets/javascripts/renalware/components/sortable.js +3 -0
- data/app/assets/javascripts/renalware/{core.js.erb → core.js} +0 -7
- data/app/assets/javascripts/renalware/rollup_compiled.css +62433 -43575
- data/app/assets/javascripts/renalware/rollup_compiled.js +10 -14
- data/app/assets/stylesheets/renalware/base/_variables.scss +1 -0
- data/app/assets/stylesheets/renalware/lib/_foundation_and_overrides.scss +1 -620
- data/app/assets/stylesheets/renalware/lib/_select2-foundation5-overrides.scss +1 -1
- data/app/assets/stylesheets/renalware/modules/_clinical.scss +13 -0
- data/app/assets/stylesheets/renalware/modules/_medications.scss +9 -9
- data/app/assets/stylesheets/renalware/modules/_patients.scss +4 -0
- data/app/assets/stylesheets/renalware/modules/_users.scss +2 -1
- data/app/assets/stylesheets/renalware/partials/_forms.scss +11 -0
- data/app/assets/stylesheets/renalware/partials/_navigation.scss +15 -12
- data/app/assets/stylesheets/renalware/partials/_simple_form.scss +1 -1
- data/app/assets/stylesheets/renalware/partials/_tables.scss +15 -8
- data/app/assets/stylesheets/renalware/partials/_toggle.scss +0 -66
- data/app/assets/stylesheets/renalware/partials/_toggling.scss +18 -0
- data/app/assets/stylesheets/renalware/partials/_trix.scss +12 -0
- data/app/components/renalware/admissions/active_consult_alert_component.html.slim +4 -0
- data/app/components/renalware/admissions/active_consult_alert_component.rb +25 -0
- data/app/components/renalware/article_component.html.slim +5 -0
- data/app/components/renalware/article_component.rb +12 -0
- data/app/components/renalware/events/event_list_component.rb +6 -1
- data/app/components/renalware/medications/tabbed_prescriptions_list_component.html.slim +41 -0
- data/app/components/renalware/medications/tabbed_prescriptions_list_component.rb +47 -0
- data/app/components/renalware/patients/messages_component.html.slim +45 -0
- data/app/components/renalware/patients/messages_component.rb +52 -0
- data/app/components/renalware/pd/adequacy_results_component.html.slim +3 -5
- data/app/components/renalware/pd/pet_results_component.html.slim +1 -3
- data/app/components/renalware/system/admin_menu_component.html.slim +3 -1
- data/app/components/renalware/users/last_signin_component.html.slim +3 -0
- data/app/components/renalware/users/last_signin_component.rb +23 -0
- data/app/controllers/renalware/admin/playgrounds_controller.rb +1 -1
- data/app/controllers/renalware/admin/users_controller.rb +1 -0
- data/app/controllers/renalware/drugs/drugs_controller.rb +4 -0
- data/app/controllers/renalware/hd/historical_profiles_controller.rb +1 -1
- data/app/controllers/renalware/medications/prescriptions_controller.rb +5 -2
- data/app/controllers/renalware/messaging/internal/messages_controller.rb +14 -5
- data/app/controllers/renalware/pathology/observation_descriptions_controller.rb +58 -0
- data/app/controllers/renalware/patients/mdms_controller.rb +104 -0
- data/app/controllers/renalware/pd/pet_results_controller.rb +1 -1
- data/app/controllers/renalware/system/view_metadata_controller.rb +61 -0
- data/app/controllers/renalware/users_controller.rb +25 -0
- data/app/helpers/renalware/drugs_helper.rb +6 -0
- data/app/helpers/renalware/layout_helper.rb +1 -1
- data/app/models/concerns/renalware/sortable.rb +49 -0
- data/app/models/renalware/accesses/patient.rb +2 -2
- data/app/models/renalware/accesses/plan.rb +1 -1
- data/app/models/renalware/admissions/request.rb +1 -0
- data/app/models/renalware/clinical/body_composition.rb +1 -1
- data/app/models/renalware/clinical/dry_weight.rb +1 -1
- data/app/models/renalware/clinics/clinic_visit.rb +5 -4
- data/app/models/renalware/feeds/files/create_feed_file.rb +1 -1
- data/app/models/renalware/hd/patient.rb +1 -1
- data/app/models/renalware/hd/preference_set.rb +1 -1
- data/app/models/renalware/hd/profile.rb +4 -4
- data/app/models/renalware/hd/schedule_definition.rb +1 -1
- data/app/models/renalware/hd/session.rb +2 -2
- data/app/models/renalware/hd/session_forms/batch_compile_pdfs.rb +1 -1
- data/app/models/renalware/hd/station.rb +2 -1
- data/app/models/renalware/letters/description.rb +2 -0
- data/app/models/renalware/letters/letter.rb +1 -1
- data/app/models/renalware/letters/part/prescriptions.rb +12 -3
- data/app/models/renalware/letters/pdf_letter_cache.rb +1 -1
- data/app/models/renalware/letters/printing/batch_compile_pdfs.rb +1 -1
- data/app/models/renalware/letters/recipient_params_processor.rb +1 -1
- data/app/models/renalware/medications/prescription.rb +0 -4
- data/app/models/renalware/messaging/internal/message_form.rb +1 -0
- data/app/models/renalware/messaging/internal/message_form_builder.rb +2 -1
- data/app/models/renalware/pathology/current_observations_for_descriptions_query.rb +3 -3
- data/app/models/renalware/pathology/measurement_unit.rb +13 -0
- data/app/models/renalware/pathology/observation_description.rb +23 -5
- data/app/models/renalware/pathology/observation_descriptions_by_code_query.rb +1 -1
- data/app/models/renalware/pathology/observation_requests_attributes_builder.rb +45 -5
- data/app/models/renalware/pathology/observations_within_date_range_query.rb +1 -1
- data/app/models/renalware/patient.rb +2 -2
- data/app/models/renalware/patients/bookmark.rb +2 -2
- data/app/models/renalware/patients/mdm_menu.rb +41 -0
- data/app/models/renalware/patients/mdm_patients_query.rb +1 -1
- data/app/models/renalware/patients/search_query.rb +1 -1
- data/app/models/renalware/patients/worry.rb +0 -1
- data/app/models/renalware/pd/mdm_patients_query.rb +1 -1
- data/app/models/renalware/problems/problem.rb +2 -1
- data/app/models/renalware/snippets/snippet_query.rb +1 -1
- data/app/models/renalware/surveys/question.rb +1 -2
- data/app/models/renalware/system/column_definition.rb +43 -0
- data/app/models/renalware/system/filter_definition.rb +29 -0
- data/app/models/renalware/system/update_user.rb +5 -0
- data/app/models/renalware/system/version.rb +11 -0
- data/app/models/renalware/system/view_metadata.rb +25 -0
- data/app/models/renalware/transplants/donation.rb +1 -1
- data/app/models/renalware/transplants/donor_followup.rb +0 -1
- data/app/models/renalware/transplants/failure_cause_description.rb +1 -1
- data/app/models/renalware/transplants/mdm_patients_query.rb +2 -2
- data/app/models/renalware/transplants/patient.rb +1 -1
- data/app/models/renalware/transplants/recipient_followup.rb +1 -3
- data/app/models/renalware/transplants/registration.rb +1 -3
- data/app/models/renalware/transplants/registrations/wait_list_query.rb +4 -4
- data/app/models/renalware/ukrdc/measurement_unit.rb +21 -0
- data/app/models/renalware/ukrdc/outgoing/rendering/lab_order.rb +30 -2
- data/app/models/renalware/ukrdc/paths.rb +1 -1
- data/app/models/renalware/ukrdc/treatment_timeline/prepare_tables.rb +1 -1
- data/app/models/renalware/ukrdc/treatment_timeline/remap_model_table_names_to_their_prepared_equivalents.rb +1 -1
- data/app/models/renalware/virology/vaccination.rb +5 -0
- data/app/policies/application_policy.rb +1 -1
- data/app/policies/renalware/medications/prescription_policy.rb +35 -0
- data/app/policies/renalware/system/view_metadata_policy.rb +17 -0
- data/app/presenters/concerns/renalware/accountable_presentation.rb +33 -0
- data/app/presenters/renalware/clinics/visit_presenter.rb +11 -0
- data/app/presenters/renalware/events/event_presenter.rb +11 -0
- data/app/presenters/renalware/mdm_presenter.rb +11 -0
- data/app/presenters/renalware/pathology/results_presenter.rb +1 -2
- data/app/presenters/renalware/renal/clinical_summary_presenter.rb +9 -6
- data/app/presenters/renalware/user_session_presenter.rb +1 -3
- data/app/views/renalware/admin/playgrounds/show.html.slim +2 -6
- data/app/views/renalware/admin/users/edit.html.slim +9 -0
- data/app/views/renalware/admin/users/index.html.slim +6 -0
- data/app/views/renalware/admissions/admissions/_filters.html.slim +8 -16
- data/app/views/renalware/clinical/allergies/_list.html.slim +3 -1
- data/app/views/renalware/dashboard/dashboards/show.html.slim +1 -0
- data/app/views/renalware/hd/protocols/_virology.html.slim +4 -5
- data/app/views/renalware/letters/letters/_form.html.slim +1 -1
- data/app/views/renalware/letters/mailshots/mailshots/_form.html.slim +25 -21
- data/app/views/renalware/letters/parts/_prescriptions.html.slim +4 -0
- data/app/views/renalware/mdm/_prescriptions.html.slim +4 -13
- data/app/views/renalware/mdm/prescriptions/_table.html.slim +3 -1
- data/app/views/renalware/medications/prescriptions/_current_hd.html.slim +13 -0
- data/app/views/renalware/medications/prescriptions/_filter_form.html.slim +26 -13
- data/app/views/renalware/medications/prescriptions/_form.html.slim +3 -2
- data/app/views/renalware/medications/prescriptions/_options.html.slim +3 -3
- data/app/views/renalware/medications/prescriptions/_table.html.slim +5 -4
- data/app/views/renalware/medications/prescriptions/_tables.html.slim +13 -16
- data/app/views/renalware/medications/prescriptions/index.html.slim +5 -4
- data/app/views/renalware/messaging/internal/messages/_form.html.slim +3 -0
- data/app/views/renalware/messaging/internal/messages/index.html.slim +36 -0
- data/app/views/renalware/navigation/_mdms.html.slim +5 -0
- data/app/views/renalware/navigation/_renal.html.slim +1 -0
- data/app/views/renalware/navigation/{_super_admin.html.slim → _super_admin.html.slim.dead} +0 -0
- data/app/views/renalware/pathology/code_groups/edit.html.slim +5 -5
- data/app/views/renalware/pathology/code_groups/index.html.slim +4 -5
- data/app/views/renalware/pathology/code_groups/show.html.slim +25 -26
- data/app/views/renalware/pathology/observation_descriptions/_filters.html.slim +14 -0
- data/app/views/renalware/pathology/observation_descriptions/edit.html.slim +21 -0
- data/app/views/renalware/pathology/observation_descriptions/index.html.slim +38 -0
- data/app/views/renalware/pathology/requests/requests/request_form/_crs_form.html.slim +1 -1
- data/app/views/renalware/patients/alerts/_list.html.slim +1 -0
- data/app/views/renalware/patients/mdms/_filters.html.slim +38 -0
- data/app/views/renalware/patients/mdms/_table.html.slim +72 -0
- data/app/views/renalware/patients/mdms/show.html.slim +18 -0
- data/app/views/renalware/patients/side_menu/_general.html.slim +4 -0
- data/app/views/renalware/patients/worryboard/_filters.html.slim +18 -13
- data/app/views/renalware/pd/_peritonitis_episodes.html.slim +13 -13
- data/app/views/renalware/pd/adequacy_results/_form_fields.html.slim +1 -1
- data/app/views/renalware/pd/adequacy_results/_table.html.slim +2 -2
- data/app/views/renalware/pd/peritonitis_episodes/show.html.slim +8 -6
- data/app/views/renalware/shared/_fieldset.html.slim +1 -2
- data/app/views/renalware/shared/_magellan_block.html.slim +1 -2
- data/app/views/renalware/system/view_metadata/_columns_table.html.slim +44 -0
- data/app/views/renalware/system/view_metadata/_filters_form.html.slim +19 -0
- data/app/views/renalware/system/view_metadata/_versions.html.slim +23 -0
- data/app/views/renalware/system/view_metadata/edit.html.slim +66 -0
- data/app/views/renalware/transplants/mdm/_prescriptions.html.slim +6 -22
- data/app/views/renalware/users/_filters.html.slim +11 -0
- data/app/views/renalware/users/index.html.slim +24 -0
- data/app/views/renalware/virology/vaccinations/_cell.html.slim +1 -1
- data/app/views/renalware/virology/vaccinations/_inputs.html.slim +1 -0
- data/app/views/renalware/virology/vaccinations/_toggled_cell.html.slim +2 -0
- data/config/initializers/core_extensions.rb +2 -2
- data/config/initializers/delayed_job.rb +1 -1
- data/config/initializers/inflections.rb +1 -0
- data/config/initializers/pagy.rb +5 -0
- data/config/locales/renalware/clinical/allergies.en.yml +1 -0
- data/config/locales/renalware/medications/tabbed_prescriptions_list_component.yml +15 -0
- data/config/locales/renalware/navigation/renal.en.yml +1 -0
- data/config/locales/renalware/patients/side_menu.en.yml +1 -0
- data/config/locales/renalware/virology/virology.en.yml +2 -0
- data/config/permissions.yml +1 -0
- data/config/routes.rb +1 -0
- data/config/routes/messaging.rb +9 -1
- data/config/routes/pathology.rb +1 -0
- data/config/routes/patients.rb +1 -0
- data/config/routes/system.rb +3 -0
- data/config/routes/users.rb +3 -0
- data/db/functions/convert_to_float_with_explicit_return_v01.sql +18 -0
- data/db/functions/update_current_observation_set_from_trigger_v05.sql +92 -0
- data/db/functions/update_pathology_observations_nresult_from_trigger_v01.sql +13 -0
- data/db/migrate/20200122182018_update_patient_current_modalities.rb +7 -0
- data/db/migrate/20200122182036_create_transplant_mdm_patients.rb +7 -0
- data/db/migrate/20200122190909_create_view_metadata.rb +44 -0
- data/db/migrate/20200131133223_create_hd_mdm_patients.rb +7 -0
- data/db/migrate/20200205185151_add_columns_to_system_view_metadata.rb +13 -0
- data/db/migrate/20200219113324_create_supportive_care_mdm_patients_view.rb +7 -0
- data/db/migrate/20200622120232_add_limits_to_path_obs_descriptions.rb +18 -0
- data/db/migrate/20200626081248_overload_convert_to_float_function.rb +13 -0
- data/db/migrate/20200626090256_add_nresult_to_pathology_observations.rb +29 -0
- data/db/migrate/20200628094228_add_prescriber_to_users.rb +14 -0
- data/db/migrate/20200812074223_add_public_flag_to_messages.rb +18 -0
- data/db/migrate/20200815150303_create_system_versions.rb +16 -0
- data/db/migrate/20200817085618_create_pd_mdm_patients.rb +7 -0
- data/db/migrate/20200817103930_create_low_clearance_mdm_patients.rb +7 -0
- data/db/migrate/20201001144512_update_fn_update_current_obs_set_triggerv05.rb +13 -0
- data/db/migrate/20201001145452_add_position_to_letter_descriptions.rb +5 -0
- data/db/migrate/20201009090959_make_drug_types_unique.rb +8 -0
- data/db/migrate/20201012160414_add_suggested_measurement_unit_to_pathology_observation_descriptions.rb +18 -0
- data/db/migrate/20201012171428_create_ukrdc_measurement_units.rb +18 -0
- data/db/migrate/20201015160542_add_position_to_drug_types.rb +31 -0
- data/db/migrate/20201020155510_add_bmi_to_clinic_visits.rb +31 -0
- data/db/migrate/20201020164524_update_pd_mdm_patients_view.rb +7 -0
- data/db/migrate/20201020170921_update_hd_mdm_patients_view.rb +7 -0
- data/db/migrate/20201020171139_update_low_clearance_mdm_patients_view.rb +7 -0
- data/db/migrate/20201021153832_update_supportive_care_mdm_patients_view.rb +7 -0
- data/db/migrate/20201021154809_update_transplant_mdm_patients_view.rb +7 -0
- data/db/migrate/20201023092859_remove_unused_indexes.rb +20 -0
- data/db/migrate/20201105153422_update_medication_current_prescriptions_view.rb +7 -0
- data/db/migrate/20201112152752_update_pd_mdm_patients_view1.rb +7 -0
- data/db/seeds/default/system/seeds.rb +1 -0
- data/db/seeds/default/system/view_metadata.rb +91 -0
- data/db/seeds/default/ukrdc/measurement_units.csv +12 -0
- data/db/seeds/default/ukrdc/measurement_units.rb +15 -0
- data/db/seeds/default/ukrdc/seeds.rb +1 -0
- data/db/triggers/update_pathology_observations_nresult_trigger_v01.sql +11 -0
- data/db/views/hd_mdm_patients_v01.sql +69 -0
- data/db/views/hd_mdm_patients_v02.sql +70 -0
- data/db/views/low_clearance_mdm_patients_v01.sql +38 -0
- data/db/views/low_clearance_mdm_patients_v02.sql +39 -0
- data/db/views/medication_current_prescriptions_v01.sql +2 -1
- data/db/views/medication_current_prescriptions_v02.sql +30 -0
- data/db/views/patient_current_modalities_v02.sql +18 -0
- data/db/views/pd_mdm_patients_v01.sql +42 -0
- data/db/views/pd_mdm_patients_v02.sql +43 -0
- data/db/views/pd_mdm_patients_v03.sql +50 -0
- data/db/views/reporting_anaemia_audit_v01.sql +0 -2
- data/db/views/supportive_care_mdm_patients_v01.sql +28 -0
- data/db/views/supportive_care_mdm_patients_v02.sql +29 -0
- data/db/views/transplant_mdm_patients_v01.sql +46 -0
- data/db/views/transplant_mdm_patients_v02.sql +47 -0
- data/lib/renalware/configuration.rb +2 -5
- data/lib/renalware/engine.rb +2 -2
- data/lib/renalware/version_number.rb +1 -1
- data/lib/tasks/db.rake +9 -0
- data/lib/tasks/pd.rake +28 -0
- data/spec/factories/drugs/drug_types.rb +5 -1
- data/spec/factories/messaging/internal/messages.rb +1 -0
- data/spec/factories/patients/practices.rb +1 -1
- data/spec/factories/patients/primary_care_physicians.rb +1 -1
- data/spec/factories/system/users.rb +1 -0
- data/spec/factories/system/view_metadata.rb +20 -0
- data/spec/support/capybara_helper.rb +2 -4
- data/spec/support/letters_spec_helper.rb +1 -1
- data/spec/support/matchers/validate_timeliness_of.rb +1 -1
- data/spec/support/pathology_spec_helper.rb +1 -2
- data/spec/support/policy_spec_helper.rb +12 -0
- data/vendor/assets/javascripts/foundation/foundation.alert.js +43 -0
- data/vendor/assets/javascripts/foundation/foundation.dropdown.js +468 -0
- data/vendor/assets/javascripts/foundation/foundation.js +727 -0
- data/vendor/assets/javascripts/foundation/foundation.reveal.js +522 -0
- data/vendor/assets/javascripts/foundation/foundation.tab.js +247 -0
- data/vendor/assets/javascripts/foundation/foundation.tooltip.js +348 -0
- data/vendor/assets/javascripts/foundation/foundation.topbar.js +458 -0
- data/vendor/assets/stylesheets/foundation/_functions.scss +156 -0
- data/vendor/assets/stylesheets/foundation/components/_alert-boxes.scss +128 -0
- data/vendor/assets/stylesheets/foundation/components/_buttons.scss +261 -0
- data/vendor/assets/stylesheets/foundation/components/_dropdown-buttons.scss +130 -0
- data/vendor/assets/stylesheets/foundation/components/_dropdown.scss +269 -0
- data/vendor/assets/stylesheets/foundation/components/_forms.scss +601 -0
- data/vendor/assets/stylesheets/foundation/components/_global.scss +566 -0
- data/vendor/assets/stylesheets/foundation/components/_grid.scss +292 -0
- data/vendor/assets/stylesheets/foundation/components/_labels.scss +106 -0
- data/vendor/assets/stylesheets/foundation/components/_pagination.scss +163 -0
- data/vendor/assets/stylesheets/foundation/components/_panels.scss +107 -0
- data/vendor/assets/stylesheets/foundation/components/_reveal.scss +212 -0
- data/vendor/assets/stylesheets/foundation/components/_side-nav.scss +120 -0
- data/vendor/assets/stylesheets/foundation/components/_split-buttons.scss +203 -0
- data/vendor/assets/stylesheets/foundation/components/_sub-nav.scss +125 -0
- data/vendor/assets/stylesheets/foundation/components/_tables.scss +135 -0
- data/vendor/assets/stylesheets/foundation/components/_tabs.scss +142 -0
- data/vendor/assets/stylesheets/foundation/components/_tooltips.scss +142 -0
- data/vendor/assets/stylesheets/foundation/components/_top-bar.scss +745 -0
- data/vendor/assets/stylesheets/foundation/components/_type.scss +525 -0
- data/vendor/assets/stylesheets/foundation/components/_visibility.scss +425 -0
- metadata +172 -71
- data/app/assets/javascripts/renalware/components/reporting.js.erb +0 -0
- data/app/assets/javascripts/renalware/components/session_timeout_redirect.js.erb +0 -37
- data/app/views/renalware/pd/infection_organisms/_edit.html.slim.obsolete +0 -16
- data/app/views/renalware/transplants/donor_operations/_sections_nav.html.slim +0 -11
- data/app/views/renalware/transplants/donor_workups/_sections_nav.html.slim +0 -15
- data/app/views/renalware/transplants/recipient_operations/_sections_nav.html.slim +0 -14
- data/app/views/renalware/transplants/recipient_workups/_sections_nav.html.slim +0 -15
- data/lib/core_extensions/active_record/sort.rb +0 -52
- data/spec/support/pages/accesses/procedure_page.rb +0 -53
- data/spec/support/pages/accesses/profile_page.rb +0 -45
- data/spec/support/pages/admissions/consults_page.rb +0 -26
- data/spec/support/pages/clinical/allergy_page.rb +0 -74
- data/spec/support/pages/clinical/profile_page.rb +0 -28
- data/spec/support/pages/hd/prescription_administration_dialog.rb +0 -132
- data/spec/support/pages/letters/form.rb +0 -63
- data/spec/support/pages/letters/mailshots/form.rb +0 -58
- data/spec/support/pages/letters/patient_letters.rb +0 -20
- data/spec/support/pages/low_clearance/profile_page.rb +0 -70
- data/spec/support/pages/medications/home_delivery_dialog.rb +0 -77
- data/spec/support/pages/medications/prescription_fom.rb +0 -62
- data/spec/support/pages/page_object.rb +0 -10
@@ -21,8 +21,6 @@ module Renalware
|
|
21
21
|
# data-session-timeout="3600">
|
22
22
|
# rubocop:disable Metrics/MethodLength
|
23
23
|
def self.session_controller_data_attributes
|
24
|
-
return {} if Renalware.config.session_expiry_use_previous_mechansim
|
25
|
-
|
26
24
|
urls = Renalware::Engine.routes.url_helpers
|
27
25
|
{
|
28
26
|
data: {
|
@@ -39,6 +37,6 @@ module Renalware
|
|
39
37
|
}
|
40
38
|
}
|
41
39
|
end
|
40
|
+
# rubocop:enable Metrics/MethodLength
|
42
41
|
end
|
43
|
-
# rubocop:enable Metrics/MethodLength
|
44
42
|
end
|
@@ -21,12 +21,8 @@ css:
|
|
21
21
|
|
22
22
|
= within_new_admin_layout(title: "Admin Playground") do
|
23
23
|
|
24
|
-
|
25
|
-
|
26
|
-
h2 Pathology Charts
|
27
|
-
span A testbed for trying out highchart linecharts
|
28
|
-
br
|
29
|
-
br
|
24
|
+
= render(Renalware::ArticleComponent.new(title: "Pathology Charts")) do
|
25
|
+
p A testbed for trying out highchart linecharts
|
30
26
|
|
31
27
|
.chart-container(data-controller="charts"
|
32
28
|
data-charts-url=pathology_chart_data_admin_playground_path)
|
@@ -52,6 +52,15 @@
|
|
52
52
|
checked_value: "true",
|
53
53
|
unchecked_value: "false",
|
54
54
|
wrapper: :horizontal_small
|
55
|
+
|
56
|
+
- if current_user.has_role?(:super_admin)
|
57
|
+
= f.input :prescriber,
|
58
|
+
as: :boolean,
|
59
|
+
hint: " User will able to add/edit/terminate prescriptions".html_safe,
|
60
|
+
checked_value: "true",
|
61
|
+
unchecked_value: "false",
|
62
|
+
wrapper: :horizontal_small
|
63
|
+
|
55
64
|
- msg = user.approved? ? "Update" : "Approve"
|
56
65
|
= f.submit msg, class: "button"
|
57
66
|
' or
|
@@ -20,6 +20,7 @@
|
|
20
20
|
th.col-width-tiny= sort_link(user_search, :approved, "Approved")
|
21
21
|
th.col-width-tiny= sort_link(user_search, :hidden, "Hidden")
|
22
22
|
th.col-width-tiny= sort_link(user_search, :consultant, "Consultant")
|
23
|
+
th.col-width-tiny= sort_link(user_search, :prescriber, "Prescriber")
|
23
24
|
th.col-width-date= sort_link(user_search, :expired_at, "Expired On")
|
24
25
|
th.col-width-date-time.show-for-large-up= sort_link(user_search, :current_sign_in_at, "Current sign in")
|
25
26
|
th.col-width-date-time.show-for-large-up= sort_link(user_search, :last_sign_in_at, "Last sign in")
|
@@ -58,6 +59,11 @@
|
|
58
59
|
i.far.fa-check-square
|
59
60
|
- else
|
60
61
|
i.muted.unapproved.far.fa-square
|
62
|
+
td
|
63
|
+
- if user.prescriber?
|
64
|
+
i.far.fa-check-square
|
65
|
+
- else
|
66
|
+
i.muted.unapproved.far.fa-square
|
61
67
|
td.expired= l(user.expired_at&.to_date)
|
62
68
|
td.show-for-large-up= l(user.current_sign_in_at)
|
63
69
|
td.show-for-large-up= l(user.last_sign_in_at)
|
@@ -1,23 +1,15 @@
|
|
1
|
-
.search-form.filters
|
1
|
+
.search-form.filters.filters--flex.max-w-screen-md
|
2
2
|
= simple_form_for form,
|
3
3
|
as: :query,
|
4
4
|
url: admissions_admissions_path,
|
5
5
|
method: :get do |f|
|
6
6
|
|
7
|
-
.row
|
8
|
-
.
|
9
|
-
|
10
|
-
|
11
|
-
.
|
12
|
-
|
13
|
-
|
14
|
-
.columns.medium-2.large-2
|
15
|
-
= ward_dropdown_grouped_by_hospital_unit(f, :hospital_ward_id, label: "Ward", wrapper: nil)
|
16
|
-
.columns.medium-3.large-3
|
17
|
-
= f.input :status,
|
18
|
-
collection: form.status_dropdown_options,
|
19
|
-
include_blank: "Any"
|
20
|
-
.columns.medium-2.large-2.actions.end
|
21
|
-
= f.submit "Filter", class: "button"
|
7
|
+
.flex.flex-col.sm:flex-row.items-end.pb-4
|
8
|
+
.w-full.sm:max-w-xs.pr-2= f.input :term
|
9
|
+
.w-full.pr-2= f.input :hospital_unit_id, collection: Renalware::Hospitals::Unit.pluck(:name, :id)
|
10
|
+
.w-full.sm:min-w-md.pr-2= ward_dropdown_grouped_by_hospital_unit(f, :hospital_ward_id, label: "Ward", wrapper: nil)
|
11
|
+
.w-full.sm:min-w-xs.pr-2= f.input :status, collection: form.status_dropdown_options, include_blank: "Any"
|
12
|
+
.flex-shrink-0.pt-4.filters--actions
|
13
|
+
= f.submit "Filter", class: "button", style: "margin: 0"
|
22
14
|
' or
|
23
15
|
= link_to t("helpers.reset"), admissions_admissions_path
|
@@ -16,6 +16,7 @@ article.clinical-allergies
|
|
16
16
|
tr
|
17
17
|
th.col-width-large= t(".description")
|
18
18
|
th.col-width-date-time= t(".recorded_at")
|
19
|
+
th.col-width-medium= t(".recorded_by")
|
19
20
|
th.col-width-tiny
|
20
21
|
tbody
|
21
22
|
- delete_confirmation_msg = I18n.t("prompts.confirm_delete_with_model", model: "allergy")
|
@@ -23,7 +24,8 @@ article.clinical-allergies
|
|
23
24
|
tr data-allergy-id=allergy.id
|
24
25
|
td= allergy.description
|
25
26
|
td = l(allergy.recorded_at)
|
26
|
-
td.
|
27
|
+
td = allergy.created_by
|
28
|
+
td.actions
|
27
29
|
= link_to t(".delete"),
|
28
30
|
patient_clinical_allergy_path(patient_id: patient, id: allergy),
|
29
31
|
method: :delete,
|
@@ -1,9 +1,8 @@
|
|
1
|
-
- document = Renalware::Virology.cast_patient(protocol.patient).profile&.document || Renalware::
|
1
|
+
- document = Renalware::Virology.cast_patient(protocol.patient).profile&.document || Renalware::Virology::ProfileDocument.new
|
2
2
|
table(style="text-align: left;")
|
3
3
|
/ Do not display hepatitis_b_core_anti_body in the HD protocol as that does not
|
4
4
|
/ imply the patient is infectious
|
5
5
|
- %i(hiv hepatitis_b hepatitis_c htlv).each do |attr|
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
td= document.public_send(attr).to_s
|
6
|
+
tr
|
7
|
+
th= attr_name(document, attr)
|
8
|
+
td= document.public_send(attr).to_s
|
@@ -17,7 +17,7 @@ ruby:
|
|
17
17
|
|
18
18
|
= f.association :letterhead, autofocus: true
|
19
19
|
= f.input :description,
|
20
|
-
collection: Renalware::Letters::Description.pluck(:text).uniq,
|
20
|
+
collection: Renalware::Letters::Description.ordered.pluck(:text).uniq,
|
21
21
|
input_html: { class: "searchable_select" }
|
22
22
|
= hidden_field_tag "description_id"
|
23
23
|
= f.input :clinical, as: :hidden
|
@@ -38,24 +38,28 @@
|
|
38
38
|
br
|
39
39
|
.panel
|
40
40
|
h2
|
41
|
-
i.fas.fa-info-circle
|
42
|
-
span
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
41
|
+
i.fas.fa-info-circle
|
42
|
+
span.pl-3 Help
|
43
|
+
|
44
|
+
markdown:
|
45
|
+
The list of patients to include in a mailshot it determined by the SQL View chosen above.
|
46
|
+
It is intended that a systems or database administrator create this view for you in the
|
47
|
+
renalware database. The view should have one column called 'patient_id' and return the ids
|
48
|
+
of all the patients you want to send this letter to.
|
49
|
+
|
50
|
+
You should ideally create the view in the hospital's
|
51
|
+
own postgres schema (eg 'renalware_kch' in the case of Kings College Hospital) in order to
|
52
|
+
indicate your view is hospital-specific.
|
53
|
+
|
54
|
+
**Note that in order for your view to appear in the dropdown above, its name must start
|
55
|
+
with `letter_mailshot_`**
|
56
|
+
|
57
|
+
Here is a (somewhat pointless) example of a compatible SQL view definition:
|
58
|
+
|
59
|
+
```
|
60
|
+
CREATE OR REPLACE VIEW
|
61
|
+
renalware_kch.letter_mailshot_patients_where_surname_starts_with_r AS
|
62
|
+
SELECT id as patient_id
|
63
|
+
FROM patients
|
64
|
+
WHERE family_name like 'R%';
|
65
|
+
```
|
@@ -3,5 +3,9 @@
|
|
3
3
|
prescriptions: prescriptions.current,
|
4
4
|
recently_changed: prescriptions.recently_changed
|
5
5
|
|
6
|
+
= render "renalware/medications/prescriptions/current_hd",
|
7
|
+
prescriptions: prescriptions.current_hd,
|
8
|
+
recently_changed: prescriptions.recently_changed
|
9
|
+
|
6
10
|
= render "renalware/medications/prescriptions/recently_stopped",
|
7
11
|
prescriptions: prescriptions.recently_stopped
|
@@ -9,19 +9,10 @@ article
|
|
9
9
|
#prescriptions.expandable
|
10
10
|
- if local_assigns[:with_esa] == true
|
11
11
|
|
12
|
-
|
13
|
-
|
14
|
-
|
12
|
+
= render Renalware::Medications::TabbedPrescriptionsListComponent.new([ \
|
13
|
+
{ title: "Current", show_administer_on_hd: true, prescriptions: mdm.current_prescriptions, show_terminated_on: false }, \
|
14
|
+
{ title: "EPO History", prescriptions: mdm.esa_prescriptions },
|
15
|
+
{ title: "Bone Meds", prescriptions: mdm.bone_prescriptions }])
|
15
16
|
|
16
|
-
.tabs-content
|
17
|
-
#current.content.active
|
18
|
-
= render "renalware/mdm/prescriptions/table",
|
19
|
-
prescriptions: mdm.current_prescriptions,
|
20
|
-
show_administer_on_hd: true
|
21
|
-
#epo-history.content
|
22
|
-
= render "renalware/mdm/prescriptions/table",
|
23
|
-
prescriptions: mdm.esa_prescriptions,
|
24
|
-
show_terminated_on: true,
|
25
|
-
show_administer_on_hd: true
|
26
17
|
- else
|
27
18
|
= render "current_prescriptions", mdm: mdm
|
@@ -24,7 +24,9 @@ table.mdm.prescriptions
|
|
24
24
|
td= prescription.route_code
|
25
25
|
- if local_assigns[:show_administer_on_hd]
|
26
26
|
td= prescription.administer_on_hd?
|
27
|
-
td
|
27
|
+
td
|
28
|
+
/- byebug
|
29
|
+
= prescription.provider
|
28
30
|
td= I18n.l prescription.prescribed_on
|
29
31
|
- if local_assigns[:show_terminated_on]
|
30
32
|
td= l(prescription.terminated_on)
|
@@ -0,0 +1,13 @@
|
|
1
|
+
- if prescriptions.any?
|
2
|
+
h3 Drugs to give on Haemodialysis
|
3
|
+
|
4
|
+
ul
|
5
|
+
- prescriptions.each do |prescription|
|
6
|
+
- if recently_changed.include?(prescription)
|
7
|
+
= render "renalware/medications/prescriptions/prescription",
|
8
|
+
prescription: prescription,
|
9
|
+
date_changed: prescription.prescribed_on,
|
10
|
+
recently_changed: true
|
11
|
+
- else
|
12
|
+
= render "renalware/medications/prescriptions/prescription",
|
13
|
+
prescription: prescription
|
@@ -1,16 +1,29 @@
|
|
1
1
|
.medications-filter
|
2
|
-
|
3
|
-
=
|
4
|
-
|
5
|
-
|
2
|
+
.search-form.filters.filters--flex.max-w-screen-md
|
3
|
+
= simple_form_for search, as: :q, url: patient_prescriptions_path(@patient), method: :get do |f|
|
4
|
+
= hidden_field_tag :treatable_id, treatable.id
|
5
|
+
= hidden_field_tag :treatable_type, treatable.class.to_s
|
6
|
+
= hidden_field_tag :filter, 1
|
6
7
|
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
8
|
+
.flex.flex-col.sm:flex-row.items-end.pb-4
|
9
|
+
.w-full.sm:max-w-xs.pr-3
|
10
|
+
= f.input :drug_drug_types_id_in,
|
11
|
+
collection: drug_types,
|
12
|
+
include_blank: "All",
|
13
|
+
label_method: :name,
|
14
|
+
label: "Drug type"
|
15
|
+
.w-full.sm:min-w-md.pr-3
|
16
|
+
= f.input :provider_eq,
|
17
|
+
collection: Renalware::Medications::Provider.codes.map.each_with_index { |z, i| [Renalware::Medications::ProviderCodePresenter.new(z).to_label, i]},
|
18
|
+
include_blank: "Any",
|
19
|
+
label: "Provider"
|
20
|
+
.w-full.pr-3
|
21
|
+
= f.input :administer_on_hd_eq,
|
22
|
+
collection: [["Yes", true], ["No", false]],
|
23
|
+
include_blank: "Any",
|
24
|
+
label: "Give on HD"
|
13
25
|
|
14
|
-
|
15
|
-
|
16
|
-
|
26
|
+
.flex-shrink-0.pt-4.filters--actions
|
27
|
+
= f.submit t("helpers.submit.filter"), class: "button secondary"
|
28
|
+
' or
|
29
|
+
= link_to "reset", patient_prescriptions_path(@patient)
|
@@ -1,7 +1,7 @@
|
|
1
|
-
- if prescription.current?
|
2
|
-
|
1
|
+
- if prescription.current? && policy(prescription).edit?
|
2
|
+
= link_to "Edit", edit_patient_prescription_path(patient, prescription), remote: true
|
3
3
|
- unless prescription.terminated_or_marked_for_termination?
|
4
|
-
|
4
|
+
- if policy(prescription).destroy?
|
5
5
|
= link_to "Terminate",
|
6
6
|
new_patient_medications_prescription_termination_path(patient,
|
7
7
|
prescription,
|
@@ -1,4 +1,5 @@
|
|
1
1
|
- if prescriptions.any?
|
2
|
+
- display_termination_date = !current_scope || local_assigns.fetch(:display_termination_date, false)
|
2
3
|
.row
|
3
4
|
.large-12.columns
|
4
5
|
table[class="auto-layout" id="#{id}"]
|
@@ -20,7 +21,7 @@
|
|
20
21
|
th.col-width-date.wide
|
21
22
|
= sort_link_if(treatable.sortable?, search, :prescribed_on, "Prescribed on")
|
22
23
|
th Recorded By
|
23
|
-
-
|
24
|
+
- if display_termination_date
|
24
25
|
th.col-width-date Terminated On
|
25
26
|
th Terminated By
|
26
27
|
tbody
|
@@ -29,8 +30,8 @@
|
|
29
30
|
- if current_scope
|
30
31
|
td
|
31
32
|
input.discardable-checkbox-used-when-reviewing-drugs-with-patient(type="checkbox")
|
32
|
-
td= render partial: "renalware/medications/prescriptions/options",
|
33
|
-
|
33
|
+
td.actions= render partial: "renalware/medications/prescriptions/options",
|
34
|
+
locals: { patient: patient, prescription: prescription }
|
34
35
|
td= prescription.drug.name
|
35
36
|
td= prescription.drug_type_names
|
36
37
|
td= prescription.dose
|
@@ -42,7 +43,7 @@
|
|
42
43
|
td= prescription.notes
|
43
44
|
td= I18n.l prescription.prescribed_on
|
44
45
|
td= prescription.created_by.full_name
|
45
|
-
-
|
46
|
+
- if display_termination_date
|
46
47
|
td= I18n.l prescription.terminated_on
|
47
48
|
td= prescription.terminated_by&.full_name
|
48
49
|
- else
|
@@ -3,27 +3,24 @@ article
|
|
3
3
|
h2 Current
|
4
4
|
ul
|
5
5
|
li
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
6
|
+
- if policy(Renalware::Medications::Prescription).new?
|
7
|
+
= link_to "Add Prescription",
|
8
|
+
new_patient_prescription_path(patient, treatable),
|
9
|
+
remote: true,
|
10
|
+
class: %i(button add_prescription)
|
10
11
|
|
11
12
|
= render "renalware/medications/prescriptions/table",
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
search: current_search,
|
17
|
-
current_scope: true
|
13
|
+
id: "current-prescriptions",
|
14
|
+
**local_assigns.update(prescriptions: current_prescriptions,
|
15
|
+
search: current_search,
|
16
|
+
current_scope: true)
|
18
17
|
|
19
18
|
- if defined? historical_prescriptions
|
20
19
|
article
|
21
20
|
header
|
22
21
|
h2 Historical
|
23
22
|
= render "renalware/medications/prescriptions/table",
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
search: historical_prescriptions_search,
|
29
|
-
current_scope: false
|
23
|
+
id: "historical-prescriptions",
|
24
|
+
**local_assigns.update(prescriptions: historical_prescriptions,
|
25
|
+
search: historical_prescriptions_search,
|
26
|
+
current_scope: false)
|
@@ -1,8 +1,9 @@
|
|
1
1
|
= content_for(:actions) do
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
2
|
+
- if policy(Renalware::Medications::Prescription).new?
|
3
|
+
= link_to "Add",
|
4
|
+
new_patient_prescription_path(@patient),
|
5
|
+
remote: true,
|
6
|
+
class: "button"
|
6
7
|
|
|
7
8
|
= link_to patient_prescriptions_path(@patient,
|
8
9
|
treatable,
|
@@ -5,6 +5,8 @@
|
|
5
5
|
as: :internal_message,
|
6
6
|
url: messaging_internal_messages_path(patient_id: patient) do |f|
|
7
7
|
h2= t(".title")
|
8
|
+
.rounded-md.bg-yellow-100.border.px-4.py-2.mb-2
|
9
|
+
| Messages are viewable by all users in the patient's clinical summary
|
8
10
|
= f.input :replying_to_message_id, as: :hidden
|
9
11
|
|
10
12
|
/ NB the inline styling here prevents an initial flash and re-jiggle of dropdown content which
|
@@ -24,6 +26,7 @@
|
|
24
26
|
= f.input :subject
|
25
27
|
= f.input :urgent, as: :boolean, boolean_style: :inline
|
26
28
|
= f.input :body, as: :text, input_html: { rows: 7 }
|
29
|
+
= f.input :public, as: :hidden
|
27
30
|
= f.submit "Send", class: :button
|
28
31
|
' or
|
29
32
|
= link_to t(".cancel"),
|
@@ -0,0 +1,36 @@
|
|
1
|
+
= within_patient_layout(title: "Messages", current_patient: patient) do
|
2
|
+
|
3
|
+
table.toggleable.easy-read data-controller="toggle"
|
4
|
+
thead
|
5
|
+
tr
|
6
|
+
th.togglers.noprint= rows_toggler
|
7
|
+
th.col-width-tiny
|
8
|
+
th.col-width-date-time Date
|
9
|
+
th.col-width-medium Author
|
10
|
+
th.col-width-large Subject
|
11
|
+
th
|
12
|
+
' Body
|
13
|
+
i(style="font-weight: normal") - toggle to see complete message
|
14
|
+
- messages.each do |message|
|
15
|
+
tbody
|
16
|
+
tr
|
17
|
+
td= row_toggler
|
18
|
+
- if message.urgent?
|
19
|
+
td
|
20
|
+
span.rounded.bg-orange-300.px-2 urgent
|
21
|
+
- else
|
22
|
+
td
|
23
|
+
td= l(message.created_at)
|
24
|
+
td= message.author
|
25
|
+
td.with-ellipsis= message.subject
|
26
|
+
td.with-ellipsis= message.body
|
27
|
+
tr
|
28
|
+
td
|
29
|
+
td
|
30
|
+
td(colspan=4)
|
31
|
+
p
|
32
|
+
b
|
33
|
+
' Sent to:
|
34
|
+
span = message.recipients.map(&:to_s).join(" & ")
|
35
|
+
p= message.body
|
36
|
+
== pagy_foundation_nav pagination
|