##Purpose The backend serves as a interface between the frontend and the database server and provides the functionality for adding/deleting/updating/reading data from the server
Follow these steps to start the application
- Install OpenJDK 11 or higher and have the JAVA_HOME variable set
- Install Apache Maven 3.8.1 or higher
- Navigate to the root Directory of the Project
cd m223-helloworld-quarkus/
- Start the Application with
./mvnw compile quarkus:dev
If the command mentioned above does not work try to run the command without the "./"
Swagger API: http://localhost:8080/q/swagger-ui/
H2 Console: http://localhost:8080/h2/
JDBC URL: jdbc:h2:mem:punchclock
User Name: zli
Password: zli
The JPQL query with HAVING
is located in ExpenseService.getExpensesOver50() and is designed to return all Expenses with an amount that is greater than 50.
At start a script is run which inserts example data into the database
The data is as follows:
| id | title | | 1 | 'Admin' | | 2 | 'Projekte' | | 3 | 'IT-Support' |
| id | checkIn | checkOut | category_id | | 1 | '2021-09-30T07:16:14.807Z' | '2021-10-30T07:16:14.807Z' | 1 | | 2 | '2011-08-12T20:17:46.384Z' | '2011-09-11T20:17:46.384Z' | 2 | | 3 | '1989-03-30T07:16:14.807Z' | '1989-04-30T07:16:14.807Z' | 3 | | 4 | '2031-03-17T20:17:46.384Z' | '2001-02-13T20:17:46.384Z' | 2 |
| id | end | start | | 1 | '2021-09-30T07:16:14.807Z' | '2021-10-30T07:16:14.807Z' | | 2 | '2011-08-12T20:17:46.384Z' | '2011-09-11T20:17:46.384Z' | | 3 | '1989-03-30T07:16:14.807Z' | '1989-04-30T07:16:14.807Z' | | 4 | '2031-03-17T20:17:46.384Z' | '2001-02-13T20:17:46.384Z' |
| id | amount | receipt | | 1 | 67.50 | 'Vapiano-SihlCity' | | 2 | 69.25 | 'ArenaCinemas-SihlCity' | | 3 | 23.00 | 'BurgerKing-HauptBanhofZürich' | | 4 | 11.50 | 'Coop-SihlCity' | | 5 | 356.90 | 'GameStop-SihlCity' |
The Flutter frontend serves as a interface for the backend and as a way to create/edit/view/delete the entities of the database. The Flutter Application has only been tested on web but since the Flutter framework also works on IOS, Android and Windows the adjustments needed to get it working on additional operating systemns should not be too big.
Follow this guide to install Flutter:
Flutter-Install
if not already on Stable, switch to Flutter Channel Stable
flutter channel stable
Download FLutter 2.5.1 from the official Flutter releases page: Flutter releases 2.5.1
Some useful commands:
command | description |
---|---|
flutter help |
shows a list of commands Flutter supports |
flutter doctor |
check if you have installed Flutter correctly and if not tells you what to fix |
flutter --version |
gives you information about you flutter installation (Flutter verison, Flutter channel, Dart version...) |
flutter channel <CHANNEL_NAME> |
list available channels or add the channel name to switch to the given channel |
flutter run <DART_FILE> |
run a flutter app |
where flutter dart |
displays the path to the local instance of flutter & dart (omit "dart" to only display th flutter path) |
If you already have Chrome installed you should be able to start Flutter in web without any additional steps, so the steps below are some general Information.
Follow this guide to setup your Flutter app for web: Flutter-Build a web application
Some useful commands:
command | description |
---|---|
flutter create <PROJECT_NAME> |
to create a new project that includes web support |
flutter create . |
to add web support to an existing project |
flutter build web |
build the project for web |
flutter run |
to run a flutter project in web run the flutter app like normal and select a browser as a device to launch the app on |
To run the project:
flutter run
- proceed select the wanted device and the application will start