Feature #4212
openUser Story: Add New Service Type While Creating a Vendor
50%
Description
Title: Allow users to create a new Service Type directly from the Vendor creation form.
As a Manager/Admin
I want the ability to add a new Service Type from the Vendor creation screen
So that I can bind the new service type to the vendor and make it available for future vendors.
Acceptance Criteria
On the Vendor creation form, beside the Service Type label, a “+” button/icon is displayed (only if “Service” is selected as Vendor Type).
Clicking the “+” button opens a modal popup with:
Input field: “Enter Service Type Name” (required)
Submit and Cancel buttons.
On clicking Submit:
The system validates that the input is not empty and not a duplicate of existing service types.
Saves the new Service Type record in the database.
The modal closes, and the new Service Type is auto-appended to the Service Type dropdown list.
The newly created Service Type is auto-selected for the vendor being created.
The new Service Type must be visible in the Service Type dropdown for all subsequent vendor creations.
Error handling:
If DB save fails, show error message: “Failed to create service type. Please try again.”
Prevent duplicate service types (case-insensitive).
Related issues