Skip to content

[codex] fix admin server protocol validation#34

Merged
web-ppanel merged 1 commit intoperfect-panel:mainfrom
phenix3443:codex/fix-server-protocol-required-validation
Apr 11, 2026
Merged

[codex] fix admin server protocol validation#34
web-ppanel merged 1 commit intoperfect-panel:mainfrom
phenix3443:codex/fix-server-protocol-required-validation

Conversation

@phenix3443
Copy link
Copy Markdown
Contributor

Summary

This PR fixes the server protocol edit flow so enabled protocols immediately expose their required configuration and submission validates those required values before saving.

What Changed

  • auto-expand a protocol section as soon as its switch is enabled
  • mark required protocol fields with a * in the form UI
  • validate enabled protocol required fields before submit, with protocol-specific field errors
  • only submit enabled protocols after validation passes
  • include the small related formatter cleanup needed for the touched server form schema files

Root Cause

The protocol toggle only flipped enable and did not drive the form UI or validation rules. As a result, required fields like port were easy to miss, and submit logic filtered by numeric port instead of validating enabled protocol configuration explicitly.

Validation

  • bun --filter ppanel-admin-web check
  • bun --filter ppanel-admin-web build

@netlify
Copy link
Copy Markdown

netlify bot commented Apr 10, 2026

Deploy Preview for ppane-docs ready!

Name Link
🔨 Latest commit 68fccfb
🔍 Latest deploy log https://app.netlify.com/projects/ppane-docs/deploys/69d8a67e2934de0008747852
😎 Deploy Preview https://deploy-preview-34--ppane-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@phenix3443 phenix3443 marked this pull request as ready for review April 10, 2026 16:31
Copy link
Copy Markdown
Contributor

@web-ppanel web-ppanel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes look correct and well thought out:

  • Auto-expanding protocol sections on toggle is a good UX improvement to surface required fields immediately
  • Marking required fields with * provides clear visual feedback
  • Validating required fields before submission prevents silent failures
  • Filtering by enabled status rather than numeric port value is more robust logic

LGTM!

@web-ppanel web-ppanel merged commit 3f3f38d into perfect-panel:main Apr 11, 2026
4 checks passed
@phenix3443 phenix3443 deleted the codex/fix-server-protocol-required-validation branch April 12, 2026 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants