Page 1 of 1

Breadcrumbs bug

Posted: 29 Nov 2016, 10:07
by Pejka
Hello!
There seems to be a bug with the way breadcrumbs are handled, I'm using Laravel 5.1 but I think it's an unrelated aimeos issue.
If I navigate to a product in a regular fashion, that is first selecting a category, then a product, it works fine. If I then go to a different category, and select a different product, it also works fine. But, if I leave one of the product windows open, and in a new tab select a different category and/or product, refreshing the first page will show the newly selected category breadcrumbs.
Is there any way around this?
Thanks,
Máté

Re: Breadcrumbs bug

Posted: 29 Nov 2016, 18:51
by aimeos
It's not a bug but caused by keeping the last list page in the session so the detail and the basket component know where you come from (so you can get back).

Re: Breadcrumbs bug

Posted: 30 Nov 2016, 15:03
by Pejka
Actually I left it out, if you open a product's detail page directly, the breadcrumbs area simply displays 'search results'.
So yeah, it is buggy, breadcrumbs should display the full path to the current page regardless of where or how you arrived to the page.

Re: Breadcrumbs bug

Posted: 01 Dec 2016, 10:27
by aimeos
OK, seems we have a different understanding what breadcrumbs are for. We use it to give the users the chance to get back to the last category (or the categories up to the root) or to their last search result.

You want to always display the categories up to the root of the product, regardless of where the users comes from. This means they can't get back to their last search result. Also, most often products are in several categories. Which one would you choose in this situation?

Re: Breadcrumbs bug

Posted: 02 Dec 2016, 10:35
by Pejka
Yes, that's the goal. Multiple categories would be an issue, but in that case I guess you just pick one and move up the parent list up to level 0 (since categories can't have more than one parent as far as I can tell). Or maybe display multiple breadcrumbs, say, up to 3 if there are that many categories. At least in theory, since the current project doesn't require a product to be in more than 1 category.
If you stand by that that is how you actually want breadcrumbs to work, I'll just make my own logic for it. But I don't think I'm gonna be the only one who thinks otherwise, so maybe you should consider adding an option to use the other logic :)