Bananamoon wrote:Yay Error gone! Altho I have no clue what to do now, since I thought that this file would extend/overwrite this file:Code: Select all
Yes, it extends (no inheritance) the basket/mini component dynamically but doesn't overwrite it. You can now assign more data to the view and use it in the templates.
Bananamoon wrote:I'm at loss, I guess I made the wrong extension or something?
My main purpose is to show the products I put in my basket, instead of just the amount of products. I would like to add that to the cache so it loads quicker, so I figured I have to extend/overwrite above file and rewrite the _setViewParams.
OK, you have two options to fetch the product data depending on your basket content and display it:
1.) You can change your decorator to decorate the "basket/mini/main" subpart instead of the "basket/min" component so the resulting HTML will be cached. In this case you have to overwrite the existing "basket/mini/main" template and add your additional HTML code there, but this isn't the best option because this leads to a tight coupling of both and will make it hard to reuse it.
2.) Instead, I would recommend to create a new "basket/mini/product" subpart (https://aimeos.org/docs/Developers/Html_frontend/Create_new_subparts) that is independent of the "main" subpart. In that subpart, you have more freedom. This can be reused in other projects as well and we would love to get a pull request to integrate it into the core so you don't have to care about updates in the future