Open itzmuthu opened 5 years ago
Hi @itzmuthu I can reproduce this bug. TBH I don't think we had considered this scenario when developing/testing the cart functionality.
I think it should just be a matter of checking the local storage before* opening the Cart dialog. Will investigate further. Feel free to look into a solution in parallel, I would start by looking at these files:
Describe the bug Asset added to cart via details page overriding previous image in cart
Environment
To Reproduce Steps to reproduce the behavior:
open home page http://localhost:4502/content/asset-share-commons/en/light.html in chrome browser
open two assets in next tab. now URL of the each tab will be like Browser TAB 1 URL: http://localhost:4502/content/asset-share-commons/en/light.html?layout=card&p.offset=0&p.limit=48 Browser TAB 2 URL: http://localhost:4502/content/asset-share-commons/en/light/details/image.html/content/dam/asset-share-commons/en/public/pictures/sarah-dorweiler-357959.jpg Browser TAB 3 URL: http://localhost:4502/content/asset-share-commons/en/light/details/image.html/content/dam/asset-share-commons/en/public/pictures/helena-hertz-256396.jpg
now add asset in TAB 2 to cart. now cart count is 1
now add asset in TAB 3 to cart. now again cart count is 1. this asset overriding asset added to cart in tab2.
Expected behavior At above step 4, cart count should be 2 instead of 1
Screenshots refer attached screenshot
cartIssue.docx