Skip to content

Siri SudheekshaVavila: Fix bm separate add equipment tool forms#5206

Merged
one-community merged 16 commits into
developmentfrom
fix-bm-separate-add-equipment-tool-forms
May 15, 2026
Merged

Siri SudheekshaVavila: Fix bm separate add equipment tool forms#5206
one-community merged 16 commits into
developmentfrom
fix-bm-separate-add-equipment-tool-forms

Conversation

@sirisudheeksha
Copy link
Copy Markdown
Contributor

Description

image

Currently both Equipment and Tool share a single "Add Equipment/Tool" dropdown entry in the BM Dashboard header navigation and a single "Tool/Equipment" button in the project page LogBar. Both point to only one form, making the Tool add form inaccessible from the UI. This fix separates them into two distinct entries so each form is independently reachable.
Or Implements # (WBS)

Related PRS (if any):

Main changes explained:

  • Update Header.jsx — split the single "Add Equipment/Tool" dropdown item into two separate items: "Add Equipment" linking to /bmdashboard/equipment/add and "Add Tool" linking to /bmdashboard/tools/add
  • Update LogBar.jsx— split the single "Tool/Equipment" button in the "Add a New Item" section of the project details page into two buttons: "Add Equipment" linking to /bmdashboard/equipment/add and "Add Tool" linking to /bmdashboard/tools/add
  • Update ui.js — replaced the ADD_EQUIPMENT_TOOL constant with separate ADD_EQUIPMENT and ADD_TOOL constants to match the new labels

How to test:

  1. Check out branch fix-bm-separate-add-equipment-tool-forms
  2. Run npm install then npm run start:local
  3. Clear site data / cache in the browser
  4. Log in as admin
  5. Open the BM Dashboard dropdown in the top header navbar
  6. Navigate to any project page at /bmdashboard/projects/:projectId
  7. Verify the dropdown now shows "Add Equipment" and "Add Tool" as two separate items
  8. Click each button and verify they navigate to the correct separate forms
  9. Click "Add Equipment" and verify it opens the Add Type: Equipment form at /bmdashboard/equipment/add
  10. Click "Add Tool" and verify it opens the Add Type: Tool form at /bmdashboard/tools/add
  11. verify this new feature works in dark mode

Screenshots or videos of changes:

Before:

image After: image image image

Note:

Include the information the reviewers need to know.

@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 28, 2026

Deploy Preview for highestgoodnetwork-dev ready!

Name Link
🔨 Latest commit 3a3b2d8
🔍 Latest deploy log https://app.netlify.com/projects/highestgoodnetwork-dev/deploys/6a04a8210e894e0008e753b2
😎 Deploy Preview https://deploy-preview-5206--highestgoodnetwork-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

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

@one-community one-community added the High Priority - Please Review First This is an important PR we'd like to get merged as soon as possible label May 3, 2026
Copy link
Copy Markdown

@HemanthNidamanuru HemanthNidamanuru left a comment

Choose a reason for hiding this comment

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

Hi Sudheeksha,

I tested this PR locally. "Add Equipment" is not working. On the Add Tool form, validation is not working for some fields like the mobile number field and the country code is not aligned correctly in dark mode. The Add Equipment form UI also needs improvement as it is not user friendly.

Image Image Image Image Image

Copy link
Copy Markdown

@rajanidi1999 rajanidi1999 left a comment

Choose a reason for hiding this comment

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

Hi,

I checked out the branch fix-bm-separate-add-equipment-tool-forms, installed dependencies, and ran the application locally. After clearing the browser cache and logging in as an admin, I navigated to the BM Dashboard and accessed a project page. The dropdown in the top header now correctly displays “Add Equipment” and “Add Tool” as separate options. Both buttons function as expected clicking “Add Equipment” navigates to the Equipment form at /bmdashboard/equipment/add, and “Add Tool” navigates to the Tool form at /bmdashboard/tools/add. The new feature works as intended with proper routing and UI behavior, and no issues were observed during testing.

Image Image

@sirisudheeksha sirisudheeksha dismissed HemanthNidamanuru’s stale review May 7, 2026 18:29

fixed the changes and requested re- review

Copy link
Copy Markdown

@HemanthNidamanuru HemanthNidamanuru left a comment

Choose a reason for hiding this comment

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

Hi Sudheeksha,

Thank you for working on this PR.
Issues found during testing:

Country code dropdown needs improvement in dark mode on the Add Tool form.
Calendar icon and calendar styling need improvement in dark mode.
Add Equipment form UI needs improvement for better usability. Please review the layout and spacing.
Form validation errors should be displayed in red so users can clearly identify which fields are missing or invalid.

Image Image Image Image Image Image Image Image

@sirisudheeksha sirisudheeksha dismissed HemanthNidamanuru’s stale review May 9, 2026 09:53

Fixed the dark mode error messages in add tools and UI for add equipment

@sirisudheeksha sirisudheeksha force-pushed the fix-bm-separate-add-equipment-tool-forms branch from 5b3ac1a to b253fe1 Compare May 9, 2026 09:57
Siri Sudheeksha Vavila added 9 commits May 9, 2026 03:01
…ode/phone alignment

- Fix AddTypeForm: send 'description' key instead of 'desc' to match backend schema
- Fix AddTypeForm: correct Submit button disabled logic (|| instead of &&)
- Fix AddTypeForm: reset fuel to default value on successful submit
- Fix AddToolForm: fix PhoneInput country prop to lowercase 'us'
- Fix AddToolForm: wrap PhoneInput in FormGroup with label, fix input width alignment
- Fix AddToolForm: add dark mode styles to PhoneInput (input, button, dropdown)
- Fix AddToolForm: add dark mode styling for total price section
- Fix AddToolForm: apply boxStyleDark to Cancel/Submit buttons in dark mode
@sirisudheeksha sirisudheeksha force-pushed the fix-bm-separate-add-equipment-tool-forms branch from b253fe1 to b452c68 Compare May 9, 2026 10:06
Copy link
Copy Markdown

@HemanthNidamanuru HemanthNidamanuru left a comment

Choose a reason for hiding this comment

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

Hi Sudheeksha,

I tested this PR locally. The country code dropdown, calendar icon and styling, Add Equipment form layout, and form validation error colors are all looking good. A few remaining issues to address:

  1. Phone number field has no validation. Please add validation to ensure only valid phone numbers are accepted.
  2. Dark mode still has some styling issues. Please audit and fix the affected elements.
  3. In the Add Equipment form, duplicate entries can be submitted with no validation preventing it. Please add a check to block duplicate records.
  4. Two dropdown arrows are appearing in the form in dark mode. Please remove the extra one so only a single arrow is shown.
Image Image Image Image Image Image Image Image Image Image

Copy link
Copy Markdown

@HemanthNidamanuru HemanthNidamanuru left a comment

Choose a reason for hiding this comment

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

Hi Sudheeksha,
I tested this PR locally. The country code dropdown, calendar icon and styling, Add Equipment form layout, and form validation error colors are all looking good. One remaining issue to address:

Phone number validation is not enforcing country-specific lengths. For USA, a 9-digit number is being accepted when exactly 10 digits are required. Please update the validation to check the expected digit count based on the selected country code rather than using only the generic 6–15 range.

Image Image Image

@sirisudheeksha sirisudheeksha dismissed HemanthNidamanuru’s stale review May 13, 2026 16:29

implemented the requested changes and requested a re review

@sonarqubecloud
Copy link
Copy Markdown

Copy link
Copy Markdown

@HemanthNidamanuru HemanthNidamanuru left a comment

Choose a reason for hiding this comment

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

Hi Sudheeksha,

Thank you for working on improvements. Everything looks good.

Image Image

@one-community
Copy link
Copy Markdown
Member

Thank you all, merging!

@one-community one-community merged commit 31fd498 into development May 15, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

High Priority - Please Review First This is an important PR we'd like to get merged as soon as possible

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants