renalware-core 2.0.134 → 2.0.135
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/renalware/deaths_controller.rb +5 -1
- data/app/models/renalware/accesses/patient.rb +10 -3
- data/app/models/renalware/patients/clear_patient_ukrdc_data.rb +1 -0
- data/app/views/renalware/deaths/index.html.slim +2 -2
- data/lib/renalware/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1dd66726ab2f121aa82adb08e1394ac8ff1756942f8d449b9c836515ef15c036
|
4
|
+
data.tar.gz: 7ca005b27ddfc4a1cd1e26991af6919fccbe6da98b2bd9dffb7acb0a31315f53
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6f7b907624c1f47c6aababef3e08aa301f8fed2e06f16edea73d7dfb1d291ed656904e37ed3295fd4a8adb897ab9288f721f14e665b59f84a2060d10abafc8c2
|
7
|
+
data.tar.gz: 717795f78c80e5f23cad39a20ecbc0395029f77fde81a738043fc67c8c71bf06f3bda2e0f6d18b682b63d8a26bf2c9e10386839b273219b40c39410db9fff6fc
|
@@ -7,8 +7,12 @@ module Renalware
|
|
7
7
|
|
8
8
|
def index
|
9
9
|
patients = Patient.dead.page(page).per(per_page)
|
10
|
+
search = patients.ransack(params[:q])
|
10
11
|
authorize patients
|
11
|
-
render locals: {
|
12
|
+
render locals: {
|
13
|
+
patients: present(search.result, PatientPresenter),
|
14
|
+
q: search
|
15
|
+
}
|
12
16
|
end
|
13
17
|
|
14
18
|
def edit
|
@@ -27,11 +27,18 @@ module Renalware
|
|
27
27
|
SQL
|
28
28
|
}
|
29
29
|
|
30
|
+
# Because the database allows multiple current access profiles, this scope
|
31
|
+
# needs to choose just one, otherwise queries that merge in this scope
|
32
|
+
# can have duplicates, or worse, broken pagination.
|
30
33
|
scope :with_profile, lambda {
|
31
34
|
joins(<<-SQL)
|
32
|
-
left outer join
|
33
|
-
|
34
|
-
|
35
|
+
left outer join (
|
36
|
+
select distinct on (patient_id) * from access_profiles
|
37
|
+
where
|
38
|
+
access_profiles.terminated_on is null
|
39
|
+
and access_profiles.started_on <= current_date
|
40
|
+
order by patient_id, updated_at desc
|
41
|
+
) access_profiles on (access_profiles.patient_id = patients.id)
|
35
42
|
left outer join access_types on access_types.id = access_profiles.type_id
|
36
43
|
SQL
|
37
44
|
}
|
@@ -13,8 +13,8 @@
|
|
13
13
|
th.col-width-nhs-no NHS No.
|
14
14
|
th.col-width-reference-no Hosp No.
|
15
15
|
th.col-width-tiny Sex
|
16
|
-
th.col-width-date Date of Birth
|
17
|
-
th.col-width-date Date of Death
|
16
|
+
th.col-width-date= sort_link([:renalware, q], :born_on, "Date of Birth")
|
17
|
+
th.col-width-date-time= sort_link([:renalware, q], :died_on, "Date of Death")
|
18
18
|
th.col-width-tiny Age
|
19
19
|
th.col-width-medium
|
20
20
|
|
data/lib/renalware/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
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.135
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Airslie
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-02-
|
11
|
+
date: 2020-02-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: actionview-component
|