renalware-core 2.0.3 → 2.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/renalware/modules/_patients.scss +23 -0
- data/app/controllers/renalware/admissions/consults_controller.rb +2 -1
- data/app/models/renalware/admissions/consult.rb +3 -1
- data/app/models/renalware/admissions/consult_query.rb +1 -1
- data/app/models/renalware/hd/session/closed.rb +1 -1
- data/app/models/renalware/transplants/recipient_operation.rb +9 -8
- data/app/views/renalware/admissions/consults/_filters.html.slim +5 -0
- data/app/views/renalware/admissions/consults/_table.html.slim +5 -1
- data/app/views/renalware/admissions/consults/edit.html.slim +5 -0
- data/app/views/renalware/patients/_header.html.slim +8 -2
- data/db/migrate/20180313114927_remove_deleted_at_from_admission_consults.rb +5 -0
- data/db/migrate/20180313124819_remove_tx_operation_constraints.rb +9 -0
- data/lib/renalware/version.rb +1 -1
- metadata +3 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 99997d94596ca620e3d8aa825949bfab11b9e7d6c3c09249eb66c57a43ae61f9
|
4
|
+
data.tar.gz: 2f0945104f2bc36f0fb0e01583ae62ac48b86c53533faf5e83dc149216154d5c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5066afacd3a1591643cd489cb4b5711fa864061c2751c60fefa78814031088ccc513b8360c4e0f3db2575932708cca253032bf8507682fe743cbe886bd7a497a
|
7
|
+
data.tar.gz: 1f3f7ae72253ad1d0805f7e9b03b661c3e39f84caccb0faf343e6b4f591104c2b37001f44b8f44a7963e52e1966660be10d56e1fd3ef9be9dae762eb15e16ef0
|
@@ -218,6 +218,29 @@ ul.provider {
|
|
218
218
|
}
|
219
219
|
}
|
220
220
|
}
|
221
|
+
|
222
|
+
&.hospital_no {
|
223
|
+
display: inline-block;
|
224
|
+
margin-right: .6em;
|
225
|
+
margin-left: 0;
|
226
|
+
margin-top: .1rem;
|
227
|
+
|
228
|
+
dt, dd {
|
229
|
+
display: block;
|
230
|
+
padding: 0;
|
231
|
+
margin: 0;
|
232
|
+
}
|
233
|
+
dd {
|
234
|
+
font-size: 1em;
|
235
|
+
line-height: 0.9rem;
|
236
|
+
}
|
237
|
+
|
238
|
+
@media #{$medium-only} {
|
239
|
+
dd {
|
240
|
+
line-height: 0.7rem;
|
241
|
+
}
|
242
|
+
}
|
243
|
+
}
|
221
244
|
}
|
222
245
|
|
223
246
|
.menu-icon {
|
@@ -33,6 +33,7 @@ module Renalware
|
|
33
33
|
end
|
34
34
|
|
35
35
|
def edit
|
36
|
+
session[:consults_results] = request&.referer # for back link
|
36
37
|
render_edit(find_and_authorize_consult)
|
37
38
|
end
|
38
39
|
|
@@ -46,7 +47,7 @@ module Renalware
|
|
46
47
|
end
|
47
48
|
|
48
49
|
def destroy
|
49
|
-
find_and_authorize_consult.
|
50
|
+
find_and_authorize_consult.update!(ended_on: Time.zone.now, by: current_user)
|
50
51
|
redirect_to admissions_consults_path, notice: success_msg_for("consult")
|
51
52
|
end
|
52
53
|
|
@@ -5,7 +5,6 @@ module Renalware
|
|
5
5
|
class Consult < ApplicationRecord
|
6
6
|
include Accountable
|
7
7
|
extend Enumerize
|
8
|
-
acts_as_paranoid
|
9
8
|
validates :patient_id, presence: true
|
10
9
|
validates :started_on, presence: true
|
11
10
|
validates :description, presence: true
|
@@ -21,6 +20,9 @@ module Renalware
|
|
21
20
|
|
22
21
|
enumerize :transfer_priority, in: %i(unknown necessary desirable potential unnecessary)
|
23
22
|
enumerize :aki_risk, in: %i(yes no unknown)
|
23
|
+
|
24
|
+
scope :active, ->{ where(ended_on: nil) }
|
25
|
+
|
24
26
|
end
|
25
27
|
end
|
26
28
|
end
|
@@ -46,7 +46,7 @@ module Renalware
|
|
46
46
|
|
47
47
|
class Dialysis < Renalware::HD::SessionDocument::Dialysis
|
48
48
|
# rubocop:disable Rails/Validation
|
49
|
-
validates_presence_of attribute_set.map(&:name)
|
49
|
+
validates_presence_of attribute_set.map(&:name).reject{ |att| att == :machine_ktv }
|
50
50
|
# rubocop:enable Rails/Validation
|
51
51
|
end
|
52
52
|
attribute :dialysis, Dialysis
|
@@ -21,17 +21,18 @@ module Renalware
|
|
21
21
|
has_document class_name: "Renalware::Transplants::RecipientOperationDocument"
|
22
22
|
|
23
23
|
validates :performed_on, presence: true
|
24
|
-
validates :theatre_case_start_time, presence: true
|
25
|
-
validates :donor_kidney_removed_from_ice_at, presence: true
|
26
|
-
validates :kidney_perfused_with_blood_at, presence: true
|
27
24
|
validates :operation_type, presence: true
|
28
25
|
validates :hospital_centre, presence: true
|
29
|
-
validates :cold_ischaemic_time_formatted, presence: true
|
30
|
-
validates :warm_ischaemic_time_formatted, presence: true
|
31
26
|
|
32
|
-
validates :donor_kidney_removed_from_ice_at,
|
33
|
-
|
34
|
-
|
27
|
+
validates :donor_kidney_removed_from_ice_at,
|
28
|
+
timeliness: { type: :datetime },
|
29
|
+
allow_blank: true
|
30
|
+
validates :kidney_perfused_with_blood_at,
|
31
|
+
timeliness: { type: :datetime },
|
32
|
+
allow_blank: true
|
33
|
+
validates :theatre_case_start_time,
|
34
|
+
timeliness: { type: :time },
|
35
|
+
allow_blank: true
|
35
36
|
|
36
37
|
enumerize :operation_type,
|
37
38
|
in: %i(kidney kidney_dual kidney_pancreas pancreas kidney_liver liver)
|
@@ -22,6 +22,11 @@
|
|
22
22
|
include_blank: true,
|
23
23
|
collection: Renalware::Admissions::Consult.aki_risk.values.map{ |value| [value.text, value] },
|
24
24
|
label: "AKI Risk"
|
25
|
+
/ .columns.medium-2.large-1
|
26
|
+
/ = f.input :stopped_on_eq_nil,
|
27
|
+
/ include_blank: false,
|
28
|
+
/ collection: [["Yes", true], ["No", false]],
|
29
|
+
/ label: "Active"
|
25
30
|
.columns.medium-2.large-2.actions.end
|
26
31
|
= f.submit "Filter", class: "button"
|
27
32
|
span= " or "
|
@@ -2,10 +2,12 @@
|
|
2
2
|
table
|
3
3
|
thead
|
4
4
|
tr
|
5
|
-
th
|
5
|
+
th= sort_link(query, :consult_site_id, "Location")
|
6
6
|
th.at-least.col-width-medium Patient
|
7
7
|
th.col-width-nhs-no NHS No.
|
8
8
|
th.col-width-reference-no Hosp Nos.
|
9
|
+
th.col-width-date Started
|
10
|
+
th.col-width-date Ended
|
9
11
|
th.col-width-medium Modality
|
10
12
|
th.col-width-tiny Sex
|
11
13
|
th.col-width-tiny Age
|
@@ -22,6 +24,8 @@
|
|
22
24
|
td= consult.patient_name
|
23
25
|
td= consult.patient_nhs_number
|
24
26
|
td= consult.patient_hospital_identifiers
|
27
|
+
td= l(consult.started_on)
|
28
|
+
td= l(consult.ended_on)
|
25
29
|
td= consult.patient_current_modality
|
26
30
|
td= consult.patient_sex
|
27
31
|
td= consult.patient_age
|
@@ -1,6 +1,11 @@
|
|
1
|
+
|
1
2
|
= within_admin_layout( \
|
2
3
|
title: "Edit",
|
3
4
|
breadcrumbs: breadcrumb_for("Admission Consults", admissions_consults_path) \
|
4
5
|
) do
|
5
6
|
|
7
|
+
= link_to "< Back to search results",
|
8
|
+
session[:consults_results] || admissions_consults_path,
|
9
|
+
class: "button secondary"
|
10
|
+
br
|
6
11
|
= render "form", consult: consult
|
@@ -16,8 +16,14 @@
|
|
16
16
|
a
|
17
17
|
i.fa.fa-ellipsis-v
|
18
18
|
= patient
|
19
|
-
|
20
|
-
|
19
|
+
- if patient.hospital_identifiers.all.count > 1
|
20
|
+
- patient.hospital_identifiers.all.each do |hospital_identifier|
|
21
|
+
dl.hospital_no
|
22
|
+
dt= hospital_identifier[0]
|
23
|
+
dd= hospital_identifier[1]
|
24
|
+
- else
|
25
|
+
dt= patient.hospital_identifier.name
|
26
|
+
dd= patient.hospital_identifier.id
|
21
27
|
dt= t(".nhs_number")
|
22
28
|
dd= formatted_nhs_number(patient)
|
23
29
|
dt= t(".sex")
|
@@ -0,0 +1,9 @@
|
|
1
|
+
class RemoveTxOperationConstraints < ActiveRecord::Migration[5.1]
|
2
|
+
def change
|
3
|
+
change_column_null :transplant_recipient_operations, :theatre_case_start_time, true
|
4
|
+
change_column_null :transplant_recipient_operations, :donor_kidney_removed_from_ice_at, true
|
5
|
+
change_column_null :transplant_recipient_operations, :kidney_perfused_with_blood_at, true
|
6
|
+
change_column_null :transplant_recipient_operations, :warm_ischaemic_time, true
|
7
|
+
change_column_null :transplant_recipient_operations, :cold_ischaemic_time, true
|
8
|
+
end
|
9
|
+
end
|
data/lib/renalware/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: renalware-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Airslie
|
@@ -3194,6 +3194,8 @@ files:
|
|
3194
3194
|
- db/migrate/20180309140316_add_unique_constraint_to_obr_requestor.rb
|
3195
3195
|
- db/migrate/20180311071146_update_patient_summaries_to_version6.rb
|
3196
3196
|
- db/migrate/20180311104609_remove_unique_obr_requestor_order_number_index.rb
|
3197
|
+
- db/migrate/20180313114927_remove_deleted_at_from_admission_consults.rb
|
3198
|
+
- db/migrate/20180313124819_remove_tx_operation_constraints.rb
|
3197
3199
|
- db/seeds.rb
|
3198
3200
|
- db/seeds/default/accesses/access_pd_catheter_insertion_techniques.csv
|
3199
3201
|
- db/seeds/default/accesses/access_pd_catheter_insertion_techniques.rb
|