generated from codeforamerica/form-flow-starter-app
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Jefferson Parish to experiment groups (#709)
* Add Jefferson specific WIC and ECE logic
- Loading branch information
1 parent
65acfe3
commit 375813e
Showing
18 changed files
with
254 additions
and
58 deletions.
There are no files selected for viewing
24 changes: 24 additions & 0 deletions
24
src/main/java/org/ladocuploader/app/submission/conditions/EligibleForEceApplyJefferson.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package org.ladocuploader.app.submission.conditions; | ||
|
||
import static org.ladocuploader.app.submission.actions.SetExperimentGroups.ExperimentGroup.APPLY; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.ECE_CUTOFF_DATE; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.hasChildBornAfterCutoff; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.hasHouseholdPregnancy; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.inExperimentGroup; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.isJeffersonParish; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.isOrleansParish; | ||
|
||
import formflow.library.config.submission.Condition; | ||
import formflow.library.data.Submission; | ||
import org.springframework.stereotype.Component; | ||
|
||
@Component | ||
public class EligibleForEceApplyJefferson implements Condition { | ||
|
||
@Override | ||
public Boolean run(Submission submission) { | ||
return isJeffersonParish(submission) | ||
&& inExperimentGroup(APPLY.name(), submission) | ||
&& (hasChildBornAfterCutoff(submission, ECE_CUTOFF_DATE) || hasHouseholdPregnancy(submission)); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
src/main/java/org/ladocuploader/app/submission/conditions/EligibleForEceLinksJefferson.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package org.ladocuploader.app.submission.conditions; | ||
|
||
import static org.ladocuploader.app.submission.actions.SetExperimentGroups.ExperimentGroup.LINK; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.ECE_CUTOFF_DATE; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.hasChildBornAfterCutoff; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.hasHouseholdPregnancy; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.inExperimentGroup; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.isJeffersonParish; | ||
import static org.ladocuploader.app.utils.SubmissionUtilities.isOrleansParish; | ||
|
||
import formflow.library.config.submission.Condition; | ||
import formflow.library.data.Submission; | ||
import org.springframework.stereotype.Component; | ||
|
||
@Component | ||
public class EligibleForEceLinksJefferson implements Condition { | ||
|
||
@Override | ||
public Boolean run(Submission submission) { | ||
return isJeffersonParish(submission) | ||
&& inExperimentGroup(LINK.name(), submission) | ||
&& (hasChildBornAfterCutoff(submission, ECE_CUTOFF_DATE) || hasHouseholdPregnancy(submission)); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.