bcgov / business-ar

business registry annual report
BSD 3-Clause "New" or "Revised" License
0 stars 16 forks source link

Account Creation Error - Phone Extension Validation #462

Open hanlunBCRegistries opened 3 days ago

hanlunBCRegistries commented 3 days ago

Issue Description

A 400 response error occurs in the BAR API during account creation. The error originates from data validation failures in the phone number extension field when users enter non-numeric characters.

Replication

Resolutions

  1. UI Feedback: Provide a validation message in the UI when the phone extension contains invalid characters, guiding users to input only numeric values.
  2. Enhanced Logging: Add a log message in Validate function (located in api/src/business_ar_api/schemas/utils.py) to capture details of invalid inputs for easier diagnostics.
PCC199 commented 2 days ago

@nsmenon8890

PCC199 commented 2 days ago

@nsmenon8890

nsmenon8890 commented 1 day ago

Testing completed and working as expected. It is throwing validation error on inputting alphabets in the phone extension field.

image.png image.png image.png