diff --git a/frontend/src/views/Seedlot/SeedlotRegFormClassA/RegPage.tsx b/frontend/src/views/Seedlot/SeedlotRegFormClassA/RegPage.tsx index fa5728d8d..a881226fb 100644 --- a/frontend/src/views/Seedlot/SeedlotRegFormClassA/RegPage.tsx +++ b/frontend/src/views/Seedlot/SeedlotRegFormClassA/RegPage.tsx @@ -60,6 +60,12 @@ const RegPage = () => { const { isTscAdmin } = useContext(AuthContext); + const disableSubmit = !allStepCompleted + || saveStatus === 'conflict' + || !seedlotData + || (seedlotData.seedlotStatus.seedlotStatusCode !== 'PND' + && seedlotData.seedlotStatus.seedlotStatusCode !== 'INC'); + return (
@@ -176,6 +182,21 @@ const RegPage = () => { + { + formStep === 5 && disableSubmit + ? ( + + + + ) + : null + } { @@ -237,13 +258,7 @@ const RegPage = () => { { submitSeedlot.mutate( getSeedlotPayload(