This repository contains a ☕ Java Swing application.
This project needs to be run with its 🍃🥾 Spring Boot Web Server.
🟥 Please DO NOT COPY ANY CODE from this project! 🟥
This project is not intended to be open-source, feel free to use it as a reference but DO NOT FORK OR COPY!
If used as reference, please cite by providing link to project and author name (see section below).
Watch a quick demo of the project through the link below!
📼 Video Demo Link
This project is the final assignment for CMPT 213 (Dr. Victor Cheung) at SFU.
Main Screen
This project is a package delivery tracker. On program start, the user will be brought to a simple screen that has three lists: All Packages, Upcoming Packages, and Overdue Packages. Existing packages in the system will appear sorted from earliest delivery date. The screen will also show the current date and time, as well as a button for adding a package. If ADD PACKAGE button is clicked, a pop-up will appear that prompts the user to create a new package entry.
Packages
The user is able to add 3 different types of packages: Book, Perishable, and Electronic. Based on the delivery date added on package creation, it will be sorted under upcoming or overdue on the main screen. The user is able to mark padckage as delivered or remove the package on the main screen. On package removal, from any of the lists, the package will immediately be deleted from all lists. If the package is marked as delivered the package will only appear in the ALL PACKAGES list.
Saving and Exiting
If the user wants to delete a package, a pop-up will appear to confirm. If the user wants to exit, simply click the exit button and the program will automatically save the data to the server. The server will continue running if the client stops.
User needs to stop the server side by themselves! Exiting the client app will not terminate the server.
See video demo for more comprehensive walkthrough.
- Coded with OOP/D in mind.
- Fine-tuned OOP/D skills with this project.
- Practiced using MVC Model intentionally.
- Learned how to use Java's File Separator to account for backslash differences in different OS.
- Extensively used Java Swing's built in GUI Components to build UI
- Learned how to use JFrame, JPanels, etc.
- Created a lot of custom UI components through OOD concepts of Inheritance, Abstraction, and Polymorphism.
- Built simple Spring Boot web server to emulate the Client-Server Model.
- Practiced writing both front and backend code for this project.
- Practiced using CRC Cards and UML Diagrams to plan out code prior to writing code.
- This tag's folder has the documents.
- Practiced iterative programming as this project was completed in 4 different increments.
- UI is not 100% adaptive to different screen sizes.
- UI Pop-up windows are not centered on screen properly.
- UI Pop-up is not always responsive to changes.
- Package UI is not cohesive in width, some are longer and others are shorter.
- This causes information to be cut off from the screen at times.
- 🐞 There is a bug! Packages that turn overdue as the program is running does not automatically get marked as overdue.
- This minor bug is an error on the backend algorithm.
This project was created through IntelliJ.
- Windows OS or MacOS
- This project HAS BEEN tested on MacOS and does work.
- Windows 7 and up is recommended
- MacOS 10.12 and up is recommended.
- Latest version of IntelliJ
- Either Ultimate or Community version works.
The following steps are intended for use with the IntelliJ IDE
- Download this project as a ZIP file.
- Click 'Code' and then 'Download ZIP'.
- Unzip the main folder - 'package-delivery-tracker-client-master'.
- This may take a few minutes, make sure your machine has ample space!
- Open IntelliJ and select 'Open' or 'Open Project'.
- Locate where the unzipped folder from step 2 is on your machine. Click on the folder to open the project.
- Click 'Trust Project' when the pop-up appears.
- The project will now open.
- Configure the SDK by File > Project Structure > Project Settings > Project
- We will set the JDK, Language Level, and Compiler output here.
- Select JDK 18
- It is HIGHLY important that JDK 18 and up is used!
- Select 'Language Level' to be 18
- Or whichever JDK number you are using.
- Make sure 'Compiler output:' is set to the out folder
- It should already be set but if not make sure the path is ../package-delivery-tracker-client-master/out
- Go to Libraries which is also under Project Settings
- Click on the "+" button to add a library
- Click "Maven" from the library options
- Type 'com.google.gson' and click on the search button
- Select the newest gson library and click ok
- Version 2.9.1 was used to write this project
- Click 'OK' when pop-up comes up on adding 'client app' to module
- If asked to replace old libary, click CANCEL and the old libary will be added to path.
- Click 'Apply' and then 'OK'
- Click Run and the app will run properly. Make sure to run the server side of the program too!
- The console will print Status Codes on each operation.
- Usually 200, 201 are the SUCCESS codes that will print
- The console will print Status Codes on each operation.
All references are cited within the program's API.
However, there are a few external libraries used that should be noted:
Example of citing this project as a reference:
Reference used for creating MVC model: https://github.com/mrpthemrp/package-delivery-tracker-client/tree/master/src/cmpt213/assignment4/packagedeliveries/client
Date Accessed: August 2022
Developer: Deborah Wang
If using this project as a reference please copy and paste the following into your references/citations:
Reference for <code referenced>: <file/folder URL>
Date Accessed: <date accessed>
Developer: Deborah Wang (https://github.com/mrpthemrp)Last Code Update Date: August 2022
Copyright August 2022, Deborah Wang