Skip to main content

3.8 - Test Find Books Dashboard

Last updated 12/06/2023

We have completed building the Find Books dashboard, so now would be a great time to run the Book Club application and test how it all works. We will use two member accounts so you can view what happens.

The members, Chelsea and Rick, will be used to demonstrate how the Find Books dashboard works for both members.

As this demonstration is being performed locally, we will need to perform the following workflow to see how the Book Club application is currently working:

  • Log in as Rick to search and request a book.
  • Log in as Chelsea to see the request notification and accept the request.
  • Log in as Rick again to see where the book is available to pickup.


tip
If you are working in the Cloud, you can just use different browsers for each member to prevent the need to log in and out of the Book Club application!


1. Click the Run button in Five's toolbar.


Run Button
Figure 1 - Run button


Sign In With the Member Rick

1. Type rick in the Username field.

2. Type Demo123! in the Password field.

3. Click the Sign In button.


Sign in as the Member Rick
Figure 2 - Sign in as the member Rick


info
On intial log in, you will see a list of all of Rick's books in the system.

4. Click Find Books in the menu.


Find Books Menu Item
Figure 3 - Find Books menu item


info
The Find Books menu holds the Find Books dashboard that we just created. Rick can either search for a book via the title or the ISBN for the book. The book/s will be returned if they are saved in the system.

5. Type TypeScript in the Title field.

6. Click the Search button.


Search Books
Figure 4 - Search books


tip
The SetSearchISBN function attached to the On Click event for the SEARCH button is executed when the SEARCH button is clicked! The function sets the variables ISBN, Title, and UserKey and calls refresh on the Book and iUser tables so the live query monitoring the table will re-execute.


info
All books with the word TypeScript in the title will be returned in the results. At the end of each row, the REQUEST BOOK button is available if the book is not already borrowed out. Four books are returned all owned by Chelsea.


Returned Books
Figure 5 - Books returned


7. Use the scroll if required and click the REQUEST BOOK button for the first record in the list.


tip
The RequestBook function attached to the On Click event for the REQUEST BOOK button is executed and calls the RequestBookServer function when the REQUEST BOOK button is clicked! The function will send a notification to the owner making a request for their book.


Request Book Button
Figure 6 - REQUEST BOOK button


info
An in-app message is sent to Rick informing him that his request for the book has been sent to the owner of the book.

8. Click the OK button.


OK Button
Figure 7 - OK button


9. Click the Avatar button.

10. Click the Logout button.


Log Out as the Member Rick
Figure 8 - Log out as the member Rick


Sign In With the Member Chelsea

1. Type chelsea in the Username field.

2. Type Demo123! in the Password field.

3. Click the Sign In button.


Sign in with the Member Chelsea
Figure 9 - Sign in as the member Chelsea



info
On Chelsea's sign in, she has a notification.

3. Click the Notifications bell.


Notifications Button
Figure 10 - Notifications button


Important
A request has been sent informing Chelsea that Rick would like to borrow her Mastering TypeScript 3 book. She could now find her book record for Mastering TypeScript 3 and edit the record and select Rick in the Borrow By field. We are not going to do this just yet as we need to add a table event to the Book table, this table event will execute when a Book record is updated and will send the member requesting the book (Rick) a notification as to where to pick the book up.

4. Click the Cancel button.


Cancel Button
Figure 11 - Cancel button


5. Click the Avatar button.

6. Click the Logout button.


Log Out as the Member Chelsea
Figure 12 - Log out as the member Chelsea


7. Click the Cancel button for the window and return to Five.