-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add SNAP/OHEP info screens to flow start (#110)
- Loading branch information
1 parent
61b8338
commit b4d20b5
Showing
10 changed files
with
254 additions
and
167 deletions.
There are no files selected for viewing
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
20 changes: 20 additions & 0 deletions
20
src/main/java/org/mdbenefits/app/submission/conditions/ProgramsIncludeSnapOrTCA.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,20 @@ | ||
package org.mdbenefits.app.submission.conditions; | ||
|
||
import formflow.library.config.submission.Condition; | ||
import formflow.library.data.Submission; | ||
import java.util.ArrayList; | ||
import org.springframework.stereotype.Component; | ||
|
||
@Component | ||
public class ProgramsIncludeSnapOrTCA implements Condition { | ||
|
||
@Override | ||
public Boolean run(Submission submission) { | ||
var inputData = submission.getInputData(); | ||
if (inputData.containsKey("programs[]")) { | ||
var programArr = (ArrayList<String>) submission.getInputData().get("programs[]"); | ||
return programArr.contains("SNAP") || programArr.contains("TCA"); | ||
} | ||
return false; | ||
} | ||
} |
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
52 changes: 11 additions & 41 deletions
52
src/main/resources/templates/mdBenefitsFlow/expeditedSnapNotice.html
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 |
---|---|---|
@@ -1,57 +1,27 @@ | ||
<!DOCTYPE html> | ||
<html th:lang="${#locale.language}"> | ||
<head th:replace="~{fragments/head :: head(title=#{expedited-snap.title})}"></head> | ||
<html th:lang="${#locale.language}" xmlns:th="http://www.thymeleaf.org"> | ||
<head th:replace="~{fragments/head :: head(title=#{expedited-snap-notice.title})}"></head> | ||
<body> | ||
<div class="page-wrapper"> | ||
<div th:replace="~{fragments/toolbar :: toolbar}"></div> | ||
<section class="slab"> | ||
<div class="grid"> | ||
<div th:replace="~{fragments/goBack :: goBackLink}"></div> | ||
<main id="content" role="main" class="form-card spacing-above-35"> | ||
<th:block th:replace="~{fragments/icons :: groceries}"></th:block> | ||
<main id="content" role="main" class="form-card spacing-above-35 expedited-snap-notice"> | ||
<th:block th:replace="~{fragments/icons :: choosePrograms}"></th:block> | ||
<th:block | ||
th:replace="~{fragments/cardHeader :: cardHeader(header=#{expedited-snap.header})}"/> | ||
<th:block th:replace="~{'fragments/honeycrisp/reveal' :: reveal( | ||
controlId='r1', | ||
linkLabel=~{::revealLabel1}, | ||
content=~{::revealContent1}, | ||
forceShowContent='true')}"> | ||
<th:block th:ref="revealLabel1"> | ||
<i class="icon-"></i> | ||
<span th:text="#{expedited-snap.what-is}"></span> | ||
</th:block> | ||
<th:block th:ref="revealContent1"> | ||
<p th:text="#{expedited-snap.what-is.content}"></p> | ||
</th:block> | ||
</th:block> | ||
<th:block th:replace="~{'fragments/honeycrisp/reveal' :: reveal( | ||
controlId='r2', | ||
linkLabel=~{::revealLabel2}, | ||
content=~{::revealContent2}, | ||
forceShowContent='true')}"> | ||
<th:block th:ref="revealLabel2"> | ||
<i class="icon-"></i> | ||
<span th:text="#{expedited-snap.who-qualifies}"></span> | ||
</th:block> | ||
<th:block th:ref="revealContent2"> | ||
<p th:text="#{expedited-snap.who-qualifies}"></p> | ||
<ul class="list--bulleted"> | ||
<li th:utext="#{expedited-snap.who-qualifies.li1}"></li> | ||
<li th:utext="#{expedited-snap.who-qualifies.li2}"></li> | ||
<li th:utext="#{expedited-snap.who-qualifies.li3}"></li> | ||
</ul> | ||
</th:block> | ||
</th:block> | ||
|
||
<div class="form-card__footer spacing-below-60"> | ||
th:replace="~{fragments/cardHeader :: cardHeader(header=#{expedited-snap-notice.header})}"/> | ||
<div class="form-card__content"> | ||
<p class="h2" th:text="#{expedited-snap-notice.no-income}"></p> | ||
<p class="h2 spacing-below-95" th:text="#{expedited-snap-notice.expedited-snap}"></p> | ||
</div> | ||
<div class="form-card__footer"> | ||
<th:block th:replace="~{fragments/continueButton :: continue}"/> | ||
</div> | ||
</th:block> | ||
</th:block> | ||
</main> | ||
</div> | ||
</section> | ||
</div> | ||
<th:block th:replace="~{fragments/footer :: footer}"/> | ||
</body> | ||
</html> | ||
</html> |
Oops, something went wrong.