renalware-core 2.0.137 → 2.0.138

Sign up to get free protection for your applications and to get access to all the features.
Files changed (173) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/images/renalware/icons/home.svg +1 -0
  3. data/app/assets/images/renalware/icons/settings.svg +1 -0
  4. data/app/assets/javascripts/renalware/components/hd.js +0 -109
  5. data/app/assets/javascripts/renalware/components/toggler.js +0 -29
  6. data/app/assets/javascripts/renalware/core.js.erb +5 -1
  7. data/app/assets/javascripts/renalware/rollup_compiled.js +3888 -0
  8. data/app/assets/stylesheets/renalware/modules/_hd.scss +40 -17
  9. data/app/assets/stylesheets/renalware/partials/_dashboards.scss +1 -1
  10. data/app/assets/stylesheets/renalware/partials/_modal_window.scss +1 -0
  11. data/app/assets/stylesheets/renalware/partials/_navigation.scss +45 -2
  12. data/app/assets/stylesheets/renalware/partials/_pagination.scss +21 -0
  13. data/app/assets/stylesheets/renalware/partials/_tables.scss +9 -0
  14. data/app/assets/stylesheets/renalware/protocol_pdf.scss +45 -6
  15. data/app/components/renalware/application_component.rb +1 -1
  16. data/app/components/renalware/hd/administer_prescription_dropdown_component.html.slim +22 -0
  17. data/app/components/renalware/hd/administer_prescription_dropdown_component.rb +22 -0
  18. data/app/components/renalware/hd/prescription_last_administration_component.html.slim +6 -0
  19. data/app/components/renalware/hd/prescription_last_administration_component.rb +19 -0
  20. data/app/components/renalware/letters/letters_in_progress_component.html.slim +1 -1
  21. data/app/components/renalware/system/admin_menu_component.html.slim +25 -0
  22. data/app/components/renalware/system/admin_menu_component.rb +56 -0
  23. data/app/components/renalware/system/users_awaiting_approval_component.html.slim +6 -0
  24. data/app/components/renalware/system/users_awaiting_approval_component.rb +25 -0
  25. data/app/controllers/renalware/admin/dashboards_controller.rb +9 -0
  26. data/app/controllers/renalware/hd/base_controller.rb +4 -0
  27. data/app/controllers/renalware/hd/prescription_administrations_controller.rb +87 -0
  28. data/app/controllers/renalware/hd/sessions_controller.rb +6 -44
  29. data/app/controllers/renalware/hd/transmission_logs_controller.rb +7 -6
  30. data/app/controllers/renalware/hd/witnesses_controller.rb +62 -0
  31. data/app/helpers/renalware/application_helper.rb +1 -0
  32. data/app/helpers/renalware/layout_helper.rb +12 -0
  33. data/app/helpers/renalware/toggle_helper.rb +13 -4
  34. data/app/javascript/renalware/controllers/another_test_controller.js +8 -0
  35. data/app/javascript/renalware/controllers/hd/prescription_administration_controller.js +22 -0
  36. data/app/javascript/renalware/controllers/test_controller.js +8 -0
  37. data/app/javascript/renalware/controllers/toggle_controller.js +36 -0
  38. data/app/javascript/renalware/index.js +25 -0
  39. data/app/models/renalware/hd/patient.rb +1 -0
  40. data/app/models/renalware/hd/prescription_administration.rb +57 -33
  41. data/app/models/renalware/hd/prescription_last_administration_query.rb +29 -0
  42. data/app/models/renalware/hd/sessions/save_session.rb +1 -25
  43. data/app/models/renalware/hd/witness_form.rb +31 -0
  44. data/app/policies/renalware/hd/prescription_administration_policy.rb +8 -0
  45. data/app/presenters/renalware/admin/users/{summary_part.rb → summary_part.rb.dead} +0 -0
  46. data/app/presenters/renalware/hd/dashboard_presenter.rb +16 -7
  47. data/app/views/renalware/accesses/plans/_details.html.slim +1 -1
  48. data/app/views/renalware/admin/cache/show.html.slim +1 -1
  49. data/app/views/renalware/admin/dashboards/show.html.slim +4 -0
  50. data/app/views/renalware/admin/users/{_summary_part.html.slim → _summary_part.html.slim.dead} +1 -1
  51. data/app/views/renalware/admin/users/edit.html.slim +1 -1
  52. data/app/views/renalware/admin/users/index.html.slim +1 -1
  53. data/app/views/renalware/admissions/_summary_part.html.slim +5 -4
  54. data/app/views/renalware/admissions/consults/_summary_part.html.slim +7 -7
  55. data/app/views/renalware/dashboard/dashboards/_content.html.slim +5 -5
  56. data/app/views/renalware/drugs/drugs/edit.html.slim +2 -2
  57. data/app/views/renalware/drugs/drugs/index.html.slim +1 -1
  58. data/app/views/renalware/drugs/drugs/new.html.slim +1 -1
  59. data/app/views/renalware/events/types/edit.html.slim +1 -1
  60. data/app/views/renalware/events/types/index.html.slim +1 -1
  61. data/app/views/renalware/events/types/new.html.slim +1 -1
  62. data/app/views/renalware/hd/cannulation_types/edit.html.slim +1 -1
  63. data/app/views/renalware/hd/cannulation_types/index.html.slim +5 -5
  64. data/app/views/renalware/hd/cannulation_types/new.html.slim +1 -1
  65. data/app/views/renalware/hd/dashboards/_page_actions.html.slim +4 -1
  66. data/app/views/renalware/hd/dashboards/show.html.slim +1 -0
  67. data/app/views/renalware/hd/dialysates/edit.html.slim +1 -1
  68. data/app/views/renalware/hd/dialysates/index.html.slim +1 -1
  69. data/app/views/renalware/hd/dialysates/new.html.slim +1 -1
  70. data/app/views/renalware/hd/dialysers/edit.html.slim +1 -1
  71. data/app/views/renalware/hd/dialysers/index.html.slim +4 -5
  72. data/app/views/renalware/hd/dialysers/new.html.slim +1 -1
  73. data/app/views/renalware/hd/prescription_administrations/_form.html.slim +96 -0
  74. data/app/views/renalware/hd/prescription_administrations/_row.html.slim +25 -0
  75. data/app/views/renalware/hd/prescription_administrations/_table.html.slim +8 -0
  76. data/app/views/renalware/hd/prescription_administrations/_thead.html.slim +11 -0
  77. data/app/views/renalware/hd/prescription_administrations/create.js.erb +4 -0
  78. data/app/views/renalware/hd/prescription_administrations/edit.html.slim +5 -0
  79. data/app/views/renalware/hd/prescription_administrations/edit.js.erb +11 -0
  80. data/app/views/renalware/hd/prescription_administrations/index.html.slim +3 -0
  81. data/app/views/renalware/hd/prescription_administrations/new.html.slim +3 -0
  82. data/app/views/renalware/hd/prescription_administrations/new.js.erb +5 -0
  83. data/app/views/renalware/hd/protocols/_allergies.html.slim +3 -0
  84. data/app/views/renalware/hd/protocols/_latest_dry_weight.html.slim +3 -2
  85. data/app/views/renalware/hd/protocols/_prescriptions.html.slim +15 -7
  86. data/app/views/renalware/hd/protocols/_profile.html.slim +12 -12
  87. data/app/views/renalware/hd/protocols/_protocol.pdf.slim +2 -3
  88. data/app/views/renalware/hd/sessions/_form.html.slim +2 -6
  89. data/app/views/renalware/hd/sessions/_index_tabs.html.slim +11 -0
  90. data/app/views/renalware/hd/sessions/_list.html.slim +21 -1
  91. data/app/views/renalware/hd/sessions/_table.html.slim +1 -18
  92. data/app/views/renalware/hd/sessions/closed/_form.html.slim +1 -2
  93. data/app/views/renalware/hd/sessions/edit.html.slim +1 -2
  94. data/app/views/renalware/hd/sessions/new.html.slim +1 -2
  95. data/app/views/renalware/hd/sessions/open/_form.html.slim +1 -2
  96. data/app/views/renalware/hd/transmission_logs/index.html.slim +2 -2
  97. data/app/views/renalware/hd/witnesses/_form.html.slim +49 -0
  98. data/app/views/renalware/hd/witnesses/edit.html.slim +1 -0
  99. data/app/views/renalware/hd/witnesses/edit.js.erb +3 -0
  100. data/app/views/renalware/hd/witnesses/update.js.erb +4 -0
  101. data/app/views/renalware/layouts/_admin.html.slim +28 -0
  102. data/app/views/renalware/layouts/_patient.html.slim +1 -1
  103. data/app/views/renalware/letters/batches/index.html.slim +1 -1
  104. data/app/views/renalware/letters/letters/_letter.html.slim +1 -1
  105. data/app/views/renalware/modalities/descriptions/edit.html.slim +1 -1
  106. data/app/views/renalware/modalities/descriptions/index.html.slim +1 -1
  107. data/app/views/renalware/modalities/descriptions/new.html.slim +1 -1
  108. data/app/views/renalware/navigation/_admin.html.slim +1 -1
  109. data/app/views/renalware/navigation/_menu.html.slim +7 -6
  110. data/app/views/renalware/navigation/_user.html.slim +3 -4
  111. data/app/views/renalware/pathology/observation_requests/_filters.html.slim +1 -1
  112. data/app/views/renalware/pathology/requests/requests/index.html.slim +1 -1
  113. data/app/views/renalware/pathology/requests/rules/index.html.slim +1 -1
  114. data/app/views/renalware/patients/_layout.html.slim +1 -1
  115. data/app/views/renalware/patients/_summary_part.html.slim +1 -1
  116. data/app/views/renalware/patients/primary_care_physicians/edit.html.slim +1 -1
  117. data/app/views/renalware/patients/primary_care_physicians/index.html.slim +3 -5
  118. data/app/views/renalware/patients/primary_care_physicians/new.html.slim +1 -1
  119. data/app/views/renalware/pd/bag_types/edit.html.slim +1 -1
  120. data/app/views/renalware/pd/bag_types/index.html.slim +1 -1
  121. data/app/views/renalware/pd/bag_types/new.html.slim +1 -1
  122. data/app/views/renalware/problems/problems/_summary_part.html.slim +1 -1
  123. data/app/views/renalware/research/study_participants/index.html.slim +2 -3
  124. data/app/views/renalware/surveys/_pos_s_summary_part.html.slim +2 -1
  125. data/app/views/renalware/system/email_templates/index.html.slim +5 -1
  126. data/app/views/renalware/system/messages/edit.html.slim +1 -1
  127. data/app/views/renalware/system/messages/index.html.slim +1 -1
  128. data/app/views/renalware/system/messages/new.html.slim +1 -1
  129. data/app/views/renalware/system/user_feedback/edit.html.slim +1 -1
  130. data/app/views/renalware/system/user_feedback/index.html.slim +1 -1
  131. data/app/views/renalware/transplants/mdm/_bottom.html.slim +1 -1
  132. data/config/initializers/pagy.rb +9 -0
  133. data/config/locales/renalware/hd/dashboards.en.yml +1 -0
  134. data/config/locales/renalware/hd/session.en.yml +2 -1
  135. data/config/routes/admin.rb +1 -0
  136. data/config/routes/hd.rb +9 -0
  137. data/db/migrate/20190627141751_add_tokens_to_hd_prescription_administrations.rb +0 -2
  138. data/db/migrate/20200204153231_alter_hd_prescription_administrations.rb +18 -0
  139. data/db/seeds/default/accesses/access_pd_catheter_insertion_techniques.rb +0 -1
  140. data/db/seeds/default/accesses/access_plan_types.rb +0 -1
  141. data/db/seeds/default/accesses/access_sites.rb +0 -1
  142. data/db/seeds/default/clinics/clinics.rb +0 -1
  143. data/db/seeds/default/events/event_types.rb +0 -1
  144. data/db/seeds/default/hd/cannulation_types.rb +0 -1
  145. data/db/seeds/default/hd/dialysers.rb +0 -1
  146. data/db/seeds/default/modalities/reasons.rb +19 -19
  147. data/db/seeds/default/pathology/measurement_units.rb +0 -1
  148. data/db/seeds/default/patients/patients_ethnicities.rb +0 -1
  149. data/db/seeds/default/patients/patients_languages.rb +1 -0
  150. data/db/seeds/default/patients/patients_religions.rb +0 -1
  151. data/db/seeds/default/pd/bag_types.rb +0 -1
  152. data/db/seeds/default/pd/organisms.rb +0 -1
  153. data/db/seeds/default/pd/systems.rb +0 -1
  154. data/db/seeds/default/pd/training_sites.rb +0 -1
  155. data/db/seeds/default/pd/training_types.rb +0 -1
  156. data/db/seeds/default/practices/practices.rb +2 -2
  157. data/db/seeds/default/practices/primary_care_physicians.rb +1 -2
  158. data/db/seeds/default/renal/prd_descriptions.rb +1 -0
  159. data/db/seeds/default/system/roles.rb +1 -1
  160. data/lib/renalware/engine.rb +1 -0
  161. data/lib/renalware/version.rb +1 -1
  162. data/spec/factories/hd/prescription_administrations.rb +17 -0
  163. data/spec/support/factory_bot.rb +2 -0
  164. data/spec/support/pages/hd/prescription_administration_dialog.rb +132 -0
  165. metadata +62 -12
  166. data/app/assets/javascripts/renalware/components/bla.es6 +0 -1
  167. data/app/controllers/renalware/hd/prescription_administration_authorisations_controller.rb +0 -27
  168. data/app/javascript/controllers/clipboard_controller.js.dead +0 -16
  169. data/app/views/renalware/hd/sessions/_administered_drugs_row.html.slim +0 -27
  170. data/app/views/renalware/hd/sessions/_administered_drugs_thead.html.slim +0 -11
  171. data/app/views/renalware/hd/sessions/_prescription_administrations.html.slim +0 -20
  172. data/app/views/renalware/hd/sessions/closed/_administered_drugs_row.html.slim +0 -3
  173. data/app/views/renalware/hd/sessions/form/_drugs_to_be_administered.html.slim +0 -84
@@ -11,11 +11,10 @@
11
11
  tr
12
12
  th.protocol-hd-profile HD Profile
13
13
  th.protocol-allergies
14
- = clinical_patient.allergy_status&.text
14
+ | Allergies
15
15
  - if clinical_patient.allergy_status_updated_at
16
16
  span.allergy_status_updated_at
17
- = "#{l(clinical_patient.allergy_status_updated_at&.to_date)}"
18
-
17
+ = " #{l(clinical_patient.allergy_status_updated_at&.to_date)}"
19
18
  th.protocol-prescriptions Prescriptions on HD
20
19
  th.protocol-recent-pathology Recent Pathology
21
20
  tbody
@@ -57,7 +57,7 @@ ruby:
57
57
  = fcm.input :line_exit_site_status,
58
58
  wrapper: :horizontal_tiny,
59
59
  hint: link_to("", "#",
60
- data: {"reveal-id" => "mr-vistor-help-modal" }),
60
+ data: { "reveal-id" => "mr-vistor-help-modal" }),
61
61
  hint_html: { class: "hint-help-link" }
62
62
 
63
63
  = render layout: "renalware/shared/fieldset",
@@ -66,7 +66,7 @@ ruby:
66
66
  = favf.input :score,
67
67
  wrapper: :horizontal_small,
68
68
  hint: link_to("", "#",
69
- data: {"reveal-id" => "avf-assessment-help-modal" }),
69
+ data: { "reveal-id" => "avf-assessment-help-modal" }),
70
70
  hint_html: { class: "hint-help-link" }
71
71
  = favf.input :aneurysm, as: :inline_radio_buttons, wrapper: :horizontal_medium
72
72
  = favf.input :bruit, as: :inline_radio_buttons, wrapper: :horizontal_medium
@@ -124,10 +124,6 @@ ruby:
124
124
  = fcm.input :subs_goal, wrapper: :horizontal_tiny
125
125
  = fcm.input :subs_volume, wrapper: :horizontal_tiny
126
126
 
127
- = render "renalware/hd/sessions/form/drugs_to_be_administered",
128
- f: f,
129
- prescription_administrations: f.object.prescription_administrations
130
-
131
127
  = render layout: "renalware/shared/fieldset",
132
128
  locals: { legend: "Notes/Complications", name: "complications" } do
133
129
  = fd.simple_fields_for :complications, fd.object.complications do |fcm|
@@ -0,0 +1,11 @@
1
+ .sub-nav
2
+ /with-tabs
3
+ dl
4
+ dd
5
+ = link_to "Details",
6
+ patient_hd_sessions_path(patient)
7
+ /,data: { "trigger-masonry-refresh" => true }
8
+ dd
9
+ = link_to "Drugs given",
10
+ patient_hd_prescription_administrations_path(patient)
11
+ /,data: { "trigger-masonry-refresh" => true }
@@ -2,6 +2,11 @@ article.hd-sessions
2
2
  header
3
3
  h2= t(".title")
4
4
  ul
5
+ li= link_to patient_hd_prescription_administrations_path(@patient),
6
+ class: :button do
7
+ i.fas.fa-capsules
8
+ = t(".view_all_drugs_given")
9
+
5
10
  li= link_to t(".view_all"),
6
11
  patient_hd_sessions_path(@patient),
7
12
  class: :button
@@ -14,4 +19,19 @@ article.hd-sessions
14
19
  new_patient_hd_session_path(@patient),
15
20
  class: "button"
16
21
 
17
- = render "renalware/hd/sessions/table", sessions: sessions
22
+ .sub-nav.with-tabs
23
+ dl
24
+ dd.active
25
+ = link_to "Details", "#hd-sessions", data: { "trigger-masonry-refresh" => true }
26
+ dd
27
+ = link_to "Drugs given", "#hd-session-drugs", data: { "trigger-masonry-refresh" => true }
28
+
29
+ hr.tab-bottom-border
30
+
31
+ = render "renalware/hd/sessions/table",
32
+ sessions: sessions,
33
+ prescription_administrations: prescription_administrations
34
+
35
+ = render "renalware/hd/prescription_administrations/table",
36
+ prescription_administrations: prescription_administrations,
37
+ initially_visible: false
@@ -1,13 +1,6 @@
1
1
 
2
- .sub-nav.with-tabs
3
- dl
4
- dd.active
5
- = link_to "Details", "#hd-sessions", data: { "trigger-masonry-refresh" => true }
6
- dd
7
- = link_to "Drugs given", "#hd-session-drugs", data: { "trigger-masonry-refresh" => true }
8
- hr.tab-bottom-border
9
2
  / .column_hover
10
- table.toggleable.auto-layout.hd-sessions#hd-sessions
3
+ table.toggleable.auto-layout.hd-sessions#hd-sessions(data-controller="toggle")
11
4
  = render "renalware/hd/sessions/thead"
12
5
 
13
6
  - sessions.each_with_index do |session, index|
@@ -15,13 +8,3 @@ table.toggleable.auto-layout.hd-sessions#hd-sessions
15
8
  = render "renalware/hd/sessions/#{session.state}/row",
16
9
  session: session,
17
10
  stripe_class: stripe_class
18
-
19
- /.column_hover
20
- table.toggleable.auto-layout.hd-sessions.hd-session-drugs#hd-session-drugs(style="display: none")
21
- = render "renalware/hd/sessions/administered_drugs_thead"
22
-
23
- - sessions.each_with_index do |session, index|
24
- - stripe_class = index % 2 == 0 ? "even" : "odd"
25
- = render "renalware/hd/sessions/#{session.state}/administered_drugs_row",
26
- session: session,
27
- stripe_class: stripe_class
@@ -1,5 +1,4 @@
1
1
  = render "renalware/hd/sessions/form",
2
2
  f: f,
3
3
  session: session,
4
- patient: patient,
5
- prescriptions_to_be_administered_on_hd: prescriptions_to_be_administered_on_hd
4
+ patient: patient
@@ -12,5 +12,4 @@
12
12
  = render "renalware/hd/sessions/#{session.state}/form",
13
13
  f: f,
14
14
  session: session,
15
- patient: patient,
16
- prescriptions_to_be_administered_on_hd: prescriptions_to_be_administered_on_hd
15
+ patient: patient
@@ -13,5 +13,4 @@
13
13
  = render "renalware/hd/sessions/#{session.state}/form",
14
14
  f: f,
15
15
  session: session,
16
- patient: patient,
17
- prescriptions_to_be_administered_on_hd: prescriptions_to_be_administered_on_hd
16
+ patient: patient
@@ -1,5 +1,4 @@
1
1
  = render "renalware/hd/sessions/form",
2
2
  f: f,
3
3
  session: session,
4
- patient: patient,
5
- prescriptions_to_be_administered_on_hd: prescriptions_to_be_administered_on_hd
4
+ patient: patient
@@ -1,4 +1,4 @@
1
- = within_admin_layout(title: "HD Transmission Logs") do
1
+ = within_new_admin_layout(title: "HD Transmission Logs") do
2
2
  .hd_transmission_logs
3
3
  table.stripeless
4
4
  thead
@@ -52,4 +52,4 @@
52
52
  td.result
53
53
  = log.error_messages.compact.uniq.join("<br>").html_safe
54
54
 
55
- = paginate logs
55
+ == pagy_foundation_nav pagy
@@ -0,0 +1,49 @@
1
+ = simple_form_for(form,
2
+ remote: true,
3
+ as: :form,
4
+ html: { autocomplete: "off" },
5
+ method: :patch,
6
+ url: hd_prescription_administration_witness_path(form.prescription_administration_id)) do |f|
7
+ .modal
8
+ .modal__header
9
+ h2= "Witness HD Drug"
10
+ = render "renalware/shared/modal_close_link"
11
+
12
+ .modal__body
13
+
14
+ - prescription = Renalware::Medications::PrescriptionPresenter.new(administration.prescription)
15
+ .hd-drug-administration.panel
16
+ .summary
17
+ .hd-drug
18
+ .hd-drug--name= prescription.drug_name
19
+ .hd-drug--dose= prescription.dose
20
+ .hd-drug--route= prescription.route_code
21
+ .hd-drug--frequency= prescription.frequency
22
+ .hd-drug--prescribed-on= l(prescription.prescribed_on)
23
+ .hd-drug--prescriber-name= prescription.updated_by
24
+
25
+ - if prescription.terminated_on.present?
26
+ .hd-drug--termination
27
+ | Terminates
28
+ .hd-drug--termination-date= l(prescription.terminated_on)
29
+ br
30
+ span= "Recorded #{l(administration.recorded_on)} by #{administration.administered_by}"
31
+
32
+ = f.input :user_id,
33
+ as: :user_picker,
34
+ collection: Renalware::User.ordered,
35
+ wrapper: :hz_small
36
+ = f.input :password,
37
+ as: :password,
38
+ wrapper: :hz_small
39
+
40
+ .modal__footer
41
+ .right
42
+ = f.submit "Witness", class: "button"
43
+ | &nbsp;&nbsp;
44
+ = f.submit "Update User Only", name: "form[update_user_only]", class: "button secondary"
45
+ span= " or "
46
+ = link_to "Cancel",
47
+ "#",
48
+ "aria-label" => "Close",
49
+ class: "reveal-modal-close"
@@ -0,0 +1 @@
1
+ = render "form", form: form, administration: administration
@@ -0,0 +1,3 @@
1
+ // Render this to re-display the form with errors after an unsuccessful save
2
+ var modal = $("#hd-prescription-administration-modal")
3
+ $(modal).html("<%= j(render 'form', form: form, administration: administration) %>");
@@ -0,0 +1,4 @@
1
+ <%# We render this on successful creation %>
2
+ <%= refresh(".flash-message", partial: "renalware/shared/flash_messages", locals: local_assigns) %>
3
+ $('#hd-prescription-administration-modal').foundation('reveal', 'close');
4
+ window.location.reload();
@@ -0,0 +1,28 @@
1
+ - generate_page_title(local_assigns: local_assigns)
2
+
3
+ nav.patient-side-nav.admin-side-nav.full-screenable
4
+ .layout-wrapper
5
+ = render Renalware::System::AdminMenuComponent.new(current_user: current_user)
6
+
7
+ .non-patient-page.main-content
8
+ .layout-wrapper
9
+ .non-patient-page-header(class=("with-tabs" if content_for?(:tabs)))
10
+ .row
11
+ .columns.small-12
12
+ ul.page-heading
13
+ li
14
+ h1
15
+ = breadcrumbs_and_title(breadcrumbs: local_assigns[:breadcrumbs],
16
+ title: local_assigns[:title])
17
+ li.page-actions
18
+ / Output any page-level actions
19
+ = yield(:actions)
20
+
21
+ - if content_for?(:tabs)
22
+
23
+ = yield(:tabs)
24
+
25
+ .row
26
+ .columns.small-12
27
+ = yield(:filters)
28
+ = yield
@@ -6,7 +6,7 @@
6
6
 
7
7
  nav.patient-side-nav.full-screenable
8
8
  .layout-wrapper
9
- = render Renalware::Patients::SideMenuComponent, patient: current_patient
9
+ = render Renalware::Patients::SideMenuComponent.new(patient: current_patient)
10
10
 
11
11
  .main-content.patient-content.full-screenable
12
12
  .layout-wrapper
@@ -1,4 +1,4 @@
1
- = within_admin_layout(title: "Print Batches") do
1
+ = within_new_admin_layout(title: "Print Batches") do
2
2
 
3
3
  table
4
4
  thead
@@ -1,6 +1,6 @@
1
1
  - columns = local_assigns[:columns] || []
2
2
  - cache([letter, columns.join("-")]) do
3
- tr(class=letter.state.dasherize)
3
+ tr(class=letter.state.dasherize data-controller="toggle")
4
4
  td.noprint= toggler("#letter-quick-preview-#{letter.id}")
5
5
  td.noprint.actions
6
6
  = link_to letter.view_label, patient_letters_letter_path(letter.patient, letter)
@@ -1,4 +1,4 @@
1
- = within_admin_layout(title: "Edit",
1
+ = within_new_admin_layout(title: "Edit",
2
2
  breadcrumbs: breadcrumb_for("Modalities", modalities_descriptions_path))
3
3
 
4
4
  = render "form",
@@ -3,7 +3,7 @@
3
3
  new_modalities_description_path,
4
4
  class: "button"
5
5
 
6
- = within_admin_layout(title: "Modalities") do
6
+ = within_new_admin_layout(title: "Modalities") do
7
7
 
8
8
  table.modality-codes
9
9
  thead
@@ -1,4 +1,4 @@
1
- = within_admin_layout(title: "New",
1
+ = within_new_admin_layout(title: "New",
2
2
  breadcrumbs: breadcrumb_for("Modalities", modalities_descriptions_path))
3
3
 
4
4
  = render "form",
@@ -3,7 +3,7 @@ li.has-dropdown
3
3
  ul.dropdown
4
4
  li= link_to "Users", admin_users_path
5
5
  li= link_to "Request Form Print History", pathology_requests_requests_path
6
- li= link_to "Pathology Requesting Configuration", pathology_requests_rules_path
6
+ li= link_to "Path Request Config", pathology_requests_rules_path
7
7
  li= link_to "HD Transmission Logs", hd_transmission_logs_path
8
8
  - unless Rails.env.production?
9
9
  li
@@ -8,12 +8,13 @@ section.top-bar-section
8
8
  = render "renalware/navigation/mdms"
9
9
  = render "renalware/navigation/patients_admin"
10
10
  = render "renalware/navigation/directory"
11
- - if current_user_is_admin?
12
- = render "renalware/navigation/admin"
13
- - if current_user_is_super_admin?
14
- = render "renalware/navigation/super_admin"
15
- - if current_user_is_developer?
16
- = render "renalware/navigation/developer"
11
+
12
+ - if current_user_is_admin? || current_user_is_super_admin?
13
+ li.menu-item.menu-item--admin
14
+ = link_to renalware.admin_dashboard_path
15
+ i
16
+ | Admin
17
+
17
18
  li.divider
18
19
  = render "renalware/navigation/sign_out"
19
20
  li.divider
@@ -2,11 +2,10 @@
2
2
  li.show-for-medium-up= link_to("Feedback",
3
3
  new_system_user_feedback_path,
4
4
  class: "button secondary")
5
- li.has-dropdown
5
+ li.has-dropdown.menu-item.menu-item--home
6
6
  = link_to dashboard_path do
7
- i.fas.fa-home
8
- | &nbsp;
9
- = current_user.username
7
+ i
8
+ =current_user.username
10
9
  ul.dropdown
11
10
  li= link_to "My Dashboard", dashboard_path
12
11
  li= link_to "Update Profile", edit_user_registration_path
@@ -8,7 +8,7 @@
8
8
  = f.input :description_id_eq,
9
9
  collection: obr_filter_options,
10
10
  label: "Filter by Code",
11
- label_method: ->(arr){ "#{arr[0]} - #{arr[2]}" },
11
+ label_method: ->(arr) { "#{arr[0]} - #{arr[2]}" },
12
12
  input_html: { class: "searchable_select" }
13
13
 
14
14
  .columns.medium-2.large-2.actions.end
@@ -1,4 +1,4 @@
1
- = within_admin_layout(title: "Request Form Print History") do
1
+ = within_new_admin_layout(title: "Request Form Print History") do
2
2
  .row
3
3
  .search-form
4
4
  fieldset
@@ -1,4 +1,4 @@
1
- = within_admin_layout(title: "Pathology Request Form Algorithm") do
1
+ = within_new_admin_layout(title: "Pathology Request Form Algorithm") do
2
2
  table
3
3
  thead
4
4
  tr
@@ -10,7 +10,7 @@
10
10
  - patient_page_title(title: title, patient: current_patient)
11
11
 
12
12
  nav.patient-side-nav
13
- / = render Renalware::Patients::SideMenuComponent, patient: current_patient
13
+ / = render Renalware::Patients::SideMenuComponent.new(patient: current_patient)
14
14
  = render "renalware/patients/side_menu", patient: current_patient
15
15
 
16
16
  .patient-content
@@ -24,7 +24,7 @@
24
24
  header
25
25
  h2 Worryboard notes
26
26
  = link_to("Remove",
27
- patient_worry_path( summary_part.patient, summary_part.worry),
27
+ patient_worry_path(summary_part.patient, summary_part.worry),
28
28
  method: :delete,
29
29
  data: { confirm: "Are you sure you want to remove the patient from the worryboard?" },
30
30
  class: :button)
@@ -1,2 +1,2 @@
1
- = within_admin_layout(title: "Edit Primary Care Physician") do
1
+ = within_new_admin_layout(title: "Edit Primary Care Physician") do
2
2
  = render "form"
@@ -1,9 +1,7 @@
1
- = content_for(:tabs) do
2
- dl.sub-nav
3
- dd= link_to "List", patients_primary_care_physicians_path
4
- dd= link_to "Add Primary Care Physician", new_patients_primary_care_physician_path
1
+ = content_for(:actions) do
2
+ = link_to t("new_record.link_title"), new_patients_primary_care_physician_path, class: "button"
5
3
 
6
- = within_admin_layout(title: "Primary Care Physicians") do
4
+ = within_new_admin_layout(title: "Primary Care Physicians") do
7
5
  table.primary-care-physicians
8
6
  thead
9
7
  tr
@@ -1,2 +1,2 @@
1
- = within_admin_layout(title: "New Primary Care Physician") do
1
+ = within_new_admin_layout(title: "New Primary Care Physician") do
2
2
  = render "form"
@@ -1,2 +1,2 @@
1
- = within_admin_layout(breadcrumbs: breadcrumb_for("PD Bag Types", pd_bag_types_path)) do
1
+ = within_new_admin_layout(breadcrumbs: breadcrumb_for("PD Bag Types", pd_bag_types_path)) do
2
2
  = render "form", bag_type: bag_type
@@ -1,7 +1,7 @@
1
1
  = content_for(:actions) do
2
2
  = link_to t("new_record.link_title"), new_pd_bag_type_path, class: "button"
3
3
 
4
- = within_admin_layout do
4
+ = within_new_admin_layout do
5
5
  table
6
6
  thead
7
7
  tr
@@ -1,2 +1,2 @@
1
- = within_admin_layout(breadcrumbs: breadcrumb_for("PD Bag Types", pd_bag_types_path)) do
1
+ = within_new_admin_layout(breadcrumbs: breadcrumb_for("PD Bag Types", pd_bag_types_path)) do
2
2
  = render "form", bag_type: bag_type
@@ -20,7 +20,7 @@
20
20
  = link_to patient_problems_path(summary_part.patient), class: "button" do
21
21
  | Add
22
22
 
23
- table#problems.toggleable.toggleable--without-border-between-toggled-and-non-toggled-tr
23
+ table#problems.toggleable.toggleable--without-border-between-toggled-and-non-toggled-tr(data-controller="toggle")
24
24
  thead.toggleable--open
25
25
  th.togglers.noprint =rows_toggler
26
26
  th Description