Feature #3944
openFeature #3942: User Story: Manage Labour Types for Fieldstaff
User Story: Frontend Management of Labour Types
0%
Description
As an Admin / Sales Manager(frontend user)
I want a user interface to create, view, update, and delete labour types
So that I can easily manage labour categories and their rates for solar installation quotations.
Acceptance Criteria
Create Labour Type (Form UI)
A form with the following fields:
Name (text input, required)
Description (textarea, optional)
Rate Type (dropdown: Hourly / Daily)
Base Rate (number input, required)
Overtime Rate (number input, optional)
“Save” button creates the labour type via API.
Show success/failure message on submission.
View Labour Types (List Page)
Display a table/grid of all labour types with columns:
Name, Description, Rate Type, Base Rate, Overtime Rate, Actions.
Search bar to filter by Name.
Pagination (if records exceed X items).
Update Labour Type (Edit UI)
Clicking Edit on a row opens the form with pre-filled details.
Admin can modify details and click Update to save changes.
Updated values reflect immediately in the table.
Delete Labour Type (Action Button)
Clicking Delete on a row asks for confirmation (modal).
On confirmation, labour type is deleted via API.
Deleted type disappears from the table.
Deactivated/deleted labour types should not appear in new job/quotation forms.
UI/UX Enhancements
Loading indicators while fetching/saving data.
Form validation (required fields, numeric values > 0).
Toast/alert messages for success/error feedback.
Test Scenarios (Frontend)
When creating a labour type, form validation works (required fields).
Submitting valid data calls the backend API and shows success message.
Labour type list shows newly created entries without refresh.
Editing a labour type updates details in both form and list.
Deleting a labour type removes it from the UI after confirmation.
API errors show a proper error message to the user.
Subtasks
Related issues
No data to display