Power Apps - Dashboard Display Sequence

On Power Apps, I have a dashboard to display all orders made by users. The dashboard is to let users know their order status either their order is in "In Preparation", "Order Received" or "Completed" status. I am using SharePoint List as the data source. Below is the dashboard I have created.

enter image description here

There are two conditions that I like the dashboard to follow.

Order Date & Time: The latest order made by user will lead the flow of the menu on the dashboard screen. In this case, SMT 1 is the first order created by users and in SPL. Thus, dashboard will display the order made by SMT 1 first. Order Urgency: There are two levels of order urgency: Normal and Urgent. In this case, Urgent orders will override the order in first condition. For example, SMT 3 and SMT 4 orders. Even though SMT 3 made the order ahead than SMT 4, I would like the dashboard gives the priority to SMT 4 and display SMT 4 orders first, followed by SMT 3.

I am using gallery and container to make the dashboard anyway.

I`d appreciate if any of you guys could lend me some help and show me guidance on the solution to this issue.

Thank you.

7

1 Answer

You have to use the SortByColumns() function in Power Apps for such requirements.

For example, you can use the formula like below:

SortByColumns( SPListName, "OrderUrgency", SortOrder.Descending, "OrderDateTime", SortOrder.Ascending ) 

Where OrderUrgency and OrderDateTime are the internal names of your SharePoint list columns. You can get the internal name of your column by following this article: How to find the Internal name of columns in SharePoint Online?

9

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

You Might Also Like