Likeat is a web application designed to allow users to manage, evaluate, and review restaurants. Built with a Java Spring Boot backend and a React (Vite) frontend, the platform ensures a smooth and secure user experience.
Restaurant owners can manage their listings, customers can leave reviews, and admins oversee operations. A fair ranking algorithm ensures unbiased restaurant ratings.
- Authentication & Authorization: Secure login using Spring Security & JWT.
- Restaurant Management: Owners can register, edit, and delete their restaurants.
- User Roles: Supports customers, restaurant owners, and admins.
- Restaurant Reviews: Customers can leave reviews and rate restaurants.
- Fair Ranking Algorithm: Ensures unbiased and fair restaurant ratings.
- Secure API Endpoints: Protected with role-based access control (RBAC).
- Modern UI: React (Vite) ensures a fast and responsive user experience.
- Java 11 or higher
- Maven 3.6.0+
- Spring Boot (with Spring Security & JWT)
- MySQL
- Node.js 14.x or higher
- npm 6.x or higher
- React Router for navigation
-
Clone this repository:
git clone https://github.com/aggsakellariou/Secure-Likeat.git
-
Navigate to the backend directory:
cd Likeat/backend-likeat -
Configure your database and JWT settings in
application.yml:spring: datasource: url: jdbc:mysql://localhost:3306/likeat username: your-username password: your-password application: security: jwt: secret: your-secret-key expiration: 86400000 # 1 day in milliseconds
-
Build the project using Maven:
mvn clean install
-
Run the backend:
mvn spring-boot:run
-
Navigate to the frontend directory:
cd Likeat/frontend-likeat -
Install dependencies:
npm install
-
Start the development server:
npm run dev
-
Access the backend API at
http://localhost:8443. -
Access the frontend at
http://localhost:5173. -
Register or log in to receive a JWT token.
-
Include the JWT token in the
Authorizationheader for protected API requests:Authorization: Bearer your-jwt-token -
User Roles:
- Customers: Browse restaurants, leave reviews.
- Restaurant Owners: Manage restaurant listings.
- Admins: Manage users and approve restaurants.
- Backend: Java, Spring Boot, Spring Security, JWT, Hibernate, MySQL
- Frontend: React, Vite, Axios, Bootstrap CSS
- Deployment: Docker, Render