Attribute a restaurant to each page

Hello Guys ,

Basically , I have a database with a list of restaurant . And one page for each restaurant in order to display the products of each restaurant .

I’m not able to link each page to the correct restaurant of my data type restaurant

Behavior target : When a user open a page the restaurant unique id is stored in the user .

Thank you very much for your time and help

Could you try to explain your use case a little better and why you’re not able to achieve the results you want? And why do you want to store the restaurant unique id in the user?

I’m going to assume you have a directory of restaurants and when a user clicks on a restaurant in the directory, it opens a page that displays all of the details relating to that restaurant.

To achieve that, you don’t need to store anything in the user.

Use 1 page which has 2 groups:

  1. One group contains the “directory” or list of restaurants
  2. Another group will display the restaurant information, with content type “restaurant”.

When the user clicks on one of the restaurants, hide the first group and display the second, and use a workflow action to set this restaurant as the source of the second group.

Populate the second group with all of the elements necessary to display your restaurant information.

@saas.paytab

Building on @project-monitor great advice:

  • Change the approach from one page per restaurant to a one page for all restaurants. Call it “restaurant” and make it of type of content “restaurant” … prior to this … make sure that you create a data type called “restaurant” in the database.
  • From your other page where you list your restaurants … on click of a restaurant row of the restaurante repeating group … use the action “go to page” and send the row-restaurant information to your “restaurant” page.

The following video should help you understand this approach with more detail (just replace baseball caps for … restaurants … when thinking through the logic presented in the video):

This topic was automatically closed after 70 days. New replies are no longer allowed.