-
Notifications
You must be signed in to change notification settings - Fork 2
Android App Documentation
We created our android application in React Native. The application builds using gradle and js. Instructions on how to run the application on an android emulator are below.
- Start the android emulator from Android Studio via the AVD Manager
- Navigate to
LibrarySystem-Android/LibrarySystem/
- run
npm install
in terminal or cmd (with admin privileges) - run
npx react-native run-android
in terminal or cmd (with admin privileges)
If step 4 does not work, you can build the application and run the metro server using npm start
and then drag app-debug.apk from /LibrarySystem-Android
into the running emulator, and the application will start.
Upon opening the app, a user is greeted with this page, which shows the operating hours of the library, as well as three buttons. "See Items" directs them to the page with the catalog of items, "See Rooms" does the same for the rooms, and "Login" takes the user to the login page. Even if they are not logged in, the user is still able to view browse the items the library has to offer, as well as the rooms available for event rentals.
To access all the features available to them, the user can press the three horizontal lines in the top-left corner and a navigation menu will appear.
To navigate the application, the user can tap on the option of their choice on the navigation menu. If a user is not logged in, they will have the option to navigate to the Homepage, to the Browse Items page, to the Brose Rooms page, or to the login page, as seen in the image above.
The user can scroll through the catalogue or type in the search bar shown at the top of the image and press the "search" button (the magnifying glass) to the left of the search bar if they are looking for a particular item. Items can be searched by title or other relevant information. Information for each item, such as the item's title, description, and the image is provided for the user. As they are not logged in the user is only able to browse the item catalogue and nothing more.
The user can browse the rentable rooms in the library and see their capacity. As with Browse Items, the user can search for a specific room by typing the desired room name in the search bar at the top of the page and pressing the "search" button on its left.
Log in page | Sign up page |
---|---|
Once the patron is logged in, they are able to view all the pages they have access to.
Items Page | Reserve an Item | Reserved Successfully |
---|---|---|
Item Reservations | Renew Item Reservation | Cancel Item Reservation |
---|---|---|
Browse Rooms | Create Room Booking | Pick Date | Error message | Booking Created |
---|---|---|---|---|
The patron is able to view and search all rooms as shown in the not logged in documentation. In addition to that, they are able to make a room booking by clicking on the reserve button below the room of their choosing. The app directs the patron to a different screen on which the patron can choose the date, start time and end time of the booking. If all the inputs are valid, the room booking will be created and the patron is directed to the View Room bookings page. Otherwise, an error message will appear indicating the specific error, such as the start time is before the library opens.
View Room Bookings | Cancel Room Booking |
---|---|
On the View Room booking page, the patron is able to see all their room bookings with the room number, date, day of the week, and start and end time. They are able to cancel their room bookings by clicking on the cancel button on the room booking card of their choosing. Once they press cancel, a message pop ups informing them that the room booking is cancelled, and the screen automatically refreshes to reflect the change.
The user can access the Settings page from the Navigation Menu once they log in, regardless of whether they are logged in as a patron or librarian. In this page, they can see their current account details (first name, last name, address, email) and change these details. Once the user is done, they can press “save changes” to save their updated account details. This screen also allows the user to change their password. To do so, the user first needs to enter their current password, followed by their new password. Then they can press “change password” to update their password. If the password they entered for their current password is correct, and if the new password is valid, the password will be updated.
The patron can log out of their account by opening the nav bar and clicking on Log out.
For a librarian to login, they can click on the "login" button on the homepage and they will be directed to the login screen shown above. By entering their username and password and clicking on "LOGIN" they will be logged in. An example librarian, whose username and password are shown in the image, has been added to the database under the name "Jeff". Note that since the head-librarian does not have any additional features available to them in the android application, their usage is identical to that of a regular librarian.
To access the navigation menu, a librarian user presses on the three horizontal lines on the top-left corner of their screen. The menu shown in the image above will appear. In addition to the pages available to patrons, librarians can view a list of all librarians, a list of everyone's shifts, and create an account for a patron.
The user can scroll through a list of all librarians added to the system and view their name, email, and address displayed on individual cards. As well, there is a button (titled "View Their Shifts") to view an individual librarian's shifts at the bottom of each card. At the top of the page, the "View All Shifts" button directs the user to the "View All Shifts" page.
Upon pressing the "View Their Shifts" button for a certain librarian, a dialogue box pops up displaying a list of the librarian's shifts as shown in the image above for Kevin's shifts.
A librarian can navigate to this page by either pressing "View All Shifts" in the navigation menu or the button with the same title in the View Librarians page. They are presented with a list of all the scheduled shifts. The first name of users is used as the identifier, with the exception of the head-librarian, who shows up as "admin" for their shifts.
View All Patrons | Verify Patron | Delete Patron Successful | Delete Patron Failed |
---|---|---|---|
On the "View all Patrons" screen, the librarian is able to see all Patron accounts in the Library System. They can also search for a specific patron. In addition, librarians are able to verify a patron, as well as delete their account by pressing the verify and delete buttons under each patron, respectively. Once a patron is deleted or verified, a message pops up saying whether the action was carried out successfully or if there was an error and the page is updated to show the change. A patron with an existing item reservation or room booking cannot be deleted.
Sign Up In-Person Patron Account | Patron Signed Up Successfully |
---|---|
A librarian can go to the "Sign Up For Patron" screen from the navigation menu to sign up an in-person patron account for a patron who goes to the libarary in-person to make an account with the library. Once the account is made, the new patron is seen in the list of patrons in the "View All Patrons" screen.
The librarian can access the "View All Room Bookings" screen from the navigation menu and this screen would be the same as the "View Room Bookings" page for patron except that the librarian would be able to see all room bookings for all patrons that currently exist in the system and will also be able to cancel a room booking by pressing the "Cancel" button under a room booking.
The librarian can go to the "Browse Item Reservations" screen to see all existing Item Reservations for all patrons. They can also cancel an existing item reservation or renew it by pressing the "cancel" and "renew" buttons respectively.
Browse all Items | Reserve Item |
---|---|
A librarian can go to "Items" from the Navigation Menu and click on the reserve button under an item to access the "Reserve Item" screen shown above. Once in the this screen, the librarian can enter the patron's ID for whom they want to reserve the item and click submit to create the item reservation. The librarian can also click on return to return an item if it is checked out. If the item is not checked out, the system will let the librarian know by throwing an error.
Browse all Items | Checkout Item |
---|---|
When logged in as a librarian, the librarian can go to "Items" from the navigation menu and press on checkout to check out items for a patron, if there is no reservation for that item already. This will create an item reservation for them that will last two weeks. If there is a reservation and it is for the patron that would like to check it out, then it will simply update that reservation to state that it is checked out, and extend the reservation to two weeks from “today” if possible. If there was already a reservation for a different patron, the application will simply prevent the item from being checked out.
When logged in as a librarian, the librarian can browse all rooms - this view is identical to what a patron sees, with the exception of the added ‘Reserve’ buttons under each room card. Once the button is clicked, the librarian is prompted with the reserve room screen in which they can view the selected card, as well as input values for the patron’s id number, the date, start time and end time. Once the inputs are provided, the submit button can be pressed to finish the booking process.