logic to show reps button

This commit is contained in:
2024-05-29 16:23:35 +01:00
parent d2f1a7d8b7
commit 01f2d7d766
7 changed files with 81 additions and 44 deletions
+45 -34
View File
@@ -436,41 +436,52 @@ const CaseSummary = (props) => {
.caseReference
.appealType
) ? (
<>
<Link
href={{
pathname:
"/myportal/representation",
query: {
case:
currentType ==
"searchResultsObj"
? detailsObj.pinswg_name
: currentType ==
"watchedCases"
? casesObj.pinswg_title
: casesObj.reference,
},
}}
className="govuk-button"
>
{t(
"case:summary-make-representation-label"
)}
</Link>
props.currentView
.caseReference
.appealType ==
846040018 &&
props.currentView
.caseReference
.specialistProcess ==
846040000 ? (
""
) : (
<>
<Link
href={{
pathname:
"/myportal/representation",
query: {
case:
currentType ==
"searchResultsObj"
? detailsObj.pinswg_name
: currentType ==
"watchedCases"
? casesObj.pinswg_title
: casesObj.reference,
},
}}
className="govuk-button"
>
{t(
"case:summary-make-representation-label"
)}
</Link>
<a
onClick={() => {
//spinnerState();
router.back();
}}
className="govuk-button govuk-button--secondary"
>
{t(
"case:summary-back-button-label"
)}
</a>
</>
<a
onClick={() => {
//spinnerState();
router.back();
}}
className="govuk-button govuk-button--secondary"
>
{t(
"case:summary-back-button-label"
)}
</a>
</>
)
) : !isLPA &&
props.currentView
.caseReference