feat: auto-check all wizard step checkboxes and require them before advancing (ENH-008) - #109
Merged
Merged
Conversation
…dvancing (ENH-008)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Every PISN graduation wizard verification step now has a checkbox that must be checked before advancing, with server-side auto-check where the criterion is objectively verifiable.
stepPostnow requires all four checkboxes (identity_ok,academic_ok,transcript_ok,pisn_ok) before moving to the next student.identity_okauto-checks when the optional Excelnamais present and exactly equals the PDDIKTI registered name (identity['nama_mahasiswa']).academic_okauto-checks when the last active academic row's IPK equals the Excel IPK and its status is Aktif — recomputed in realtime in the browser (on page load, on either IPK input, and after the ENH-006 "Auto-update" button).transcript_okauto-checks when a thesis/skripsi course exists with a non-empty grade andchoosed:true.pisn_okstays manual only.Every checkbox remains manually togglable regardless of the auto-check state (manual-verification design).
Also fixed (needed to surface the new validation failures):
step()now reads thegraduation_errorflash set bystepPost, so rejected submissions show their aggregated messages instead of silently re-rendering.Related issues
Fixes #102
Checklist
php -lpasses on all modified PHP filesnpm run buildsucceeds and committed assets are up to date (no asset diff)php spark routesshows correct new routes (no routes changed)vendor/bin/php-cs-fixer fixpasses (no style violations)vendor/bin/phpunitis green (36/36)dd(),var_dump(),console.log(),print_r(),exit()stepPost)csrf_field()(existing form unchanged)esc()Screenshot (if applicable)
None attached — text verification below.
Notes for reviewers
Behaviour verified live via Playwright on NIM 202010087 (real graduation wizard session, no Neo Feeder mutation — the session was cancelled before any submission to the API):
identity_okrenders unchecked, step 3transcript_okauto-checks (thesis Skripsi exists + grade A +choosed:true), step 2academic_okunchecked.academic_okflips to checked in the browser without a submit.identity_ok,academic_ok,pisn_ok); no message fortranscript_okbecause it auto-checked.