diff --git a/components/case/representation/representationAgent.js b/components/case/representation/representationAgent.js index 1439c16c..9213c10c 100644 --- a/components/case/representation/representationAgent.js +++ b/components/case/representation/representationAgent.js @@ -208,20 +208,21 @@ const RepAgent = (props) => { > {t("common:continue-button")} - - { - setRepresentationCapacity(); - props.updateField( - "representationForm", - "representationCapacity", - "" - ); - }} - className="govuk-link" - > - {t("common:back-link")} - + {router.query.state != "edit" && ( + { + setRepresentationCapacity(); + props.updateField( + "representationForm", + "representationCapacity", + "" + ); + }} + className="govuk-link" + > + {t("common:back-link")} + + )} )} diff --git a/components/case/representation/representationAppellant.js b/components/case/representation/representationAppellant.js index 8b0776c9..d2db43da 100644 --- a/components/case/representation/representationAppellant.js +++ b/components/case/representation/representationAppellant.js @@ -192,19 +192,21 @@ const RepAppellant = (props) => { > {t("common:continue-button")} - { - setRepresentationCapacity(); - props.updateField( - "representationForm", - "representationType", - "" - ); - }} - className="govuk-link" - > - {t("common:back-link")} - + {router.query.state != "edit" && ( + { + setRepresentationCapacity(); + props.updateField( + "representationForm", + "representationType", + "" + ); + }} + className="govuk-link" + > + {t("common:back-link")} + + )} )} diff --git a/components/case/representation/representationLPA.js b/components/case/representation/representationLPA.js index b7338374..16764349 100644 --- a/components/case/representation/representationLPA.js +++ b/components/case/representation/representationLPA.js @@ -480,19 +480,21 @@ let RepLPA = (props) => { > {t("common:continue-button")} - { - //setRepresentationCapacity(); - props.updateField( - "representationForm", - "representationType", - "" - ); - }} - className="govuk-link" - > - {t("common:back-link")} - + {router.query.state != "edit" && ( + { + //setRepresentationCapacity(); + props.updateField( + "representationForm", + "representationType", + "" + ); + }} + className="govuk-link" + > + {t("common:back-link")} + + )} )} diff --git a/components/case/representation/representationLandowner.js b/components/case/representation/representationLandowner.js index 0fcd0e4f..a643666a 100644 --- a/components/case/representation/representationLandowner.js +++ b/components/case/representation/representationLandowner.js @@ -116,14 +116,16 @@ const RepLandOwner = (props) => { > {t("common:continue-button")} - { - setRepresentationCapacity(); - }} - className="govuk-link" - > - {t("common:back-link")} - + {router.query.state != "edit" && ( + { + setRepresentationCapacity(); + }} + className="govuk-link" + > + {t("common:back-link")} + + )} )}