Merged PR 2441: electricity shouldnt be showing reps available
electricity shouldnt be showing reps available Related work items: #24008
This commit is contained in:
@@ -72,6 +72,9 @@ export function getEntryCtaLabelKey(appealType) {
|
||||
}
|
||||
|
||||
export function shouldSuppressBlockedMessage({ appealType, isLPA }) {
|
||||
if (!canShowRepresentationButtonForAppealType(appealType)) {
|
||||
return true;
|
||||
}
|
||||
return !isLPA && appealType == 846040004;
|
||||
}
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@ const RepsOnResults = (props) => {
|
||||
Object.prototype.hasOwnProperty.call(obj || {}, key);
|
||||
|
||||
function showRepButton(appealType) {
|
||||
appealType = Number(appealType);
|
||||
if (!canShowRepresentationButtonForAppealType(appealType)) {
|
||||
return false;
|
||||
}
|
||||
@@ -90,33 +91,18 @@ const RepsOnResults = (props) => {
|
||||
detailsObj.pinswg_consultationclose
|
||||
)) && (
|
||||
<>
|
||||
{showRepButton(detailsObj.appealType) ? (
|
||||
<>
|
||||
{/* <Link
|
||||
href={{
|
||||
pathname:
|
||||
"/myportal/representation",
|
||||
query: {
|
||||
case: detailsObj.pinswg_name,
|
||||
},
|
||||
}}
|
||||
className="govuk-button"
|
||||
>
|
||||
{t(
|
||||
"case:summary-make-representation-label"
|
||||
)}
|
||||
</Link> */}
|
||||
<div className="govuk-body govuk-!-font-size-14">
|
||||
{appealType == 846040002
|
||||
? t(
|
||||
"case:summary-consultation-open-label"
|
||||
)
|
||||
: t(
|
||||
"case:summary-representation-open-label"
|
||||
)}{" "}
|
||||
</div>
|
||||
</>
|
||||
) : !isLPA && appealType == 846040004 ? (
|
||||
{showRepButton(Number(appealType)) ? (
|
||||
<div className="govuk-body govuk-!-font-size-14">
|
||||
{appealType == 846040002
|
||||
? t("case:summary-consultation-open-label")
|
||||
: t(
|
||||
"case:summary-representation-open-label"
|
||||
)}{" "}
|
||||
</div>
|
||||
) : !canShowRepresentationButtonForAppealType(
|
||||
appealType
|
||||
) ||
|
||||
(!isLPA && appealType == 846040004) ? (
|
||||
""
|
||||
) : (
|
||||
<>
|
||||
|
||||
Reference in New Issue
Block a user