diff --git a/server/pages/templates/workflow.html b/server/pages/templates/workflow.html index d4e5108..68a1767 100644 --- a/server/pages/templates/workflow.html +++ b/server/pages/templates/workflow.html @@ -452,16 +452,13 @@ return; } - // Success - if (result.status === 'advanced' || result.status === 'completed') { - showFormSuccess(result.status === 'completed' - ? 'Thank you! Your submission is complete.' - : 'Submitted! Moving to the next step...'); - if (result.status === 'advanced') { - setTimeout(function() { window.location.reload(); }, 1500); - } + // Success — API returns instance status: "active" (advanced) or "completed" + if (result.status === 'completed') { + showFormSuccess('Thank you! Your submission is complete.'); } else { - showFormSuccess('Your response has been submitted.'); + // Still active = advanced to next stage — reload to render it + showFormSuccess('Submitted! Moving to the next step...'); + setTimeout(function() { window.location.reload(); }, 1500); } } catch(e) { alert('Network error: ' + e.message);