Skip to content

kkaraivanov/TourPortal

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

👓 Project Introduction


Tour Posrtal is my defense project for ASP.NET Core course at SoftUni (June-August 2021). The website is a part of a major project, that consists of 2 parts (TourPortal Client and TourPortal Server). Each of the two starts independently, giving functionality to a Single Page Application (SPA).


✏️ Overview


Tour Portal is a site that represents a platform for gathering people looking for a hotel to visit and hoteliers offering their services. By registering to the website, each user can choose a role between being a user or an owner so they can receive different functionality from the platform. The main idea is to organize a space in which businesses can get a working environment, offering and selling their services, and consumers having easy access to them..

Each hotel owner can register the services he offers, as well as his employees.

A employee of the hotel is a user who processes the bookings of services. A registered service is confirmed by the employee when a user who has booked a service visits the hotel. The employee cannot register his account in the platform.

Each user can search for services by criteria such as free date, number of beds, number of people and then can make a reservation for a selected service.


There is only one registered administrator in the platform. It receives information about registered users, services and reservations. The administrator can disable or delete entries in the system.

🔏 Used Roles


  • Administrator
  • Owner
  • Employe
  • User

🔨 Used technologies



📷 Screenshots


1. Unregistered users have these views

  • Home page
  • Register page
  • Login page
  • Menu options

2. Registered users have these views

  • Hotel page
  • Employe page
  • Profile view
  • Profile edit

🔧Setup of the application


To start the application you need to follow the following steps:

1. In appsethings.json file on the TourPortal.Server change the connection string to your database

{
 "ConnectionStrings": {
   "DefaultConnection": "Server=.\\YourServer;Initial Catalog=DbName;User Id=userName;Password=password;MultipleActiveResultSets=true"
 },

 "JwtSecurity": {
   "JwtSecurityKey": "set your secret key",
   "JwtIssuer": "https://localhost",
   "JwtAudience": "https://localhost",
   "JwtExpiryInDays": 10
 }
}

2. In wwwroot/appsethings.json file on the TourPortal.Client change the url to your TourPortal.Server host

{
 "apiUrl": "http://localhost:5000/"
}

3. In the Solution -> Set Startup Projects -> use radio button Multiple startup projects and selectеd the action for Cliend and Server to run simultaneously


🔧Setup of the layouts


The application uses two layouts for registered and unregistered users respectively. The default layout is the layout for unregistered users. All required CSS and JS libraries are loaded through the layout for registered users using the following code:

private async Task RemoveElementsFromTemplate(IJSObjectReference module)
{
   await module.InvokeVoidAsync("removeScripts");
    await module.InvokeVoidAsync("removeCss");
}

private async Task AddStyles(IJSObjectReference module)
{
   foreach (var cssPath in cssPaths)
   {
       await module.InvokeVoidAsync("addCss", cssPath);
   }
}

private async Task AddScripts(IJSObjectReference module)
{
   foreach (var scriptPath in scriptPaths)
   {
       await module.InvokeVoidAsync("addScripts", scriptPath);
   }
}

💎 Used templates

  • Picstudio – Photography Studio PSD Template
  • Pluto - Bootstrap Admin Dashboard

✍️ Author


Kostadin Karaivanov

      Discord