Make sure you are selecting the right language above.
-
On an emulator or mobile device, open another app, such as Chrome, which will cause the Wiz App to no longer be the foreground app.
-
If you now send another notification, you will notice that because the app is in the background, or not running, a notification is placed in the notification drawer.
-
Tapping the notification will bring the app to the foreground or open the app.
If the app was not running when the notification was tapped, due to a change made in the previous tutorial, you can view it by pressing Back and navigating from the Categories screen to the Entity list screen.
Currently, the message is displayed in a dialog with cancel action.
You can add custom logic to the app to decide on the action to take, such as displaying the new Office Furniture category.
For further information on push, see Push Notifications, Push API Notification Scenarios, and About FCM Messages.
Congratulations! You have seen how an app can make use of foreground and background notifications.