Requisition non-full supply product Add Product modal has locked but required dropdowns

Description

The Add Product modal on the Non-Full Supply Products tab of the Requisition form has an unusual select form field behavior. Category and Product are required fields, BUT if you have already added both (there are 2) available products onto your requisition form, then when you are in this modal again those select fields are still required but they are locked/inactive so you cannot use them.

Steps to Reproduce:
1. Log in to OpenLMIS as a user who can create and fill out requisitions
2. Navigate to Requisition > Create/Authorize and Proceed into a new or initiated requisition in Family Planning program (for Comfort facility in Apr2017 period)
3. Click Add Product. If you can choose a Category and Product, that means you have not yet added both available products (there are 2 of them) onto this requisition. So add each one by entering a quantity and explanation. Click Add Product to close the modal.
4. Do step 3 over and over again (twice) until you cannot add any more products.
5. ERROR: Click Add Product to open the modal again. Since all of your available non-full products are already on your form, there really are not any more to choose from. Yet the modal opens anyway. The Category and Product fields are Required, but they are also both inactive/locked where the user cannot make a choice. There is no indication to the user about why it is locked or about how to make a choice or what to do.

PROPOSED SOLUTION (from Nick and Brandon):

  • If all of the available non-full products are already added onto this requisition, then clicking "Add Product" button will not open the modal at all. Instead, it will display a warning message to alert the user:
    "There are no more products to add. All available non-full supply products have already been added onto this requisition."

Environment

None

Attachments

4

QAlity Plus - Test Management

Checklists

Activity

Show:
Lucyna Laska
May 23, 2017 at 11:06 AM

Now it looks okay. I checked that on Chrome and Firefox.

Also validated the standards described in the document: Testing Standards Checklist.

Brandon Bowersox-Johnson
May 22, 2017 at 8:40 PM

Thanks for your attention to detail here!

Lucyna Laska
May 22, 2017 at 6:49 AM

Now it's possible to add non-full supply product(s).
However, when I opened the submitted requisition and clicked the Add product button on the Non full supply product(s) I saw the "Add product" modal. I think that when all available non-full products are already added onto this requisition (regardless of the requisition status), the warning should be displayed.

Steps to reproduce:
1. Initiate the requisition
2. Insert all required fields for full supply product(s)
3. Add all available non-full supply products
4. Click Add product again to verify if warning is displayed
5. Submit the requisition
6. Open the submitted requisition
7. Navigate to the Non full supply product(s) tan
8. Click Add product again
9. Modal "Add product" is visible. It should not be visible (products were already added when requisition was initiated). Warning should be displayed.

Lucyna Laska
May 19, 2017 at 11:47 AM

The warning message is displayed. However, I can't add a non-full supply product(s), even when none of them have been added yet.

Done
Pinned fields
Click on the next to a field label to start pinning.

Details

Assignee

Reporter

Story Points

Original estimate

Time tracking

1d 7h logged

Components

Sprint

None

Fix versions

Affects versions

Priority

Time Assistant

Created May 8, 2017 at 10:54 PM
Updated December 29, 2021 at 12:36 PM
Resolved May 23, 2017 at 11:06 AM