Say, there is a page /catalog which is a parent to all products. I can have permanent routes with pages, e.g. /catalog/product/1, /catalog/product/2 etc.
But a user can choose any other page to be a parent page for catalog products, e.g. /stock.
How can I render products data on a variable node, e.g. /{variable-page}/product/{id}?
It's easy with multiple pages for each product - just make a block 'product_list' to render all products on a parent page and a block 'product' to render each product on a child page of the product_list.
But I don't want a million pages. I need only 1 page to render DB content of any product under a parent page where its name and route can change.
Not sure it's the best way though... The following works. Now it doesn't matter which page has the product list, any child is taken care of at /whatever/product/uid
Controller:
View: