Skip to content

Commit

Permalink
CDR Module: Ready for review by community.
Browse files Browse the repository at this point in the history
  • Loading branch information
bradymiller committed Apr 25, 2011
1 parent 0747cb1 commit fa8c4f8
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
14 changes: 14 additions & 0 deletions interface/super/rules/library/RuleCriteriaListsBuilder.php
Expand Up @@ -30,6 +30,12 @@ function resolveRuleCriteriaType( $method, $methodDetail, $value ) {
} else if ( $methodDetail == 'medication' ) {
// its a medication
return RuleCriteriaType::from( RuleCriteriaType::medication );
} else if ( $methodDetail == 'allergy' ) {
// its a medication
return RuleCriteriaType::from( RuleCriteriaType::allergy );
} else if ( $methodDetail == 'surgery' ) {
// its a medication
return RuleCriteriaType::from( RuleCriteriaType::surgery );
}
}

Expand All @@ -56,6 +62,14 @@ function build( $ruleCriteriaType, $value, $methodDetail ) {
return new RuleCriteriaMedication( xl( "Medication" ), $value );
}

if ( $ruleCriteriaType->code == 'surgery' ) {
return new RuleCriteriaSurgery( xl( "Surgery" ), $value );
}


if ( $ruleCriteriaType->code == 'allergy' ) {
return new RuleCriteriaAllergy( xl( "Allergy" ), $value );
}
// its unknown
return null;
}
Expand Down
2 changes: 1 addition & 1 deletion version.php
Expand Up @@ -12,5 +12,5 @@
// is a database change in the course of development. It is used
// internally to determine when a database upgrade is needed.
//
$v_database = 20;
$v_database = 21;
?>

0 comments on commit fa8c4f8

Please sign in to comment.