enterprise-ng icon indicating copy to clipboard operation
enterprise-ng copied to clipboard

Lookup: Changing the selection results in incorrect selections

Open madebyannalam opened this issue 3 years ago • 4 comments

Describe the bug When we have a Lookup Component set up as a single select, with pagination enabled and running in async mode, the popup modal is returning multiple selections when one jumps between selections repeatedly.

To Reproduce Please refer to the attached Stackblitz: Lookup Single Select Async Bug (Source code) Steps to reproduce the behavior:

  1. Run the above Stackblitz
  2. Open the modal
  3. Select the 1st item on page 1
  4. Reopen the modal and navigate to page 2 and select select any of the items from that page
  5. Reopen the modal and select any item from page 1. At this point, you should have 2 selections in the textbox.
  6. If, at step 5, you do not have the 2 selections, repeat steps 3-5 until you do.

Expected behavior No matter how many times we change the selection for a single select scenario, we should only ever return a single selection from the modal.

Version

  • ids-enterprise-ng: 13.0.1

Screenshots image

Platform

  • Device (if applicable): Dell Laptop
  • OS Version: Windows 11 Enteprise
  • Browser Name: Google Chrome
  • Browser Version: Version 99.0.4844.74 (Official Build) (64-bit)

Additional context This issue was reported on behalf of Sumeeth Prabhakar of the MRM team.

madebyannalam avatar Mar 21 '22 02:03 madebyannalam

@thatannalam can you test it with

          [options]="{
...
            allowSelectAcrossPages: true,
...
          }"

There is an option that might make it work? Also i suggest adding a checkbox column if using multiselect

tmcconechy avatar Mar 21 '22 13:03 tmcconechy

Hi Tim, Issue raised here is for single select lookup. It doesn't clear the previous selection when user changes the selection. its random but its consistent when pagination is enabled in the lookup grid.

SumeethPrabhakar avatar Mar 22 '22 01:03 SumeethPrabhakar

adding allowSelectAcrossPages: true to options has not fixed the issue.

SumeethPrabhakar avatar Mar 22 '22 01:03 SumeethPrabhakar

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contribution.

github-actions[bot] avatar May 05 '24 01:05 github-actions[bot]

This issue was closed because it has been inactive for 14 days since being marked as stale.

github-actions[bot] avatar May 19 '24 01:05 github-actions[bot]