Skip to content

Fixes: Signup page - Multi-Role Selection, Incorrect Validation & Admin role exclusion #238

@coder-girl-shadia

Description

@coder-girl-shadia

What is the problem/feature request? :

  • Multi-Role Selection: The form uses checkboxes, which incorrectly allows users to select multiple roles at once with no proper user friendly format.

  • Incorrect Validation: All users (including customers) are forced to fill out restaurant details to successfully submit the form.

  • Admin role exclusion: The ADMIN role option is publicly visible and selectable during signup.

Steps to Reproduce

  • Go to the signup page.

  • Notice that multiple roles can be selected simultaneously using checkboxes.

  • Try registering as a standard CUSTOMER; the form will fail due to missing restaurant details validation.

  • Notice that the ADMIN option is visible to public visitors.

Scope
[FRONTEND]

Role Selection:

  • Checkboxes are replaced with a Dropdown Menu to enforce a strict single-role selection state in Register.jsx.

  • Conditional Validation: Yup schema validations and layout conditions are configured so restaurant fields are rendered and required only when RESTAURANT_OWNER is selected.

  • Role Filtering: The backend response is filtered to exclude and hide the ADMIN role from public registration forms.

@rdodiya Kindly assign me this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions