Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Issue]: Cannot submit "Not applicable to needs/goals" as team status in Grant Finder #3380

Open
mhuang-usdr opened this issue Aug 13, 2024 · 1 comment
Assignees
Labels
bug Something isn't working good first issue Good for newcomers Grant Finder Issues related to the Grant Finder

Comments

@mhuang-usdr
Copy link
Contributor

mhuang-usdr commented Aug 13, 2024

Why is this issue important?

This is a bug in production for a supported user journey.

Current State

When user visits a Grants detail page (here is a random example) and selects "Not applicable to needs/goals" as the Team Status, the Submit button greys out and does not allow submission. All other options for Team Status work correctly.

image

Expected State

When user visits a Grants detail page (here is a random example) and selects "Not applicable to needs/goals" as the Team Status, the Submit button should allow submission, same as any other status.

image

Implementation Plan

The problem seems to be related to the :disabled property of the submit button in the "Team Status" component, although it doesn't seem like it should. Observe that in its current state, this evaluation causes the bug to manifest:

:disabled="!selectedInterestedCode"

whereas this evaluation (when tested locally) results in the expected state:

:disabled="selectedInterestedCode === null"

A bit of digging (at least to explain why !selectedInterestedCode, which seems to be valid syntax) would be appreciated here. In particular, the strictness of the === evaluation demonstrated above is a drawback – something that evaluates to true when selectedInterestedCode is any "false-y" value would be preferred. However, the above would be acceptable in absence of a better alternative.

Note the documented behavior of the disabled prop for the b-button component.

Relevant Code Snippets

Usage in the button's disabled prop:

:disabled="!selectedInterestedCode"

Initialization of selectedInterestedCode:

selectedInterestedCode: null,

@mhuang-usdr mhuang-usdr added bug Something isn't working Grant Finder Issues related to the Grant Finder labels Aug 13, 2024
@ClaireValdivia ClaireValdivia added the good first issue Good for newcomers label Aug 14, 2024
@greg-adams greg-adams self-assigned this Aug 15, 2024
@ClaireValdivia
Copy link
Contributor

Looks great in staging!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers Grant Finder Issues related to the Grant Finder
Projects
Status: 🚢 Completed
Development

No branches or pull requests

3 participants