dpickett-clinical 0.2.7 → 0.2.8
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/clinical.gemspec +1 -1
- data/features/finding_clinical_trials.feature +2 -0
- data/lib/clinical/trial.rb +10 -2
- metadata +1 -1
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.8
|
data/clinical.gemspec
CHANGED
@@ -45,6 +45,8 @@ Feature: As a potential participant for a clinical study
|
|
45
45
|
And the trial should have a "minimum_age" of "21 Years"
|
46
46
|
And the trial should have "sponsors" like "M.D. Anderson"
|
47
47
|
And the trial should have an "overall_official" like "Alexandra Phan, MD"
|
48
|
+
And the trial should have "eligibility_criteria" like "DISEASE CHARACTERISTICS"
|
49
|
+
And the trial should have "brief_summary" like "Pazopanib"
|
48
50
|
|
49
51
|
Scenario: Find trials that were updated between a range of dates
|
50
52
|
Given I am searching for trials that have been updated between "07/06/2009" and "07/07/2009"
|
data/lib/clinical/trial.rb
CHANGED
@@ -37,8 +37,8 @@ module Clinical
|
|
37
37
|
element :first_received_at, Date, :tag => "firstreceived_date"
|
38
38
|
element :updated_at, Date, :tag => "lastchanged_date"
|
39
39
|
|
40
|
-
element :
|
41
|
-
element :
|
40
|
+
element :parsed_minimum_age, String, :tag => "eligibility/minimum_age"
|
41
|
+
element :parsed_maximum_age, String, :tag => "eligibility/maximum_age"
|
42
42
|
element :gender, String, :tag => "eligibility/gender"
|
43
43
|
element :healthy_volunteers, String, :tag => "eligibility/healthy_volunteers"
|
44
44
|
|
@@ -66,6 +66,14 @@ module Clinical
|
|
66
66
|
@sponsors ||= [lead_sponsor, (collaborators || []), (agencies || [])].flatten
|
67
67
|
end
|
68
68
|
|
69
|
+
def minimum_age
|
70
|
+
parsed_minimum_age == "N/A" ? nil : parsed_minimum_age
|
71
|
+
end
|
72
|
+
|
73
|
+
def maximum_age
|
74
|
+
parsed_maximum_age == "N/A" ? nil : parsed_maximum_age
|
75
|
+
end
|
76
|
+
|
69
77
|
def outcomes
|
70
78
|
@outcomes ||= [primary_outcomes, secondary_outcomes].flatten
|
71
79
|
end
|