Return to main view after click action button

Hello. I am using AppSheet to manage the patients in the ward.

In the main view, i have all the patients listed. When i click on a patient, it shows the details and have an action button to discharge the patient (what it does is to set [discharge] to TRUE. However, when i click it, the view keeps the same, and the collegues don’t understand that tha patients has been discharged.

So my question is if it’s possible to:

1 - after clicking the discharge action button, is possible to automaticaly go to the manin view?

2 - after clicking the discharge action button, is possible to automaticaly sync so the patient will disapear from the ward / main view?

Thank you

What you are looking for is possible using navigation actions and grouping actions.

Yes, for this

  1. Please create a navigation action called say “Go to Main View” of “Go to another view within this app” type action with an expression something like LINKTOVIEW(“Your Main View Name”)

A sample action (but with different view and table name )below

  1. Please create group action called say “Discharge Main” which has following two constituent actions

A sample action below

A) Set Discharge action that sets [Discharge] to TRUE. This action you have already created. Please set the prominence of this action as “do not display”

B) Set the navigation action “Go to Main View” created in Step 1 as the second action in the group action.

C) For this group action “Discharge Main”, set the condition as [Discharge]= FALSE or NOT([Discharge]) . This will ensure the group action displays only for the non discharged records.

Actions: The Essentials - AppSheet Help

App column type (deep link) - AppSheet Help

When you implement the above steps, further forced syncing is not required.

3 Likes