diff --git a/components/case/representation/index.js b/components/case/representation/index.js index 5cbecbb0..36f58fda 100644 --- a/components/case/representation/index.js +++ b/components/case/representation/index.js @@ -489,6 +489,8 @@ let MakeRepresentation = (props) => { ? router.query.state == "edit" ? props.props.myRepresentations.myRepresentations : props.props.searchResultsObj.searchDetailsObj + : props.currentType == "watchedCases" + ? props.props.watchedCases.watchedCasesDetails : props.props.searchResultsObj.searchDetailsObj; router.query.hasOwnProperty("state") && @@ -751,436 +753,21 @@ let MakeRepresentation = (props) => { - { - formObj.hasOwnProperty( + {formObj.hasOwnProperty( + "representationForm" + ) && + formObj[ "representationForm" + ].hasOwnProperty("values") && + formObj[ + "representationForm" + ].values.hasOwnProperty( + "representationType" ) && - formObj[ - "representationForm" - ].hasOwnProperty("values") && - formObj[ - "representationForm" - ].values.hasOwnProperty( - "representationType" - ) && - formObj["representationForm"] - .values - .representationType == - "Questionnaire" && - whichProgress() - // - } + formObj["representationForm"].values + .representationType == + "Questionnaire" && + whichProgress()} diff --git a/components/case/representation/representationElements.js b/components/case/representation/representationElements.js index d532bc95..49e801e6 100644 --- a/components/case/representation/representationElements.js +++ b/components/case/representation/representationElements.js @@ -491,14 +491,11 @@ export const RenderPickList = ({ : "govuk-form-group " } > -