Data view data holder as a page

0
Hi, I have a requirement, where I need to show counts of few status attributes from an entity on the home page I have used microflow to calculate the counts as calculated value of these attributes. The home page is already having a data grid(Must have) using the same entity and I using a dataview connecting the same entity to get the counts. However I am getting error saying that you home page is expecting the entity and can’t be used as a home page. Does mendix restrict to use a page which usign dataview as a home page? How to make use of the dataview on homepage without creating or going for another home page sans dataview? Please help...it's urgent
asked
3 answers
1

You cannot directly use a data view on the homepage, because you need to pass the object in question to the page for it to work. To make it work, instead of using the page as your homepage, use a microflow as your homepage. You can then retrieve the object in your microflow and use a “show page” action to open that homepage, while passing the object as a parameter.

answered
1

Because your home page contains a data view, you will need to provide the object of data view’s entity when opening home page. This data view on the home page needs a data source. Just like when you open a new/edit page, it actually contains a data view which receives the object to edit. This is how data view works. It needs an entity passed to it.
In case of home page, you are not opening the page on click of button that you may pass an object from.

  • You need to change home page in navigation:
  • select call a microflow for home page action in navigation
  • From that microflow for home page, retrieve your entity, open home page using microflow activity and pass that entity
answered
0

Many thanks both Eline and Umar. Your quick response helped me to solve the problem.

 

Thank you.

answered