watch case link on case summary
This commit is contained in:
+68
-63
@@ -288,74 +288,79 @@ const CaseSummary = (props) => {
|
||||
</dl>
|
||||
</div>
|
||||
</div>
|
||||
{props.currentView.showReps == true ||
|
||||
(props.currentView.showReps == "true" &&
|
||||
_.has(detailsObj, "pinswg_startdate") &&
|
||||
hasEndDate &&
|
||||
showReps(
|
||||
detailsObj.pinswg_startdate,
|
||||
detailsObj.pinswg_representation_period_end_date
|
||||
) && (
|
||||
<div className="govuk-grid-row">
|
||||
<div className="govuk-grid-column-full">
|
||||
<div className="govuk-button-group">
|
||||
<Link
|
||||
href={{
|
||||
pathname:
|
||||
"/myportal/representation",
|
||||
query: {
|
||||
case:
|
||||
currentType ==
|
||||
"searchResultsObj"
|
||||
? detailsObj.pinswg_name
|
||||
: casesObj.reference,
|
||||
},
|
||||
}}
|
||||
>
|
||||
<a className="govuk-button">
|
||||
<div className="govuk-grid-row">
|
||||
<div className="govuk-grid-column-full">
|
||||
<div className="govuk-button-group">
|
||||
{props.currentView.showReps == true ||
|
||||
(props.currentView.showReps == "true" &&
|
||||
_.has(detailsObj, "pinswg_startdate") &&
|
||||
hasEndDate &&
|
||||
showReps(
|
||||
detailsObj.pinswg_startdate,
|
||||
detailsObj.pinswg_representation_period_end_date
|
||||
) && (
|
||||
<>
|
||||
<Link
|
||||
href={{
|
||||
pathname:
|
||||
"/myportal/representation",
|
||||
query: {
|
||||
case:
|
||||
currentType ==
|
||||
"searchResultsObj"
|
||||
? detailsObj.pinswg_name
|
||||
: casesObj.reference,
|
||||
},
|
||||
}}
|
||||
>
|
||||
<a className="govuk-button">
|
||||
{t(
|
||||
"case:summary-make-representation-label"
|
||||
)}
|
||||
</a>
|
||||
</Link>
|
||||
<a
|
||||
onClick={() => {
|
||||
//spinnerState();
|
||||
router.back();
|
||||
}}
|
||||
className="govuk-button govuk-button--secondary"
|
||||
>
|
||||
{t(
|
||||
"case:summary-make-representation-label"
|
||||
"case:summary-back-button-label"
|
||||
)}
|
||||
</a>
|
||||
</Link>
|
||||
|
||||
<a
|
||||
onClick={() => {
|
||||
//spinnerState();
|
||||
router.back();
|
||||
}}
|
||||
className="govuk-button govuk-button--secondary"
|
||||
>
|
||||
{t(
|
||||
"case:summary-back-button-label"
|
||||
)}
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
))}
|
||||
<div className="govuk-body">
|
||||
<Link href="">
|
||||
<a className="govuk-link">
|
||||
Watch this case
|
||||
</a>
|
||||
</Link>
|
||||
</div>
|
||||
))}
|
||||
|
||||
{props.currentView.showReps == true ||
|
||||
(props.currentView.showReps == "true" &&
|
||||
_.has(detailsObj, "pinswg_startdate") &&
|
||||
hasEndDate &&
|
||||
showRepsEnded(
|
||||
detailsObj.pinswg_startdate,
|
||||
detailsObj.pinswg_representation_period_end_date
|
||||
) && (
|
||||
<div className="govuk-grid-row">
|
||||
<div className="govuk-grid-column-full">
|
||||
<div className="govuk-button-group">
|
||||
<div className="govuk-body">
|
||||
Representation Period ended on{" "}
|
||||
{formatDates(
|
||||
detailsObj.pinswg_representation_period_end_date
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>{" "}
|
||||
<div className="govuk-grid-row">
|
||||
<div className="govuk-grid-column-full">
|
||||
{props.currentView.showReps == true ||
|
||||
(props.currentView.showReps == "true" &&
|
||||
_.has(detailsObj, "pinswg_startdate") &&
|
||||
hasEndDate &&
|
||||
showRepsEnded(
|
||||
detailsObj.pinswg_startdate,
|
||||
detailsObj.pinswg_representation_period_end_date
|
||||
) && (
|
||||
<div className="govuk-body">
|
||||
Representation Period ended on{" "}
|
||||
{formatDates(
|
||||
detailsObj.pinswg_representation_period_end_date
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
))}
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
{/* 1{" "}
|
||||
{_.has(detailsObj, "pinswg_startdatetimeiftheevent") &&
|
||||
detailsObj.pinswg_startdatetimeiftheevent}
|
||||
|
||||
Reference in New Issue
Block a user