Validate Q1b and Q2 before proceeding to Step 2
Users could skip Q1b (customer type) and Q2 (voice delivery) and hit Next — the wizard silently defaulted to retail. Now validates: - Q1b must be answered (customer type selected) - Q2 must be answered if voice is checked and not wholesale-only Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
fbf3b8a1ea
commit
611b8a9600
1 changed files with 2 additions and 0 deletions
|
|
@ -514,6 +514,8 @@ select:focus,input:focus{outline:none;border-color:#1e3a5f;box-shadow:0 0 0 2px
|
|||
// ── Step 1 → 2: Derive registrations ──
|
||||
document.getElementById('btn-next-1').addEventListener('click', function() {
|
||||
if (wizard.serviceTypes.length === 0) { alert('Please select at least one service type.'); return; }
|
||||
if (!document.querySelector('[data-custtype].selected')) { alert('Please select who your customers are (retail, wholesale, or both).'); return; }
|
||||
if (wizard.serviceTypes.indexOf('voice') >= 0 && wizard.customerType !== 'wholesale' && !wizard.voiceDelivery) { alert('Please select how you will deliver voice service.'); return; }
|
||||
|
||||
var hasVoice = wizard.serviceTypes.indexOf('voice') >= 0;
|
||||
var hasBroadband = wizard.serviceTypes.indexOf('broadband') >= 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue