@ppkantorski wrote:
Hello,
I am having trouble adding in and correctly calling upon the corresponding details in my program based upon the Ionic 4 Full Starter App template. For instance, when viewing the “Categories” section and clicking on “Food,” you are given a selection of restaurants. However when clicking on any of the restaurants, it will take you to the same restaurant details regardless of which restaurant you click. This appears to be the case for every entry in the Categories page. I tried to add details for the 2nd and 3rd restaurant in the details.json file, but that changes the structure of how it should be called. I tried making an items list in the details.json as follows:
{
“items”: [
{
“id”: 1,
…
},
{
“id”: 2
…
},
{
“id”: 3,
…
}
]
}but I cant seem to link the /app/categories/food/RESTAURANT_NAME to the corresponding data properly.
I also tried adding to the food-details.html page:
and calling on the details through the defined item variable, but this puts all 3 of my entries in the details.json file on every restaurant details page.
Can anyone please help me figure out how to properly link the data in the details.json file to the correct pages?
Posts: 1
Participants: 1